curl --request PATCH \
--url https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"is_primary": true,
"title": "Summer banner"
}
'import requests
url = "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}"
payload = {
"is_primary": True,
"title": "Summer banner"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({is_primary: true, title: 'Summer banner'})
};
fetch('https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'is_primary' => true,
'title' => 'Summer banner'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}"
payload := strings.NewReader("{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}"
response = http.request(request)
puts response.read_body{
"asset_type": "banner",
"created": "2026-06-01T09:00:00Z",
"description": "Homepage hero for the summer range.",
"height": 400,
"id": "kL2mN4pQ6rS8tV3wX5yZ7a",
"is_primary": true,
"modified": "2026-06-19T14:30:00Z",
"title": "Summer banner",
"url": "https://media.closient.com/brands/assets/summer-banner.png",
"width": 1600
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "unrecognized image bytes from uploaded file",
"reason": "invalid_content_type"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}Update a brand asset
Change an asset’s type, title, description or primary flag. Send only the fields you are changing; null is refused with 422. A logo, banner or icon must be an image Closient accepts, read from the file’s own bytes and never its name or declared type: JPEG, PNG, GIF, WebP or BMP, at most 20 MB and 8000 px on either side. Anything else is refused with 422 and a machine-readable reason, and nothing is stored. A document or other asset may be any file. Requires the Owner, Manager or Editor role; a read-only key is refused with 403.
curl --request PATCH \
--url https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id} \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <api-key>' \
--data '
{
"is_primary": true,
"title": "Summer banner"
}
'import requests
url = "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}"
payload = {
"is_primary": True,
"title": "Summer banner"
}
headers = {
"X-API-Key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {'X-API-Key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({is_primary: true, title: 'Summer banner'})
};
fetch('https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'is_primary' => true,
'title' => 'Summer banner'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}"
payload := strings.NewReader("{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("X-API-Key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}")
.header("X-API-Key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://www.closient.com/brands/api/v1/brands/{id}/assets/{asset_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["X-API-Key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"is_primary\": true,\n \"title\": \"Summer banner\"\n}"
response = http.request(request)
puts response.read_body{
"asset_type": "banner",
"created": "2026-06-01T09:00:00Z",
"description": "Homepage hero for the summer range.",
"height": 400,
"id": "kL2mN4pQ6rS8tV3wX5yZ7a",
"is_primary": true,
"modified": "2026-06-19T14:30:00Z",
"title": "Summer banner",
"url": "https://media.closient.com/brands/assets/summer-banner.png",
"width": 1600
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}{
"detail": "unrecognized image bytes from uploaded file",
"reason": "invalid_content_type"
}{
"detail": "The requested resource was not found.",
"error_code": "not_found",
"retryable": false,
"status": 404,
"timestamp": "2026-03-31T12:00:00+00:00",
"title": "Not Found",
"type": "https://closient.com/docs/errors/not_found"
}Authorizations
Path Parameters
URL-safe brand identifier.
22^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$Identifier of the asset, as listed.
22^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$Body
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.
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.
logo, banner, icon, document, other Title, up to 255 characters.
255^[^\x00]{0,255}$Description.
5000^[^\x00]{0,}$Make this the brand's primary asset of its type, demoting the current one.
Response
OK
One file in a brand's media library.
Identifier of the asset.
22^[23456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz]{22}$Kind of asset: logo, banner, icon, document or other.
logo, banner, icon, document, other Optional title; empty when none was given.
Optional description; empty when none was given.
Whether this is the brand's primary asset of its type. Each type has at most one.
URL the file can be downloaded from.
Width in pixels of a logo, banner or icon; null for other types.
Height in pixels of a logo, banner or icon; null for other types.
ISO-8601 upload timestamp.
ISO-8601 last-modified timestamp.