> For the complete documentation index, see [llms.txt](https://help.blotato.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.blotato.com/agent-workflows/agent-workflows/comments.md).

# Manage comments

Read Instagram or Facebook comments, select the parent comment, and verify an authorized reply.

Blotato's comments API and MCP tools support Instagram and Facebook.

Prompt for your assistant:

> Find comments on the posts I select, summarize them, and draft replies. When I ask you to send a reply, post it and verify its final status.

## Find the post and comment

1. Use an [authenticated connection](/api-and-mcp-concepts/authentication.md) and an Instagram or Facebook account with comments enabled and the required permissions.
2. Call `blotato_list_posts` to find the selected published post's Blotato ID.
3. Call `blotato_list_comments` with the following shape. Replace the example `postId` with the returned ID.

```json
{"postId": "123e4567-e89b-12d3-a456-426614174000", "limit": 50}
```

4. Read `items`. If a `cursor` is returned and more results are needed, pass it with the same filters in the next call. A missing cursor marks the end.
5. Select the intended comment. A reply's parent must be a top-level comment with `status: "posted"` on the same post. Replies to replies are not supported.

## Send an approved reply

Call `blotato_post_comment` once with the user's approved text and IDs from the lookup:

```json
{
  "postId": "123e4567-e89b-12d3-a456-426614174000",
  "parentCommentId": "123e4567-e89b-12d3-a456-426614174001",
  "text": "Thanks for your question. Registration closes on October 10."
}
```

Omit `parentCommentId` only when the user requested a new top-level comment. Do not omit it to bypass a reply error.

Save the returned comment `id`. Call `blotato_get_comment` with:

```json
{"commentId": "123e4567-e89b-12d3-a456-426614174002"}
```

For REST, use `GET https://backend.blotato.com/v2/comments?postId=PUBLISHED_POST_ID&limit=50`, `POST /v2/comments` with the same reply JSON, and `GET /v2/comments/RETURNED_COMMENT_ID`. Include `blotato-api-key: YOUR_API_KEY` on every request and `Content-Type: application/json` on POST. URL-encode query values.

## Completion and recovery

| Returned status          | Next action                                                                      |
| ------------------------ | -------------------------------------------------------------------------------- |
| `posted`                 | Report the reply as posted.                                                      |
| `queued` or `processing` | Read the same comment again. Do not send another reply.                          |
| `failed`                 | Stop and inspect `errorCode` and `errorMessage`.                                 |
| `deleted`                | Report the deleted state. Do not replace the comment without the user's request. |

Use a client polling budget, such as 10-second intervals for up to 2 minutes. This is not a delivery-time guarantee. If still pending, retain the ID and report the pending state. After a send timeout with no ID, inspect recent comments before considering another write. If the outcome remains uncertain, stop rather than risk a duplicate reply.

Read [Comments](/rest-api-reference/comments.md) for plan access, retention, and platform restrictions.

An empty inbox after connecting is a sync question. Follow [Inbox setup and timing](/web-app-features/inbox.md) before concluding the account has no comments.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://help.blotato.com/agent-workflows/agent-workflows/comments.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
