Skip to content

Update an existing photo

Request

Update metadata of a photo identified by its uberall unique id. Only metadata fields are supported here (e.g., type, description, identifier, crop values, sourceUrl). The photo file/content cannot be replaced via this endpoint. Each location can contain only one photo of a given type. If a photo of that type already exists, the request will fail.

Security
X-API-KEY or Authorization
Path
idstringrequired

The uberall unique id of the photo

Bodyapplication/jsonrequired

The photo metadata to update

identifierstring

Client-defined identifier. Must be unique per location

typestring

Photo type

Enum:"MAIN""DOCTOR_COM_PORTRAIT""LOGO""STOREFINDER_LOGO""SQUARED_LOGO""LANDSCAPE""STOREFINDER_COVER""FACEBOOK_LANDSCAPE""APPLE_LANDSCAPE""MENU"
descriptionstring, <= 255 characters

Optional description

sourceUrlstring

Original/source URL of the image. Not used to upload a new file.

cropOffsetXinteger, (int32)

Horizontal crop offset in pixels

cropOffsetYinteger, (int32)

Vertical crop offset in pixels

cropHeightinteger, (int32)

Crop height in pixels

cropWidthinteger, (int32)

Crop width in pixels

curl -i -X PATCH \
  'https://uberall.com/api/photos/{id}' \
  -H 'Content-Type: application/json' \
  -H 'X-API-KEY: YOUR_API_KEY_HERE' \
  -d '{
    "identifier": "string",
    "type": "MAIN",
    "description": "string",
    "sourceUrl": "string",
    "cropOffsetX": 0,
    "cropOffsetY": 0,
    "cropHeight": 0,
    "cropWidth": 0
  }'

Responses

The photo has been updated

Bodyapplication/json
statusstringrequired
Enum:"SUCCESS""PENDING""QUOTA_LIMIT_EXCEED""NOT_AUTHORIZED""FORBIDDEN""BAD_ACCESS_TOKEN""BAD_PRIVATE_KEY""BAD_PUBLIC_KEY""MISSING_PARAMETER""INVALID_PARAMETER"
messagestring

(optional) Holds further information about the response

warningsArray of strings

(optional) Holds further warnings

responseobjectrequired

The actual response object of the response

Response
{ "status": "SUCCESS", "message": "string", "warnings": [ "string" ], "response": { "photo": {} } }