Skip to main content
PATCH
Update a brand asset

Authorizations

X-API-Key
string
header
required

Path Parameters

id
string<shortuuid>
required

URL-safe brand identifier.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
asset_id
string<shortuuid>
required

Identifier of the asset, as listed.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$

Body

application/json

Payload to change an asset's details: send only the fields you are changing. The file itself is replaced by uploading a new asset and deleting this one.

asset_type
enum<string> | null

Kind of asset: logo, banner, icon, document or other. Changing it to logo, banner or icon checks the stored file is an image Closient accepts, and refuses with 422 if it is not.

Available options:
logo,
banner,
icon,
document,
other
title
string | null

Title, up to 255 characters.

Maximum string length: 255
Pattern: ^[^\x00]{0,255}$
description
string | null

Description.

Maximum string length: 5000
Pattern: ^[^\x00]{0,}$
is_primary
boolean | null

Make this the brand's primary asset of its type, demoting the current one.

Response

OK

One file in a brand's media library.

id
string<shortuuid>
required

Identifier of the asset.

Required string length: 22
Pattern: ^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$
asset_type
enum<string>
required

Kind of asset: logo, banner, icon, document or other.

Available options:
logo,
banner,
icon,
document,
other
title
string
required

Optional title; empty when none was given.

description
string
required

Optional description; empty when none was given.

is_primary
boolean
required

Whether this is the brand's primary asset of its type. Each type has at most one.

url
string
required

URL the file can be downloaded from.

width
integer | null
required

Width in pixels of a logo, banner or icon; null for other types.

height
integer | null
required

Height in pixels of a logo, banner or icon; null for other types.

created
string<date-time>
required

ISO-8601 upload timestamp.

modified
string<date-time>
required

ISO-8601 last-modified timestamp.