{
  "openapi": "3.0.1",
  "info": {
    "title": "Facebook Group Posts & All Photos Scraper",
    "description": "Scrape public Facebook group posts with all recoverable photo URLs, including hidden +N grids. Get text, timestamps, authors, engagement, stable post URLs, and agent-ready JSON for Apify API, MCP, monitoring, and research workflows.",
    "version": "0.3",
    "x-build-id": "0Vog8Ev1duovDELM8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/spbotdel~facebook-group-posts-all-photos-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-spbotdel-facebook-group-posts-all-photos-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/spbotdel~facebook-group-posts-all-photos-scraper/runs": {
      "post": {
        "operationId": "runs-sync-spbotdel-facebook-group-posts-all-photos-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/spbotdel~facebook-group-posts-all-photos-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-spbotdel-facebook-group-posts-all-photos-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": [
          "groupUrls"
        ],
        "properties": {
          "groupUrls": {
            "title": "Facebook group URLs",
            "type": "array",
            "description": "Required. Public Facebook group URLs, vanity URLs, or numeric group IDs. Use group URLs only, not post URLs, Marketplace URLs, or private/login-only groups. Up to maxGroupsPerRun groups are processed inside one Actor run.",
            "items": {
              "type": "string"
            }
          },
          "maxGroupsPerRun": {
            "title": "Max groups per run",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Maximum number of groupUrls to process in one Actor run. Extra group URLs are skipped and listed in SUMMARY.skippedGroupUrls.",
            "default": 10
          },
          "maxPostsPerGroup": {
            "title": "Max posts per group",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum number of post results to return per group. For deep historical backfills, run up to 1,000 posts, store SUMMARY.pointer.nextCursor, then continue with startCursor.",
            "default": 30
          },
          "sortMode": {
            "title": "Sort mode",
            "enum": [
              "CHRONOLOGICAL",
              "RECENT_ACTIVITY",
              "TOP_POSTS"
            ],
            "type": "string",
            "description": "Facebook group feed sort mode. New posts first is the best fit for latest-post collection and daily monitoring.",
            "default": "CHRONOLOGICAL"
          },
          "expandAllPhotos": {
            "title": "Expand all photos",
            "type": "boolean",
            "description": "Recover photo URLs hidden behind Facebook +N grids when publicly available. Keep enabled for complete media rows; disable only for faster preview-only runs.",
            "default": true
          },
          "includeRawPayload": {
            "title": "Include raw payload",
            "type": "boolean",
            "description": "Include the raw parsed Facebook payload in each dataset row. Useful for debugging, but makes output much larger.",
            "default": false
          },
          "sinceDate": {
            "title": "Since date",
            "type": "string",
            "description": "Optional monitoring boundary. With New posts first sorting, the Actor stops when posts older than this date are reached."
          },
          "knownPostIds": {
            "title": "Known post IDs",
            "type": "array",
            "description": "Post IDs already stored by your pipeline. With New posts first sorting, the Actor stops when it reaches one of them. Best for daily monitoring.",
            "items": {
              "type": "string"
            }
          },
          "checkpoint": {
            "title": "Checkpoint",
            "type": "object",
            "description": "Checkpoint object from a previous SUMMARY. Use it for incremental monitoring or per-group continuation when your pipeline stores run state."
          },
          "startCursor": {
            "title": "Start cursor",
            "type": "string",
            "description": "Cursor from SUMMARY.pointer.nextCursor. Use it for older-post historical backfills only. Do not use yesterday's cursor to collect newer posts."
          },
          "startCursorsByGroup": {
            "title": "Start cursors by group",
            "type": "object",
            "description": "Optional map of group URL to GraphQL cursor for older-page backfill in multi-group runs. Prefer passing the previous SUMMARY/checkpoint when available."
          },
          "paginationMode": {
            "title": "Pagination mode",
            "enum": [
              "ranked_snapshot",
              "cursor_page"
            ],
            "type": "string",
            "description": "Ranked snapshot collects candidates and sorts locally by creation time. Cursor page preserves feed cursor order, emits a next pointer, and is recommended for monitoring or backfills.",
            "default": "ranked_snapshot"
          },
          "maxCandidates": {
            "title": "Max candidate posts",
            "minimum": 0,
            "maximum": 3000,
            "type": "integer",
            "description": "Candidate posts collected before local sorting. Use 0 for automatic candidate budget based on Max posts per group.",
            "default": 0
          },
          "maxPages": {
            "title": "Max GraphQL pages",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "Maximum GraphQL pagination requests after the public group bootstrap. Use 0 for automatic page budget based on Max posts per group.",
            "default": 0
          },
          "bootstrapRetries": {
            "title": "Bootstrap retries",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "How many fresh proxy/session bootstrap attempts to try if Facebook returns a poor or login-walled public group page.",
            "default": 4
          },
          "graphqlPageRetries": {
            "title": "GraphQL page retries",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Retry count for transient empty/small GraphQL pagination responses.",
            "default": 2
          },
          "proxyCountry": {
            "title": "Proxy country",
            "type": "string",
            "description": "Apify proxy country code.",
            "default": "US"
          },
          "mediaSetRetries": {
            "title": "Photo-set retries",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Retry count for each Facebook media/set request.",
            "default": 1
          },
          "mediaSetRetryDelayMs": {
            "title": "Photo-set retry delay",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Base delay for media/set retries.",
            "default": 800
          },
          "mediaExpansionConcurrency": {
            "title": "Photo expansion concurrency",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "How many posts can expand Facebook media/set pages in parallel. Higher values can speed up all-photos runs but may increase transient Facebook/proxy failures.",
            "default": 3
          },
          "mediaExpansionAdaptive": {
            "title": "Adaptive photo expansion",
            "type": "boolean",
            "description": "When enabled, the Actor can lower high photo expansion concurrency back to the stable level if recent media/set expansion quality degrades.",
            "default": true
          },
          "mediaDeferredRetry": {
            "title": "Deferred photo retry",
            "type": "boolean",
            "description": "Retry only suspicious photo-set rows after the main pass, before final dataset output. This improves +N coverage at a small extra runtime cost.",
            "default": true
          },
          "mediaDeferredRetryConcurrency": {
            "title": "Deferred retry concurrency",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "How many suspicious posts to retry in parallel during the deferred photo retry pass.",
            "default": 2
          },
          "mediaDeferredRetryExtraRetries": {
            "title": "Deferred retry extra attempts",
            "minimum": 0,
            "maximum": 5,
            "type": "integer",
            "description": "Additional retry attempts for suspicious media/set rows during the deferred pass.",
            "default": 2
          },
          "mediaDeferredRetryDelayMs": {
            "title": "Deferred retry delay",
            "minimum": 0,
            "maximum": 20000,
            "type": "integer",
            "description": "Base delay for the deferred photo retry pass.",
            "default": 1500
          },
          "debug": {
            "title": "Debug output",
            "type": "boolean",
            "description": "Include response samples and discovery details in SUMMARY. Leave off for normal production runs.",
            "default": false
          },
          "discoverBundles": {
            "title": "Discover doc_id in JS bundles",
            "type": "boolean",
            "description": "Fetch Facebook JS bundles to discover the current GraphQL doc_id. Costs extra transfer; fallback doc_id is tried either way.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}