{
  "openapi": "3.0.1",
  "info": {
    "title": "Twitter (X) Email & Lead Finder",
    "description": "Get verified business emails from X (Twitter) profiles in seconds. Feed it handles, URLs, or keyword searches and export ready-to-use leads with follower counts, verification badges, and MX-validated contact data.",
    "version": "0.0",
    "x-build-id": "zemnUWKsPgQgQiCeD"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lurkapi~x-twitter-email-lead-finder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lurkapi-x-twitter-email-lead-finder",
        "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-email-lead-finder/runs": {
      "post": {
        "operationId": "runs-sync-lurkapi-x-twitter-email-lead-finder",
        "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-email-lead-finder/run-sync": {
      "post": {
        "operationId": "run-sync-lurkapi-x-twitter-email-lead-finder",
        "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 profile URLs. Any /handle path is accepted; extra suffixes are ignored.",
            "items": {
              "type": "string"
            }
          },
          "searchQueries": {
            "title": "🔍 Search keywords ($)",
            "type": "array",
            "description": "Search X for profiles matching each keyword and extract their emails. See Pricing for the additional per-row cost when an email is discovered through this path.",
            "items": {
              "type": "string"
            }
          },
          "maxResultsPerQuery": {
            "title": "Max profiles per keyword",
            "minimum": 1,
            "maximum": 300,
            "type": "integer",
            "description": "Cap how many profiles to enrich per keyword search.",
            "default": 30
          },
          "expandFollowers": {
            "title": "Scrape each target's followers (or following) ($)",
            "type": "boolean",
            "description": "For every direct-target handle you provide above, also pull emails from the accounts around it. See Pricing for the additional per-row cost when an email is discovered through this path.",
            "default": false
          },
          "expansionRelation": {
            "title": "Which list to scrape",
            "enum": [
              "Followers",
              "Following"
            ],
            "type": "string",
            "description": "Choose whether to pull leads from accounts that follow the target, or from accounts the target itself follows.",
            "default": "Followers"
          },
          "maxFollowersPerHandle": {
            "title": "Max profiles to scan per target",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Upper bound on how many follower or following rows to enrich for each direct-target handle.",
            "default": 200
          },
          "minFollowers": {
            "title": "Minimum followers",
            "minimum": 0,
            "type": "integer",
            "description": "Drop rows below this follower count."
          },
          "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 accounts only",
            "type": "boolean",
            "description": "Keep only accounts with any verified badge (Blue, Business, Government, or Legacy).",
            "default": false
          },
          "verifiedType": {
            "title": "Verified type",
            "enum": [
              "",
              "Blue",
              "Business",
              "Government",
              "Legacy"
            ],
            "type": "string",
            "description": "Filter to a specific verified badge type.",
            "default": ""
          },
          "minAccountAgeDays": {
            "title": "Minimum account age (days)",
            "minimum": 0,
            "type": "integer",
            "description": "Drop accounts joined less than this many days ago."
          },
          "bioContains": {
            "title": "Bio must contain this text",
            "type": "string",
            "description": "Only keep profiles whose bio contains this text (case-insensitive)."
          },
          "locationContains": {
            "title": "Location must contain this text",
            "type": "string",
            "description": "Only keep profiles whose location contains this text (case-insensitive)."
          },
          "usernameContains": {
            "title": "Username must contain this text",
            "type": "string",
            "description": "Only keep profiles whose handle contains this text (case-insensitive)."
          },
          "maxItems": {
            "title": "Max email rows per run",
            "minimum": 1,
            "type": "integer",
            "description": "Hard cap on total email rows shipped across all sources. Default 100.",
            "default": 100
          },
          "sortBy": {
            "title": "Sort",
            "enum": [
              "Default",
              "followers",
              "following",
              "tweetCount",
              "createdAt"
            ],
            "type": "string",
            "description": "Field used to order successful rows before they land in the output. Choose Default to keep them in the order they were found.",
            "default": "Default"
          },
          "sortOrder": {
            "title": "Sort order",
            "enum": [
              "desc",
              "asc"
            ],
            "type": "string",
            "description": "Ignored when Sort = Default.",
            "default": "desc"
          },
          "validateEmails": {
            "title": "Validate emails (MX + disposable check) ($)",
            "type": "boolean",
            "description": "Verify each extracted email by resolving its domain's mail server and flagging known disposable providers. Every row gets a validation verdict (valid, invalid, disposable, or unchecked). See Pricing for the per-validation cost.",
            "default": true
          },
          "outputId": {
            "title": "Include numeric user ID",
            "type": "boolean",
            "description": "Include the numeric user ID in the output row.",
            "default": true
          },
          "outputUsername": {
            "title": "Include username",
            "type": "boolean",
            "description": "Include the username in the output row.",
            "default": true
          },
          "outputName": {
            "title": "Include display name",
            "type": "boolean",
            "description": "Include the display name in the output row.",
            "default": true
          },
          "outputBio": {
            "title": "Include bio",
            "type": "boolean",
            "description": "Include the bio in the output row.",
            "default": true
          },
          "outputUrl": {
            "title": "Include profile URL",
            "type": "boolean",
            "description": "Include the profile URL in the output row.",
            "default": true
          },
          "outputFollowers": {
            "title": "Include followers count",
            "type": "boolean",
            "description": "Include the followers count in the output row.",
            "default": true
          },
          "outputFollowing": {
            "title": "Include following count",
            "type": "boolean",
            "description": "Include the following count in the output row.",
            "default": true
          },
          "outputTweetCount": {
            "title": "Include tweet count",
            "type": "boolean",
            "description": "Include the tweet count in the output row.",
            "default": true
          },
          "outputMediaCount": {
            "title": "Include media count",
            "type": "boolean",
            "description": "Include the media count in the output row.",
            "default": false
          },
          "outputLikesCount": {
            "title": "Include likes count",
            "type": "boolean",
            "description": "Include the likes count in the output row.",
            "default": false
          },
          "outputVerified": {
            "title": "Include verified flag",
            "type": "boolean",
            "description": "Include the verified flag in the output row.",
            "default": true
          },
          "outputVerifiedType": {
            "title": "Include verified type",
            "type": "boolean",
            "description": "Include the verified type (Blue, Business, Government, Legacy) in the output row.",
            "default": true
          },
          "outputLocation": {
            "title": "Include location",
            "type": "boolean",
            "description": "Include the location in the output row.",
            "default": true
          },
          "outputWebsite": {
            "title": "Include website",
            "type": "boolean",
            "description": "Include the website URL in the output row.",
            "default": true
          },
          "outputProfileImageUrl": {
            "title": "Include profile image URL",
            "type": "boolean",
            "description": "Include the profile image URL in the output row.",
            "default": true
          },
          "outputBannerUrl": {
            "title": "Include banner URL",
            "type": "boolean",
            "description": "Include the banner image URL in the output row.",
            "default": false
          },
          "outputCreatedAt": {
            "title": "Include createdAt (joined)",
            "type": "boolean",
            "description": "Include the account created date in the output row.",
            "default": true
          },
          "outputProtected": {
            "title": "Include protected flag",
            "type": "boolean",
            "description": "Include the protected flag in the output row.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}