# Instagram / Comments

Fetch public comments for a post.

```
GET /api/v1/instagram/comments
```

Auth: `Authorization: Bearer <SOCIFY_KEY>`  
Credits: 1 credit per request

## Parameters

| Name | Required | Description | Example |
|------|----------|-------------|---------|
| `code` | no | Exactly one of code, id, or url. Prefer shortcode. | `C-6WRvdS75Q` |
| `id` | no | Numeric media id (alternative to code/url). | `3439159241662512720` |
| `url` | no | Full Instagram post URL (alternative to code/id). | `https://www.instagram.com/p/C-6WRvdS75Q/` |
| `cursor` | no | Pagination cursor from a previous response. |  |

## Example

```bash
curl -s 'https://trysocify.com/api/v1/instagram/comments?code=C-6WRvdS75Q' \
  -H "Authorization: Bearer $SOCIFY_KEY"
```

## Response fields

| Field | Type | Description |
|-------|------|-------------|
| `comments` | array | Comments for this page. |
| `comments[].id` | string | Comment id. |
| `comments[].text` | string | Comment text. |
| `comments[].likes` | number | Like count. |
| `comments[].created_at` | number | Unix timestamp. |
| `comments[].author` | object | Author username, id, verified. |
| `cursor` | string | Pass as cursor for the next page. |
## Sample response

Successful lookups wrap the payload in `{ ok, platform, resource, params, data, meta }`. `data` is shown below.

```json
{
  "ok": true,
  "platform": "instagram",
  "resource": "comments",
  "params": {
    "code": "C-6WRvdS75Q"
  },
  "data": {
    "comments": [
      {
        "author": {
          "id": "64490093540",
          "username": "photo_fan",
          "verified": false
        },
        "created_at": 1754086530,
        "id": "18079390237903009",
        "likes": 42,
        "text": "Incredible shot!"
      }
    ],
    "cursor": "QVFEZC01eGxyeUlfUXFfRU5VNHNJcFlF..."
  },
  "meta": {
    "credits_charged": 1,
    "latency_ms": 420,
    "platform": "instagram",
    "resource": "comments",
    "path": "/api/v1/instagram/comments"
  }
}
```

## Links

- HTML docs: https://trysocify.com/docs/api/instagram/comments
- SEO page: https://trysocify.com/instagram/comments
- OpenAPI: https://trysocify.com/openapi.json
- Catalog: https://trysocify.com/catalog.json
