{
  "openapi": "3.0.1",
  "info": {
    "title": "Top 30 Zimbabwean Influencers Scraper",
    "description": "Builds a combined top-30 list of Zimbabwean social media influencers, with name, profile picture and follower counts for YouTube, Facebook, Twitter/X and TikTok.",
    "version": "1.0",
    "x-build-id": "YyMeBq0Cpf7jfJ3O9"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/outspoken_strategy~top-zim-influencers-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-outspoken_strategy-top-zim-influencers-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/outspoken_strategy~top-zim-influencers-scraper/runs": {
      "post": {
        "operationId": "runs-sync-outspoken_strategy-top-zim-influencers-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/outspoken_strategy~top-zim-influencers-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-outspoken_strategy-top-zim-influencers-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": {
          "maxItems": {
            "title": "Number of influencers in the final list",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "How many influencers to keep in the final combined ranking.",
            "default": 30
          },
          "includeDiaspora": {
            "title": "Include diaspora celebrities",
            "type": "boolean",
            "description": "Include Zimbabwean-born celebrities based abroad (e.g. Tinashe, Danai Gurira). They usually dominate the ranking, so this is off by default.",
            "default": false
          },
          "discoverFromRankings": {
            "title": "Auto-discover candidates from public rankings",
            "type": "boolean",
            "description": "Scrape public country rankings (StarNgage TikTok Zimbabwe, Social Blade YouTube Zimbabwe) to add candidates beyond the built-in seed list. Best-effort: failures are logged and skipped.",
            "default": true
          },
          "extraCandidates": {
            "title": "Extra candidates",
            "type": "array",
            "description": "Additional influencers to consider. Each object: {\"name\": \"...\", \"youtube\": \"handleOrChannelId\", \"tiktok\": \"handle\", \"twitter\": \"handle\", \"facebook\": \"pageSlug\"}. Handles are without the @. Entries here override seed entries with the same name.",
            "default": []
          },
          "youtubeApiKey": {
            "title": "YouTube Data API key (optional)",
            "type": "string",
            "description": "If set, exact subscriber counts and avatars are fetched from the official (free) YouTube Data API instead of scraping channel pages."
          },
          "useStoreActorsForTwitter": {
            "title": "Fetch Twitter/X data via an Apify Store actor",
            "type": "boolean",
            "description": "Twitter/X cannot be scraped anonymously, so follower counts are fetched by calling a Store actor (consumes Apify credits). If disabled, Twitter followers will be null and only the avatar (via unavatar.io) is included.",
            "default": true
          },
          "useStoreActorsForFacebook": {
            "title": "Fetch Facebook data via an Apify Store actor",
            "type": "boolean",
            "description": "Facebook pages cannot be scraped anonymously, so follower counts are fetched by calling apify/facebook-pages-scraper (consumes Apify credits). If disabled, Facebook followers will be null.",
            "default": true
          },
          "twitterScraperActorId": {
            "title": "Twitter scraper actor ID",
            "type": "string",
            "description": "Store actor used to fetch Twitter/X profiles.",
            "default": "apidojo/twitter-user-scraper"
          },
          "facebookScraperActorId": {
            "title": "Facebook scraper actor ID",
            "type": "string",
            "description": "Store actor used to fetch Facebook pages.",
            "default": "apify/facebook-pages-scraper"
          },
          "maxCandidates": {
            "title": "Max candidates to enrich (debug)",
            "minimum": 0,
            "type": "integer",
            "description": "Cap the candidate pool before enrichment. 0 = no cap. Useful for cheap test runs.",
            "default": 0
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Proxies used for scraping YouTube/TikTok pages and ranking sites. Apify residential proxies strongly recommended for TikTok.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}