# Reddit Comments by link API (reddit.comments_lookup)

- Canonical page: [https://everyinfra.com/en/reddit-api/comments_lookup](https://everyinfra.com/en/reddit-api/comments_lookup?utm_medium=ai_doc&utm_campaign=page_md)
- Endpoint: POST https://api.everyinfra.com/api/v1/social with {"platform": "reddit", "action": "comments_lookup", "params": {...}}
- Price: $0.000792 per call ($0.79 per 1,000 requests); failed calls and empty results are not charged
- Returns: list
- Mode: sync; add "mode": "async" for slow tasks

## Health

- Live health (24h percent, hourly and daily trends): https://api.everyinfra.com/api/v1/social/availability?platform=reddit&action=comments_lookup

## Parameters

| name | type | required | default | description |
|---|---|---|---|---|
| comment_urls | not declared | yes | not declared | Reddit comment links for `comments_lookup`, as an array of up to 20 entries; a comma-separated string is not accepted. Each entry is the link to one comment itself, such as the `url` of a comment returned by `comments`: `https://www.reddit.com/r/<subreddit>/comments/<post_id>/comment/<comment_id>/`. The older `/comments/<post_id>/<title>/<comment_id>/` form, `old.reddit.com` links and links with a query string such as `?context=3` also work. A comment ID alone is not enough, because Reddit finds a comment by post ID plus comment ID, and a post link is not a comment link. The `url` that `user_comments` returns points to the post, so it cannot be used here. List each comment once. A request with an unrecognized entry, a duplicate or more than 20 entries is rejected with a 422 before any charge, and so is a `limit` smaller than the number of entries. Billed per request, not per comment; comments not read (deleted, or not under that post) produce no row, so match the rows to your entries with `input`. A request that reads none is not charged. |
| limit | integer (1–) | no | not declared | The most rows to return in this call, an integer of 1 or more. The default applies when you leave it out, and a call can return fewer rows. |

## Response fields (items in `results`)

| field | meaning |
|---|---|
| id | The record's unique ID on the platform. Unique only within one platform; IDs can repeat across platforms. |
| text | Body text with HTML removed, returned in full and never cut short (on a few platforms the list results themselves carry only an excerpt; the platform's field notes say so). |
| author_username | Author's username (@handle), usually usable in URLs. |
| like_count | Likes. null means the platform or this capability does not disclose it; it is not 0. |
| community | platform-native meaning |
| url | Link to the record on the platform. |
| posted_at | Publish time in ISO 8601, UTC (for example 2026-08-07T12:34:56+00:00). Non-standard strings from the platform are passed through as is, so parse defensively. null means the platform does not disclose it. |
| platform | Source platform identifier, the same as platform in the request (for example xiaohongshu, tiktok). |
| post_title | Title of the post the comment was left on (user_comments, comments_lookup; painpoint pain_comment rows). |
| post_url | Link to the post the comment was left on (comments_lookup). |
| input | The entry that this row answers, returned exactly as you passed it: for posts_batch an entry of urls, for comments_lookup an entry of comment_urls. Use it to match rows to your entries; the returned url can be written differently, for example a full post link where you passed a `redd.it` short link. |

## Example

```bash
curl -X POST 'https://api.everyinfra.com/api/v1/social' \
  -H "Authorization: Bearer $EVERYINFRA_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-raw '{
  "platform": "reddit",
  "action": "comments_lookup",
  "params": {
    "comment_urls": [
      "https://www.reddit.com/r/pics/comments/1xwxo1e/comment/19sogasefdc5g/"
    ]
  }
}'
```

```python
import os
import requests

response = requests.post(
    "https://api.everyinfra.com/api/v1/social",
    headers={"Authorization": f"Bearer {os.environ['EVERYINFRA_API_KEY']}"},
    json={
        "platform": "reddit",
        "action": "comments_lookup",
        "params": {
            "comment_urls": [
                "https://www.reddit.com/r/pics/comments/1xwxo1e/comment/19sogasefdc5g/",
            ],
        },
    },
    timeout=120,
)
print(response.status_code)
print(response.json())
```

## Response example

No real sample for these example parameters yet: structure only, every value is a placeholder (…).

```text
{
  "id": "req_…",
  "platform": "reddit",
  "action": "comments_lookup",
  "results": [
    {
      "id": …,
      "text": …,
      "author_username": …,
      "like_count": …,
      "community": …,
      "url": …,
      "posted_at": …,
      "platform": …,
      "post_title": …,
      "post_url": …,
      "input": …
    }
  ],
  "count": …,
  "billing": {
    "charged": …,
    "charged_usd": …,
    "balance_after_usd": …,
    …
  },
  "quota": { … }
}
```

## Also

- Capability catalog (no key): https://api.everyinfra.com/api/v1/social/catalog?platform=reddit
- OpenAPI: https://everyinfra.com/openapi.json · Agents guide: https://everyinfra.com/agents.md
