# Reddit Users Actor (`pintostudio/reddit-users-actor`) Actor

Looking on ways to get user profile information, their posts, or their comments with customizable filters and pagination from Reddit? The Reddit User Scraper is an Apify Actor that extracts data from Reddit user profiles.

- **URL**: https://apify.com/pintostudio/reddit-users-actor.md
- **Developed by:** [Pinto Studio](https://apify.com/pintostudio) (community)
- **Categories:** Social media, Developer tools, Other
- **Stats:** 14 total users, 2 monthly users, 95.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$7.99 / 1,000 results

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/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 User Scraper - Documentation

### Overview

The Reddit User Scraper is an Apify Actor that extracts data from Reddit user profiles. You can scrape user profile information, their posts, or their comments with customizable filters and pagination.

### What You Can Scrape

This actor supports three types of operations:

1. **Profile** - Get basic information about a Reddit user
2. **Posts** - Retrieve posts submitted by a user
3. **Comments** - Fetch comments made by a user

### Input Parameters

#### Required Parameters

| Parameter | Type | Description | Example |
|-----------|------|-------------|---------|
| `userUrl` | String | Full Reddit URL of the user to scrape | `https://www.reddit.com/user/wsbapp/` |

#### Optional Parameters

| Parameter | Type | Default | Description |
|-----------|------|---------|-------------|
| `operationType` | String | `profile` | Type of data to scrape: `profile`, `posts`, or `comments` |
| `limit` | Integer | 25 | Number of items to fetch per page (1-100) |
| `page` | Integer | 1 | Page number to fetch (1-50) |
| `sortBy` | String | `hot` | Sort order for posts/comments: `hot`, `new`, `top`, `rising`, or `controversial` |

### How to Use

#### Example 1: Get User Profile

**Input:**
```json
{
  "operationType": "profile",
  "userUrl": "https://www.reddit.com/user/wsbapp/"
}
````

**Output:**

```json
{
  "success": true,
  "message": "Success",
  "data": {
    "user": {
      "id": "qbvp0eq8b",
      "name": "wsbapp",
      "created": "2023-12-20T07:48:10.000Z",
      "linkKarma": 106831,
      "commentKarma": 176,
      "totalKarma": 107007,
      "isGold": false,
      "isMod": true,
      "verified": true,
      "avatar": "https://www.redditstatic.com/avatars/defaults/v2/avatar_default_3.png",
      "isEmployee": false,
      "hasVerifiedEmail": false,
      "isBanned": false,
      "url": "https://reddit.com/user/wsbapp"
    }
  },
  "error": null
}
```

#### Example 2: Get User Posts

**Input:**

```json
{
  "operationType": "posts",
  "userUrl": "https://www.reddit.com/user/wsbapp/",
  "limit": 25,
  "page": 1,
  "sortBy": "new"
}
```

**Output:**

```json
{
  "success": true,
  "message": "Success",
  "data": {
    "username": "wsbapp",
    "page": 1,
    "limit": 25,
    "count": 25,
    "after": "t3_1pult0m",
    "posts": [
      {
        "id": "1q79zu2",
        "title": "Daily Discussion Thread for January 08, 2026",
        "author": "wsbapp",
        "subreddit": "wallstreetbets",
        "score": 138,
        "upvoteRatio": 0.94,
        "numComments": 3570,
        "created": "2026-01-08T12:01:19.000Z",
        "url": "https://www.reddit.com/r/wallstreetbets/comments/1q79zu2/...",
        "permalink": "https://reddit.com/r/wallstreetbets/comments/1q79zu2/...",
        "isVideo": false,
        "isSelf": true,
        "thumbnail": "self",
        "domain": "self.wallstreetbets",
        "gilded": 0,
        "locked": false,
        "spoiler": false,
        "nsfw": false
      }
    ]
  },
  "error": null
}
```

#### Example 3: Get User Comments

**Input:**

```json
{
  "operationType": "comments",
  "userUrl": "https://www.reddit.com/user/wsbapp/",
  "limit": 10,
  "page": 1,
  "sortBy": "hot"
}
```

**Output:**

```json
{
  "success": true,
  "message": "Success",
  "data": {
    "username": "wsbapp",
    "page": 1,
    "limit": 10,
    "count": 10,
    "after": "t1_ktj7bqs",
    "comments": [
      {
        "id": "ktjb25r",
        "author": "wsbapp",
        "body": "#Ban Bet Won\n\n/u/Storewars56 made a bet...",
        "score": 45,
        "created": "2024-03-06T00:22:00.000Z",
        "parentId": "t3_1b72tbp",
        "gilded": 0,
        "permalink": "https://reddit.com/r/wallstreetbets/comments/1b72tbp/.../ktjb25r/",
        "url": "https://www.reddit.com/r/wallstreetbets/comments/1b72tbp/...",
        "replies": []
      }
    ]
  },
  "error": null
}
```

### Output Data Structure

#### Profile Operation

Returns user account information including:

- Account ID and username
- Creation date
- Karma scores (link, comment, and total)
- Account status (verified, mod, employee, banned)
- Avatar URL
- Profile URL

#### Posts Operation

Returns an array of posts with:

- Post ID and title
- Author and subreddit
- Score and upvote ratio
- Number of comments
- Creation date
- URLs (post URL and permalink)
- Media type indicators (isVideo, isSelf)
- Post status (locked, spoiler, nsfw, gilded)
- Pagination info (page, limit, count, after token)

#### Comments Operation

Returns an array of comments with:

- Comment ID and author
- Comment text (body)
- Score and gilded count
- Creation date
- Parent post ID
- Permalink and post URL
- Replies array
- Pagination info (page, limit, count, after token)

### Tips for Beginners

1. **Start with Profile**: If you're new, begin with the `profile` operation to verify the user exists before fetching posts or comments.

2. **Pagination**: Use the `page` parameter to fetch more results. Start with page 1, then increment to get older content.

3. **Limit Your Requests**: Start with a small `limit` (like 10-25) to test, then increase if needed. Maximum is 100 items per page.

4. **Sort Options**:
   - Use `hot` for currently trending content
   - Use `new` for most recent content
   - Use `top` for highest-scoring content
   - Use `controversial` for divisive content

5. **Valid User URLs**: Make sure your `userUrl` follows this format: `https://www.reddit.com/user/USERNAME/`

### Error Handling

If the actor encounters an error, the output will include:

```json
{
  "success": false,
  "message": "Error description",
  "data": null,
  "error": "Detailed error message"
}
```

Common errors:

- Invalid user URL format
- User doesn't exist

### Limitations

- Maximum 100 items per page
- Maximum 50 pages per request
- Cannot access private or suspended accounts

### Support

For issues, questions, or feature requests, please refer to the Apify platform documentation or:

1. Create an issue and share your resource
2. Send us private message
3. Contact us via Telegram: @pintoflow

# Actor input Schema

## `operationType` (type: `string`):

Type of data to scrape from the Reddit user

## `userUrl` (type: `string`):

The full Reddit URL of the user to scrape (e.g., https://www.reddit.com/user/wsbapp/)

## `limit` (type: `integer`):

Maximum number of comments to fetch (for comments operation)

## `page` (type: `integer`):

Maximum number of comment pages to fetch (for comments operation)

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

How to sort comments (for comments operation)

## Actor input object example

```json
{
  "operationType": "profile",
  "userUrl": "https://www.reddit.com/user/wsbapp/",
  "limit": 25,
  "page": 1,
  "sortBy": "hot"
}
```

# 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 = {
    "operationType": "profile",
    "userUrl": "https://www.reddit.com/user/wsbapp/",
    "limit": 25,
    "page": 1,
    "sortBy": "hot"
};

// Run the Actor and wait for it to finish
const run = await client.actor("pintostudio/reddit-users-actor").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 = {
    "operationType": "profile",
    "userUrl": "https://www.reddit.com/user/wsbapp/",
    "limit": 25,
    "page": 1,
    "sortBy": "hot",
}

# Run the Actor and wait for it to finish
run = client.actor("pintostudio/reddit-users-actor").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 '{
  "operationType": "profile",
  "userUrl": "https://www.reddit.com/user/wsbapp/",
  "limit": 25,
  "page": 1,
  "sortBy": "hot"
}' |
apify call pintostudio/reddit-users-actor --silent --output-dataset

```

## MCP server setup

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

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Reddit Users Actor",
        "description": "Looking on ways to get user profile information, their posts, or their comments with customizable filters and pagination from Reddit? The Reddit User Scraper is an Apify Actor that extracts data from Reddit user profiles.",
        "version": "0.0",
        "x-build-id": "uFE0zOjWqPB1V8v2o"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/pintostudio~reddit-users-actor/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-pintostudio-reddit-users-actor",
                "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/pintostudio~reddit-users-actor/runs": {
            "post": {
                "operationId": "runs-sync-pintostudio-reddit-users-actor",
                "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/pintostudio~reddit-users-actor/run-sync": {
            "post": {
                "operationId": "run-sync-pintostudio-reddit-users-actor",
                "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": [
                    "userUrl",
                    "limit",
                    "page",
                    "sortBy"
                ],
                "properties": {
                    "operationType": {
                        "title": "Operation Type",
                        "enum": [
                            "profile",
                            "posts",
                            "comments"
                        ],
                        "type": "string",
                        "description": "Type of data to scrape from the Reddit user"
                    },
                    "userUrl": {
                        "title": "User URL",
                        "type": "string",
                        "description": "The full Reddit URL of the user to scrape (e.g., https://www.reddit.com/user/wsbapp/)"
                    },
                    "limit": {
                        "title": "Limit",
                        "minimum": 1,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Maximum number of comments to fetch (for comments operation)"
                    },
                    "page": {
                        "title": "Page Number",
                        "minimum": 1,
                        "maximum": 50,
                        "type": "integer",
                        "description": "Maximum number of comment pages to fetch (for comments operation)"
                    },
                    "sortBy": {
                        "title": "Comments Sort Order",
                        "enum": [
                            "hot",
                            "new",
                            "top",
                            "rising",
                            "controversial"
                        ],
                        "type": "string",
                        "description": "How to sort comments (for comments operation)"
                    }
                }
            },
            "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
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
