You can add interactive elements so people can engage in your Instagram ads.
The instagram_actor_id
field for the act_<AD_ACCOUNT_ID>/adcreatives
has been deprecated for v22.0 and will be deprecated for all versions January 20, 2026. Please migrate your API calls to use the instagram_user_id
field.
Learn more in the
v22.0 API Changelog
and
our News for Developers blog post.
You can add product tags to your ads, using the product_tag_spec
under interactive_components_spec
. Under component
, you will need to specify:
type
as product_tag
product_id
under product_tag_spec
x
and y
parameters of position_spec
x
and y
parameters are required for image ads and optional for video ads. Sample of a single interactive_components_spec
feed image/video media
curl \
-F 'name=Sample Creative TESTING' \
-F 'object_story_spec={
"link_data": {
"link": "https://www.facebook.com/",
"attachment_style": "link",
"call_to_action": {
"value": {},
"type": "LEARN_MORE"
},
"image_hash": "IMAGE_HASH",
"image_crops": {},
"preferred_image_tags": {},
"media_elements": {},
"customization_rules_spec": {},
"retailer_item_ids": {},
"collection_thumbnails": {}
},
"page_id": "PAGE_ID",
"instagram_user_id": "<IG_USER_ID>"
}
' \
-F 'interactive_components_spec={
"components": [
{
"type": "product_tag",
"product_tag_spec": {
"product_id": 4382881195057752
},
"position_spec": {
"x": 0.5,
"y": 0.5,
}
}
]
}' \
-F 'access_token=<ACCESS TOKEN>' \
https://graph.facebook.com/v22.0
/act_<AD_ACCOUNT_ID>/adcreatives
Sample of multiple interactive_components_spec
objects for feed carousel media
curl \
-F 'name=Sample Creative TESTING' \
-F 'object_story_spec={
"link_data": {
"link": "https://www.facebook.com/",
"attachment_style": "link",
"call_to_action": {
"value": {},
"type": "LEARN_MORE"
},
"image_hash": "IMAGE_HASH",
"image_crops": {},
"preferred_image_tags": {},
"media_elements": {},
"customization_rules_spec": {},
"retailer_item_ids": {},
"collection_thumbnails": {}
},
"page_id": "PAGE_ID",
"instagram_user_id": "<IG_USER_ID>"
}' \
-F 'interactive_components_spec={
"child_attachments": [
{
"components": [
{
"type": "product_tag",
"position_spec": {
"x": 0.5,
"y": 0.5
},
"product_tag_spec": {
"product_id": 4382881195057752
}
}
]
},
{
"components": [
{
"type": "product_tag",
"position_spec": {
"x": 0.2,
"y": 0.8
},
"product_tag_spec": {
"product_id": 4382881195057752
}
}
]
},
{
"components": [
{
"type": "product_tag",
"position_spec": {
"x": 0.3,
"y": 0.7
},
"product_tag_spec": {
"product_id": 4382881195057752
}
}
]
}
]
}'\
-F 'access_token=<ACCESS TOKEN>' \
https://graph.facebook.com/v22.0
/act<AD_ACCOUNT_ID>/adcreatives
You can get information about the product_id
in your product_tag_spec
object from an ad creative you created with the product_tag
type.
To retrieve the product_tag_spec
information from your ad creative:
curl -G \
-d "fields=interactive_components_spec" \
-d "access_token=<ACCESS_TOKEN>" \
"https://graph.facebook.com/v22.0
/<AD_CREATIVE_ID>"
Sample Response
{ "interactive_components_spec": { "components": [ { "position_spec": { "x": 0.5, "y": 0.5 }, "type": "PRODUCT_TAG", "product_tag_spec": { "product_id": "4382881195057752" } } ] }, "id": "23862467608880374" }
This feature automatically tags best-matched products from the your product catalog when you create ads using single images or carousel images you've uploaded and applies the relevant product tags to ads.
The automated tagging ad system detects matches in two ways:
If product tags are specified in the interactive_components_spec
parameter, the automated tagging feature will be disabled for the ad to respect product tags that are specified by you.
Note: This feature is enabled by default. Set enroll_status
to opt_out
in the interactive_components_spec
parameter to opt out of the feature per product item.
"interactive_components_spec": { "components": [ { "type": "product_tag", "enroll_status": "opt_out" } ] }
Note: You cannot set enroll_status
and product_tag_spec
at the same time; it will return an error.