{
  "openapi": "3.0.1",
  "info": {
    "title": "Weibo Scraper - Posts, Comments, Hot Search, Profiles",
    "description": "Scrape public Weibo data: keyword search posts with a date window, user posts, comments with replies, post details with full text, the hot-search board and profile details. No login, no proxy setup.",
    "version": "0.1",
    "x-build-id": "CLxXATymGfPTkWG5a"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/teodor_banea~weibo-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-teodor_banea-weibo-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/teodor_banea~weibo-scraper/runs": {
      "post": {
        "operationId": "runs-sync-teodor_banea-weibo-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/teodor_banea~weibo-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-teodor_banea-weibo-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": {
          "mode": {
            "title": "What to scrape",
            "enum": [
              "keywordSearch",
              "userPosts",
              "postComments",
              "postDetails",
              "hotSearch",
              "profiles"
            ],
            "type": "string",
            "description": "Choose what the run collects. Keyword search: posts that match your words (newest first, with an optional date window). User posts: the latest posts of users. Comments: comments and replies of posts. Post details: one row per post with its full text. Hot search: the live hot-search board. Profiles: one row per user.",
            "default": "keywordSearch"
          },
          "searchQueries": {
            "title": "Search queries",
            "type": "array",
            "description": "Enter words or phrases to search Weibo for, one per line (Chinese works best, e.g. 新能源汽车). Each query is read newest first. Weibo filters what it shows in search, so results are a large sample of the matching posts, not every post. Up to 100 queries per run.",
            "items": {
              "type": "string"
            }
          },
          "dateFrom": {
            "title": "Posted from",
            "type": "string",
            "description": "Keep only posts published on or after this day (Beijing time, UTC+8), or within a recent period such as \"7 days\". Search stops as soon as it reaches older posts, so this also makes runs faster. Applies to keyword search and user posts."
          },
          "dateTo": {
            "title": "Posted until",
            "type": "string",
            "description": "Keep only posts published on or before this day (Beijing time, UTC+8; the whole day is included). Search starts at the end of this day, so you can reach older periods directly. Applies to keyword search and user posts."
          },
          "maxPostsPerQuery": {
            "title": "Maximum posts per query",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Limit the posts taken for each search query. Set to 0 for as many as Weibo lists (still limited by Maximum results).",
            "default": 100
          },
          "users": {
            "title": "Users",
            "type": "array",
            "description": "Enter Weibo users, one per line: a numeric user id (1234567890), a profile link (https://weibo.com/u/1234567890, https://m.weibo.cn/u/1234567890, or a custom address like https://weibo.com/example), or a screen name. Up to 500 per run.",
            "items": {
              "type": "string"
            }
          },
          "maxPostsPerUser": {
            "title": "Maximum posts per user",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Limit the posts taken from each user (newest first). Weibo shows logged-out visitors at most the newest 100 posts of a user; above 100, only older video posts can be added (turn on the option below). Set to 0 for all.",
            "default": 100
          },
          "includeOlderVideoPosts": {
            "title": "Include older video posts",
            "type": "boolean",
            "description": "After the newest 100 posts, keep going back through the user's video posts (video posts only — Weibo does not list older non-video posts to logged-out visitors). Useful for creators who post mostly videos.",
            "default": false
          },
          "postUrls": {
            "title": "Post URLs",
            "type": "array",
            "description": "Enter posts, one per line: a post link (https://weibo.com/1234567890/AbCdEfGhI, https://m.weibo.cn/detail/5300000000000000 or https://m.weibo.cn/status/AbCdEfGhI), a numeric post id or a post code. Up to 1,000 per run.",
            "items": {
              "type": "string"
            }
          },
          "maxCommentsPerPost": {
            "title": "Maximum comments per post",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Limit the comments (replies included) taken from each post, newest first after the top comments. Set to 0 for all that Weibo shows.",
            "default": 500
          },
          "includeReplies": {
            "title": "Include replies",
            "type": "boolean",
            "description": "Add the replies under each comment, right after it (one more request per comment that has several replies). Up to \"Maximum replies per comment\" each.",
            "default": true
          },
          "maxRepliesPerComment": {
            "title": "Maximum replies per comment",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Limit the replies taken under each comment, so busy threads do not crowd out the other comments. Set to 0 for all replies Weibo shows (to leave replies out, turn off \"Include replies\").",
            "default": 10
          },
          "includeCommenterNames": {
            "title": "Include commenter screen names",
            "type": "boolean",
            "description": "Commenters are mostly private people, so their screen names are left out by default: the author name is null, @mentions in the comment text become @… and the leading 回复@name: is removed (the numeric user id is always kept). Turn this on only if you have a lawful reason to process the names.",
            "default": false
          },
          "includeEntertainmentBoard": {
            "title": "Include the entertainment board",
            "type": "boolean",
            "description": "Mode \"Hot search board\": also add the entertainment hot list (about 50 more rows).",
            "default": false
          },
          "expandLongText": {
            "title": "Get the full text of long posts",
            "type": "boolean",
            "description": "Long posts arrive cut off with a \"full text\" link. On: one more request per long post gets the whole text (about a quarter of search results are long posts). Off: the preview is kept and isTextTruncated is true.",
            "default": true
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Stop after this many rows in total (posts, comments, hot-search entries or profiles). Set to 0 for unlimited (capped at 10,000 for safety).",
            "default": 100
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}