Update media

Updates an existing media file by its ID.

You can update the file metadata (name, folder) or replace the file content entirely.

Path Parameters

ParameterTypeRequiredDescription
idintegerYesMedia unique identifier

Body Fields

FieldTypeRequiredDescription
namestringNoFile name with extension
mimestringNoMIME type (required if replacing file)
folderstringNoFolder/category for organization
filestringNoBase64-encoded file data to replace the file

Response Fields

FieldTypeDescription
idintegerMedia unique identifier
namestringFile name
urlstringPublic URL to access the file
mimestringMIME type
folderstringFolder/category
pathstringStorage path
thumbnailstringThumbnail URL
thumbPathstringThumbnail storage path
createdAtdatetimeCreation timestamp
updatedAtdatetimeLast update timestamp

Response

  • 200 OK: Media successfully updated
  • 400 Bad Request: Invalid request body or validation error
  • 401 Unauthorized: Invalid or missing API key
  • 404 Not Found: Media not found
Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…
Path Params
integer
required
Body Params
string
string
Responses
200

Resource updated

400

Bad request

401

Unauthorized

404

Resource not found

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here!