Analytics

Get post analytics

Returns one post when postId is supplied. Otherwise returns a paginated analytics list with aggregate overview metrics.

get/v1/analytics

Request

  • Base URL: https://api.postzen.dev
  • URL: https://api.postzen.dev/v1/analytics
  • Auth: HTTP bearer

Query parameters

postIdstring

PostZen post id or platform post id. When supplied, the response is a single analytics object.

'x' | 'instagram' | 'tiktok' | 'linkedin' | 'facebook' | 'youtube' | 'threads' | 'pinterest' | 'bluesky' | 'telegram'
OR
'all'

Platform slug, or all for every platform.

profileIdstring

Filter by PostZen profile id.

accountIdstring

Filter by connected social account id.

source'all' | 'postzen' | 'external'

Filter by posts published through PostZen or imported from a platform.

string date
OR
string date-time

Inclusive range start. Defaults to 90 days before toDate.

string date
OR
string date-time

Inclusive range end. Defaults to the current time.

limitinteger

Page size.

pageinteger

1-based page number.

sortBy'date' | 'engagement' | 'impressions' | 'reach' | 'likes' | 'comments' | 'shares' | 'saves' | 'clicks' | 'views'

Field used to order list results.

order'asc' | 'desc'

Sort direction.

Response

Single-post analytics or a paginated analytics list.

OR

Changes

No recorded changes to this operation across all 1 revision of this API.