{
  "openapi": "3.0.1",
  "info": {
    "title": "Threads Search Scraper - Posts, Users, Replies & Profiles",
    "description": "Search Threads posts by keyword and date, find users, export every reply on a post, and bulk look up profiles with bio, followers and links.",
    "version": "1.0",
    "x-build-id": "5C3AnwNQ5YV3G5MJ6"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/seemuapps~threads-search-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-seemuapps-threads-search-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/seemuapps~threads-search-scraper/runs": {
      "post": {
        "operationId": "runs-sync-seemuapps-threads-search-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/seemuapps~threads-search-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-seemuapps-threads-search-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": {
          "mode": {
            "title": "What to scrape",
            "enum": [
              "searchPosts",
              "searchUsers",
              "postReplies",
              "profiles"
            ],
            "type": "string",
            "description": "Search posts: keyword search with optional date range. Search users: find accounts matching a keyword. Replies on post URLs: the post plus its replies. Profile details: bio, follower count, verified badge and bio links for a list of usernames.",
            "default": "searchPosts"
          },
          "searchQueries": {
            "title": "Search keywords",
            "type": "array",
            "description": "Keywords, phrases or #hashtags to search for, one per line. Used by 'Search posts' and 'Search users'. Short keywords return the most results.",
            "items": {
              "type": "string"
            }
          },
          "startDate": {
            "title": "Start date (posts)",
            "type": "string",
            "description": "Search posts only: oldest day to include (YYYY-MM-DD). Leave empty to start from the latest posts and walk back day by day until the limits below are reached."
          },
          "endDate": {
            "title": "End date (posts)",
            "type": "string",
            "description": "Search posts only: newest day to include (YYYY-MM-DD). Leave empty for today. Set it to continue an earlier run further back in time."
          },
          "maxPostsPerQuery": {
            "title": "Max posts per keyword",
            "minimum": 0,
            "type": "integer",
            "description": "Search posts only: stop after this many unique posts for each keyword. 0 = no limit (bounded by Max requests per keyword).",
            "default": 50
          },
          "maxRequestsPerKeyword": {
            "title": "Max requests per keyword",
            "minimum": 1,
            "maximum": 400,
            "type": "integer",
            "description": "Search posts only: each request covers one day and returns up to about 20 posts. This caps how many days are scanned per keyword.",
            "default": 10
          },
          "includeProfileDetails": {
            "title": "Include full profile details (users)",
            "type": "boolean",
            "description": "Search users only: also fetch bio, follower count and bio links for every user found. Without it you get username, name, verified badge and picture.",
            "default": false
          },
          "postUrls": {
            "title": "Post URLs",
            "type": "array",
            "description": "Replies mode only: Threads post URLs, one per line (threads.com/@user/post/CODE, threads.net links and threads.com/t/CODE all work).",
            "items": {
              "type": "string"
            }
          },
          "includeOriginalPost": {
            "title": "Include the original post",
            "type": "boolean",
            "description": "Replies mode only: add a row for the post itself (and any follow-up posts the author added to the thread) before its replies.",
            "default": true
          },
          "includeNestedReplies": {
            "title": "Include replies to replies",
            "type": "boolean",
            "description": "Replies mode only: also open every reply that has its own replies and collect those (one extra request per reply branch, bounded by Max requests per post).",
            "default": false
          },
          "maxRepliesPerPost": {
            "title": "Max replies per post",
            "minimum": 0,
            "type": "integer",
            "description": "Replies mode only: stop after this many reply rows for each post. 0 = no limit.",
            "default": 100
          },
          "maxRequestsPerPost": {
            "title": "Max requests per post",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Replies mode only: cap on requests used for one post, including the first one. Only matters when replies to replies are included.",
            "default": 10
          },
          "usernames": {
            "title": "Usernames",
            "type": "array",
            "description": "Profile details mode only: Threads usernames or profile URLs, one per line (with or without @).",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}