{
  "openapi": "3.0.1",
  "info": {
    "title": "Twitter X Reply Scraper By Verified & Engagement Filter",
    "description": "💬 Twitter X Reply Scraper captures public replies from X/Twitter threads — usernames, timestamps, text, links, IDs & engagement. ⚡ Export CSV/JSON, filter by keywords, track sentiment & monitor campaigns. 🚀 Perfect for social listening, customer support, and research.",
    "version": "0.1",
    "x-build-id": "wr1aQC4YClsuu2s3M"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/api-empire~twitter-x-reply-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-api-empire-twitter-x-reply-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/api-empire~twitter-x-reply-scraper/runs": {
      "post": {
        "operationId": "runs-sync-api-empire-twitter-x-reply-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/api-empire~twitter-x-reply-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-api-empire-twitter-x-reply-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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "🔗 Start URLs — posts, profiles or searches",
            "type": "array",
            "description": "📋 Add any mix of three X link types:\n\n• **Post link** — `https://x.com/user/status/123…` → that post plus its replies. Works with **no login**.\n• **Profile link** — `https://x.com/nasa` → that account's recent posts plus each one's replies. Works with **no login**.\n• **Search link** — `https://x.com/search?q=…` → every matching post plus its replies. **Requires your X session** (`authToken` + `ct0`) because X refuses search to logged-out callers.\n\nAdd as many links as you need — they run one after another. 🌍✅",
            "items": {
              "type": "string"
            }
          },
          "maxSearchResults": {
            "title": "📊 Maximum posts to collect",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "🎯 How many posts to take from each link — a hard cap, never exceeded. Post links always yield one post; profile and search links yield up to this many. Higher numbers give a broader snapshot; lower numbers finish faster. ⚡📈",
            "default": 10
          },
          "maxReplies": {
            "title": "💬 Maximum replies per post",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "💡 How many replies to keep per post — counted AFTER the filters below run, and enforced as a hard cap. Note: without an X session, X server-renders only 3 replies per post to logged-out visitors, so 3 is the real ceiling in that mode. 🙌🧵",
            "default": 5
          },
          "verifiedRepliersOnly": {
            "title": "✅ Verified repliers only",
            "type": "boolean",
            "description": "Keep only replies written by an account that shows a check on X — an X Premium subscriber (`is_blue_verified`) or a verified organisation/government account (`verified_type`). Since 2023 that check is purchasable, so it means \"paid or organisation-verified\", not \"identity-vetted\". Unverified replies are dropped before your reply limit is applied. Default is off.",
            "default": false
          },
          "minReplyLikes": {
            "title": "👍 Minimum reply likes",
            "minimum": 0,
            "maximum": 10000000,
            "type": "integer",
            "description": "Drop any reply with fewer likes (favorites) than this number. Example: minReplyLikes=5 keeps only replies with 5 or more likes. Set to 0 to keep replies with any like count. Default is 0.",
            "default": 0
          },
          "replyKeywords": {
            "title": "🔍 Include replies with keywords",
            "type": "array",
            "description": "Keep only replies whose text contains at least one of these words or phrases (case-insensitive substring match). Example: [\"pitch\", \"available\"] keeps replies mentioning either. Leave empty to keep replies regardless of wording.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "🚫 Exclude replies with keywords",
            "type": "array",
            "description": "Drop any reply whose text contains one of these words or phrases (case-insensitive substring match). Example: [\"spam\", \"giveaway\"] removes replies mentioning either. Leave empty to disable. Applied after the include filter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "authToken": {
            "title": "🔐 Session — auth token (optional)",
            "type": "string",
            "description": "🔑 Optional. Your own X account's `auth_token` cookie (or set the AUTH_TOKEN environment variable). Leave empty and the Actor runs in public mode: post and profile links still work, capped at 3 replies per post. Fill it in (together with ct0) to unlock X **search** links and full reply threads. Keep it private — never share it publicly! 🤫🔒"
          },
          "ct0": {
            "title": "🛡️ Session — security (ct0, optional)",
            "type": "string",
            "description": "✨ Optional. The companion `ct0` (CSRF) cookie for your X session, or use the CT0 env var. Both authToken and ct0 must be present for session mode — one without the other stays in public mode. 🔐💙"
          },
          "proxyConfiguration": {
            "title": "🌐 Connection & privacy (proxy)",
            "type": "object",
            "description": "🌍 **Apify Proxy** settings. Recommended on: X rate-limits per IP, and rotating datacenter IPs keeps longer runs healthy. Turn it off to go out from the platform's own IP. ☁️✅",
            "default": {
              "useApifyProxy": 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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}