{
  "openapi": "3.0.1",
  "info": {
    "title": "Threads Scraper: Posts, Search, Tags, Replies",
    "description": "Scrape Threads without a login: the posts of any profile, keyword and tag search results, the replies under a post and the profile itself (followers, bio, verified). One row per post with text, author, time, likes, replies, reposts, quotes, media and links. JSON, CSV, API. Pay per post.",
    "version": "0.1",
    "x-build-id": "ZIaBQGFzoLH90rlsM"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation_craft~threads-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation_craft-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/automation_craft~threads-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation_craft-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/automation_craft~threads-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation_craft-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",
        "properties": {
          "usernames": {
            "title": "Profiles (usernames or profile URLs)",
            "type": "array",
            "description": "Threads handles or profile URLs, one per line: zuck, @mosseri, https://www.threads.com/@netflix. Each gives one profile row (followers, bio, verified) and its newest posts up to maxPostsPerProfile. A handle that does not exist is a free status row. Up to 200 per run.",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "Search words",
            "type": "array",
            "description": "Keyword searches, one per line, as typed into the Threads search box. Each returns the top posts the logged out search shows (about 20 to 28 per page); searchMode adds the recent page or one page per day of the date range. Up to 100 per run.",
            "items": {
              "type": "string"
            }
          },
          "tags": {
            "title": "Tags",
            "type": "array",
            "description": "Threads tags (topics), one per line, with or without the #: nike, #marathontraining. Searched like a keyword in tag mode. Up to 100 per run.",
            "items": {
              "type": "string"
            }
          },
          "postUrls": {
            "title": "Posts (URLs or codes)",
            "type": "array",
            "description": "Post URLs such as https://www.threads.com/@zuck/post/Dd1MqfcG0aH, or post codes, one per line. Each gives the post itself (with its view count) plus the first reply threads the public page shows, up to maxRepliesPerPost. A post that no longer exists is a free status row. Up to 200 per run.",
            "items": {
              "type": "string"
            }
          },
          "maxPostsPerProfile": {
            "title": "Posts per profile",
            "minimum": 0,
            "maximum": 5000,
            "type": "integer",
            "description": "Newest posts to read per profile (11 per feed page). 0 reads the profile row only. Default 50, at most 5,000."
          },
          "maxPostsPerQuery": {
            "title": "Posts per search",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Posts to keep per search word or tag across its pages. Default 100, at most 5,000."
          },
          "maxRepliesPerPost": {
            "title": "Replies per post",
            "minimum": 0,
            "maximum": 5000,
            "type": "integer",
            "description": "Replies to keep under each post URL. The logged out web shows the first reply threads of a post only (about 10 to 20 replies with their nested replies); more replies need a login, which this Actor never uses. 0 reads the post only. Default 100."
          },
          "maxPosts": {
            "title": "Posts per run",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The cap of post rows for the whole run, across every profile, search and post. Default 1,000, at most 100,000."
          },
          "searchMode": {
            "title": "Search depth",
            "enum": [
              "top",
              "recent",
              "top_and_recent",
              "daily_windows"
            ],
            "type": "string",
            "description": "top: the top posts page of each search (one page). recent: the newest posts page. top_and_recent: both. daily_windows: one top page per day between postedAfter and postedBefore (the last 7 days when no dates are given), the deepest the logged out search goes. Each page the site answers with posts is one search page event."
          },
          "postedAfter": {
            "title": "Posted on or after",
            "type": "string",
            "description": "Keep posts from this UTC day on: YYYY-MM-DD, today, yesterday, or \"7 days\", \"2 weeks\", \"1 month\" (counted back). A profile walk stops once it reaches older posts. With daily_windows this is the first day searched."
          },
          "postedBefore": {
            "title": "Posted on or before",
            "type": "string",
            "description": "Keep posts up to this UTC day: YYYY-MM-DD, today or yesterday. Default today."
          },
          "languages": {
            "title": "Languages",
            "type": "array",
            "description": "Keep only posts whose language, as Threads detects it, is one of these codes: en, es, ja, pt. Threads itself labels only Chinese, Japanese and Korean posts; every other post is classified from its text here (languageSource says which; texts under 80 characters stay unknown). Unknown posts are KEPT and marked languageUnknown true unless dropUnknownLanguage is on. The coverage row counts both.",
            "items": {
              "type": "string"
            }
          },
          "dropUnknownLanguage": {
            "title": "Drop posts without a detected language",
            "type": "boolean",
            "description": "With a languages list: drop posts that carry no language value instead of keeping them as unknown. Off by default so nothing is dropped silently."
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only posts with at least this many likes. Default 0."
          },
          "excludeReplies": {
            "title": "Exclude replies",
            "type": "boolean",
            "description": "Drop posts that are replies to another post (search results and profile feeds carry some). Off by default."
          },
          "onlyWithMedia": {
            "title": "Only posts with media",
            "type": "boolean",
            "description": "Keep only posts with an image, a video or a carousel. Off by default."
          },
          "includeProfile": {
            "title": "Profile row per username",
            "type": "boolean",
            "description": "Deliver one profile row (followers, bio, verified, links) per username looked up. On by default; switch off to read posts only."
          },
          "memoryName": {
            "title": "Memory name (pay once per post across runs)",
            "type": "string",
            "description": "Give a name and every later run with the same name delivers and charges only posts it has not delivered before: the way to run a scheduled monitor. The memory is a named key-value store this Actor creates in your account. Profile rows are delivered on every run (that is the monitoring value). Leave empty for a one off run."
          },
          "resetMemory": {
            "title": "Reset the memory",
            "type": "boolean",
            "description": "Forget every post the named memory holds before this run, so every post counts as new again (and is charged again)."
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Apify datacenter proxy by default (one exit address per run). Residential proxy is not needed; use it only if your runs see refusals."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}