Skip to main content
PUT
/
api
/
v1
/
media
/
{media_id}
Update Media Asset
curl --request PUT \
  --url http://localhost:8000/api/v1/media/{media_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "tags": [
    "<string>"
  ],
  "alt_text": "<string>"
}
'
{
  "id": 123,
  "filename": "<string>",
  "url": "<string>",
  "file_size": 123,
  "mime_type": "<string>",
  "source_type": "upload",
  "date_added": "2023-11-07T05:31:56Z",
  "date_updated": "2023-11-07T05:31:56Z",
  "width": 123,
  "height": 123,
  "external_id": "<string>",
  "external_metadata": {},
  "tags": [
    "<string>"
  ],
  "alt_text": "<string>"
}

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

media_id
integer
required

Query Parameters

company_id
integer
required

Company ID

Body

application/json
tags
string[] | null

Optional new tags list

alt_text
string | null

Optional new alt text

Response

Successful Response

id
integer
required
filename
string
required
url
string
required
file_size
integer
required
mime_type
string
required
source_type
enum<string>
required
Available options:
upload,
stock,
ai_generated
date_added
string<date-time>
required
date_updated
string<date-time>
required
width
integer | null
height
integer | null
external_id
string | null
external_metadata
External Metadata · object
tags
string[]
alt_text
string | null