# Reddit Posts, Comments & Subreddit Analytics Scraper (`khadinakbar/reddit-posts-comments-scraper`) Actor

Scrape public Reddit posts, comments, search results and subreddit stats as structured JSON for research, AI and brand monitoring. No Reddit account or API key needed.

- **URL**: https://apify.com/khadinakbar/reddit-posts-comments-scraper.md
- **Developed by:** [Khadin Akbar](https://apify.com/khadinakbar) (community)
- **Categories:** Social media, Lead generation, MCP servers
- **Features:** Limited permissions
- **Stats:** 962 total users, 75 monthly users, 99.5% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.00 / 1,000 result founds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### What is Reddit Posts, Comments & Subreddit Analytics Scraper?

Use this Apify Actor to collect public Reddit posts, comments, search results, and subreddit analytics in structured JSON. It accepts subreddit URLs or names, a search query across Reddit, or direct post URLs, and each returned record represents one Reddit item: a post, a comment, or subreddit analytics. Useful fields include author, subreddit, score, upvote ratio, comment count, post type, media URLs, subscriber counts, active users, and timestamps, so the output can support AI workflows, research, monitoring, and reporting. This Actor is available through Apify and can also be called through Apify MCP.

### Best fit and connected workflows

This Actor fits workflows that need public Reddit data in a clean dataset rather than page HTML. It is well suited for:

- subreddit-level research with `subredditUrls`
- broad topic monitoring with `searchQuery`
- thread extraction from a specific Reddit post with `postUrls`
- post-only scraping or post-plus-comment collection
- subreddit analytics snapshots for audience size and activity context

If you are building an AI workflow, the dataset structure makes it easy to filter by `type` and route posts, comments, and subreddit analytics into different downstream steps.

### Practical scenario

Maya, a product manager, wants to understand how users discuss a new feature in `r/Python`. She starts with the subreddit name, sets `includeComments` to true, and limits comment depth so the output stays easy to review. The returned records include post titles, scores, comment bodies, authors, and the subreddit analytics record. Maya uses the post scores and comment threads to decide which discussions to bring into a weekly review, then shares the result set with her team for follow-up reading.

### Input fields

| Field | Type | Purpose |
| --- | --- | --- |
| `subredditUrls` | array of strings | Scrape posts from one or more subreddit URLs or names. |
| `searchQuery` | string | Search across all of Reddit by keyword or phrase. |
| `withinSubreddit` | string | Restrict a search to one subreddit. |
| `postUrls` | array of strings | Extract specific posts with their full comment threads. |
| `maxPosts` | integer | Maximum number of posts to return. |
| `maxCommentsPerPost` | integer | Maximum number of comments to extract for each post. |
| `commentDepthLimit` | integer | Maximum nesting depth for comment extraction. |
| `postDateLimit` | string | Ignore posts created before a given ISO 8601 date or datetime. |
| `includeComments` | boolean | Include full comment threads for each post. |
| `includeSubredditAnalytics` | boolean | Include subreddit metadata such as subscribers and active users. |
| `sortBy` | string | Sort results by `hot`, `new`, `top`, `rising`, `comments`, or `relevance`. |
| `timeFilter` | string | Apply a time window for `top` or search results. |
| `includeNsfw` | boolean | Include posts marked as NSFW. |

#### Focused JSON input example

```json
{
  "subredditUrls": [
    "https://reddit.com/r/MachineLearning"
  ],
  "maxPosts": 10,
  "includeComments": true,
  "maxCommentsPerPost": 5,
  "commentDepthLimit": 2,
  "includeSubredditAnalytics": true,
  "sortBy": "hot",
  "timeFilter": "week",
  "includeNsfw": false
}
```

### Output fields

The dataset can include three record types: `post`, `comment`, and `subreddit_analytics`. Filter on the `type` field to separate them.

| Field | Type | Meaning |
| --- | --- | --- |
| `type` | string | Record type discriminator. |
| `id` | string or null | Reddit item ID. |
| `title` | string or null | Post title. |
| `body` | string or null | Post body or comment text. |
| `author` | string | Author username. |
| `subreddit` | string or null | Subreddit name for posts and comments. |
| `subreddit_subscribers` | integer or null | Subscriber count at scrape time. |
| `score` | integer or null | Net score. |
| `upvote_ratio` | number or null | Upvote ratio for posts. |
| `num_comments` | integer or null | Comment count for posts. |
| `url` | string or null | Direct Reddit URL for the record. |
| `external_url` | string or null | External link target for link posts. |
| `media_urls` | array or null | Image or video URLs attached to the post. |
| `flair` | string or null | Post flair label. |
| `awards_count` | integer | Awards received. |
| `post_type` | string or null | `text`, `link`, `image`, or `video`. |
| `is_nsfw` | boolean | NSFW flag. |
| `is_spoiler` | boolean | Spoiler flag. |
| `is_stickied` | boolean | Sticky/pinned flag. |
| `post_id` | string or null | Parent post ID for comments. |
| `parent_id` | string or null | Parent comment or post ID for comments. |
| `depth` | integer or null | Comment nesting depth. |
| `is_submitter` | boolean or null | Whether the commenter is the original post author. |
| `name` | string or null | Subreddit display name for analytics records. |
| `description` | string or null | Subreddit description for analytics records. |
| `subscribers` | integer or null | Total subscribers for analytics records. |
| `active_users` | integer or null | Currently active users for analytics records. |
| `nsfw` | boolean or null | NSFW flag for the subreddit. |
| `subreddit_type` | string or null | Subreddit visibility type. |
| `icon_url` | string or null | Subreddit icon URL. |
| `banner_url` | string or null | Subreddit banner URL. |
| `created_at` | string | Original Reddit creation timestamp. |
| `source_url` | string | Reddit JSON API URL used to extract the record. |
| `scraped_at` | string | Timestamp when the Actor extracted the record. |

#### Illustrative output record

```json
{
  "type": "post",
  "id": "t3_abc123",
  "title": "Python libraries for machine learning discussion in 2026",
  "body": "I've been using scikit-learn and comparing other libraries...",
  "author": "u/john_doe",
  "subreddit": "r/MachineLearning",
  "subreddit_subscribers": 2840000,
  "score": 1482,
  "upvote_ratio": 0.94,
  "num_comments": 73,
  "url": "https://reddit.com/r/MachineLearning/comments/abc123/python_libraries_discussion/",
  "external_url": "https://arxiv.org/abs/2401.12345",
  "media_urls": [
    "https://i.redd.it/example.jpg"
  ],
  "flair": "Research Paper",
  "awards_count": 5,
  "post_type": "text",
  "is_nsfw": false,
  "is_spoiler": false,
  "is_stickied": false,
  "created_at": "2026-03-20T14:22:00.000Z",
  "source_url": "https://www.reddit.com/r/MachineLearning.json?sort=hot&limit=100",
  "scraped_at": "2026-03-28T14:30:00.000Z"
}
```

### How it works

This Actor uses owner-managed provider-backed access to read public Reddit data. It works across three modes: subreddit scraping, Reddit search, and specific post URL extraction. The output is structured as JSON and written to the default dataset, with `OUTPUT` and `RUN_SUMMARY` records also stored in the key-value store for diagnostics and execution summaries.

The dataset schema is designed for downstream filtering by `type`, so posts, comments, and subreddit analytics can be processed separately or together.

### Pricing

Reddit Posts, Comments & Subreddit Analytics Scraper uses Pay per event with Apify platform usage included. The primary billable event is `Result found`, which is charged for each extracted Reddit post, comment, or subreddit analytics record. There is also a one-time actor start event.

A simple event-count example: if a run returns one hundred posts and fifty comments, the Actor records one hundred fifty `Result found` events, plus the start event, and Apify platform usage is included, so there are no extra compute charges. Example: 100 posts with 25 comments each is 2,600 results, or $7.80 (paid Apify plans pay less per result: from $0.0028 on Silver to $0.0026 on Gold and above). **From 23 November 2026** each run also pays a one-time start fee of $0.01, which covers the fixed cost of the first request; before that date the start fee stays $0.00005. For current pricing details, check the live Pricing tab in the Apify console.

#### Free Apify plan

Runs started from a free Apify plan return up to 660 results per run, with every input mode and output field available. Paid Apify plans have no per-run limit, so your usual result settings apply.

### Use with AI agents (MCP)

This Actor is available through Apify MCP and is designed for tool use in AI-assisted workflows. It can be called by an agent that translates a natural-language request into the Actor input fields, then reads the dataset output back into the conversation.

Exact Actor identity: `khadinakbar/reddit-posts-comments-scraper`

Example agent prompt:

> Find posts from r/MachineLearning about foundation models from the last month, include comments up to depth 2, and return subreddit analytics too.

Output interpretation:

- `type = post` identifies post records
- `type = comment` identifies comment records
- `type = subreddit_analytics` identifies subreddit metadata records
- use `post_id` and `parent_id` to reconstruct comment threads
- use `scraped_at` for freshness tracking
- use `source_url` for provenance and repeatable re-fetching

Scope and pagination guidance:

- use `maxPosts` to set the number of posts to collect
- use `maxCommentsPerPost` to control comment volume
- use `commentDepthLimit` to shape thread depth
- use `postDateLimit` to focus on recent content
- use `includeComments` and `includeSubredditAnalytics` to select which record types are included
- for broad searches, `sortBy` and `timeFilter` help narrow the result set

### Apify API example

```javascript
import { ApifyClient } from 'apify-client';

const client = new ApifyClient({
  token: process.env.APIFY_TOKEN,
});

const run = await client.actor('khadinakbar/reddit-posts-comments-scraper').call({
  searchQuery: 'artificial intelligence regulation',
  maxPosts: 20,
  sortBy: 'relevance',
  timeFilter: 'month',
  includeComments: true,
  maxCommentsPerPost: 10,
  includeSubredditAnalytics: true,
});

const items = await client.dataset(run.defaultDatasetId).listItems();
console.log(items.items.filter((item) => item.type === 'post'));
```

### Best results and outcome guidance

Choose `subredditUrls` when you already know the community you want to inspect. Use `searchQuery` when you are tracking a topic across Reddit. Use `postUrls` when you need a specific thread with its comments. For comment-heavy threads, combine a moderate `maxCommentsPerPost` with `commentDepthLimit` to keep the output focused. For monitoring workflows, `postDateLimit` and `sortBy: "new"` or `sortBy: "top"` help keep result sets aligned with the time window you care about.

### Continue the workflow

- Then use [Reddit Scraper – Posts, Comments & Subreddits](https://apify.com/khadinakbar/reddit-posts-scraper) to extend Reddit Posts, Comments & Subreddit Analytics Scraper research with a complementary content contract.
- Then use [Reddit Posts Search Scraper](https://apify.com/khadinakbar/reddit-posts-search-scraper) to extend Reddit Posts, Comments & Subreddit Analytics Scraper research with a complementary discovery contract.

### Design note

I found that every dataset record is required to include `type` and `scraped_at`, which makes it straightforward to sort records by category and freshness in downstream workflows.

### FAQ

**How should I choose between subreddit URLs and search queries?**\
Use `subredditUrls` for a known community and `searchQuery` for a topic that spans Reddit.

**Can I pull comments without posts?**\
This Actor is structured around post extraction with optional comment threads. Set `includeComments` to false for post-only runs, or use `postUrls` when you want a specific discussion thread.

**How can I filter the dataset after the run?**\
Filter by `type` to separate `post`, `comment`, and `subreddit_analytics` records.

**What is the difference between `post_id` and `parent_id` in comments?**\
`post_id` points to the parent post. `parent_id` points to the direct parent item, which can be a post or another comment.

**When should I use `withinSubreddit`?**\
Use it together with `searchQuery` when you want a search limited to one subreddit.

### Responsible use

This Actor is for public Reddit data. Use it in ways that respect Reddit content access, your rights and approvals, and the intended downstream use of the data. Review the returned records before redistribution, and use the `is_nsfw`, `is_spoiler`, and `is_stickied` fields as part of your own filtering and handling logic where relevant.

Reddit Posts, Comments & Subreddit Analytics Scraper is designed as a focused workflow.

### What's new

- **2026-11-10 (pricing):** Start fee rises to $0.01 per run on 23 Nov 2026 and paid Apify plans get a lower per-result price (Silver $0.0028, Gold and above $0.0026). The $0.003 per-result price for everyone else is unchanged.
- **2026-11-10:** Several searches in one run, one list for any Reddit links (subreddit, post, comment or search URLs), keyword, score, comment-count and flair filters, exact date windows (after, before, last N hours), comment order (best, top, new, old), automatic de-duplication across sources, and an optional feedback box for AI agents. Filtered posts are skipped before comments are fetched, so they are never charged.

### Use with AI agents (copy this)

```text
Use khadinakbar/reddit-posts-comments-scraper on Apify. Give it "urls" (any Reddit subreddit, post or search links) or "searchQueries". Set maxPosts and maxCommentsPerPost to control cost (each post, comment or subreddit record is one result). Use keywordFilter, minScore, minComments or postedAfter to keep only what you need. If something is missing, put it in "feedback".
```

Related Actors: [Reddit Posts Scraper](https://apify.com/khadinakbar/reddit-posts-scraper) for posts only, [Reddit Archive Scraper](https://apify.com/khadinakbar/reddit-archive-scraper) for history.

# Actor input Schema

## `subredditUrls` (type: `array`):

Use this field when the user provides specific subreddit names or URLs to scrape posts from. Accepts full URLs (e.g., 'https://reddit.com/r/MachineLearning') or shorthand names (e.g., 'r/MachineLearning' or just 'MachineLearning'). Can be a list of multiple subreddits. Do NOT use this when the user wants to search all of Reddit by keyword — use searchQuery for that. Example triggers: 'scrape posts from r/Python', 'get top posts from MachineLearning subreddit', 'analyze r/wallstreetbets'.

## `searchQuery` (type: `string`):

Use this field when the user provides a keyword, topic, or phrase to search across all of Reddit (not a specific subreddit). To scope the search to one subreddit, also set the withinSubreddit field. Do NOT use this when the user provides a specific subreddit URL or name — use subredditUrls for that. Example triggers: 'search Reddit for AI news', 'find posts about climate change', 'monitor mentions of my brand name on Reddit', 'what are people saying about ChatGPT'.

## `withinSubreddit` (type: `string`):

Optional. When set alongside searchQuery, restricts the search to a single subreddit instead of searching all of Reddit. Accepts a subreddit name with or without the r/ prefix (e.g., 'r/MachineLearning' or 'MachineLearning'). Example triggers: 'search r/Python for pandas tips', 'find posts about GPT-4 in r/artificial', 'search within a subreddit'.

## `postUrls` (type: `array`):

Use this field when the user provides direct links to specific Reddit posts and wants to extract the post content plus all comments. Example triggers: 'get all comments from this post: reddit.com/r/.../comments/...', 'scrape this Reddit thread', 'extract the discussion from this specific Reddit URL'.

## `maxPosts` (type: `integer`):

Maximum number of posts to return. Each post counts as one result in your quota. Set lower values for quick tests, higher for bulk research. Note: comments are charged separately. Free Apify plan runs return up to 660 results per run.

## `maxCommentsPerPost` (type: `integer`):

Maximum number of comments to extract per post. Each comment counts as one result. Includes nested replies up to the depth limit. Set to 0 to skip comment extraction entirely (faster).

## `commentDepthLimit` (type: `integer`):

Maximum nesting depth to extract for comment threads. 0 = top-level comments only. 1 = top-level + one reply level. Higher values include deeper nested replies. Leave blank or set to a high value (e.g., 10) to extract all depths. Useful for AI/LLM use cases where deeply nested threads add noise.

## `postDateLimit` (type: `string`):

Optional. If set, skips any post created before this date. Use ISO 8601 format: 'YYYY-MM-DD' or full datetime 'YYYY-MM-DDTHH:MM:SSZ'. Example: '2025-01-01' to only get posts from 2025 onward. Works with all scrape modes (subreddit, search, post URLs). Example triggers: 'only posts from this year', 'posts after January 2025', 'recent posts only'.

## `includeComments` (type: `boolean`):

When enabled, the actor automatically fetches and returns full comment threads for each post. Disable to scrape posts only — much faster and uses fewer credits.

## `includeSubredditAnalytics` (type: `boolean`):

When enabled, fetches subreddit metadata (subscriber count, active users, description, rules) for each subreddit. One analytics record per subreddit. Disable if you only need post data.

## `sortBy` (type: `string`):

How to sort posts when scraping a subreddit. Use 'hot' for trending posts, 'new' for latest posts, 'top' for highly scored posts (use with timeFilter), 'rising' for gaining traction, 'comments' for heavily discussed posts, 'relevance' for search results.

## `timeFilter` (type: `string`):

Time window for filtering posts when sortBy is 'top' or when searching. Use 'hour' for posts from the last hour, 'day' for today, 'week', 'month', 'year', or 'all' for all time. Ignored for 'hot', 'new', 'rising', and 'comments' sorts.

## `includeNsfw` (type: `boolean`):

When enabled, includes posts marked as NSFW (Not Safe For Work) in the results. Disabled by default to keep results suitable for business use cases.

## `urls` (type: `array`):

Optional. One list for any Reddit links: subreddit URLs, post or comment URLs, and search URLs (reddit.com/search?q=...). Each link is routed automatically. Use this when you have a mixed list; the specific fields below also work.

## `searchQueries` (type: `array`):

Optional. Several keyword searches in one run, one per line (brand names, competitors, topics). Combined with the single search field. Results are de-duplicated across searches.

## `postedAfter` (type: `string`):

Optional. Skips posts created before this date. ISO format 'YYYY-MM-DD' or full datetime. Replaces the older 'Ignore posts older than' field, which still works.

## `postedBefore` (type: `string`):

Optional. Skips posts created at or after this date. ISO format 'YYYY-MM-DD'. Use with Only posts after to get an exact window.

## `maxPostAgeHours` (type: `integer`):

Optional. For example 24 keeps only posts from the last day. 0 means no limit.

## `keywordFilter` (type: `array`):

Optional. Keep a post only if its title or text contains at least one of these words (case-insensitive). Filtered posts are skipped before comments are fetched, so they cost nothing.

## `keywordMode` (type: `string`):

'any' searches title and text; 'titleonly' searches the title only.

## `minScore` (type: `integer`):

Optional. Skip posts with fewer upvotes (net score) than this. 0 keeps everything.

## `minComments` (type: `integer`):

Optional. Skip posts with fewer comments than this. Useful for finding active discussions.

## `flairFilter` (type: `array`):

Optional. Keep only posts whose flair contains one of these words (for example 'Discussion', 'Question').

## `commentSort` (type: `string`):

Order of the top-level comments kept per post: 'best' (Reddit default), 'top' (highest score), 'new' or 'old'.

## `feedback` (type: `string`):

Optional. Say what you needed and did not get (a missing field, filter or wrong result). It is saved in the run summary and read by the maintainer. Does not change the results.

## Actor input object example

```json
{
  "subredditUrls": [
    "https://reddit.com/r/MachineLearning"
  ],
  "searchQuery": "artificial intelligence trends 2026",
  "postUrls": [
    "https://www.reddit.com/r/programming/comments/1s7xp78/joins_are_not_expensive/"
  ],
  "maxPosts": 25,
  "maxCommentsPerPost": 25,
  "commentDepthLimit": 10,
  "includeComments": true,
  "includeSubredditAnalytics": true,
  "sortBy": "relevance",
  "timeFilter": "month",
  "includeNsfw": false,
  "maxPostAgeHours": 0,
  "keywordMode": "any",
  "minScore": 0,
  "minComments": 0,
  "commentSort": "best"
}
```

# Actor output Schema

## `results` (type: `string`):

Dataset of posts, comments, and subreddit analytics. Filter by 'type' field.

## `output` (type: `string`):

Compact machine-readable run outcome, item counts, warnings, and billable event totals.

## `runSummary` (type: `string`):

Detailed run diagnostics, input summary, validation counts, request errors, and cost-cap state.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "subredditUrls": [
        "https://reddit.com/r/MachineLearning"
    ],
    "searchQuery": "artificial intelligence trends 2026",
    "postUrls": [
        "https://www.reddit.com/r/programming/comments/1s7xp78/joins_are_not_expensive/"
    ],
    "maxPosts": 25,
    "maxCommentsPerPost": 25,
    "commentDepthLimit": 10,
    "includeComments": true,
    "includeSubredditAnalytics": true,
    "sortBy": "hot",
    "timeFilter": "all",
    "includeNsfw": false
};

// Run the Actor and wait for it to finish
const run = await client.actor("khadinakbar/reddit-posts-comments-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "subredditUrls": ["https://reddit.com/r/MachineLearning"],
    "searchQuery": "artificial intelligence trends 2026",
    "postUrls": ["https://www.reddit.com/r/programming/comments/1s7xp78/joins_are_not_expensive/"],
    "maxPosts": 25,
    "maxCommentsPerPost": 25,
    "commentDepthLimit": 10,
    "includeComments": True,
    "includeSubredditAnalytics": True,
    "sortBy": "hot",
    "timeFilter": "all",
    "includeNsfw": False,
}

# Run the Actor and wait for it to finish
run = client.actor("khadinakbar/reddit-posts-comments-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "subredditUrls": [
    "https://reddit.com/r/MachineLearning"
  ],
  "searchQuery": "artificial intelligence trends 2026",
  "postUrls": [
    "https://www.reddit.com/r/programming/comments/1s7xp78/joins_are_not_expensive/"
  ],
  "maxPosts": 25,
  "maxCommentsPerPost": 25,
  "commentDepthLimit": 10,
  "includeComments": true,
  "includeSubredditAnalytics": true,
  "sortBy": "hot",
  "timeFilter": "all",
  "includeNsfw": false
}' |
apify call khadinakbar/reddit-posts-comments-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,khadinakbar/reddit-posts-comments-scraper"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/Srlt6S5DwhhYqiIot/builds/flUhHXtnpvyggv139/openapi.json
