Zernio
APIFor you
Zernio
APIFor you
API Reference

Messages

Conversations

List conversationsGETSearch conversationsGETCreate conversationPOSTGet conversationGETUpdate conversation statusPUTMark a conversation as readPOSTChange who answers a conversation (handover)POST

Messages

List messagesGETSend messagePOSTEdit messagePATCHDelete messageDELETEUpload media filePOSTResolve message attachmentGET

Reactions & Typing

Add reactionPOSTRemove reactionDELETESend typing indicatorPOST

Other

Accept a message requestPOSTAdd a label to a conversationPOSTCreate a conversation labelPOSTDelete conversationDELETEDelete a conversation labelDELETEList the labels on a conversationGETList the Page's conversation labelsGETRemove a label from a conversationDELETE
Dashboard
OverviewPlatformsAPI ReferenceResources
Messages

Add a label to a conversation

Facebook Messenger only. Applies one of the Page's custom labels to the person in this conversation (Graph POST /{label-id}/label?user={psid}). The id must be one of the Page's custom labels, otherwise 404 resource_not_found. Other platforms answer 400 platform_not_supported.


POST
/v1/inbox/conversations/{conversationId}/labels

Authorization

bearerAuth
AuthorizationBearer <token>

API key authentication: send your Zernio API key in the Authorization header, prefixed with Bearer.

In: header

Path Parameters

conversationId*string

Conversation ID (Zernio id or Meta platform conversation id)

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

import Zernio from '@zernio/node';const zernio = new Zernio({ apiKey: process.env.ZERNIO_API_KEY });const { data } = await zernio.messages.addConversationLabel({  path: {    conversationId: 'conversation_abc123',  },  body: {    accountId: 'account_abc123',    labelId: 'label_abc123',  },});console.log(data);
{  "success": true}
Was this page helpful?

Accept a message request

Accept a Facebook or Instagram Message Request by replying to it (Facebook Page requests are listed with `GET /v1/inbox/conversations?folder=requests`; Instagram answers PLATFORM_LIMITATION there). Meta has no separate accept call: the first reply is what moves the thread into the inbox, so this sends `message` through the same path, checks and webhooks as `POST /v1/inbox/conversations/{conversationId}/messages`, and answers the same way. Supports the `Idempotency-Key` header.

Create a conversation label

Facebook Messenger only. Creates a custom label on the Page (Graph `POST /{page-id}/custom_labels`). Other platforms answer 400 `platform_not_supported`.

accountId*string

Facebook social account ID

labelId*string

Meta label id from listInboxLabels

Match^[0-9]+$