{
  "openapi": "3.0.1",
  "info": {
    "title": "vidIQ YouTube Stats & Earnings Scraper",
    "description": "Scrape public vidIQ YouTube stats without a login: channel subscribers, views and estimated earnings, world ranks, growth, video stats, top 500 rankings by category and country, channel comparisons, trending topics, keywords and TikTok sounds.",
    "version": "0.1",
    "x-build-id": "MydB2E1mlmOiOiptz"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/goat255~vidiq-youtube-stats-earnings-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-goat255-vidiq-youtube-stats-earnings-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/goat255~vidiq-youtube-stats-earnings-scraper/runs": {
      "post": {
        "operationId": "runs-sync-goat255-vidiq-youtube-stats-earnings-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/goat255~vidiq-youtube-stats-earnings-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-goat255-vidiq-youtube-stats-earnings-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": {
          "channels": {
            "title": "Channels",
            "type": "array",
            "description": "YouTube channels to get full stats and estimated earnings for. Accepts an @handle, a channel link, a channel ID or a channel name. Example: @nasa, https://www.youtube.com/@natgeo, UCLA_DiR1FfKNvjuUpBHmylQ, National Geographic.",
            "items": {
              "type": "string"
            }
          },
          "includeProfile": {
            "title": "Include channel profile",
            "type": "boolean",
            "description": "Adds the channel description, country and start date to each channel row.",
            "default": true
          },
          "includeLatestVideos": {
            "title": "Include latest videos",
            "type": "boolean",
            "description": "Adds the channel's latest long-form videos and Shorts, with views and duration.",
            "default": true
          },
          "includeSimilarChannels": {
            "title": "Include similar channels",
            "type": "boolean",
            "description": "Adds the closest-match and fastest-growing channels in the same niche, with their 30-day growth.",
            "default": false
          },
          "includeExtendedData": {
            "title": "Include extended history",
            "type": "boolean",
            "description": "Adds 30 days of daily views and earnings, the long-form vs Shorts split over 7 days to a year, and per-video likes, comments and thumbnails. For single videos it adds the full view history.",
            "default": true
          },
          "searchQueries": {
            "title": "Find channels by name",
            "type": "array",
            "description": "Channel names to search. Returns the best matching channels with their ID, @handle and subscriber count. Example: nasa, space documentaries.",
            "items": {
              "type": "string"
            }
          },
          "maxSearchResults": {
            "title": "Max results per search",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "How many matching channels to return for each name searched.",
            "default": 10
          },
          "expandSearchResults": {
            "title": "Return full stats for each match",
            "type": "boolean",
            "description": "When on, each match is returned as a full channel stats row instead of a short search result.",
            "default": false
          },
          "compareChannels": {
            "title": "Compare channels",
            "type": "array",
            "description": "Pairs of channels to compare side by side, written as two handles separated by vs. Returns subscribers, views, videos, ranks, grade, country and category for both. Example: @nasa vs @natgeo.",
            "items": {
              "type": "string"
            }
          },
          "videos": {
            "title": "Videos",
            "type": "array",
            "description": "Videos to get stats for, written as the channel handle and the video ID, or as the channel's stats page link for the video. Returns views, views per hour, likes, comments, engagement and view history. Example: @nasa/pAKqJxuxDgk.",
            "items": {
              "type": "string"
            }
          },
          "rankings": {
            "title": "Rankings",
            "type": "array",
            "description": "Most subscribed channel lists to return. Use top50, top100 or top500 for worldwide, category:gaming (or just gaming) for a category, country:in (or just in) for a country, or all-categories / all-countries for every list. Categories: autos, business, education, entertainment, food, gaming, health, lifestyle, music, news, pets, religion, sports, tech, travel.",
            "items": {
              "type": "string"
            }
          },
          "trending": {
            "title": "Trends",
            "type": "array",
            "description": "Trend lists to return. Use topics-day, topics-week or topics-month for trending search topics, keywords for trending keywords, tiktok-popular or tiktok-rising for trending TikTok sounds, or all for everything.",
            "items": {
              "type": "string"
            }
          },
          "maxConcurrency": {
            "title": "Concurrency",
            "minimum": 1,
            "maximum": 200,
            "type": "integer",
            "description": "How many requests run at the same time. Raise it to finish large jobs faster.",
            "default": 20
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxy used for requests. Rotating residential proxies are the default and are recommended for large runs.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}