This document shows you how to enable format automation so you can create a single ad that automatically delivers multiple optimized ad formats.
Familiarize yourself with these topics to set up your ad campaigns for format automation:
page_manage_adsYou can use the format_transformation_spec paramter to opt-in to different types of formats and data sources used to build the formats.
Not including the format_transformation_spec in the creative spec will result in the default system behavior.
curl -X POST \
-F 'name="Ad Creative with Format Transformation Spec Sample"' \
-F 'object_story_spec={
"page_id": "<PAGE_ID>"
... // Fields to create a Advantage+ catalog ad carousel creative \
}' \
-F 'product_set_id=<PRODUCT_SET_ID>' \
-F 'asset_feed_spec= {
"ad_formats": [
"CAROUSEL",
"COLLECTION"
],
"optimization_type": "FORMAT_AUTOMATION"
}' \
-F 'format_transformation_spec=[{
"data_source": ["catalog"],
"format": "da_collection"
}]' \
-F 'access_token=<ACCESS_TOKEN>' \
https://graph.facebook.com/v24.0/act_<AD_ACCOUNT_ID>/adcreatives
| Name | Description |
|---|---|
| Required. |
| Optional.
Note: Not including the |
To opt into format automation, specify the format transformations format:
"format_transformation_spec": [
{
"format": "da_collection",
}
]
To opt-out of all transformations and data sources, set the data_source parameter to none:
"format_transformation_spec": [
{
"format": "da_collection",
"data_source": ["none"],
}
]
To opt into the catalog data source set the data_source parameter to catalog:
"format_transformation_spec": [
{
"format": "da_collection",
"data_source": ["catalog"]
}
]
Leave the data_source field empty to opt into all data_sources:
"format_transformation_spec": [
{
"format": "da_collection",
"data_source": []
}
]
To check your ad, make an API call requesting the format_transformation_spec:
curl -G \
-d 'fields=format_transformation_spec' \
-d 'access_token=<ACCESS_TOKEN>' \
https://graph.facebook.com/v24.0/<CREATIVE_ID>
{
{
"format_transformation_spec": [
{
"data_source": ["catalog"]
"format": "da_collection"
}]
},
"id": <AD_CREATIVE_ID>
}