Analytics
Post statistics
One post’s numbers on each account it went to, and how they grew. Needs analytics:read.
GET
/
v1
/
analytics
/
posts
/
{postId}
Post statistics
curl --request GET \
--url https://api.postinger.dev/v1/analytics/posts/{postId} \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.postinger.dev/v1/analytics/posts/{postId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.postinger.dev/v1/analytics/posts/{postId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"postId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"targets": [
{
"socialAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"platform": "instagram",
"format": "<string>",
"publishedAt": "2023-11-07T05:31:56Z",
"externalUrl": "<string>",
"state": "active",
"lastSyncedAt": "2023-11-07T05:31:56Z",
"nextSyncAt": "2023-11-07T05:31:56Z",
"error": "<string>",
"metrics": {
"views": 123,
"reach": 123,
"likes": 123,
"comments": 123,
"shares": 123,
"saves": 123,
"engagements": 123,
"avgWatchSeconds": 123
},
"snapshots": [
{
"takenAt": "2023-11-07T05:31:56Z",
"metrics": {
"views": 123,
"reach": 123,
"likes": 123,
"comments": 123,
"shares": 123,
"saves": 123,
"engagements": 123,
"avgWatchSeconds": 123
}
}
]
}
]
}Was this page helpful?
⌘I
Post statistics
curl --request GET \
--url https://api.postinger.dev/v1/analytics/posts/{postId} \
--header 'Authorization: Bearer <token>'const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.postinger.dev/v1/analytics/posts/{postId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.postinger.dev/v1/analytics/posts/{postId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"postId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"targets": [
{
"socialAccountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"platform": "instagram",
"format": "<string>",
"publishedAt": "2023-11-07T05:31:56Z",
"externalUrl": "<string>",
"state": "active",
"lastSyncedAt": "2023-11-07T05:31:56Z",
"nextSyncAt": "2023-11-07T05:31:56Z",
"error": "<string>",
"metrics": {
"views": 123,
"reach": 123,
"likes": 123,
"comments": 123,
"shares": 123,
"saves": 123,
"engagements": 123,
"avgWatchSeconds": 123
},
"snapshots": [
{
"takenAt": "2023-11-07T05:31:56Z",
"metrics": {
"views": 123,
"reach": 123,
"likes": 123,
"comments": 123,
"shares": 123,
"saves": 123,
"engagements": 123,
"avgWatchSeconds": 123
}
}
]
}
]
}