{
  "openapi": "3.0.1",
  "info": {
    "title": "WeChat Official Account 公众号 Scraper - Articles & Read Counts",
    "description": "Scrape WeChat and Weixin Official Accounts (微信公众号): search articles by keyword, list an account's articles, get full article text with images and account IP location, read, like and share counts, and search WeChat Channels (视频号) videos. No login or cookies needed.",
    "version": "0.1",
    "x-build-id": "btrHG3TuKGhzWameb"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/clover_folktale~wechat-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-clover_folktale-wechat-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/clover_folktale~wechat-scraper/runs": {
      "post": {
        "operationId": "runs-sync-clover_folktale-wechat-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/clover_folktale~wechat-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-clover_folktale-wechat-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": "Mode",
            "enum": [
              "search",
              "account",
              "article",
              "stats",
              "videoSearch",
              "articleComments",
              "channelVideos",
              "channelProfile",
              "channelCollections",
              "channelVideoDetails",
              "channelComments",
              "miniProgram",
              "principal",
              "channelCollectionVideos",
              "channelLives",
              "accountMenu",
              "hotVideos"
            ],
            "type": "string",
            "description": "What to scrape: articles by keyword, the article list of an account, the full text of articles, the read/like counts of articles, the comments under articles, WeChat Channels videos by keyword, or a Channels account's videos, profile, collections, a Channels video's details and comments, mini programs by keyword, the registered company behind an Official Account, the videos inside a Channels collection, a Channels account's live replays, and an Official Account's custom menu.",
            "default": "search"
          },
          "keyword": {
            "title": "Keyword (modes: search, videoSearch)",
            "type": "string",
            "description": "Search keyword. Chinese keywords work best, e.g. \"美食\". If the usual search cannot answer, `search` uses a fallback search: each fallback page costs at least about $0.16, even with no article on it (see Pricing in the README).",
            "default": "美食"
          },
          "sort": {
            "title": "Sort (modes: search, videoSearch)",
            "enum": [
              "default",
              "latest",
              "hot"
            ],
            "type": "string",
            "description": "Relevance, newest first, or most liked first.",
            "default": "default"
          },
          "publishTime": {
            "title": "Published within (modes: search, videoSearch)",
            "enum": [
              "all",
              "day",
              "week",
              "half_year"
            ],
            "type": "string",
            "description": "Only items published within this period.",
            "default": "all"
          },
          "keywords": {
            "title": "Keywords (mode: miniProgram)",
            "type": "array",
            "description": "Search keywords for mini programs, one per line. Each keyword is one search page of about 25 results and pays 10 run-start fees (10 × $0.015) in advance.",
            "items": {
              "type": "string"
            }
          },
          "accounts": {
            "title": "Accounts (modes: account, principal, accountMenu)",
            "type": "array",
            "description": "Account IDs (gh_...), custom WeChat IDs, or the link of any article the account published. In account mode a link costs one extra lookup per account; principal mode looks the account up directly. The accountMenu mode takes account IDs or custom WeChat IDs only (no article links); an account without a custom menu returns nothing and is not charged.",
            "items": {
              "type": "string"
            }
          },
          "articles": {
            "title": "Articles (modes: article, stats, articleComments)",
            "type": "array",
            "description": "Article links: https://mp.weixin.qq.com/s/... or the long form https://mp.weixin.qq.com/s?__biz=...&mid=...&idx=...&sn=...",
            "items": {
              "type": "string"
            }
          },
          "channels": {
            "title": "Channels accounts (modes: channelVideos, channelProfile, channelCollections, channelLives)",
            "type": "array",
            "description": "Channel usernames (v2_...@finder), or the share link (https://weixin.qq.com/sph/...) of any video of the channel. A share link costs one extra lookup per account (in channelLives that lookup is not charged separately). Channel IDs (sph...) are not accepted.",
            "items": {
              "type": "string"
            }
          },
          "collections": {
            "title": "Channels collections (mode: channelCollectionVideos)",
            "type": "array",
            "description": "Numeric collection IDs, as listed in the collectionId field by the channelCollections mode, e.g. 14934343679109171232. Each collection is listed page by page (about 20 videos per page). A collection that cannot be found returns nothing and is not charged.",
            "items": {
              "type": "string"
            }
          },
          "includeReplies": {
            "title": "Also list replies (mode: articleComments)",
            "type": "boolean",
            "description": "Also list the replies under comments that have 3 or more replies (they count toward maxResults and are billed like comments). Replies are fetched only while the run's earnings cover the extra lookups, so a run with few comments may list none.",
            "default": false
          },
          "channelKeyword": {
            "title": "Search inside the channel (mode: channelVideos)",
            "type": "string",
            "description": "Optional. Only list the channel's videos that match this keyword; leave empty to list all videos."
          },
          "videos": {
            "title": "Channels videos (modes: channelVideoDetails, channelComments)",
            "type": "array",
            "description": "Share links (https://weixin.qq.com/sph/...), export IDs (export/..., they expire quickly) or numeric object IDs. For comments, a share link or export ID costs one extra lookup per video. The IDs of videos found by keyword search are not object IDs: use their exportId.",
            "items": {
              "type": "string"
            }
          },
          "hotCategory": {
            "title": "Creator category (mode: hotVideos)",
            "enum": [
              "ALL",
              "FOOD",
              "LIFESTYLE",
              "COMEDY",
              "EMOTION",
              "SOCIETY",
              "HUMANITIES_ARTS",
              "DRAMA",
              "ENTERTAINMENT",
              "TECHNOLOGY",
              "FINANCE",
              "FILM_TV_VARIETY",
              "GAMING",
              "PARENTING",
              "MUSIC",
              "TRAVEL",
              "SPORTS",
              "SCIENCE",
              "AUTOMOTIVE",
              "EDUCATION",
              "CAREER",
              "HEALTH",
              "PETS"
            ],
            "type": "string",
            "description": "The creator category of the monthly ranking. All categories ranks every video together.",
            "default": "ALL"
          },
          "hotSort": {
            "title": "Rank by (mode: hotVideos)",
            "enum": [
              "INTERACTION",
              "PLAY",
              "THUMB_LIKE",
              "HEART_LIKE",
              "COMMENT",
              "SHARE"
            ],
            "type": "string",
            "description": "The metric the ranking is sorted by, highest first.",
            "default": "INTERACTION"
          },
          "hotMonth": {
            "title": "Month (mode: hotVideos)",
            "pattern": "^$|^20[0-9]{2}-(0[1-9]|1[0-2])$",
            "type": "string",
            "description": "Optional. The month of the ranking as yyyy-MM, e.g. 2026-09. Leave empty for the latest month published (a month's ranking usually appears some weeks after it ends; only the last few months are kept). The ranking comes in whole pages of 48, so maxResults is rounded up to a multiple of 48."
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum number of items to return in total for this run. You are charged per item returned.",
            "default": 20
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}