{
  "openapi": "3.0.1",
  "info": {
    "title": "📘 Facebook Pages Scraper - Details, Ratings & Ad Status",
    "description": "Scrape Facebook pages for website, address, business hours, ratings, follower counts and whether the page is running ads right now. Bulk export. No login.",
    "version": "0.0",
    "x-build-id": "epWxVAL0xer8LEvJd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/unseenuser~fb-pages/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-unseenuser-fb-pages",
        "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/unseenuser~fb-pages/runs": {
      "post": {
        "operationId": "runs-sync-unseenuser-fb-pages",
        "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/unseenuser~fb-pages/run-sync": {
      "post": {
        "operationId": "run-sync-unseenuser-fb-pages",
        "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": [
          "startUrls"
        ],
        "properties": {
          "startUrls": {
            "title": "Facebook page URLs",
            "minItems": 1,
            "uniqueItems": true,
            "type": "array",
            "description": "One or more public Facebook page URLs, one per line. Use the full page URL, for example https://www.facebook.com/mantraindianfolsom. Click Bulk edit to paste a large list at once.",
            "items": {
              "type": "string"
            }
          },
          "getBusinessHours": {
            "title": "Include business hours",
            "type": "boolean",
            "description": "Include the weekly opening hours for each page (Monday through Sunday). No extra cost.",
            "default": true
          },
          "cacheMaxAge": {
            "title": "Use cached results up to",
            "enum": [
              "",
              "1d",
              "3d",
              "7d",
              "14d",
              "30d"
            ],
            "type": "string",
            "description": "Reuse a recent cached result for page details instead of scraping fresh. A cache hit is faster and the row is marked with cached: true and cached_at. Leave as Always fetch live if you need real-time data such as current ad status.",
            "default": ""
          },
          "includeGatedProfile": {
            "title": "Include gated and age-restricted pages",
            "type": "boolean",
            "description": "When a page is age-restricted or private, still return the limited public fields Facebook exposes (id, name, category, likeCount, profile picture, links) instead of an empty result. Has no effect on normal public pages.",
            "default": false
          },
          "includeEvents": {
            "title": "Include events",
            "type": "boolean",
            "description": "Also return the page's public events. Each event is emitted as its own row in the dataset and is billed as one result.",
            "default": false
          },
          "maxEvents": {
            "title": "Max events per page (0 = all)",
            "minimum": 0,
            "type": "integer",
            "description": "Only used when Include events is on. Events paginate about 3 per upstream call, so a page with many events costs several calls.",
            "default": 0
          },
          "includePosts": {
            "title": "Include posts",
            "type": "boolean",
            "description": "Also return the page's recent posts: text, engagement counts, author, top comments, and video details.",
            "default": false
          },
          "maxPosts": {
            "title": "Max posts per page (0 = all)",
            "minimum": 0,
            "type": "integer",
            "description": "Only used when Include posts is on. At 0 there is no cap and you accept the full bill for however many posts the page has. Minimum when non-zero: 3 (upstream page size).",
            "default": 0
          },
          "enrichPosts": {
            "title": "Enrich posts and reels (extra cost per item)",
            "type": "boolean",
            "description": "Fetch full detail for each post and reel: share count, accurate view count, and optionally comments and a video transcript. This costs ONE extra upstream call per item on top of the row itself, so it is the most expensive option here. Use Max items to enrich to bound it.",
            "default": false
          },
          "maxEnrichedItems": {
            "title": "Max items to enrich (0 = all)",
            "minimum": 0,
            "type": "integer",
            "description": "Caps how many posts and reels per page get the extra detail call. Items beyond the cap are still returned, just without enrichment. Strongly recommend a small number here.",
            "default": 10
          },
          "getComments": {
            "title": "Include comments on enriched items",
            "type": "boolean",
            "description": "Fetch the full comment thread for each enriched post or reel. Only applies when enrichment is on.",
            "default": false
          },
          "getTranscript": {
            "title": "Include video transcript on enriched items",
            "type": "boolean",
            "description": "Fetch a transcript for each enriched video post or reel. Only applies when enrichment is on and the item is a video.",
            "default": false
          },
          "includePhotos": {
            "title": "Include photos",
            "type": "boolean",
            "description": "Also return the page's photos with Facebook's native captions (alt-text).",
            "default": false
          },
          "maxPhotos": {
            "title": "Max photos per page (0 = all)",
            "minimum": 0,
            "type": "integer",
            "description": "Only used when Include photos is on. At 0 there is no cap and you accept the full bill for however many photos the page has.",
            "default": 0
          },
          "includeReels": {
            "title": "Include reels",
            "type": "boolean",
            "description": "Also return the page's recent reels.",
            "default": false
          },
          "maxReels": {
            "title": "Max reels per page (0 = all)",
            "minimum": 0,
            "type": "integer",
            "description": "Only used when Include reels is on. At 0 there is no cap and you accept the full bill for however many reels the page has. Minimum when non-zero: 10 (upstream page size).",
            "default": 0
          },
          "outputStyle": {
            "title": "Output style",
            "enum": [
              "clean",
              "raw"
            ],
            "type": "string",
            "description": "Clean maps every row onto a small, stable set of camelCase columns that line up across pages, posts, photos and reels. Raw returns each item exactly as the source API sends it, including duplicate snake_case copies of the same values - use it only if you already have an integration reading those exact keys.",
            "default": "clean"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}