{
  "openapi": "3.0.1",
  "info": {
    "title": "Facebook Group Scraper: All-in-One",
    "description": "Facebook Group Scraper: All-in-One extracts Facebook group posts, comments, members, profiles, and engagement data for research and lead generation. 高效抓取 Facebook 群组帖子、评论、成员、个人资料及互动数据，助力市场研究与精准获客。",
    "version": "0.1",
    "x-build-id": "0wRG1Gkmkb4jDlsQV"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scraper-fleet~facebook-group-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scraper-fleet-facebook-group-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/scraper-fleet~facebook-group-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scraper-fleet-facebook-group-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/scraper-fleet~facebook-group-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scraper-fleet-facebook-group-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": [
          "operation"
        ],
        "properties": {
          "operation": {
            "title": "1️⃣ Operation 操作",
            "enum": [
              "posts",
              "group_info",
              "members",
              "search"
            ],
            "type": "string",
            "description": "What to scrape. posts/group_info/members work WITHOUT a cookie. 选择要执行的操作。posts/group_info/members 无需 Cookie 即可使用。",
            "default": "posts"
          },
          "urls": {
            "title": "Group URLs 小组链接",
            "type": "array",
            "description": "posts / group_info / members: one or more Facebook group URLs or numeric group IDs. 适用于上述三种操作，填入小组链接或纯ID。",
            "default": [
              "https://www.facebook.com/groups/claudeaicommunity"
            ],
            "items": {
              "type": "string"
            }
          },
          "searchQuery": {
            "title": "Search query 搜索词",
            "type": "string",
            "description": "search only. Requires the Cookie field below (Facebook 404s group search for anonymous requests). 仅用于 search，需要下方 Cookie 字段。"
          },
          "maxPosts": {
            "title": "Max posts (all groups combined) 所有小组帖子总数上限",
            "minimum": 1,
            "type": "integer",
            "description": "posts only. Total cap across all group URLs combined, not per group. 仅用于 posts，跨所有小组的总上限。",
            "default": 20
          },
          "maxItems": {
            "title": "Max items (members / search) 成员或搜索最大条数",
            "minimum": 1,
            "type": "integer",
            "description": "members / search only. 仅用于 members 和 search。",
            "default": 20
          },
          "maxRetries": {
            "title": "Max retries per request 每个请求重试次数",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Retries for a single failed HTTP request before giving up on it. 单个请求失败后的重试次数。",
            "default": 3
          },
          "sortingOrder": {
            "title": "Sort order 排序方式",
            "enum": [
              "newest_posts",
              "newest_activity",
              "most_relevant"
            ],
            "type": "string",
            "description": "posts only. 仅用于 posts。",
            "default": "newest_posts"
          },
          "postsNewerThan": {
            "title": "Posts newer than 发布时间不早于",
            "type": "string",
            "description": "posts only. Relative (\"2 days\", \"1 month\") or absolute (YYYY-MM-DD / ISO timestamp). Leave empty for no filter. 仅用于 posts，支持相对或绝对时间。"
          },
          "postsOlderThan": {
            "title": "Posts older than 发布时间不晚于",
            "type": "string",
            "description": "posts only. Same format as above. 仅用于 posts。"
          },
          "includeTopComment": {
            "title": "Include top comment 包含热评",
            "type": "boolean",
            "description": "posts only: fetch each post's single top comment. 仅用于 posts，获取每条帖子的一条热评。",
            "default": true
          },
          "fetchAllComments": {
            "title": "Fetch all (top-level) comments 获取所有一级评论",
            "type": "boolean",
            "description": "posts only: fetch up to 20 top-level comments per post instead of just the top one. Comment replies are not supported. 仅用于 posts，每条帖子最多获取 20 条一级评论。",
            "default": false
          },
          "cookie": {
            "title": "Cookie",
            "type": "string",
            "description": "Paste a `Cookie:` header string (DevTools → Network → any www.facebook.com request → Copy as cURL, take the -b/--cookie value) OR a Cookie-Editor/EditThisCookie JSON export, from a logged-in facebook.com session. Leave empty for posts/group_info, or for members without an exact total count. 登录后从浏览器导出的 Cookie。"
          },
          "proxyOptions": {
            "title": "Proxy configuration 代理设置",
            "type": "object",
            "description": "Apify Proxy configuration. Defaults to Residential, which this Actor needs on the Apify platform.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}