Search posts
Search public Facebook posts by keyword, with date filters.
Request
POST https://dev-backend.tryingrow.com/public-api/facebook/search-postsSend your key in the x-api-key header and a JSON body.
Body
| Field | Type | Description |
|---|---|---|
date_posted | string | Filter posts by year (e.g., "2021"). Optional. Must be between 2004 and current year. |
end_cursor | string | for pagination - use the end_cursor from the previous request |
end_date | string | Filter posts until this date (YYYY-MM-DD format). Must be used together with start_date. Cannot be used with date_posted. |
queryrequired | string | the search query |
recent_posts | boolean | Filter by recent posts. Optional. Defaults to false |
start_date | string | Filter posts from this date (YYYY-MM-DD format). Must be used together with end_date. Cannot be used with date_posted. |
Example
curl -X POST https://dev-backend.tryingrow.com/public-api/facebook/search-posts \
-H "x-api-key: $INGROW_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query":"…"}'Response
JSON from Facebook, fetched live. Every response also carries two headers: x-cost-usd with what the call cost and x-balance-usd with the balance left. Errors: 402 when the balance or your monthly spend limit is too low, 429 when over the rate limit (wait for retry-after seconds).
Pricing and limits
- How much does the InGrow Search posts API cost?
- $0.003 per successful call, taken from your InGrow balance. Failed calls are refunded, and every new organization starts with $1 free credit.
- What is the rate limit of the Search posts API?
- 1 request per second per organization, shared by every Facebook endpoint. Over the limit returns 429 with a retry-after header.
- How do I call the Search posts API?
- Send POST https://dev-backend.tryingrow.com/public-api/facebook/search-posts with a JSON body and your API key in the x-api-key header. Required fields: query. The same key works through the InGrow MCP server.
More Facebook APIs
- Resolve urlResolve any Facebook URL (profile, page, group, post, photo) to its type and numeric id, for use in the other Facebook endpoints.$0.003
- Search profilesSearch Facebook profiles of people by name or keyword.$0.003
- Profile aboutGet the about section of a Facebook profile (work, education, places, contact info), by profile id.$0.003
- Profile postsGet recent posts published by a Facebook profile, by profile id.$0.003
- Search pagesSearch Facebook pages of businesses and brands by keyword.$0.003
- Page detailsGet a Facebook page's details (category, followers, website, contact info, address), by page id.$0.003
- Page postsGet recent posts published by a Facebook page, by page id.$0.003
- Search groupsSearch Facebook groups by keyword.$0.003
- Group infoGet a Facebook group's details (description, privacy, member count), by group id.$0.003
- Group postsGet recent posts from a public Facebook group, by group id.$0.003
- PostGet a single Facebook post with its text, author and engagement counts, by post id.$0.003
- Post commentsGet the comments on a Facebook post, by post id.$0.003
- Post reactionsGet the people who reacted to a Facebook post, by post id.$0.003
- Search adsSearch the Meta Ad Library for ads by keyword, with country, status, media type and date filters.$0.003
- Search advertisersSearch advertisers in the Meta Ad Library by name, to get their page id.$0.003
- Advertiser adsGet the ads a page runs in the Meta Ad Library, by page id, with country, status, media type and date filters.$0.003