Update affiliate media
PUT/affiliate-manager/:locationId/media/:mediaId
Update a media file or folder for a location.
Request
Version stringrequired
API Version
Available options
v3locationId stringrequired
Location Id
mediaId stringrequired
Media Id
- application/json
- Body
- Example (auto)
Bodyrequired
namestring
Updated file or folder name
parentIdstring
Updated parent folder identifier
{
"name": "File/Folder Name",
"parentId": "63d376de11be1d26d38f7369"
}
Successful response
- application/json
- Schema
- Example (auto)
Schema
_idstring
Media identifier
locationIdstring
Location identifier
namestring
Media name
typestring
Media type
Available options
folderfileparentIdstring
Parent folder identifier
altIdstring
Alternative identifier
altTypestring
Alternative identifier type
contentTypestring
Content type
urlstring
Media URL
sizenumber
Media size in bytes
campaignIdsstring[]
Campaign identifiers associated with the media
campaignsobject[]
Campaigns associated with the media
deletedboolean
Whether the media is deleted
createdAtstring<date-time>
Creation time
updatedAtstring<date-time>
Last update time
{
"_id": "63d376de11be1d26d38f7369",
"locationId": "ve9EPM428h8vShlRW1KT",
"name": "brand-logo.png",
"type": "file",
"parentId": "63d376de11be1d26d38f7369",
"altId": "ve9EPM428h8vShlRW1KT",
"altType": "media",
"contentType": "image/png",
"url": "https://example.com/brand-logo.png",
"size": 45678,
"campaignIds": [
"63d376de11be1d26d38f7369"
],
"campaigns": [
{
"_id": "63d376de11be1d26d38f7369",
"name": "Summer campaign"
}
],
"deleted": false,
"createdAt": "2024-01-01T00:00:00.000Z",
"updatedAt": "2024-01-01T00:00:00.000Z"
}