{
  "openapi": "3.0.1",
  "info": {
    "title": "Meta Threads Scraper & Threads API: Posts, Profiles, Replies",
    "description": "Scrape public Meta Threads posts, profiles, keyword search and post replies to CSV, JSON or Excel. No login or cookies. Start with a full profile snapshot: $1 per 1,000 posts, $1.50 per 1,000 profiles. Logged-out keyword search coverage is limited.",
    "version": "0.1",
    "x-build-id": "hzfKuIBAhZmvtiJOx"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/varnmill~threads-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-varnmill-threads-scraper",
        "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/varnmill~threads-scraper/runs": {
      "post": {
        "operationId": "runs-sync-varnmill-threads-scraper",
        "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/varnmill~threads-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-varnmill-threads-scraper",
        "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": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "What to scrape",
            "enum": [
              "posts",
              "search",
              "replies",
              "profiles"
            ],
            "type": "string",
            "description": "posts: latest posts of each profile (paginated). search: keyword search results. replies: replies under each post URL. profiles: profile details only (followers, bio, links).",
            "default": "posts"
          },
          "usernames": {
            "title": "Usernames or profile URLs",
            "type": "array",
            "description": "For 'Profile posts' and 'Profile details'. Accepts zuck, @zuck or https://www.threads.com/@zuck (threads.net links work too).",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "Search keywords",
            "type": "array",
            "description": "For 'Keyword search'. Each keyword is searched separately, the same as typing it into the Threads search box. Hashtags like #coffee work too.",
            "items": {
              "type": "string"
            }
          },
          "postUrls": {
            "title": "Post URLs",
            "type": "array",
            "description": "For 'Post replies'. Links like https://www.threads.com/@zuck/post/DeZtp-TkQHh. The post itself is returned first, then its replies.",
            "items": {
              "type": "string"
            }
          },
          "maxPostsPerProfile": {
            "title": "Max posts per profile",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stop after this many posts per profile ('Profile posts' mode). Threads serves 15 per page.",
            "default": 30
          },
          "maxResultsPerQuery": {
            "title": "Max results per keyword",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Stop after this many posts per keyword ('Keyword search' mode). Logged-out Threads search returns roughly 20 to 60 posts per keyword; schedule the run with 'Only new posts' to collect more over time.",
            "default": 50
          },
          "includeTopicTagResults": {
            "title": "Also search topic tags",
            "type": "boolean",
            "description": "Keyword search: also read the topic-tag results for the keyword, which usually adds 10 to 30 different posts.",
            "default": true
          },
          "maxRepliesPerPost": {
            "title": "Max replies per post",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stop after this many replies per post ('Post replies' mode). Direct replies and the visible sub-replies under them both count.",
            "default": 50
          },
          "includeParentPost": {
            "title": "Include the post itself",
            "type": "boolean",
            "description": "Post replies: also output the post the replies belong to (charged as one post).",
            "default": true
          },
          "includeProfile": {
            "title": "Also output each profile",
            "type": "boolean",
            "description": "Profile posts: add one profile row (followers, bio, links) per username before its posts.",
            "default": false
          },
          "postedAfter": {
            "title": "Only posts newer than",
            "type": "string",
            "description": "Skip older posts. A date (2026-10-01), an ISO timestamp, or a relative period such as '7 days' or '24 hours'. In 'Profile posts' mode pagination stops once posts get older than this."
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Skip posts with fewer likes than this. 0 keeps everything.",
            "default": 0
          },
          "onlyNewPosts": {
            "title": "Only new posts (monitor mode)",
            "type": "boolean",
            "description": "Remember delivered post/reply IDs per target and output unseen rows within the configured scan limit (seen rows count toward that limit). Keep one consistent scope per memory name. Start fees and optional profile rows still apply. Capped undelivered rows remain eligible for retry.",
            "default": false
          },
          "stateStoreName": {
            "title": "Monitor memory name",
            "type": "string",
            "description": "Key-value store holding monitor memory. Use different names for independent scopes. Runs sharing this name and target serialize access; hard interruption between delivery and state storage may cause duplicate rows on retry.",
            "default": "threads-scraper-seen"
          },
          "maxConcurrency": {
            "title": "Parallel inputs",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "How many profiles, keywords or posts to process at the same time.",
            "default": 3
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Not needed: by default the Actor connects directly and only switches to Apify datacenter proxy if Threads starts refusing requests. Residential proxy is never required.",
            "default": {
              "useApifyProxy": false
            }
          },
          "autoProxyFallback": {
            "title": "Fall back to datacenter proxy when refused",
            "type": "boolean",
            "description": "When no proxy is selected and Threads refuses requests, retry through Apify datacenter proxy automatically.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}