> ## Documentation Index
> Fetch the complete documentation index at: https://docs.socq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Facebook Comments

> Collect public Facebook comment data.

# Facebook Comments

Collect public Facebook comment data for public post URLs, including comment text, author fields, engagement metrics, and raw JSONL output.

## Endpoint

```http theme={"system"}
POST https://api.socq.ai/v1/facebook/comments
```

## Request Body

```json theme={"system"}
{
  "urls": ["https://www.facebook.com/facebook/posts/POST_ID"]
}
```

## Use with MCP

| Interface      | Value                                               |
| -------------- | --------------------------------------------------- |
| REST           | `POST /v1/facebook/comments`                        |
| Compact MCP    | `socq_execute` with `endpoint: "facebook/comments"` |
| Typed MCP      | `socq_facebook_comments`                            |
| Exact-tool URL | `https://api.socq.ai/mcp?tools=facebook_comments`   |
| CLI            | `socq facebook comments`                            |

Use the JSON request body above as the nested `input` object for `socq_execute`, or pass the same fields directly to the typed tool. Typed tools also accept `_wait_seconds`, `_result_limit`, and `_idempotency_key`.

<Info>
  A successful collection returns a `task_id`. Continue with `socq_get_task` until the task succeeds, then read normalized records from `results.items`.
</Info>

See [MCP quickstart](/integrations/mcp) for the complete submission and polling flow.

All returned comments are billed by the actual result count. This endpoint does not accept a result-count limit.

## Result Item

After the task succeeds, call `GET /v1/tasks/{task_id}` to read paginated standard records under `results`.

```json theme={"system"}
{
  "id": "1569965031842178_123456789",
  "platform": "facebook",
  "resource": "comments",
  "type": "comment",
  "url": "https://www.facebook.com/facebook/posts/POST_ID",
  "text": "Comment text",
  "author": {
    "id": "100064860875397",
    "username": "facebook",
    "name": "facebook",
    "url": "https://www.facebook.com/facebook/",
    "avatar_url": null,
    "is_verified": null,
    "is_private": null
  },
  "metrics": {
    "likes_count": 18,
    "replies_count": 2
  },
  "media": [],
  "created_at": "2026-07-07T19:17:33",
  "collected_at": "2026-07-08T08:59:45",
  "extra": {
    "post_id": "1569965031842178",
    "post_url": "https://www.facebook.com/facebook/posts/POST_ID",
    "parent_comment_id": null,
    "input_url": "https://www.facebook.com/facebook/posts/POST_ID"
  }
}
```

## Response

```json theme={"system"}
{
  "code": 200,
  "data": {
    "task_id": "A1B2C3D4E5F6G7H8",
    "status": "queued",
    "created_time": "2026-07-08T10:30:00"
  }
}
```


## OpenAPI

````yaml api-manual/agent-api/agent-api.json POST /v1/facebook/comments
openapi: 3.1.0
info:
  title: SocQ Agent API
  version: v1-063d1c96173a
  description: Asynchronous social data API generated from the SocQ Capability Registry.
servers:
  - url: https://api.socq.ai
security: []
paths:
  /v1/facebook/comments:
    post:
      tags:
        - facebook
      summary: Facebook Comments API
      description: Facebook Comments API
      operationId: socq_facebook_comments
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: https://json-schema.org/draft/2020-12/schema
              type: object
              additionalProperties: false
              properties:
                callback_url:
                  type: string
                  format: uri
                urls:
                  type: array
                  items:
                    type: string
                    minLength: 1
                  minItems: 1
                  description: Public profile or content URLs.
              required:
                - urls
      responses:
        '200':
          description: Task accepted
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentSubmitResponse'
      security:
        - bearerAuth: []
        - apiKeyAuth: []
components:
  schemas:
    AgentSubmitResponse:
      type: object
      properties:
        code:
          type: integer
          const: 200
        data:
          type: object
          properties:
            task_id:
              type: string
            status:
              type: string
            created_time:
              type:
                - string
                - 'null'
            idempotent_replay:
              type: boolean
          required:
            - task_id
            - status
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
    apiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````