Request Thread Control API Reference

To use the Handover Protocol, the Graph API version should be set to 2.6 or greater.

Part of the Handover Protocol, request thread control allows a Secondary Receiver app to ask for control of a specific thread. The Primary Receiver app will receive a messaging_handovers webhook event with the request_thread_control property when/request_thread_control` is called.

Contents

Request URI

To thread control, make a POST request to

https://graph.facebook.com/v2.6/me/request_thread_control?access_token=<PAGE_ACCESS_TOKEN>

Example Request

curl -X POST -H "Content-Type: application/json" -d '{
  "recipient":{"id":"<PSID>"},
  "metadata":"additional content that the caller wants to set" 
}' "https://graph.facebook.com/v2.6/me/request_thread_control?access_token=<PAGE_ACCESS_TOKEN>"

Example Response

{
  "success":true
}

Properties

Property Type Description

recipient

Object

recipient object

recipient.id

Integer

The PSID of the message recipient.

metadata

String

Optional. Metadata passed back to the secondary app in the take_thread_control webhook event.

Error Codes

For error codes see this page.