{
  "openapi": "3.0.1",
  "info": {
    "title": "Reddit Scraper API — Posts, Comments, Search, Users",
    "description": "Scrape Reddit posts, comments, subreddits, users and search into one flat table. Score and upvote ratio on every row, no flag to enable. No API key, no login. Paste any Reddit URL or community name. Filters run before billing, so the rows you discard are free.",
    "version": "0.1",
    "x-build-id": "sIGBP5XXGaUxKtM20"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/vonsensey~reddit-scraper-posts-comments-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-vonsensey-reddit-scraper-posts-comments-api",
        "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/vonsensey~reddit-scraper-posts-comments-api/runs": {
      "post": {
        "operationId": "runs-sync-vonsensey-reddit-scraper-posts-comments-api",
        "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/vonsensey~reddit-scraper-posts-comments-api/run-sync": {
      "post": {
        "operationId": "run-sync-vonsensey-reddit-scraper-posts-comments-api",
        "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",
        "properties": {
          "startUrls": {
            "title": "Reddit URLs",
            "type": "array",
            "description": "Paste any Reddit address and it is routed for you: a community, a sorted community feed, a post, a comment permalink, a user profile, a search results page, or a redd.it short link. Mix them freely.",
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "subreddits": {
            "title": "Communities",
            "type": "array",
            "description": "Community names, with or without the r/ prefix — for example `askreddit` or `r/rust`. If you also fill in Keywords, these become the communities those keywords are searched inside.",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "Keywords",
            "type": "array",
            "description": "Search terms. Supports Reddit's own operators, e.g. `title:launch`, `author:spez`, `\"exact phrase\"`, `flair:news`. Searched across all of Reddit, or inside the communities above if you listed any.",
            "items": {
              "type": "string"
            }
          },
          "usernames": {
            "title": "Users",
            "type": "array",
            "description": "Reddit usernames, with or without the u/ prefix. Returns that user's public posts.",
            "items": {
              "type": "string"
            }
          },
          "sort": {
            "title": "Sort communities by",
            "enum": [
              "hot",
              "new",
              "top",
              "rising",
              "controversial",
              "best"
            ],
            "type": "string",
            "description": "Which community feed to read. `top` and `controversial` also use the time window below.",
            "default": "hot"
          },
          "time": {
            "title": "Time window",
            "enum": [
              "hour",
              "day",
              "week",
              "month",
              "year",
              "all"
            ],
            "type": "string",
            "description": "Applies to Top and Controversial sorts and to keyword searches.",
            "default": "all"
          },
          "maxPostsPerSource": {
            "title": "Results per source",
            "minimum": 1,
            "maximum": 1000000,
            "type": "integer",
            "description": "How many posts to take from each community, search or user. Reddit itself stops a single feed at about 1,000 — switch on Deep coverage below to go past that.",
            "default": 100
          },
          "maxItems": {
            "title": "Total row limit",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "A hard ceiling on billable rows for the whole run, counting posts and comments together. Leave at 0 for no limit. This is a spending safety net: the run stops here even if more data exists.",
            "default": 0
          },
          "deepCoverage": {
            "title": "Deep coverage — go past Reddit's per-feed ceiling",
            "type": "boolean",
            "description": "Reddit stops any single feed at roughly 1,000 posts. With this on, the same community is read through its other sorts and time windows and the results are de-duplicated, which reaches materially more of it. Costs more requests, so leave it off for small pulls.",
            "default": false
          },
          "includeComments": {
            "title": "Include comments",
            "type": "boolean",
            "description": "Fetch the comment thread under every post returned. Comments are billed at their own, lower rate.",
            "default": false
          },
          "maxCommentsPerPost": {
            "title": "Comments per post",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Upper bound on comments returned for each post, including replies pulled out from behind Reddit's 'load more' links.",
            "default": 50
          },
          "commentSort": {
            "title": "Sort comments by",
            "enum": [
              "confidence",
              "top",
              "new",
              "controversial",
              "old",
              "qa"
            ],
            "type": "string",
            "description": "Which comments Reddit returns first when a thread is larger than your per-post limit. Best is Reddit's own default ranking.",
            "default": "confidence"
          },
          "maxCommentDepth": {
            "title": "Reply depth",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "How deep to follow reply chains. 0 returns only top-level comments.",
            "default": 10
          },
          "postedAfter": {
            "title": "Posted after",
            "type": "string",
            "description": "Keep only posts and comments newer than this. Takes a date (`2026-01-31`) or an age (`7 days`, `12h`, `3 months`) — an age is the one to use in a scheduled run, because a fixed date goes stale. Rows outside the window are discarded before billing, so you are never charged for them."
          },
          "postedBefore": {
            "title": "Posted before",
            "type": "string",
            "description": "Keep only posts and comments older than this. Same formats as above. Combine the two to pull an exact date range."
          },
          "mustIncludeKeywords": {
            "title": "Must contain",
            "type": "array",
            "description": "Keep only rows whose text contains at least one of these words. Case-insensitive. Discarded rows are free.",
            "items": {
              "type": "string"
            }
          },
          "mustExcludeKeywords": {
            "title": "Must not contain",
            "type": "array",
            "description": "Drop rows whose text contains any of these words. Discarded rows are free.",
            "items": {
              "type": "string"
            }
          },
          "minScore": {
            "title": "Minimum score",
            "type": "integer",
            "description": "Drop posts and comments below this score. Leave empty for no minimum. Discarded rows are free."
          },
          "skipNsfw": {
            "title": "Skip NSFW posts",
            "type": "boolean",
            "description": "Drop posts marked over-18 before they are delivered or billed.",
            "default": false
          },
          "onlyNew": {
            "title": "Only rows I have not had before",
            "type": "boolean",
            "description": "For scheduled runs. Remembers what this input already returned and delivers only what is new since last time — so a daily run does not re-charge you for the same posts every day. The first run returns everything.",
            "default": false
          },
          "feedName": {
            "title": "Feed name",
            "type": "string",
            "description": "Optional label that groups runs sharing one 'only new' memory. Leave empty and it is derived from your inputs, so each distinct input list remembers separately."
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Lower this if you are on a small proxy allowance.",
            "default": 8
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Reddit refuses datacenter addresses, so residential proxy is the default and is required for the Actor to return anything.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}