Edit the metadata of a set of Assets by the specified assets selector.
Use the BY_IDS selector to edit a specific list of Asset.ids, or the BY_CRITERION selector to edit a search criterion, e.g. all Assets in a specific folder. See AssetSearch for more detail on the available criterion.
metadataFieldValueUpdates also has two types of objects that can be used. For example, a FieldOption with a value of "My Option" and an id of "3ba2cb5b-dbe9-48ed-8e07-71f26929e617" can be set either BY_VALUES by using the value "My Option", or BY_IDS by using the id "3ba2cb5b-dbe9-48ed-8e07-71f26929e617". For Fields that do not have FieldOptions (e.g. text fields), either type can be used.
Metadata field value changes to apply to each selected asset. Defaults to no metadata field changes, allowing a request to only apply a variantCriterionUpdate.
Variant criteria change to apply to each selected asset. Omit or set to null to leave each selected asset's variant criteria unchanged.
SET fully replaces each selected asset's variant criteria with the provided list, creating them where none exist. REMOVE deletes all of each selected asset's variant criteria and is a no-op for assets without any.
- Productionhttps://api-v2.dash.app/asset-metadata-edit-batch-jobs
- Staginghttps://api-v2.dashstaging.app/asset-metadata-edit-batch-jobs
- Metadata only
- Variant criterion SET only
- Metadata and variant criterion SET
- Variant criterion REMOVE
curl -i -X POST \
https://api-v2.dash.app/asset-metadata-edit-batch-jobs \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"selector": {
"type": "BY_IDS",
"ids": [
"9e5d1db4-719d-4d61-97c8-f7fd7eec9b8a"
]
},
"metadataFieldValueUpdates": [
{
"type": "BY_IDS",
"operation": "SET",
"fieldId": "3bb4e180-46df-4738-a836-6c2e1685dc2a",
"ids": [
"0f85e50b-3b24-44e0-954d-22557fdfebc7"
]
}
]
}'Success
Unique identifier of the job that has been created
The ID of the account the job is happening in
The ID of the User who created the job
- IN_PROGRESS
- COMPLETED
- FAILED
- In progress
- Complete
{ "id": "be161977-d44e-4888-af3c-66522e223963", "accountId": "cfb665ca-ce35-4418-b9d5-70ee815db4bd", "creatorId": "google-oauth2|110955770826801837334", "type": "IN_PROGRESS", "status": "PENDING", "progress": { "steps": [ … ] } }