{
  "openapi": "3.0.1",
  "info": {
    "title": "Threads Replies Scraper: Comments of Any Post",
    "description": "Scrape the replies of any Threads post without a login: every reply Threads serves to a logged out visitor, page by page, plus the replies of replies to the depth you choose. Text, author, time, likes, media, depth and parent on each row. JSON, CSV, Excel, API. Pay per reply.",
    "version": "0.1",
    "x-build-id": "P96c0v5YWY8AN2YGC"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation_craft~threads-replies-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation_craft-threads-replies-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-replies-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation_craft-threads-replies-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-replies-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation_craft-threads-replies-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": {
          "postUrls": {
            "title": "Post URLs",
            "type": "array",
            "description": "Threads posts whose replies you want, one per line: a post URL (threads.com or threads.net, /@user/post/CODE or /t/CODE) or a bare post code. A reply's URL works too (its own replies are read). Up to 200 per run. A post that does not exist gets a free status row.",
            "items": {
              "type": "string"
            }
          },
          "maxRepliesPerPost": {
            "title": "Replies per post",
            "minimum": 0,
            "maximum": 5000,
            "type": "integer",
            "description": "Replies to keep per post, nested replies included; the walk of that post stops when it is reached. Default 100 when left out (the Console form starts at 20), at most 5,000. 0 delivers the post row only."
          },
          "replySort": {
            "title": "Order of replies",
            "enum": [
              "oldest_first",
              "newest_first"
            ],
            "type": "string",
            "description": "oldest_first: the order Threads shows replies in, the first replies first. newest_first: the newest replies first; with a cap this keeps the latest replies. Default oldest_first, and newest_first when a memory name is given. top and recent (Threads' own names) are accepted too."
          },
          "replyDepth": {
            "title": "Reply depth",
            "enum": [
              "1",
              "2",
              "3",
              "4",
              "5",
              "6"
            ],
            "type": "string",
            "description": "1: the post's direct replies, with the nested replies Threads shows inside them. 2: also walks the replies of every reply that has more replies than were shown under it. 3 to 6: that many levels. Every row carries its depth and its parent. Default 2, and 1 when a memory name is given."
          },
          "postedAfter": {
            "title": "Replied on or after",
            "type": "string",
            "description": "Keep replies from this moment on (UTC): YYYY-MM-DD, YYYY-MM-DDTHH:MM, today, yesterday, \"7 days\", \"2 weeks\" or \"6 hours\" (counted back from the run's start). Older replies are read and left out free (a new reply can sit under an old one, so the walk reads on)."
          },
          "postedBefore": {
            "title": "Replied on or before",
            "type": "string",
            "description": "Keep replies up to this moment (UTC): YYYY-MM-DD (the end of that day), YYYY-MM-DDTHH:MM, today, yesterday or \"N hours\". With oldest_first the walk stops at the first page of direct replies newer than this (every reply under them is newer still)."
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only replies with at least this many likes. Default 0."
          },
          "excludePostAuthor": {
            "title": "Exclude the post author's own replies",
            "type": "boolean",
            "description": "Drop replies written by the author of the post (including the author's own continuation of the post). Off by default; every row carries isPostAuthor."
          },
          "onlyWithMedia": {
            "title": "Only replies with media",
            "type": "boolean",
            "description": "Keep only replies with an image, a video or a carousel. Off by default."
          },
          "languages": {
            "title": "Languages",
            "type": "array",
            "description": "Keep only replies whose language is one of these codes: en, es, ja, pt. Threads itself labels only Chinese, Japanese and Korean posts; every other reply is classified from its text here (languageSource says which; texts under 80 characters stay unknown). Unknown replies are KEPT and marked languageUnknown true unless dropUnknownLanguage is on.",
            "items": {
              "type": "string"
            }
          },
          "dropUnknownLanguage": {
            "title": "Drop replies without a detected language",
            "type": "boolean",
            "description": "With a languages list: drop replies that carry no language value instead of keeping them as unknown. Off by default so nothing is dropped silently."
          },
          "maxItems": {
            "title": "Rows per run",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The cap of post and reply rows for the whole run, across every post. No cap when left out (Replies per post and your charge limit bound the run), at most 100,000."
          },
          "memoryName": {
            "title": "Memory name (pay once per reply across runs)",
            "type": "string",
            "description": "Give a name and every later run with the same name delivers and charges only replies it has not delivered before: the way to monitor a post for new replies on a schedule. With a memory the defaults are newest_first and depth 1, so new replies come on the first pages; each run then reads on through replies it already delivered (free) within the work allowance, about 1,000 known direct replies a run, so on a busier post a run ends with stoppedBy work_allowance after its new replies. The post row is delivered on each run day with its fresh counts. The memory is a named key-value store this Actor creates in your account. Leave empty for a one off run."
          },
          "resetMemory": {
            "title": "Reset the memory",
            "type": "boolean",
            "description": "Forget every reply the named memory holds before this run, so every reply counts as new again (and is charged again)."
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Apify datacenter proxy (one exit address at a time; a run moves to a fresh exit when Threads asks it to wait, up to 4 times). Threads answers it fully, so a residential or other Apify proxy group is not used and the run says so; your own proxy URLs are used as given."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}