Fetch a Page or profile's posts
Fetch one page of a public Page or profile's posts, newest first, with engagement counts.
GET /v1/facebook/page/{page_id}/posts
Path parameter
| Parameter | Description |
|---|---|
page_id | A vanity username (nasa), a numeric id, or a full Facebook Page/profile URL. |
Query parameters
| Parameter | Required | Description |
|---|---|---|
cursor | no | Omit for the first page; pass the next_cursor from a previous response to fetch the next page. |
Example
curl "$LISTENX_BASE/v1/facebook/page/nasa/posts" \
-H "X-API-Key: $LISTENX_KEY"
Fetch the next page:
curl "$LISTENX_BASE/v1/facebook/page/nasa/posts?cursor=eyJ..." \
-H "X-API-Key: $LISTENX_KEY"
Response
{
"page": "nasa",
"profile": {
"id": "100064000",
"name": "NASA",
"username": "NASA",
"url": "https://www.facebook.com/NASA",
"follower_count": "28M"
},
"returned": 10,
"has_next_page": true,
"next_cursor": "eyJ...",
"results": [
{
"id": "100064000_777000111",
"url": "https://www.facebook.com/story.php?story_fbid=777000111&id=100064000",
"author": {
"id": null,
"name": "NASA",
"username": "NASA",
"url": "https://www.facebook.com/NASA/"
},
"text": "Our Artemis mission is one step closer…",
"created_at": "5 hrs",
"engagement": {
"reaction_count": 8200,
"comment_count": 210,
"share_count": 44
}
}
],
"billing": {
"endpoint": "facebook.page_posts",
"units": 1,
"unit_price": "0.010000",
"amount": "0.010000",
"balance_after": "97.220000",
"request_id": "…"
}
}
Fields
| Field | Description |
|---|---|
page | The identifier you requested. |
profile | Page/profile summary (id, name, username, url, follower_count). |
returned | Number of posts on this page. |
has_next_page | true if more posts remain. |
next_cursor | Pass back as cursor to fetch the next page; null when exhausted. |
results[] | Posts with author, text, timestamp, and engagement counts. |
Billing
Billed per page — units = 1 per request. See Billing.
Errors
| HTTP | code | Meaning |
|---|---|---|
| 400 | invalid_request | Empty page id or invalid cursor. |
| 404 | not_found | Page/profile not found or not public. |
| 429 | upstream_rate_limited | Transient block — retry with backoff. |