{
  "openapi": "3.0.1",
  "info": {
    "title": "Facebook Page ID Finder: Names to Page IDs",
    "description": "Facebook page ID finder for brand, advertiser and page names in bulk, no login. Get every page that carries the exact name with its page ID, likes, category, verification and Instagram, or paste links, @handles and IDs. Add page transparency, contact details and ads. CSV, JSON or API.",
    "version": "0.1",
    "x-build-id": "2Zbf7tcFuVsCC0uVz"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation_craft~facebook-page-id-finder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation_craft-facebook-page-id-finder",
        "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/automation_craft~facebook-page-id-finder/runs": {
      "post": {
        "operationId": "runs-sync-automation_craft-facebook-page-id-finder",
        "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/automation_craft~facebook-page-id-finder/run-sync": {
      "post": {
        "operationId": "run-sync-automation_craft-facebook-page-id-finder",
        "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": {
          "names": {
            "title": "Names, links or ids",
            "type": "array",
            "description": "Brand, advertiser or page names (Nike), @handles (@nike), Facebook page links (https://www.facebook.com/nike), Ad Library links with view_all_page_id or a search word, numeric page ids (either of a page's two ids) or company websites (patagonia.com). Add a website after a | to tell pages of one name apart: Patagonia | patagonia.com. Matching ignores case, spaces, punctuation and accents, never part of a word.",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Country",
            "type": "array",
            "description": "The Ad Library country the name is looked up in: ALL (the default) or one two letter country code such as US, GB or DE. One country per run: for several countries, start one run per country. With a country code, Page details also carry the page's ad spend in that country (political and issue ads).",
            "items": {
              "type": "string"
            }
          },
          "pageDetails": {
            "title": "Page details (paid add-on)",
            "type": "boolean",
            "description": "One Page details row per matched page from the Ad Library's About tab: creation date, name change dates, the countries of the people who manage the page with their counts, the confirmed owner with address and phone, state media label, active ads count, related country pages, the page's second id, and spend when one country is given. Charged per row (Page details event)."
          },
          "pageContact": {
            "title": "Page contact (paid add-on)",
            "type": "boolean",
            "description": "One Page contact row per matched page from the page's public Contact and basic info section: website, phone, email, address, rating with review count, hours, price range, services. Only what the page itself shows publicly. Charged per row (Page contact event)."
          },
          "adsPerPage": {
            "title": "Ads per page (paid add-on)",
            "minimum": 0,
            "maximum": 30,
            "type": "integer",
            "description": "Up to this many of the page's ads from the Ad Library (active ones unless Ad status says otherwise), one Page ad row each: text, title, link, call to action, images, videos, platforms, start date. The Ad Library shows the first 30; 0 (the default) reads none. Charged per row (Page ad event)."
          },
          "adStatus": {
            "title": "Which ads",
            "enum": [
              "active",
              "all",
              "inactive"
            ],
            "type": "string",
            "description": "Which of the page's ads the Page ad rows show (used only with Ads per page above 0). Page details always count the active ads."
          },
          "adMediaType": {
            "title": "Ad media type",
            "enum": [
              "all",
              "image",
              "meme",
              "image_and_meme",
              "video",
              "none"
            ],
            "type": "string",
            "description": "Only Page ad rows of this media type, as the Ad Library sorts them (used only with Ads per page above 0)."
          },
          "includeTotalAdsCount": {
            "title": "Total ads count in Page details",
            "type": "boolean",
            "description": "Page details always carry the active ads count. Switch this on to add the count of every ad the page ever ran (one more request per page, no extra charge)."
          },
          "verifiedOnly": {
            "title": "Verified pages only",
            "type": "boolean",
            "description": "Only blue verified pages count as matches; unverified pages of the same name are counted as filtered out. A name whose matches are all filtered out gets a free row."
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Only pages with at least this many likes count as matches. 0 (the default) keeps every page."
          },
          "onMultipleMatches": {
            "title": "When several pages match",
            "enum": [
              "list",
              "aliasMatch",
              "mostLiked",
              "verifiedMostLiked"
            ],
            "type": "string",
            "description": "Every matching page is always listed in matches; a pick only fills pageId. aliasMatch picks the page whose address name is the name itself (the brand's main page: facebook.com/adidas, not facebook.com/adidasUS); the like rules pick only when one page has strictly more likes than every other (the country pages of a global brand share one count: then nothing is picked). A website after | picks first. Left empty, no page is picked."
          },
          "maxCandidates": {
            "title": "Candidates per name",
            "minimum": 0,
            "maximum": 15,
            "type": "integer",
            "description": "How many of the other pages the Ad Library suggested (not matching the name exactly) are listed in each row. Default 5, at most 15 (the Ad Library suggests at most 15 pages per name)."
          },
          "maxDetailsPerName": {
            "title": "Pages per name for the add-ons",
            "minimum": 1,
            "maximum": 15,
            "type": "integer",
            "description": "When several pages match a name and none is picked, the add-ons read up to this many of them, in the Ad Library's order. Default 5."
          },
          "adSearchFallback": {
            "title": "Search ads when no page matches",
            "type": "boolean",
            "description": "When no page the Ad Library suggests matches a name, also look at the advertisers behind the ads that mention the name (one more request). Pages found this way match by the same rule and say foundBy: ad_search. No extra charge."
          },
          "includeRawData": {
            "title": "Include the source's own records",
            "type": "boolean",
            "description": "Add the Ad Library's own record of each page (raw) to the rows, for developers who want every source field."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}