Each step of a CTMLG lead gen message template
GET /v25.0/{messenger-ads-partial-automated-step-id} HTTP/1.1
Host: graph.facebook.com/* PHP SDK v5.0.0 */
/* make the API call */
try {
// Returns a `Facebook\FacebookResponse` object
$response = $fb->get(
'/{messenger-ads-partial-automated-step-id}',
'{access-token}'
);
} catch(Facebook\Exceptions\FacebookResponseException $e) {
echo 'Graph returned an error: ' . $e->getMessage();
exit;
} catch(Facebook\Exceptions\FacebookSDKException $e) {
echo 'Facebook SDK returned an error: ' . $e->getMessage();
exit;
}
$graphNode = $response->getGraphNode();
/* handle the result *//* make the API call */
FB.api(
"/{messenger-ads-partial-automated-step-id}",
function (response) {
if (response && !response.error) {
/* handle the result */
}
}
);/* make the API call */
new GraphRequest(
AccessToken.getCurrentAccessToken(),
"/{messenger-ads-partial-automated-step-id}",
null,
HttpMethod.GET,
new GraphRequest.Callback() {
public void onCompleted(GraphResponse response) {
/* handle the result */
}
}
).executeAsync();/* make the API call */
FBSDKGraphRequest *request = [[FBSDKGraphRequest alloc]
initWithGraphPath:@"/{messenger-ads-partial-automated-step-id}"
parameters:params
HTTPMethod:@"GET"];
[request startWithCompletionHandler:^(FBSDKGraphRequestConnection *connection,
id result,
NSError *error) {
// Handle the result
}];| Field | Description |
|---|---|
idnumeric string | The id of the object |
allow_to_skipbool | This boolean determines whether a user is given the option to skip a question |
answer_crm_field_idslist<string> | List of crm field ids for answers. These map to answers field |
answer_validation_enabledbool | This boolean determines whether Answer Validation should be enabled |
answerslist<string> | List of potential answers user can give |
carousel_answerslist<MessengerAdsPartialAutomatedStepCarouselAnswerType> | List of potential answers user can give if carousel options is selected |
crm_field_idstring | FieldID which will be used to submit answer to CRM |
ctaMessengerAdsPartialAutomatedStepMessengerAdsPartialAutomatedCtaShape | All data necessary to add CTA to step |
invalid_reply_textstring | Message text sent to the user when they reply with an invalid answer. |
media_contentstring | Hash or id of the media content of the broadcast message |
media_typeenum | Media type of the broadcast message |
messagestring | Message sent to user in this step |
next_step_idslist<numeric string> | List of next steps. These map to answers above |
options_formatenum | Format option for multiple choice options |
prefill_typeenum | Type of prefill expected: email, zip code etc |
qualifying_answers_listlist<string> | List of advertiser-designated valid answers that are used to determine whether or not a lead should be disqualified. Currently being used for ZIP code disqualification. |
reply_typeenum | Type of Reply expected: Quick Replies, Prefill etc |
step_list | StepList this step belongs to |
step_typeenum | Type of Step: Question/Confirmation etc |
| Error | Description |
|---|---|
| 100 | Invalid parameter |