Facebook
Insights
Analytics and normalized metrics for Facebook Page posts.
Fetch post analytics for a published Facebook Page destination. Metrics are mapped into the shared Onepostly insights shape used across platforms.
Requires read_insights (engagement counts also need pages_read_engagement).
Request
curl "https://api.onepostly.com/v1/posts/POST_ID/insights" \
-H "x-api-key: op_YOUR_KEY"Optional: ?refresh=1 (or refresh=true) to bypass cache and refetch from Facebook.
Response includes one entry per destination under insights.destinations.
Normalized fields
| Field | Notes |
|---|---|
impressions | Post impressions when available |
reach | Unique impressions / unique video views when available |
likes | Reactions / likes when available |
comments | Comment count when available |
shares | Share count when available |
saves | Always null on Facebook |
plays | Video views when available |
engagement | Engaged users / clicks, or sum of likes + comments + shares |
Missing values are null (not 0), unless a composite field sums available siblings.
Stories are ephemeral — metrics may be limited or short-lived; empty / pending outcomes are expected.
Example response shape
{
"insights": {
"postId": "…",
"status": "ready",
"destinations": [
{
"destinationId": "…",
"platform": "facebook",
"status": "ready",
"metrics": {
"impressions": 8500,
"reach": 6200,
"likes": 210,
"comments": 18,
"shares": 7,
"saves": null,
"plays": null,
"engagement": 410
}
}
]
}
}Errors / statuses
| Code / status | Meaning |
|---|---|
NOT_PUBLISHED | Destination not published yet |
INSIGHTS_PENDING | Metrics not ready yet — retry later |
INSIGHTS_FAILED | Hard failure fetching metrics |
MISSING_EXTERNAL_ID | No object id on the destination |
Tips
- Prefer
?refresh=1only when you need fresh numbers; otherwise cached snapshots are returned - For video, check
playsin addition to impressions - Stories insights may disappear after the story expires