{
  "openapi": "3.0.1",
  "info": {
    "title": "Light-Weight Reddit Scraper",
    "description": "Fast Reddit data without the bloat. Scrape posts, feeds, search results, media, and comments with flexible filters and clean structured output for research, monitoring, and content discovery",
    "version": "0.0",
    "x-build-id": "N3nYM8SixHwoylUz6"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/glitch_404~RedditScraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-glitch_404-RedditScraper",
        "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/glitch_404~RedditScraper/runs": {
      "post": {
        "operationId": "runs-sync-glitch_404-RedditScraper",
        "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/glitch_404~RedditScraper/run-sync": {
      "post": {
        "operationId": "run-sync-glitch_404-RedditScraper",
        "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": [
          "links",
          "maxPosts"
        ],
        "properties": {
          "links": {
            "title": "Posts & Feeds URLs",
            "minItems": 1,
            "maxItems": 100,
            "type": "array",
            "description": "Add one or more Reddit URLs to crawl. (Maximum is 100 URLs) \n - You can use subreddit URLs \n - Users URLs \n - Custom feeds URLs \n - Custom Search URLs \n - Posts URLs.",
            "default": [
              "https://www.reddit.com/r/mildlyinfuriating/"
            ],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxPosts": {
            "title": "Maximum posts per link",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Set the maximum number of Reddit posts the actor should collect. Minimum is 10, and Maximum is 10000.\n careful with this option this will scrape the specified amount for every link\n so if you set it to 1000 and provide 10 subreddits/feeds links it will target crawling 10,000 posts and will keep going until 10K posts are crawled and this is not possible for this crawler it will result in 429 (too many requests) from Reddit limiting the actor and stopping it.",
            "default": 10
          },
          "cookies": {
            "title": "Account cookies (Optional) ((Not Very Optional))",
            "type": "object",
            "description": "Paste a JSON object with authenticated Reddit cookies (loid, reddit_session)\n - if you want to scrape as a logged-in account, important note: every account is limited to 100 requests per minute\n - might be needed if the actor is now working probably.\n - Example: {\"cookie_name\": \"cookie_value\", \"another_cookie_name\": \"another_cookie_value\"}"
          },
          "deepCrawl": {
            "title": "Deep crawl for comments (Charges Extra) (Requires Cookies)",
            "type": "boolean",
            "description": "Requires an account Cookies to be provided (loid, reddit_session), Enable this to try and crawl the full comment section\nthis feature is not working probably \n - issue is that it will only crawl top level comments no comments replies only the post's comments \n - also this feature will crawl for the posts links only any feeds links will be crawled without any comments",
            "default": false
          },
          "includeComments": {
            "title": "Include comments - When crawling a post",
            "type": "boolean",
            "description": "When enabled, the actor will crawl and return comments with the post, disable it and you won't get any comments with any post at all\nComments are not available when crawling a feed for an amount of posts and this behaviour can't be changed comments can only be crawled for every post link that is provided",
            "default": false
          },
          "includeRemovedComments": {
            "title": "Include removed comments",
            "type": "boolean",
            "description": "When enabled, the actor will keep removed comments in the output.\n When disabled, removed comments are skipped and filtered out",
            "default": false
          },
          "keywords": {
            "title": "Keyword filters",
            "type": "array",
            "description": "Filter posts by keyword or phrase. Add each keyword as a separate item. Examples: bitcoin, climate change, \"data breach\". Leave empty to disable keyword filtering.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "filterFields": {
            "title": "Filter Fields - Drop posts missing selected fields",
            "minItems": 0,
            "maxItems": 43,
            "type": "array",
            "description": "Drop any post that does not contain all selected fields. Leave empty to keep all posts.\nExample: selecting body and title will keep only posts that have both fields populated.\n If title or body are missing then the post will be dropped and it won't show up",
            "items": {
              "type": "string",
              "enum": [
                "thumbnail",
                "post_id",
                "crosspost_parent",
                "publisher_id",
                "subreddit_id",
                "type",
                "subreddit_type",
                "title",
                "post_flair",
                "publisher",
                "subreddit",
                "published_at",
                "body",
                "sentiment",
                "sentiment_score",
                "score",
                "upvote_ratio",
                "upvotes",
                "downvotes",
                "total_awards",
                "total_crossposts",
                "total_comments",
                "total_subreddit_subs",
                "is_hidden",
                "is_crosspost",
                "is_pinned",
                "is_author_premium",
                "is_edited",
                "can_gild",
                "is_comments_still_active",
                "is_score_hidden",
                "is_over_18",
                "is_locked",
                "is_spoiler",
                "is_gallery",
                "is_video",
                "is_original_content",
                "is_crosspostable",
                "is_removed",
                "removed",
                "link",
                "found_media",
                "comments"
              ],
              "enumTitles": [
                "Thumbnail",
                "Post ID",
                "Crosspost parent",
                "Publisher ID",
                "Subreddit ID",
                "Type",
                "Subreddit type",
                "Title",
                "Post flair",
                "Publisher",
                "Subreddit",
                "Published at",
                "Body",
                "Sentiment",
                "Sentiment score",
                "Score",
                "Upvote ratio",
                "Upvotes",
                "Downvotes",
                "Total awards",
                "Total crossposts",
                "Total comments",
                "Total subreddit subscribers",
                "Is hidden",
                "Is crosspost",
                "Is pinned",
                "Is author premium",
                "Is edited",
                "Can gild",
                "Comments still active",
                "Score hidden",
                "Over 18",
                "Locked",
                "Spoiler",
                "Is Gallery",
                "Is Video",
                "Original content",
                "Crosspostable",
                "Is Removed",
                "Removed",
                "Link",
                "Found Media",
                "Comments"
              ]
            },
            "default": []
          },
          "stopDate": {
            "title": "Stop date",
            "type": "string",
            "description": "won't return any posts older than this date. Only posts published on or after the selected date will be collected. Leave empty to crawl without a date limit.",
            "default": null
          },
          "includeCrossposts": {
            "title": "Include crossposts",
            "type": "boolean",
            "description": "When enabled, the actor will keep crossposted Reddit posts in the output.\n When disabled, crossposts are skipped and filtered out",
            "default": true
          },
          "includeRemovedPosts": {
            "title": "Include removed posts",
            "type": "boolean",
            "description": "When enabled, the actor will keep removed Reddit posts in the output.\n When disabled, removed posts are skipped and filtered out",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Choose whether the actor should use Apify Proxy or a custom proxy setup. Enable proxies if Reddit starts returning blocked or empty responses.",
            "default": {
              "useApifyProxy": 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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}