{
  "openapi": "3.0.1",
  "info": {
    "title": "X.com (Twitter) Follower Scraper",
    "description": "Scrape followers, following, verified followers, list members, and community members from any X.com profile. Full profile data per row with filters and sort.",
    "version": "0.0",
    "x-build-id": "s51NenkAPQInjqi0N"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lurkapi~x-twitter-follower-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lurkapi-x-twitter-follower-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/lurkapi~x-twitter-follower-scraper/runs": {
      "post": {
        "operationId": "runs-sync-lurkapi-x-twitter-follower-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/lurkapi~x-twitter-follower-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-lurkapi-x-twitter-follower-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": {
          "handles": {
            "title": "👤 X handles",
            "type": "array",
            "description": "Usernames (e.g. elonmusk) or full profile URLs (https://x.com/elonmusk). One entry per target.",
            "items": {
              "type": "string"
            }
          },
          "userIds": {
            "title": "🔢 Numeric user IDs",
            "type": "array",
            "description": "Numeric X user IDs (e.g. 44196397). Useful when a handle has changed.",
            "items": {
              "type": "string"
            }
          },
          "urls": {
            "title": "🔗 Full URLs",
            "type": "array",
            "description": "Full X URLs. Relation auto-detected from path suffix (/followers, /following, /verified_followers, /i/lists/.../members). Bare profile URLs use the Relation dropdown.",
            "items": {
              "type": "string"
            }
          },
          "relation": {
            "title": "Relation",
            "enum": [
              "Followers",
              "Following",
              "Verified Followers",
              "List Members",
              "Community Members"
            ],
            "type": "string",
            "description": "What to scrape for each target. Ignored when a URL already says (e.g. /followers).",
            "default": "Followers"
          },
          "maxItems": {
            "title": "Max followers per run",
            "minimum": 1,
            "type": "integer",
            "description": "Hard cap on total rows returned across all targets. Default 100.",
            "default": 100
          },
          "maxItemsPerTarget": {
            "title": "Max followers per target",
            "minimum": 1,
            "type": "integer",
            "description": "Hard cap per target. Default 100.",
            "default": 100
          },
          "skipFirst": {
            "title": "Skip first N",
            "minimum": 0,
            "type": "integer",
            "description": "Skip the first N followers X returns (per target). Use to resume where a prior run stopped without re-paying for already-scraped rows. Applied BEFORE filters. Default 0.",
            "default": 0
          },
          "sortBy": {
            "title": "Sort",
            "enum": [
              "Default",
              "followers",
              "following",
              "tweetCount",
              "createdAt"
            ],
            "type": "string",
            "description": "Default = newest follow first. Other options sort the results.",
            "default": "Default"
          },
          "sortOrder": {
            "title": "Sort order",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Ignored when Sort = Default.",
            "default": "desc"
          },
          "minFollowers": {
            "title": "Minimum followers",
            "minimum": 0,
            "type": "integer",
            "description": "Drop rows below this follower count. Filtered rows are FREE (not billed)."
          },
          "maxFollowers": {
            "title": "Maximum followers",
            "minimum": 0,
            "type": "integer",
            "description": "Drop rows above this follower count."
          },
          "minFollowing": {
            "title": "Minimum following",
            "minimum": 0,
            "type": "integer",
            "description": "Drop rows below this following count."
          },
          "maxFollowing": {
            "title": "Maximum following",
            "minimum": 0,
            "type": "integer",
            "description": "Drop rows above this following count."
          },
          "verifiedOnly": {
            "title": "Verified only",
            "type": "boolean",
            "description": "Keep only verified accounts (blue-check or legacy).",
            "default": false
          },
          "verifiedType": {
            "title": "Verified type",
            "enum": [
              "",
              "Blue",
              "Business",
              "Government"
            ],
            "type": "string",
            "description": "Restrict to a specific verification type. Ignored when Verified only is off.",
            "default": ""
          },
          "minAccountAgeDays": {
            "title": "Minimum account age (days)",
            "minimum": 0,
            "type": "integer",
            "description": "Drop accounts newer than this many days. Useful to filter out bots."
          },
          "bioContains": {
            "title": "Bio contains",
            "type": "string",
            "description": "Keep rows whose bio contains this text."
          },
          "locationContains": {
            "title": "Location contains",
            "type": "string",
            "description": "Keep rows whose location contains this text."
          },
          "usernameContains": {
            "title": "Username contains",
            "type": "string",
            "description": "Keep rows whose @handle contains this text."
          },
          "hasWebsite": {
            "title": "Has website",
            "type": "boolean",
            "description": "Keep only accounts that have a website link in their profile.",
            "default": false
          },
          "hasLocation": {
            "title": "Has location",
            "type": "boolean",
            "description": "Keep only accounts with a self-set location.",
            "default": false
          },
          "hasBio": {
            "title": "Has bio",
            "type": "boolean",
            "description": "Keep only accounts with a non-empty bio.",
            "default": false
          },
          "extractEmails": {
            "title": "Extract emails ($)",
            "type": "boolean",
            "description": "Scan each follower's bio and website for an email address. Charged only when an email is actually found. Failed lookups are free. Adds an `email` field to the row on success.",
            "default": false
          },
          "outputId": {
            "title": "id",
            "type": "boolean",
            "description": "Numeric X user ID.",
            "default": true
          },
          "outputUsername": {
            "title": "username",
            "type": "boolean",
            "description": "@ handle.",
            "default": true
          },
          "outputName": {
            "title": "name",
            "type": "boolean",
            "description": "Display name.",
            "default": true
          },
          "outputBio": {
            "title": "bio",
            "type": "boolean",
            "description": "Profile bio / description.",
            "default": true
          },
          "outputUrl": {
            "title": "url",
            "type": "boolean",
            "description": "Canonical profile URL.",
            "default": true
          },
          "outputFollowers": {
            "title": "followers",
            "type": "boolean",
            "description": "Follower count.",
            "default": true
          },
          "outputFollowing": {
            "title": "following",
            "type": "boolean",
            "description": "Following count.",
            "default": true
          },
          "outputTweetCount": {
            "title": "tweetCount",
            "type": "boolean",
            "description": "Total tweet count.",
            "default": true
          },
          "outputMediaCount": {
            "title": "mediaCount",
            "type": "boolean",
            "description": "Media tweet count.",
            "default": true
          },
          "outputLikesCount": {
            "title": "likesCount",
            "type": "boolean",
            "description": "Favourite (likes given) count.",
            "default": true
          },
          "outputVerified": {
            "title": "verified",
            "type": "boolean",
            "description": "Boolean verified flag (blue-check or legacy).",
            "default": true
          },
          "outputVerifiedType": {
            "title": "verifiedType",
            "type": "boolean",
            "description": "Verification type (Blue / Business / Government / null).",
            "default": true
          },
          "outputLocation": {
            "title": "location",
            "type": "boolean",
            "description": "Self-set location string.",
            "default": true
          },
          "outputWebsite": {
            "title": "website",
            "type": "boolean",
            "description": "Website URL.",
            "default": true
          },
          "outputProfileImageUrl": {
            "title": "profileImageUrl",
            "type": "boolean",
            "description": "Avatar image URL (full-size, un-cropped).",
            "default": true
          },
          "outputBannerUrl": {
            "title": "bannerUrl",
            "type": "boolean",
            "description": "Header/banner image URL.",
            "default": true
          },
          "outputCreatedAt": {
            "title": "createdAt",
            "type": "boolean",
            "description": "ISO-8601 account creation date.",
            "default": true
          },
          "outputProtected": {
            "title": "protected",
            "type": "boolean",
            "description": "Boolean: whether the account is private/protected.",
            "default": true
          },
          "outputCanDm": {
            "title": "canDm",
            "type": "boolean",
            "description": "Boolean: whether the account can receive DMs from you.",
            "default": true
          },
          "outputEmail": {
            "title": "email",
            "type": "boolean",
            "description": "Email field. Only present when Extract emails add-on is enabled AND an email was found.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}