You can assign tags to your creative assets: images and videos.
You can add a creative assets tag to a creative making a POST
request to the {business-image-id}/creative_asset_tags
or {business-video-id}/creative_asset_tags
endpoints. Include the parameters business-id
and tag_name
in your call.
Example request:
curl -i -X POST \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_IMAGE_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&tag_name=<TAG_NAME>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "success": true }
Example request:
curl -i -X POST \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_VIDEO_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&tag_name=<TAG_NAME>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "success": true }
Remove a tag from a business image and business video by sending a DELETE
request to the {business-image-id}/creative_asset_tags
or {business-video-id}/creative_asset_tags
endpoints. Include parameters business-id
and tag_name
.
Example request:
curl -i -X DELETE \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_IMAGE_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&tag_name=<TAG_NAME>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "success": true }
Example request:
curl -i -X DELETE \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_VIDEO_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&tag_name=<TAG_NAME>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "success": true }
To see tags associated with a specific image and video, send a GET
request to the {business_image_id}/creative_asset_tags
or {business_video_id}/creative_asset_tags
edges. Specify business_id={business_id}
in your call.
Example request:
curl -i -X GET \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_IMAGE_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "data": [ { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" } ] }
Example request:
curl -i -X GET \ "https://graph.facebook.com/v<API_VERSION>/<BUSINESS_VIDEO_ID>/creative_asset_tags?business_id=<BUSINESS_ID>&access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "data": [ { "name": "<TAG_NAME>" } ] }
To see all existing creative asset tags within business, send a GET
request to the {business_id}/creative_asset_tags
edge.
Example request:
curl -i -X GET \ "https://graph.facebook.com/v5.0/<BUSINESS_ID>/creative_asset_tags?access_token=<ACCESS_TOKEN>"
Example of a successful response:
{ "data": [ { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" }, { "name": "<TAG_NAME>" } ] }
POST
Endpoint | Description |
---|---|
| Add a creative asset tag to an image. |
| Add a creative asset tag to a video. |
READ
Endpoint | Description |
---|---|
| Get all creative asset tags associated with an image. |
| Get all creative asset tags associated with a video. |
| Get all creative asset tags from a specific business. |
DELETE
Endpoint | Description |
---|---|
| Remove a creative asset tag from an image. |
| Remove a creative asset tag from a video. |