Update: Private Replies no longer need to be sent using the Human Agent Message Tag for Graph API v8.0+.
Private Replies allows Businesses to reply to comments made on their posts with a single message on Instagram. When using this feature, the user will get a message with a reference link to the comment that is getting the reply. Private replies are allowed within 7 days, excepting Instagram Live, of the creation date of the comment. Please note that Private Replies do not open the 24 hour window for standard messaging.
This API will need a reference to comment id. Those references are typically obtained via webhook subscriptions to the Instagram feed field, to get this subscription the instagram_manage_comments permission must be present on the Page Access Token used when calling the subscribed_apps endpoint. See Instagram Webhooks.
curl -X POST -H "Content-Type: application/json" -d '{
"recipient": {
"comment_id": "17865799348089039"
},
"message": {
"text": "Thanks for liking our logo! How can I help?"
},
}' "https://graph.facebook.com/v12.0/me/messages?access_token=PAGE_ACCESS_TOKEN"
Starting Nov 9th, 2021 Private Reply will be supported on Instagram Live
Private Reply for Instagram Live has a different reply window from regular post comments private reply. Private reply for IG live can only be triggered while the live is happening and will no longer be valid as soon as the live ends. To support Private Reply on Instagram Live, developers can follow the following instructions:
live_comments
webhook field under Instagram topic on the developer app dashboard and have completed app review for instagram_manage_comments
permission.GET /{ig-comment-id}
to get the relevant details).Optionally, we have also provided several new endpoints related to IG live that could be leveraged for Private Reply or other use cases.
GET /live-media
to retrieve list of IG live media.GET /{ig-media-id}?fields={fields}
now supports IG live media to allow developers to get details of the IG live media and comments(only available while live is ongoing).GET /{ig-comment-id}?fields={fields}
now supports IG live comments during the live and several new fields (from.id
, from.username
, media.id
, media.media_product_type
, id.parent_id
).