The Analytics section provide access to social media analytics data for connected accounts in your workspace. These endpoints allow you to retrieve available charts and their corresponding data for various social media platforms.
The Charts endpoints let you:
Discover which analytics charts are available (and their IDs).
Fetch time‑series and comparative data for selected charts.
Use the returned id
values from “List Charts” with “Get Chart Data” to build dashboards and reports.
Authentication: Bearer API token
Scope: analytics
Headers:
Authorization: Bearer-API YOUR_API_KEY
Publer-Workspace-Id: YOUR_WORKSPACE_ID
Retrieve chart definitions.
GET /api/v1/analytics/charts
Returns a list of charts grouped by category (growth, insights, demographics). Different platforms expose different charts.
account_type
string
No
Filter charts for a specific account type.
Account type values:
ig_business
, fb_page
, twitter
, linkedin
, youtube
, tiktok
, google
, pin_business
, pin_personal
, threads
, wordpress_oauth
, in_profile
, in_page
, mastodon
, bluesky
id
Unique chart identifier (use in chart_ids[]
).
title
Display title.
group_id
Chart group: growth
, insights
, demographics
.
tooltip
Short explanatory text.
type
Suggested visualization: vertical
, horizontal
, side_by_side
.
last_value
Show latest value highlight.
show_percentage
Indicates client should render as percentage.
Fetch data for one or more charts by ID. Returns current and previous period blocks for comparison.
GET /api/v1/analytics/:account_id/chart_data
Supports growth metrics, post insights, and demographics. Chart IDs must come from the “List Charts” endpoint.
For better performance and lower latency, request chart data in small logical batches of related chart_ids
(e.g., growth first, then insights, then demographics) instead of sending every available chart ID in one call.
account_id
string
No
When provided, returns data for that account only; when omitted, returns aggregate across the workspace (where supported).
chart_ids[]
string[]
Yes
One or more chart IDs from /api/v1/analytics/charts
. Example: chart_ids[]=followers&chart_ids[]=post_engagement
from
string (YYYY-MM-DD)
Yes if to
used
Start date (inclusive). Defaults to workspace range if omitted with to
.
to
string (YYYY-MM-DD)
Yes if from
used
End date (inclusive). Defaults to workspace range if omitted with from
.
current
Object keyed by chart ID with current period series.
previous
Matching structure for the previous (comparison) period.
data[]
Array of { date, value }
points.
last_value
Latest cumulative snapshot (growth charts).
total
Period aggregate sum (engagement / sum charts).
Always fetch chart IDs from /api/v1/analytics/charts
; charts can change over time.
If account_id
is omitted, results are aggregated across accessible accounts (where the metric supports aggregation).
The comparison (previous) window automatically matches the current window length.
Ensure from
≤ to
when providing dates.
Not all charts are available for every account_type
.
Apply client‑side caching for chart definitions to reduce requests.
Accounts API - Manage social media accounts
Hashtag Analysis — Track hashtag performance
Best Times — Suggested posting time slots
Members — Member (team) analytics
Retrieves a list of available analytics charts filtered by account type and chart type. Charts include growth metrics (followers, connections), insights (engagement, reach), and demographics (countries, ages).
Social media platform type to filter charts for (e.g., 'ig_business', 'fb_page', 'twitter', 'linkedin', 'youtube', 'tiktok', 'google', 'pin_business')
ID of the workspace to retrieve charts from
List of available charts with metadata
Unauthorized
Permission denied or missing required scope
GET /api/v1/analytics/charts HTTP/1.1
Host: app.publer.com
Publer-Workspace-Id: text
Accept: */*
[
{
"id": "followers",
"title": "Followers",
"group_id": "growth",
"tooltip": "text",
"type": "vertical",
"last_value": true,
"show_percentage": true
}
]
Retrieves analytics data for specific charts by their IDs. Returns current and previous period data for comparison. Supports growth metrics, post insights, and demographic data.
Optional account ID to filter analytics data for a specific social media account
Array of chart IDs to retrieve data for. Use chart IDs from the /analytics/charts endpoint
{"value":["followers","post_engagement","post_reach"]}
Start date for analytics data (YYYY-MM-DD format)
End date for analytics data (YYYY-MM-DD format)
ID of the workspace to retrieve data from
Analytics chart data with current and previous period values
Unauthorized
Permission denied or missing required scope
GET /api/v1/analytics/chart_data HTTP/1.1
Host: app.publer.com
Publer-Workspace-Id: text
Accept: */*
{
"current": {
"ANY_ADDITIONAL_PROPERTY": {}
},
"previous": {
"ANY_ADDITIONAL_PROPERTY": {}
}
}