Comments & Inbox APIAPI

Every comment and message, in one queue you can code against

FoPost pulls comments and direct messages from each connected account into one inbox. List them, count what is unread, mark items handled, and reply, all through the same API your dashboard uses.

GET /v1/inbox
curl "https://api.fopost.com/v1/inbox?workspaceId=9b2f6c1e-...&state=unread" \
  -H "X-API-Key: $API_KEY"

{
  "data": [
    { "id": "inb_01j8...", "type": "comment", "platform": "instagram", "accountId": "4a71d80b-...", "author": "@customer", "text": "Does this ship to Canada?", "postId": "post_01j8...", "receivedAt": "2026-08-29T14:02:11Z" },
    { "id": "inb_01j9...", "type": "message", "platform": "facebook", "accountId": "c30e9f12-...", "author": "Jordan P.", "text": "Hi, I need help with an order.", "receivedAt": "2026-08-29T13:48:30Z" }
  ]
}

One list

Comments and messages from every account, newest first, with the same fields.

Unread count

A single call for the badge number, per workspace or per account.

Reply from code

Answer a comment or message and the reply goes back to the network.

Read

Route incoming conversations to the right place

Poll the inbox on a schedule or on demand, filter by type, account, or status, and forward each item to your helpdesk, your chat channel, or a human. Every item links back to the post it belongs to, when there is one.

Read the inbox reference
GET /v1/inbox/unread-count
curl "https://api.fopost.com/v1/inbox/unread-count?workspaceId=9b2f6c1e-..." \
  -H "X-API-Key: $API_KEY"

{ "total": 14, "byAccount": { "4a71d80b-...": 9, "c30e9f12-...": 5 } }

Filter

By type, account, platform, or read state, with cursor pagination.

Linked to the post

Comments carry the postId, so you can join them to analytics.

Inbox accounts

GET /v1/inbox/accounts lists which connected accounts feed the inbox.

Reply

Answer where the customer asked

POST a reply to an inbox item and it is posted as a comment reply or a direct message on the originating network, from the connected account. Mark items read, resolved, or snoozed with PATCH so two systems never handle the same one.

See the reply endpoint
POST /v1/inbox/:id/reply
curl -X POST https://api.fopost.com/v1/inbox/inb_01j8.../reply \
  -H "X-API-Key: $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "text": "Yes, we ship to Canada. Delivery takes 3 to 5 days." }'

curl -X PATCH https://api.fopost.com/v1/inbox/inb_01j8... \
  -H "X-API-Key: $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "state": "read" }'

Native reply

Comment replies and DMs go out through the network’s own API.

Status updates

read, archived, or flagged, so handled items drop out of the queue.

Explicit sends

Nothing replies on its own. Every outbound message is a request you make.

Sync

Fresh when you need it, quiet when you do not

The inbox syncs on a schedule for every connected account. When you need the latest right now, hit the refresh endpoint for one account and read again. Workspace scoping means an agency key only ever sees its own client’s conversations.

Start building
Connected accounts across every network in one workspace

On-demand refresh

POST /v1/inbox/refresh pulls the latest for an account immediately.

Scheduled sync

Background sync keeps the list current without any call from you.

Workspace isolated

Author identity and message text never leave the workspace they belong to.

Comments & Inbox API questions, answered

Which networks feed the inbox?

Any connected account on a network that exposes comments or messages through its API. GET /v1/inbox/accounts tells you exactly which of your accounts are included.

Can I reply to direct messages?

Yes, where the network allows it and the account has granted messaging permission. The reply endpoint returns an error naming the reason when a network does not allow it.

How quickly do new comments appear?

Background sync runs on a schedule per account. Call the refresh endpoint before reading when you need the newest items right now.

Can the API reply automatically?

No. The API never sends a reply without a request from you. If you build auto-replies, the decision to send lives in your code.

Do I get the author’s profile?

You get the display name and handle as the network exposes them, plus a link to the original item. Data stays inside the workspace the account belongs to.

Is there a rate limit?

Yes, 100 requests per minute per key. Use the unread count for polling and fetch the full list only when it changes.

Build on the Comments & Inbox API today

Starting is free and the full API is included. Create a key and make your first call in minutes.

Get your API key