Skip to main content
POST
analytics
/
posts
/
{post}
/
sync
curl -X POST "https://postsyncer.com/api/v1/analytics/posts/743/sync" \
  -H "Authorization: Bearer YOUR_API_TOKEN"
{
  "post_id": 743,
  "jobs_dispatched": 2,
  "skipped": false,
  "skip_reason": null
}

Queue analytics sync

Triggers the same logic as Post::syncAnalytics() in the app: for each published platform row that has platform_post_id, post_id, and account_id, a job is dispatched to fetch the latest insights from the network. Not immediate: responses describe how many jobs were queued. Poll GET /analytics/posts/{post} (or the dashboard) after the queue workers finish.

Eligibility

  • If the post owner does not have an active, trialing, or grace-period subscription, the request still returns 200 with skipped: true, jobs_dispatched: 0, and skip_reason: "post_owner_subscription_inactive".
  • You must belong to the post’s workspace (same access rules as reading analytics).

Request

post
integer
required
Post id (same as in /posts/{id}).
No body.
curl -X POST "https://postsyncer.com/api/v1/analytics/posts/743/sync" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Response

post_id
integer
Post id from the path
jobs_dispatched
integer
Number of insight fetch jobs queued (one per eligible published platform row)
skipped
boolean
true when no jobs were queued because of subscription rules on the post owner
skip_reason
string
post_owner_subscription_inactive when skipped; otherwise null
{
  "post_id": 743,
  "jobs_dispatched": 2,
  "skipped": false,
  "skip_reason": null
}
When the post owner’s subscription does not allow sync:
{
  "post_id": 743,
  "jobs_dispatched": 0,
  "skipped": true,
  "skip_reason": "post_owner_subscription_inactive"
}

Permissions

Requires the posts ability.

Errors

401 · 403 · 404 if the post is missing or not in a workspace you can access See also: Analytics overview.