Skip to main content

TikTok Analytics

TikTok analytics endpoints provide insights for your connected TikTok accounts.

1. GET /api/tiktok/overview

Returns account-level metrics with current vs. previous period comparison.

Sample Request

curl --location --request GET \
"https://analyze.oneupapp.io/api/tiktok/overview?apiKey=YOUR_API_KEY&social_network_id=123&preset=last_30_days"

Sample Response

{
"success": true,
"data": {
"metrics": [
{
"key": "posts",
"name": "Posts",
"value_current_period": 15,
"value_last_period": 12,
"percentage_change": "+25.0%",
"description": "Total number of posts in this period"
},
{
"key": "views",
"name": "Views",
"value_current_period": 125000,
"value_last_period": 100000,
"percentage_change": "+25.0%",
"description": "Total number of views on your videos"
},
{
"key": "likes",
"name": "Likes",
"value_current_period": 5500,
"value_last_period": 4500,
"percentage_change": "+22.2%",
"description": "The number of likes on your videos"
},
{
"key": "comments",
"name": "Comments",
"value_current_period": 280,
"value_last_period": 220,
"percentage_change": "+27.3%",
"description": "The number of comments on your videos"
},
{
"key": "shares",
"name": "Shares",
"value_current_period": 420,
"value_last_period": 340,
"percentage_change": "+23.5%",
"description": "The number of times your videos were shared"
},
{
"key": "saves",
"name": "Saves",
"value_current_period": 180,
"value_last_period": 150,
"percentage_change": "+20.0%",
"description": "The number of times your videos were saved"
}
],
"total_followers": 25000,
"post_performance": {
"most_engaging": [],
"least_engaging": [],
"most_views": [],
"least_views": [],
"most_shared": [],
"least_shared": []
}
}
}

Metrics

KeyNameDescription
postsPostsTotal posts published
viewsViewsTotal number of views on your videos
likesLikesThe number of likes on your videos
commentsCommentsThe number of comments on your videos
sharesSharesThe number of times your videos were shared
savesSavesThe number of times your videos were saved

2. GET /api/tiktok/posts

Returns analytics for individual posts.

Sample Request

curl --location --request GET \
"https://analyze.oneupapp.io/api/tiktok/posts?apiKey=YOUR_API_KEY&social_network_id=123&preset=last_30_days"

Sample Response

{
"success": true,
"data": {
"stats": [
{
"key": "posts",
"name": "Posts",
"value_current_period": 15,
"value_last_period": 12,
"percentage_change": "+25.0%",
"description": "Total number of posts in this period"
},
{
"key": "views",
"name": "Views",
"value_current_period": 125000,
"value_last_period": 100000,
"percentage_change": "+25.0%",
"description": "Total number of views on your videos"
},
{
"key": "likes",
"name": "Likes",
"value_current_period": 5500,
"value_last_period": 4500,
"percentage_change": "+22.2%",
"description": "The number of likes on your videos"
},
{
"key": "comments",
"name": "Comments",
"value_current_period": 280,
"value_last_period": 220,
"percentage_change": "+27.3%",
"description": "The number of comments on your videos"
},
{
"key": "shares",
"name": "Shares",
"value_current_period": 420,
"value_last_period": 340,
"percentage_change": "+23.5%",
"description": "The number of times your videos were shared"
},
{
"key": "saves",
"name": "Saves",
"value_current_period": 180,
"value_last_period": 150,
"percentage_change": "+20.0%",
"description": "The number of times your videos were saved"
}
],
"posts": [
{
"id": "video_7123456789",
"page_id": "tiktok_account_123",
"format": "video",
"text": "Viral dance challenge",
"permalink": "https://tiktok.com/@user/video/7123456789",
"media_type": "VIDEO",
"media_url": "https://example.com/tiktok.jpg",
"stats": {
"views": 8333,
"likes": 367,
"comments": 19,
"shares": 28,
"saves": 12
},
"timestamp": "2025-05-01 15:00:00"
}
]
}
}

Post Stats

FieldDescription
viewsNumber of views
likesNumber of likes
commentsNumber of comments
sharesNumber of shares
savesNumber of saves

3. GET /api/tiktok/demographics

Returns audience demographic data.

Sample Request

curl --location --request GET \
"https://analyze.oneupapp.io/api/tiktok/demographics?apiKey=YOUR_API_KEY&social_network_id=123&preset=last_30_days"

Sample Response

{
"success": true,
"data": [
{
"key": "age_group_demographics",
"name": "Followers by Age",
"data": [
{
"name": "18-24",
"value": 10000,
"percentage": 40.0,
"share": 40.0
},
{
"name": "25-34",
"value": 8750,
"percentage": 35.0,
"share": 35.0
},
{
"name": "13-17",
"value": 3750,
"percentage": 15.0,
"share": 15.0
},
{
"name": "35-44",
"value": 1750,
"percentage": 7.0,
"share": 7.0
},
{
"name": "45-54",
"value": 500,
"percentage": 2.0,
"share": 2.0
},
{
"name": "55+",
"value": 250,
"percentage": 1.0,
"share": 1.0
}
]
},
{
"key": "gender_demographics",
"name": "Followers by Gender",
"data": [
{
"name": "Female",
"value": 15000,
"percentage": 60.0,
"share": 60.0
},
{
"name": "Male",
"value": 10000,
"percentage": 40.0,
"share": 40.0
}
]
},
{
"key": "country_demographics",
"name": "Followers by Country",
"data": [
{
"name": "United States",
"value": 10000,
"percentage": 40.0,
"share": 40.0
},
{
"name": "United Kingdom",
"value": 3750,
"percentage": 15.0,
"share": 15.0
},
{
"name": "Canada",
"value": 2500,
"percentage": 10.0,
"share": 10.0
}
]
},
{
"key": "city_demographics",
"name": "Followers by City",
"data": [
{
"name": "New York",
"value": 2500,
"percentage": 10.0,
"share": 10.0
},
{
"name": "Los Angeles",
"value": 2000,
"percentage": 8.0,
"share": 8.0
},
{
"name": "London",
"value": 1750,
"percentage": 7.0,
"share": 7.0
}
]
}
]
}

Demographics Data

FieldDescription
nameDemographic segment name
valueCount or absolute number
percentagePercentage value
shareShare percentage (same as percentage)

Result: You have successfully retrieved TikTok analytics data!