{
  "openapi": "3.0.1",
  "info": {
    "title": "Twitch Scraper: Channels, Streams, Clips & Games",
    "description": "Scrape Twitch channels, live streams, top games, clips, and VODs. Get followers, viewers, languages, business emails and social links, up to 1,000 streams or channels per run. No login, API key or browser. Filter by language and followers.",
    "version": "0.1",
    "x-build-id": "GokY327hMxD1iMf0a"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation-lab~twitch-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation-lab-twitch-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-lab~twitch-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation-lab-twitch-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-lab~twitch-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation-lab-twitch-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": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "Twitch scraping mode",
            "enum": [
              "channels",
              "searchChannels",
              "topStreams",
              "gameStreams",
              "topGames",
              "clips"
            ],
            "type": "string",
            "description": "Choose what to scrape from Twitch.",
            "default": "channels"
          },
          "channelUsernames": {
            "title": "Twitch channel usernames or URLs",
            "type": "array",
            "description": "Twitch usernames or channel URLs (e.g., \"shroud\" or \"https://www.twitch.tv/pokimane\"). Used in Channel Profiles and Channel Clips modes.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "searchQuery": {
            "title": "Twitch channel search query",
            "type": "string",
            "description": "Search term for finding channels. Used only in Search Channels mode. Returns up to about 1,000 channels per search."
          },
          "gameName": {
            "title": "Twitch game/category name",
            "type": "string",
            "description": "Game or category name as shown on Twitch (e.g., \"League of Legends\" or \"Just Chatting\"). A category URL or slug also works. Used only in Streams by Game mode."
          },
          "maxResults": {
            "title": "Maximum Twitch results (items)",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum number of items to return. Channel Profiles mode returns one row per username and ignores this. Search and live streams go up to 1,000; Top Games up to 100; Clips up to 100 per channel. You are charged only for rows you receive.",
            "default": 30
          },
          "clipPeriod": {
            "title": "Twitch clip time period",
            "enum": [
              "LAST_DAY",
              "LAST_WEEK",
              "LAST_MONTH",
              "ALL_TIME"
            ],
            "type": "string",
            "description": "Time range for clips. Used in \"Channel Clips\" mode.",
            "default": "LAST_WEEK"
          },
          "languages": {
            "title": "Stream languages",
            "type": "array",
            "description": "Only keep streams and channels in these languages. Used in Top Live Streams, Streams by Game, and Search Channels modes. Streams by Game returns about 100 streams per language at most.",
            "items": {
              "type": "string",
              "enum": [
                "EN",
                "ES",
                "JA",
                "KO",
                "PT",
                "RU",
                "DE",
                "FR",
                "ZH",
                "IT",
                "TR",
                "AR",
                "TH",
                "PL",
                "CS",
                "NL",
                "SV",
                "NO",
                "DA",
                "FI",
                "HU",
                "EL",
                "VI",
                "ID",
                "HI",
                "BG",
                "RO",
                "SK",
                "UK",
                "TL",
                "MS",
                "CA",
                "ASL",
                "OTHER"
              ],
              "enumTitles": [
                "English",
                "Spanish",
                "Japanese",
                "Korean",
                "Portuguese",
                "Russian",
                "German",
                "French",
                "Chinese",
                "Italian",
                "Turkish",
                "Arabic",
                "Thai",
                "Polish",
                "Czech",
                "Dutch",
                "Swedish",
                "Norwegian",
                "Danish",
                "Finnish",
                "Hungarian",
                "Greek",
                "Vietnamese",
                "Indonesian",
                "Hindi",
                "Bulgarian",
                "Romanian",
                "Slovak",
                "Ukrainian",
                "Tagalog",
                "Malay",
                "Catalan",
                "American Sign Language",
                "Other"
              ]
            }
          },
          "minFollowers": {
            "title": "Minimum followers",
            "minimum": 0,
            "type": "integer",
            "description": "Only keep channels with at least this many followers. Used in Top Live Streams, Streams by Game, and Search Channels modes."
          },
          "maxFollowers": {
            "title": "Maximum followers",
            "minimum": 0,
            "type": "integer",
            "description": "Only keep channels with at most this many followers. Useful for finding small and mid-size streamers."
          },
          "includeVideos": {
            "title": "Include Recent Videos",
            "type": "boolean",
            "description": "Fetch recent VODs for each channel (Channel Profiles mode). Set the number in Recent videos per channel.",
            "default": true
          },
          "includeClips": {
            "title": "Include Top Clips",
            "type": "boolean",
            "description": "Fetch top clips for each channel (Channel Profiles mode). Set the number in Top clips per channel.",
            "default": false
          },
          "maxVideosPerChannel": {
            "title": "Recent videos per channel",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "How many recent VODs to include for each channel when Include Recent Videos is on. Up to 100, at no extra charge.",
            "default": 5
          },
          "maxClipsPerChannel": {
            "title": "Top clips per channel",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "How many top clips to include for each channel when Include Top Clips is on. Up to 100, at no extra charge.",
            "default": 5
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}