{
  "openapi": "3.0.1",
  "info": {
    "title": "Weibo Scraper",
    "description": "Fast, reliable, and cost-effective Sina Weibo (新浪微博) Scraper and Weibo API. Extract public Weibo posts, creator profiles, engagement metrics, audience followers, and date-filtered hashtag searches without needing a Weibo account, login cookies, or complex browser setups.",
    "version": "0.0",
    "x-build-id": "6gbV8hQfYo0lYKiir"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/mikolabs~weibo/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-mikolabs-weibo",
        "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/mikolabs~weibo/runs": {
      "post": {
        "operationId": "runs-sync-mikolabs-weibo",
        "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/mikolabs~weibo/run-sync": {
      "post": {
        "operationId": "run-sync-mikolabs-weibo",
        "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": [
          "operation"
        ],
        "properties": {
          "operation": {
            "title": "Select Scraping Mode",
            "enum": [
              "searchWeibo",
              "weiboDetail",
              "userDetail",
              "userFans",
              "userFollowers"
            ],
            "type": "string",
            "description": "Choose the data type to collect for this run. Each mode generates a dedicated, structured dataset:\n\n• **Search Posts**: Explore posts by keyword, hashtag `#topic#`, or search URL with optional date filtering.\n• **Post Details**: Retrieve full content, metrics, media, and author details for a specific post.\n• **User Profile**: Extract creator metrics (followers, followings, status count), bio, verification, and avatar.\n• **User Fans (Followers)**: Discover users following the target account (~20 per page).\n• **Following List**: Inspect accounts that the target user follows (~20 per page).",
            "default": "searchWeibo"
          },
          "keyword": {
            "title": "Search Query / Hashtag / URL",
            "type": "string",
            "description": "Required when **Search Posts** mode is selected.\n\nEnter any Chinese or English search term, hashtag, or mobile search URL:\n• Query: `北京` (Beijing), `Tesla`, `新能源汽车`\n• Hashtag topic: `#日本出现取消吃饭现象#`\n• Mobile URL: `https://m.weibo.cn/search?containerid=...`\n\n*Note: Ignored when running Post Details or User Profile modes.*"
          },
          "startDay": {
            "title": "Start Date (Earliest)",
            "type": "string",
            "description": "Optional filter for search results. Posts published before this date are excluded.\n\nFormat: `YYYY-MM-DD` (e.g. `2026-04-01`). Defaults to **30 days ago** if left empty."
          },
          "endDay": {
            "title": "End Date (Latest)",
            "type": "string",
            "description": "Optional filter for search results. Posts published after this date are excluded.\n\nFormat: `YYYY-MM-DD` (e.g. `2026-05-15`). Defaults to **current day** if left empty."
          },
          "weiboId": {
            "title": "Weibo Post ID",
            "type": "string",
            "description": "Required when **Post Details** mode is selected.\n\nEnter the 16-digit numeric post ID (`mid`). You can locate it:\n• At the end of a mobile URL: `https://m.weibo.cn/detail/5249718969175092`\n• From the `weiboId` column of previous search runs\n\n*Note: Ignored for Search and User modes.*"
          },
          "userId": {
            "title": "Weibo User ID (UID)",
            "type": "string",
            "description": "Required when **User Profile**, **User Fans**, or **Following List** mode is selected.\n\nEnter the account's numeric UID. You can find it:\n• In the profile URL: `https://weibo.com/u/2760523085`\n• In the `userId` field of any post, search, or fan result row\n\n*Note: Some users enable privacy restrictions on their fan or following lists.*"
          },
          "maxPages": {
            "title": "Maximum Pages to Crawl",
            "minimum": 1,
            "maximum": 50,
            "type": "integer",
            "description": "Pagination limit for multi-record operations (Search Posts: ~14 items/page; Fans/Following: ~20 users/page).\n\nSingle-record operations (Post Details, User Profile) always fetch 1 item.",
            "default": 5
          },
          "proxyConfiguration": {
            "title": "Proxy Configuration",
            "type": "object",
            "description": "Proxy service used to route requests. **Residential proxies (RESIDENTIAL)** are preconfigured by default to prevent Sina Weibo IP blocking and geographical throttling.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}