Update an asset's alt text
curl --request PATCH \
--url https://wisepim.com/api/public/v1/assets/{asset_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"alt_text": "<string>"
}
'import requests
url = "https://wisepim.com/api/public/v1/assets/{asset_id}"
payload = { "alt_text": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({alt_text: '<string>'})
};
fetch('https://wisepim.com/api/public/v1/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"filename": "<string>",
"mime_type": "<string>",
"file_size": 123,
"width": 123,
"height": 123,
"url": "<string>",
"thumbnail_url": "<string>",
"alt_text": "<string>",
"source_url": "<string>",
"products": [
{
"product_id": 123,
"position": 123,
"is_main": true
}
],
"products_truncated": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>",
"detail": [
{}
]
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}Update an asset
PATCH /assets/: set or clear an asset’s alt text, in one language or per locale. Requires assets:write.
PATCH
/
api
/
public
/
v1
/
assets
/
{asset_id}
Update an asset's alt text
curl --request PATCH \
--url https://wisepim.com/api/public/v1/assets/{asset_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"alt_text": "<string>"
}
'import requests
url = "https://wisepim.com/api/public/v1/assets/{asset_id}"
payload = { "alt_text": "<string>" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({alt_text: '<string>'})
};
fetch('https://wisepim.com/api/public/v1/assets/{asset_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"id": "<string>",
"filename": "<string>",
"mime_type": "<string>",
"file_size": 123,
"width": 123,
"height": 123,
"url": "<string>",
"thumbnail_url": "<string>",
"alt_text": "<string>",
"source_url": "<string>",
"products": [
{
"product_id": 123,
"position": 123,
"is_main": true
}
],
"products_truncated": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>",
"detail": [
{}
]
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}{
"error": "<string>",
"request_id": "<string>",
"code": "<string>"
}Authorizations
Use a project API key from Settings > API Access. Send it as Authorization: Bearer wpk_.... See authentication and scopes for setup and permissions.
Headers
Body
application/json
Response
OK

