On this page
Post numbers
Two calls give you numbers. One gives a post's views, likes, comments and shares on each account. The other counts your workspace's posts that were sent, failed or unconfirmed, and lists your top posts.
The Node.js and Python samples use api and headers from the Quickstart's first step.
A post's numbers
GET /v1/posts/{id}/results gives the post's numbers on each account it went to. Each account has one line, in the order of the post's targets.
curl https://api.postsure.dev/v1/posts/<post id>/results \ -H "Authorization: Bearer $POSTSURE_KEY"const postId = "<post id>";const numbers = await fetch(`${api}/v1/posts/${postId}/results`, { headers }).then((r) => r.json());for (const line of numbers.results) { console.log(line.account.network, line.state, line.views, line.likes);}// true: a newer read is still running. Get the results again in a moment.console.log(numbers.refreshing);post_id = "<post id>"numbers = requests.get(f"{api}/v1/posts/{post_id}/results", headers=headers).json()for line in numbers["results"]: print(line["account"]["network"], line["state"], line["views"], line["likes"])# True: a newer read is still running. Get the results again in a moment.print(numbers["refreshing"])Example response200
{ "post_id": "cmh1post0x0001l708z8x7c6v", "refreshing": false, "results": [ { "target_id": "cmh1tgt00x0001l708a1s2d3f", "account": { "id": "cmh1acc0x0001l708x9q2w3er", "network": "x", "display_name": "Riverside Bakery" }, "state": "ready", "read_at": "2026-11-21T10:13:00.000Z", "views": 1520, "likes": 48, "comments": 6, "shares": 9, "extras": { "quotes": 2, "bookmarks": 11 }, "read_error": null }, { "target_id": "cmh1tgt00t0002l708g4h5j6k", "account": { "id": "cmh1acc0t0002l708m1n2b3v4", "network": "telegram", "display_name": "Riverside news" }, "state": "not_available", "read_at": null, "views": null, "likes": null, "comments": null, "shares": null, "extras": {}, "read_error": null } ]}target_id,account- The account's line in the post's
targets, and the account: itsid,networkanddisplay_name. views,likes,comments,shares- The four common numbers. Comments are replies on some networks, and shares are reposts.
extras- The other numbers the network gives, by name:
quotes,bookmarks,saves,clicksandprofile_clicks.clicksare clicks on the post's link, andprofile_clicksare clicks on the author's profile from the post. A name that is not there is not available. state,read_at,read_error- If the numbers could be read, when they were read, and why the last read failed. See States.
What each network gives
Postsure gives a number only when the network sends it. These are the numbers it reads on each network:
| Network | Numbers |
|---|---|
| Bluesky | likes, comments (replies), shares (reposts). Extra: quotes. Bluesky has no views. |
| X | views (impressions), likes, comments (replies), shares (reposts). Extras: quotes, bookmarks, and profile_clicks for a post under 30 days old. |
views, likes, comments, shares. Extras: saves, and profile_clicks (profile visits). | |
| Threads | views, likes, comments (replies), shares (reposts). Extra: quotes. |
| Facebook Pages | views (media views), likes (reactions of every kind), comments, shares. |
| TikTok | views, likes, comments, shares. Extra: saves (favorites). |
| YouTube | views, likes, comments, shares. |
views (impressions), likes (reactions), comments. Extras: saves, and clicks (clicks on the pin's link). No shares. | |
For a company page: views (impressions), likes, comments, shares. Extra: clicks. A profile gives no numbers: LinkedIn gives them for company pages only. | |
| Telegram | No numbers: Telegram does not give them. Once the post is published, its line is not_available. |
| Discord | likes: the message's reactions, added up. Discord has no views, and no other number is read. |
null is not 0
A number that is null is not available: the network does not give it, or nothing was read yet. Postsure never shows 0 for that. A 0 is a real count: for example, a post with no likes yet.
So add up only the numbers that are not null. A Bluesky post's views is always null, because Bluesky has no views.
How often Postsure reads
Postsure reads a post's numbers only when you ask for them, with this call or the MCP tool get_post_results. It reads each account of the post at most once every 15 minutes. Every call in between gets the numbers it saved, and read_at says when the network gave them.
- When an account's last read is 15 minutes old or more, your call starts a new read. It waits up to 3 seconds for it. Calls at the same time share one read.
- If the read is not done by then, you get the saved numbers, and
refreshingistrue. Get the results again in a moment for the new ones.refreshingis alsotruewhile another call's read is running. - A failed read is not tried again before its 15 minutes are over.
- When the network limits the reads and says when its limit resets, Postsure does not read that account again before then, and waits at most a day.
- When the network says the post was removed, Postsure never reads it again. Its last numbers stay.
States
ready- The numbers of the last read.
pending- Nothing was read yet. The first read is on its way, or starts with your next call.
read_failed- The last read failed, and
read_errorsays why. The numbers are still the last ones read, atread_at. not_posted- The post is not published on this account, so there is nothing to read. An
unconfirmedpost is not read either: it may not be live. not_available- The numbers cannot be read. Telegram gives none, a LinkedIn profile gives none, or they cannot be read for this account yet. A removed account is
not_availabletoo: its last numbers andread_atstay.
When a read fails
A failed read is not an error for your call. The call still answers 200, and the account's line says read_failed. Its read_error has a category, a message that says what to do, and failed_at. Here the X read hit X's limit, while the first Bluesky read is still running:
A failed read, while another runs200
{ "post_id": "cmh1post0x0001l708z8x7c6v", "refreshing": true, "results": [ { "target_id": "cmh1tgt00x0001l708a1s2d3f", "account": { "id": "cmh1acc0x0001l708x9q2w3er", "network": "x", "display_name": "Riverside Bakery" }, "state": "read_failed", "read_at": "2026-11-21T09:40:00.000Z", "views": 1210, "likes": 41, "comments": 5, "shares": 7, "extras": { "quotes": 2 }, "read_error": { "category": "rate_limited", "message": "The network's limit was reached. The numbers refresh when the network allows it.", "failed_at": "2026-11-21T09:58:00.000Z" } }, { "target_id": "cmh1tgt00b0003l708q7w8e9r", "account": { "id": "cmh1acc0b0003l708p5o6i7u8", "network": "bluesky", "display_name": "riverside.example.com" }, "state": "pending", "read_at": null, "views": null, "likes": null, "comments": null, "shares": null, "extras": {}, "read_error": null } ]}| Category | Message |
|---|---|
auth | The account's access ended. Reconnect the account. |
permission | The account did not allow Postsure to read results. Reconnect the account and allow it. |
not_found | The post is not on the network any more, or it cannot be seen. |
removed | This post was removed on the network. |
rate_limited | The network's limit was reached. The numbers refresh when the network allows it. |
x_read_limit | This workspace reached today's limit for reading X results. The numbers refresh after midnight UTC. |
server_error | The network did not answer. The next read can be in 15 minutes. |
unknown | The results could not be read. The next read can be in 15 minutes. |
An account connected before Postsure asked to read results gets permission with: "Postsure needs one more permission to read this account's results. Reconnect the account."
Errors
| Code | Status | When |
|---|---|---|
missing_api_key | 401 | No API key. |
invalid_api_key | 401 | A wrong or revoked API key. |
not_found | 404 | No post with this id in your workspace: "No post with this id." |
Workspace numbers
GET /v1/analytics counts your workspace's posts that were sent, failed and unconfirmed. It counts them per day, network, account and failure cause, and lists your top posts. This one asks for the last 7 days, in Berlin time:
curl "https://api.postsure.dev/v1/analytics?range=7d&time_zone=Europe/Berlin" \ -H "Authorization: Bearer $POSTSURE_KEY"const params = new URLSearchParams({ range: "7d", time_zone: "Europe/Berlin" });const numbers = await fetch(`${api}/v1/analytics?${params}`, { headers }).then((r) => r.json());console.log(numbers.totals);for (const cause of numbers.causes) console.log(cause.category, cause.count, cause.what_to_do);numbers = requests.get(f"{api}/v1/analytics", headers=headers, params={ "range": "7d", "time_zone": "Europe/Berlin",}).json()print(numbers["totals"])for cause in numbers["causes"]: print(cause["category"], cause["count"], cause["what_to_do"])Example response, trimmed200
{ "range": "7d", "time_zone": "Europe/Berlin", "first_day": "2026-11-15", "last_day": "2026-11-21", "totals": { "sent": 41, "failed": 3, "unconfirmed": 1 }, "days": [ { "day": "2026-11-15", "sent": 4, "failed": 0, "unconfirmed": 0 }, { "day": "2026-11-16", "sent": 0, "failed": 0, "unconfirmed": 0 } ], "networks": [ { "network": "x", "sent": 24, "failed": 2, "unconfirmed": 1 }, { "network": "linkedin", "sent": 17, "failed": 1, "unconfirmed": 0 } ], "accounts": [ { "account_id": "cmh1acc0x0001l708x9q2w3er", "display_name": "Riverside Bakery", "sent": 24, "failed": 2, "unconfirmed": 1 }, { "account_id": "cmh1acc0l0002l708k4t6y7ui", "display_name": "Riverside Bakery Ltd", "sent": 17, "failed": 1, "unconfirmed": 0 } ]}Here days shows 2 of its 7 days. The same answer also has causes and top_posts, shown in Causes and what to do and Top posts.
The query
range7d,30dor90d: the last 7, 30 or 90 days, up to today.30dwhen not sent.time_zone- An IANA time zone name, like
Europe/Berlin. The days are counted in this zone, and the range ends today in it.UTCwhen not sent.
- An old short name is read as its zone:
ISTisAsia/Calcutta, andPSTisAmerica/Los_Angeles. The answer'stime_zoneshows that name. - A name that is not a zone of the list, like
EST5EDTorEtc/GMT+5, is refused. - Any other query field is ignored.
What counts
- Each account of a post counts once. A post to two accounts counts twice. So the lines per network and per account add up to the totals.
- Three counts.
sentis published.failedis failed.unconfirmedis not known to be live or not: check the account before you post it again. - A post counts on its send day:
publish_at, elsesent_at, elsecreated_at. A retry that ends on a later day does not move it. It is the same send time thatGET /v1/postsfilters withsend_time_afterandsend_time_before: see List posts. - Only finished accounts count. A post that is still scheduled, queued, publishing or waiting is not counted yet. A failed account that you retry leaves the count until its retry ends. So a day's numbers can still change while its posts finish.
- A draft or a cancelled post never counts.
The answer
range,time_zone- What was counted.
time_zoneis the zone's own name. first_day,last_day- The first day counted, and today, in
time_zone. totals- The counts of the whole range.
days- Every day of the range, oldest first. A day with nothing has zeros.
networks- One line per network with posts, the one with the most posts first.
accounts- One line per account with posts, the one with the most posts first.
display_nameis the account's name on the network, or its username when it has none. causes- The failures by cause, the most first. They add up to
failed. top_posts- The posts with the most views and the most likes. See Top posts.
Causes and what to do
causes groups the failed accounts by their error_category. An account with no category counts as unknown. Each cause comes with what_to_do, in plain words:
causes, in the same answer
{ "causes": [ { "category": "rate_limited", "count": 2, "what_to_do": "The network got too many posts in a short time. Wait for its limit to reset, then retry the post, and spread out the next posts." }, { "category": "auth", "count": 1, "what_to_do": "The account's connection ended. Connect the account again, then retry the post." } ]}This is what what_to_do says for each cause:
| Cause | What to do |
|---|---|
auth | The account's connection ended. Connect the account again, then retry the post. |
permission | Postsure is missing a right it needs on the network for this account. Give the right (for a bot, in the channel or server settings), then retry the post. |
rate_limited | The network got too many posts in a short time. Wait for its limit to reset, then retry the post, and spread out the next posts. |
usage_cap | The monthly post limit of the network's app is used up. Wait for it to reset next month, then retry the post. |
content_policy | The network refused the post itself, for example a duplicate or a text that is too long. Change the post, then send it again. |
media_format | The network does not take a file of the post: its format, size or length. Change the file, then send the post again. |
server_error | The network had a problem on its side, and nothing was posted. Retry the post later. |
unconfirmed | We could not tell if the post went out. Check the account on the network before you retry, so it is not posted twice. |
plan_required | The workspace has no plan for posting. Choose a plan, then retry the post. |
daily_limit_reached | The account was at its daily limit of posts in the 24 hours before the post's time. Wait until the account has room again, then retry the post, or send it as a new post at another time. |
x_monthly_limit_reached | The workspace's X posts for the post's billing period were used up. Wait until the X limit resets, then retry the post, or send it as a new post later. |
x_link_not_allowed | X posts cannot have links. Send it again as a new post without the link. |
unknown | We could not name the cause. Open the post to read its reason, then retry it or contact support. |
These are the API's own words. For usage_cap, the cap can be daily or monthly, by network: Why it failed gives an example.
To retry one failed account, see Retry or settle an account. Each cause is explained in Why it failed.
Top posts
top_posts.by_views and top_posts.by_likes list the 5 posts of the range with the most views and the most likes, the most first. On a tie, the newer post comes first.
top_posts, in the same answer, trimmed
{ "top_posts": { "by_views": [ { "post_id": "cmh1post0t0001l708x9q2w3er", "text_start": "Fresh sourdough is out of the oven. Come by before noon!", "networks": [ "x", "linkedin" ], "count": 1840 } ], "by_likes": [ { "post_id": "cmh1post0t0001l708x9q2w3er", "text_start": "Fresh sourdough is out of the oven. Come by before noon!", "networks": [ "x", "linkedin" ], "count": 64 } ] }}post_id- The post.
GET /v1/posts/{id}/resultsgives its numbers per account. text_start- The start of the post's text, or of a thread's first part: at most 200 characters.
count- The post's views or likes: the sum of its accounts' numbers that are not
null. networks- The networks of the accounts whose numbers are in
count, in the post's order.
The lists use the numbers last read. This call never starts a read. A post's numbers are read only when you ask for them. So a post whose numbers nobody asked for is not in the lists. Neither is a post with no such number, such as a post to Bluesky only in by_views.
Errors
| Code | Status | When |
|---|---|---|
invalid_request | 400 | range is not 7d, 30d or 90d: "Unknown range. Send one of: 7d, 30d, 90d." Or time_zone is not an IANA name: "Send an IANA time zone name, like Europe/Berlin or UTC." issues names the field. |
missing_api_key | 401 | No API key. |
invalid_api_key | 401 | A wrong or revoked API key. |
An AI tool gets the same numbers with the MCP tools get_post_results and get_analytics. See MCP server.
Every field and error is in the API reference.