# Reddit Profile Crawler Pro (`crawlerbros/reddit-profile-crawler-pro`) Actor

Scrape Reddit user profiles with split karma (post/comment/awarder/awardee), account age, admin/employee/moderator badges, trophies, moderated subreddits, and recent comments. Per-post: awards, gilded count, upvote ratio, media, crosspost parent. Filter by score, age, NSFW. No login.

- **URL**: https://apify.com/crawlerbros/reddit-profile-crawler-pro.md
- **Developed by:** [Crawler Bros](https://apify.com/crawlerbros) (community)
- **Categories:** Social media, Developer tools, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 13 bookmarks
- **User rating**: 5.00 out of 5 stars

## Pricing

from $1.00 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## Reddit Profile Crawler Pro

Pro-tier version of the Reddit profile crawler. Same browser-automation core, with these additions:

- 🆔 **Accepts full Reddit URLs** (`https://www.reddit.com/user/spez`) in addition to plain usernames or `u/spez` prefixed forms.
- 🏆 **Trophy case** extraction (toggle).
- 🛡️ **Moderated subreddits** list (toggle).
- 💬 **Recent comments** scraping (toggle) — visits the user's `/comments` page in addition to `/submitted`.
- 📊 **Split karma fields** — `post_karma`, `comment_karma`, `awarder_karma`, `awardee_karma`, `total_karma`, plus a `verified` flag.
- 🎁 **Per-post enrichment** — `awards[]`, `total_awards_received`, `gilded_count`, `upvote_ratio`, `is_video`, `media_metadata{type,thumbnail_*,domain}`, `crosspost_parent`.
- 🎯 **Client-side filters** — `minPostScore`, `maxPostAgeDays`, `excludeNsfwPosts`.
- ✅ **Sentinel errors** so daily-test never sees an empty dataset.
- 🧪 **190+ pytest cases** covering every helper, parser, and filter combination.

No authentication, no API keys, no proxy required.

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `usernames` | array of strings (required) | `["spez"]` | Reddit usernames. Accepts plain (`spez`), `u/spez`, or full URLs (`https://www.reddit.com/user/spez`). |
| `maxPosts` | integer | `100` (1–1000) | Max posts per user. |
| `section` | enum | `submitted` | `submitted` / `overview` / `gilded`. |
| `sort` | enum | `new` | `hot` / `new` / `top` / `controversial`. |
| `includeComments` | boolean | `false` | Also scrape the user's `/comments` page. Adds `recent_comments[]`. |
| `includeTrophies` | boolean | `false` | Pull trophy case. Adds `trophies[]`. |
| `includeModeratedSubreddits` | boolean | `false` | Pull moderated subs. Adds `moderated_subreddits[]`. |
| `minPostScore` | integer (optional) | – | Drop posts below this score. |
| `maxPostAgeDays` | integer (optional) | – | Drop posts older than N days. |
| `excludeNsfwPosts` | boolean | `false` | Drop NSFW posts. |

#### Example input

```json
{
  "usernames": ["spez", "u/example", "https://www.reddit.com/user/another"],
  "maxPosts": 50,
  "section": "submitted",
  "sort": "new",
  "includeTrophies": true,
  "includeModeratedSubreddits": true,
  "minPostScore": 10,
  "excludeNsfwPosts": true
}
````

### Output

One record per user. Empty fields are omitted (no nulls).

```json
{
  "username": "spez",
  "post_karma": 100000,
  "comment_karma": 200000,
  "awarder_karma": 50,
  "awardee_karma": 150,
  "total_karma": 350000,
  "verified": true,
  "account_created": "2005-06-06T00:00:00+00:00",
  "posts": [
    {
      "post_id": "abc123",
      "title": "...",
      "subreddit": "r/announcements",
      "score": 5000,
      "num_comments": 240,
      "url": "https://www.reddit.com/r/...",
      "old_reddit_url": "https://old.reddit.com/r/...",
      "content": "...",
      "thumbnail_image": "https://...",
      "created_at": "2024-06-15T12:00:00+00:00",
      "is_stickied": false,
      "is_nsfw": false,
      "is_video": false,
      "awards": [{"name": "Gold", "count": 1}],
      "total_awards_received": 1,
      "gilded_count": 1,
      "upvote_ratio": 0.95,
      "media_metadata": {"type": "image", "thumbnail_url": "https://..."}
    }
  ],
  "post_count": 50,
  "trophies": [{"name": "10-Year Club"}],
  "trophy_count": 1,
  "moderated_subreddits": ["r/announcements"],
  "moderated_subreddit_count": 1,
  "recent_comments": [
    {"comment_id": "c1", "body": "...", "score": 25, "subreddit": "r/python", "permalink": "https://...", "created_at": "..."}
  ],
  "recent_comment_count": 1,
  "scraped_at": "2024-12-16T14:23:11+00:00"
}
```

#### Output fields

- **`username`** — the Reddit username.
- **`post_karma`** / **`comment_karma`** / **`awarder_karma`** / **`awardee_karma`** / **`total_karma`** — split karma values.
- **`verified`** — Reddit's verified-user flag (when present).
- **`account_created`** — ISO-8601 cake-day timestamp.
- **`posts[]`** — array of post records (see post schema below). Filtered by `minPostScore`, `maxPostAgeDays`, `excludeNsfwPosts`.
- **`post_count`** — count of posts emitted (after filtering).
- **`filtered_post_count`** — only present when filters dropped one or more posts (diagnostic).
- **`trophies[]`** / **`trophy_count`** — only when `includeTrophies: true`.
- **`moderated_subreddits[]`** / **`moderated_subreddit_count`** — only when `includeModeratedSubreddits: true`.
- **`recent_comments[]`** / **`recent_comment_count`** — only when `includeComments: true`.
- **`scraped_at`** — ISO-8601 UTC timestamp.

##### Post schema (per row in `posts[]`)

`post_id`, `post_name`, `title`, `subreddit`, `score`, `num_comments`, `url`, `old_reddit_url`, `external_url`, `content`, `thumbnail_image`, `link_flair`, `created_utc`, `created_at`, `is_stickied`, `is_nsfw`, `is_promoted`, `is_spoiler`, `is_video`, `awards[]`, `total_awards_received`, `gilded_count`, `upvote_ratio`, `media_metadata`, `crosspost_parent`.

### Use cases

- **User-activity analysis** — pull posting cadence, top subreddits, karma split.
- **Account-age verification** — `account_created` + `verified` + `total_karma` build a quick "is this a bot?" signal.
- **Influence mapping** — sort users by `total_awards_received` across their post history.
- **Moderator audit** — pull every subreddit a user moderates with one input.
- **Content datasets for ML** — bulk-fetch comments + posts with structured metadata.

### FAQ

**Does it need cookies, login, or proxy?**
No. The actor connects directly using a Chrome User-Agent and the public `old.reddit.com` endpoint.

**Why use `old.reddit.com`?**
Stable HTML structure that works across years; the new Reddit UI is React-rendered and hostile to scraping.

**What happens if a user doesn't exist?**
The actor emits a sentinel record `{type: "reddit_profile_crawler_pro_error", reason: "user_not_found", username: "..."}` and continues with the rest of the input list.

**What if all posts get filtered out?**
The user record still emits with `post_count: 0` and `filtered_post_count: N` so you can tell the user existed but the filter eliminated their posts.

**How big can the result get?**
With `includeComments + includeTrophies + includeModeratedSubreddits` all on and `maxPosts: 1000`, expect ~5-10 KB per user. The actor scales linearly with users + max posts.

# Actor input Schema

## `usernames` (type: `array`):

Reddit usernames to scrape. Accepts plain usernames (`spez`), `u/spez`, OR full Reddit profile URLs (e.g. `https://www.reddit.com/user/spez`). Auto-extracts username from URLs.

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

Maximum number of posts to scrape per user profile.

## `section` (type: `string`):

Which section of the profile to scrape.

## `sort` (type: `string`):

How to sort posts on the profile.

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

Also scrape the user's recent comments page (not just submitted posts). Adds a `recent_comments[]` array to each user record.

## `includeTrophies` (type: `boolean`):

Pull the user's trophy case from `/user/<u>/`. Adds `trophies[]` to each user record.

## `includeModeratedSubreddits` (type: `boolean`):

Pull the list of subreddits the user moderates. Adds `moderated_subreddits[]` to each user record.

## `minPostScore` (type: `integer`):

Drop posts with score below this number. Optional client-side filter applied after scraping.

## `maxPostAgeDays` (type: `integer`):

Drop posts older than this many days. Optional client-side filter applied after scraping.

## `excludeNsfwPosts` (type: `boolean`):

Drop posts flagged as NSFW. Defaults to false (keeps all posts).

## Actor input object example

```json
{
  "usernames": [
    "spez",
    "u/example_user",
    "https://www.reddit.com/user/another_user"
  ],
  "maxPosts": 100,
  "section": "submitted",
  "sort": "new",
  "includeComments": false,
  "includeTrophies": false,
  "includeModeratedSubreddits": false,
  "excludeNsfwPosts": false
}
```

# 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 = {
    "usernames": [
        "spez"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("crawlerbros/reddit-profile-crawler-pro").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 = { "usernames": ["spez"] }

# Run the Actor and wait for it to finish
run = client.actor("crawlerbros/reddit-profile-crawler-pro").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "usernames": [
    "spez"
  ]
}' |
apify call crawlerbros/reddit-profile-crawler-pro --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=crawlerbros/reddit-profile-crawler-pro",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Reddit Profile Crawler Pro",
        "description": "Scrape Reddit user profiles with split karma (post/comment/awarder/awardee), account age, admin/employee/moderator badges, trophies, moderated subreddits, and recent comments. Per-post: awards, gilded count, upvote ratio, media, crosspost parent. Filter by score, age, NSFW. No login.",
        "version": "1.0",
        "x-build-id": "irLr0zMBjKfRBs1xN"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/crawlerbros~reddit-profile-crawler-pro/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-crawlerbros-reddit-profile-crawler-pro",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/crawlerbros~reddit-profile-crawler-pro/runs": {
            "post": {
                "operationId": "runs-sync-crawlerbros-reddit-profile-crawler-pro",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/crawlerbros~reddit-profile-crawler-pro/run-sync": {
            "post": {
                "operationId": "run-sync-crawlerbros-reddit-profile-crawler-pro",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "usernames"
                ],
                "properties": {
                    "usernames": {
                        "title": "Reddit usernames",
                        "type": "array",
                        "description": "Reddit usernames to scrape. Accepts plain usernames (`spez`), `u/spez`, OR full Reddit profile URLs (e.g. `https://www.reddit.com/user/spez`). Auto-extracts username from URLs.",
                        "items": {
                            "type": "string"
                        }
                    },
                    "maxPosts": {
                        "title": "Max posts per user",
                        "minimum": 1,
                        "maximum": 1000,
                        "type": "integer",
                        "description": "Maximum number of posts to scrape per user profile.",
                        "default": 100
                    },
                    "section": {
                        "title": "Profile section",
                        "enum": [
                            "submitted",
                            "overview",
                            "gilded"
                        ],
                        "type": "string",
                        "description": "Which section of the profile to scrape.",
                        "default": "submitted"
                    },
                    "sort": {
                        "title": "Sort posts by",
                        "enum": [
                            "hot",
                            "new",
                            "top",
                            "controversial"
                        ],
                        "type": "string",
                        "description": "How to sort posts on the profile.",
                        "default": "new"
                    },
                    "includeComments": {
                        "title": "Include recent comments",
                        "type": "boolean",
                        "description": "Also scrape the user's recent comments page (not just submitted posts). Adds a `recent_comments[]` array to each user record.",
                        "default": false
                    },
                    "includeTrophies": {
                        "title": "Include trophy case",
                        "type": "boolean",
                        "description": "Pull the user's trophy case from `/user/<u>/`. Adds `trophies[]` to each user record.",
                        "default": false
                    },
                    "includeModeratedSubreddits": {
                        "title": "Include moderated subreddits",
                        "type": "boolean",
                        "description": "Pull the list of subreddits the user moderates. Adds `moderated_subreddits[]` to each user record.",
                        "default": false
                    },
                    "minPostScore": {
                        "title": "Min post score (filter)",
                        "minimum": -10000,
                        "maximum": 10000000,
                        "type": "integer",
                        "description": "Drop posts with score below this number. Optional client-side filter applied after scraping."
                    },
                    "maxPostAgeDays": {
                        "title": "Max post age in days (filter)",
                        "minimum": 1,
                        "maximum": 36500,
                        "type": "integer",
                        "description": "Drop posts older than this many days. Optional client-side filter applied after scraping."
                    },
                    "excludeNsfwPosts": {
                        "title": "Exclude NSFW posts",
                        "type": "boolean",
                        "description": "Drop posts flagged as NSFW. Defaults to false (keeps all posts).",
                        "default": false
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
