{
  "openapi": "3.0.1",
  "info": {
    "title": "Facebook Post Search Scraper - Keyword Search",
    "description": "Search public Facebook posts by keyword or hashtag, no login. Facebook now limits signed-out search, so most runs return video posts only, about 5-7 per query. Get text, URL, author, date, views, media and, when Facebook shows them, reactions, comments and shares.",
    "version": "0.1",
    "x-build-id": "rmC2n7nOnFlqE5XKd"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/automation-lab~facebook-public-post-keyword-search-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-automation-lab-facebook-public-post-keyword-search-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/automation-lab~facebook-public-post-keyword-search-scraper/runs": {
      "post": {
        "operationId": "runs-sync-automation-lab-facebook-public-post-keyword-search-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/automation-lab~facebook-public-post-keyword-search-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-automation-lab-facebook-public-post-keyword-search-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": [
          "searchQueries"
        ],
        "properties": {
          "searchQueries": {
            "title": "Search queries",
            "type": "array",
            "description": "Keywords, phrases or hashtags to search Facebook posts for, one per line (for example `coffee`, `#blackfriday`, `iphone 17 battery`). Each query is searched separately with Facebook's own post search. A pasted facebook.com/search/posts/?q=... URL also works. Facebook matches loosely: single words match most precisely; use `mustContainQuery` to keep only posts that contain every word.",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "top",
              "recent"
            ],
            "type": "string",
            "description": "`top` uses Facebook's relevance ranking (popular posts of any age). `recent` turns on Facebook's Recent posts filter, which favours fresh posts and suits monitoring. Rows keep Facebook's own order, which is not strictly by date.",
            "default": "top"
          },
          "maxPostsPerQuery": {
            "title": "Max posts per query",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Maximum number of posts saved for each search query, after filters. Facebook serves about 10-12 posts per page and usually up to a few hundred posts per query; the run stops earlier when Facebook has no more pages.",
            "default": 20
          },
          "maxItems": {
            "title": "Max posts per run",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Hard cap on posts saved across all queries in this run. `0` means no run-wide cap (each query still stops at Max posts per query).",
            "default": 0
          },
          "startDate": {
            "title": "Published on or after",
            "type": "string",
            "description": "Keep only posts published on or after this UTC date. Use `YYYY-MM-DD`, a written-out date such as `November 9, 2026`, or a relative window such as `7 days`, `3 weeks` or `2 months`. The date is sent to Facebook's date filter and also checked on every post, so posts outside the window are never saved or charged."
          },
          "endDate": {
            "title": "Published on or before",
            "type": "string",
            "description": "Keep only posts published on or before this UTC date (whole day included). Same formats as the start date."
          },
          "mustContainQuery": {
            "title": "Only posts that contain every query word",
            "type": "boolean",
            "description": "When on, a post is kept only if every word of the query (case- and accent-insensitive; `#` ignored) appears in its text, its shared post text or its link title. Words are matched as parts of text (`car` also matches `Scarcity`), not as whole words or an exact phrase. Every row has `matchesQuery` either way.",
            "default": false
          },
          "postSource": {
            "title": "Post source",
            "enum": [
              "all",
              "groups",
              "pages_and_profiles"
            ],
            "type": "string",
            "description": "`groups` keeps only posts made in public groups; `pages_and_profiles` keeps only posts on Pages and profiles. Applied to each result after Facebook returns it.",
            "default": "all"
          },
          "postType": {
            "title": "Post type",
            "enum": [
              "all",
              "photo",
              "album",
              "video",
              "link",
              "share",
              "text"
            ],
            "type": "string",
            "description": "Keep only one kind of post: `photo` (one photo), `album` (several photos/videos), `video`, `link` (outbound link), `share` (reshare of another post) or `text`. Applied after Facebook returns each result.",
            "default": "all"
          },
          "minReactions": {
            "title": "Minimum reactions",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only posts with at least this many reactions. `0` keeps everything.",
            "default": 0
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify datacenter proxies (SHADER group) serve every request by default and are the tested setting. Change only if you know you need a different proxy. If Facebook keeps rate-limiting another Apify Proxy setting or no proxy, or that setting cannot connect, the run switches to SHADER. If an Apify Proxy setting cannot connect and SHADER is not available to your account, the run connects directly. Your own proxy URLs are never replaced.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "SHADER"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}