Get Messenger Profile
Returns the ice breakers and persistent menu of a Facebook Page's Messenger.
GET
Bearerheader
AuthorizationBearer <op_>Workspace API key, sent as Authorization: Bearer op_... Keys are created in the dashboard.
id*stringLength
1 <= lengthMessenger profile
application/json- response
accountId*stringiceBreakers*array<>Questions shown when a conversation starts.
persistentMenu*array<>Menu items shown in every conversation.
Example Request
import { Configuration, AccountsApi } from "@onepostly/sdk";const accountsApi = new AccountsApi( new Configuration({ accessToken: process.env.ONEPOSTLY_API_KEY }));const response = await accountsApi.getMessengerProfile({ id: "acc_YOUR_FACEBOOK_ACCOUNT_ID",});console.log(response);Example Response
{ "accountId": "acc_YOUR_FACEBOOK_ACCOUNT_ID", "iceBreakers": [ { "question": "What are your opening hours?", "payload": "HOURS" }, { "question": "Do you deliver?", "payload": "DELIVERY" } ], "persistentMenu": [ { "type": "web_url", "title": "Order online", "url": "https://example.com/order", "payload": null } ]}