{
  "openapi": "3.0.1",
  "info": {
    "title": "Reddit Subreddit Post Filter & Moderation Scraper",
    "description": "Scrape public subreddit listings and filter posts by keyword, score, comments, upvote ratio, age, flair, type, author, domain, NSFW or stickied status. Returns media, gallery, video, poll and crosspost fields. No login or API key.",
    "version": "1.1",
    "x-build-id": "BLjZQoaYOw4cv3DKH"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/nimbryxo-studio~reddit-subreddit-post-filter-and-moderation/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-nimbryxo-studio-reddit-subreddit-post-filter-and-moderation",
        "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/nimbryxo-studio~reddit-subreddit-post-filter-and-moderation/runs": {
      "post": {
        "operationId": "runs-sync-nimbryxo-studio-reddit-subreddit-post-filter-and-moderation",
        "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/nimbryxo-studio~reddit-subreddit-post-filter-and-moderation/run-sync": {
      "post": {
        "operationId": "run-sync-nimbryxo-studio-reddit-subreddit-post-filter-and-moderation",
        "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": [
          "subreddits"
        ],
        "properties": {
          "subreddits": {
            "title": "Subreddits",
            "type": "array",
            "description": "Public subreddits to scrape. Accepts names, r/ names or full Reddit URLs.",
            "items": {
              "type": "string"
            }
          },
          "sort": {
            "title": "Sort posts by",
            "enum": [
              "hot",
              "new",
              "top",
              "rising",
              "controversial",
              "best"
            ],
            "type": "string",
            "description": "How to order posts in each subreddit. Top and controversial use the time filter.",
            "default": "hot"
          },
          "timeFilter": {
            "title": "Time range for top / controversial",
            "enum": [
              "hour",
              "day",
              "week",
              "month",
              "year",
              "all"
            ],
            "type": "string",
            "description": "Time window used when Sort is Top or Controversial. Ignored for other sorts.",
            "default": "day"
          },
          "maxPosts": {
            "title": "Max matching posts per subreddit",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Stop after this many posts pass your filters. The actor keeps paging until it finds them or reaches Reddit's listing limit.",
            "default": 25
          },
          "maxItems": {
            "title": "Max posts in total",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Overall cap across all subreddits.",
            "default": 1000
          },
          "includeKeywords": {
            "title": "Include keywords",
            "type": "array",
            "description": "Keep posts containing at least one of these words or phrases. Matching is case-insensitive.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "Exclude keywords",
            "type": "array",
            "description": "Drop posts containing any of these words or phrases.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "keywordMatch": {
            "title": "Keyword matching",
            "enum": [
              "any",
              "all",
              "exact"
            ],
            "type": "string",
            "description": "Any keyword, all keywords, or the exact phrase formed by joining the include keywords.",
            "default": "any"
          },
          "searchIn": {
            "title": "Search keywords in",
            "enum": [
              "title-and-body",
              "title",
              "body"
            ],
            "type": "string",
            "description": "Search the title, the body, or both.",
            "default": "title-and-body"
          },
          "minScore": {
            "title": "Minimum score",
            "minimum": -10000,
            "maximum": 10000000,
            "type": "integer",
            "description": "Drop posts with a lower score. Leave empty for no minimum."
          },
          "maxScore": {
            "title": "Maximum score",
            "minimum": -10000,
            "maximum": 10000000,
            "type": "integer",
            "description": "Drop posts with a higher score. Leave empty for no maximum."
          },
          "minComments": {
            "title": "Minimum comments",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Drop posts with fewer comments. Leave empty for no minimum."
          },
          "maxComments": {
            "title": "Maximum comments",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Drop posts with more comments. Leave empty for no maximum."
          },
          "minUpvoteRatio": {
            "title": "Minimum upvote ratio",
            "minimum": 0,
            "maximum": 1,
            "type": "number",
            "description": "Keep posts with at least this upvote ratio, from 0 to 1. Leave empty for no minimum."
          },
          "postedAfter": {
            "title": "Posts created on or after",
            "type": "string",
            "description": "ISO date (2026-10-01) or a relative value such as 7 days or 24 hours. Leave empty for no lower bound."
          },
          "postedBefore": {
            "title": "Posts created on or before",
            "type": "string",
            "description": "ISO date or a relative value such as 7 days. Leave empty for no upper bound."
          },
          "maxAgeDays": {
            "title": "Maximum post age in days",
            "minimum": 1,
            "maximum": 36500,
            "type": "integer",
            "description": "Shortcut for keeping only recent posts. Posted after can also be used."
          },
          "flairAllowlist": {
            "title": "Only these post flairs",
            "type": "array",
            "description": "Case-insensitive exact flair names. Leave empty for any flair.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "postType": {
            "title": "Post type",
            "enum": [
              "all",
              "text",
              "link",
              "image",
              "video",
              "gallery",
              "poll",
              "crosspost",
              "gif",
              "multi_media"
            ],
            "type": "string",
            "description": "Keep one post type or all types.",
            "default": "all"
          },
          "excludeStickied": {
            "title": "Exclude stickied posts",
            "type": "boolean",
            "description": "Drop pinned moderator/announcement posts.",
            "default": false
          },
          "excludeNsfw": {
            "title": "Exclude NSFW posts",
            "type": "boolean",
            "description": "Drop posts marked NSFW. NSFW-only communities are hidden anonymously, so this is a per-post filter.",
            "default": false
          },
          "authorAllowlist": {
            "title": "Only these authors",
            "type": "array",
            "description": "Case-insensitive usernames. Leave empty for any author.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "authorBlocklist": {
            "title": "Block these authors",
            "type": "array",
            "description": "Case-insensitive usernames to drop.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "domainAllowlist": {
            "title": "Only these link domains",
            "type": "array",
            "description": "Keep posts linking to these domains. Self-posts always pass. Accepts bare domains or URLs.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "domainBlocklist": {
            "title": "Block these link domains",
            "type": "array",
            "description": "Drop posts linking to these domains. Self-posts always pass.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "includeSubredditInfo": {
            "title": "Include subreddit info records",
            "type": "boolean",
            "description": "Emit one extra record per subreddit with its description, weekly active users and weekly contributions. Adds one request per subreddit.",
            "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}