The Threads Insights API allows you to read the insights from users' own Threads.
The Threads Insights API requires an appropriate access token and permissions based on the node you are targeting. While you are testing, you can easily generate tokens and grant your app permissions by using the Graph API Explorer.
threads_basic
— Required for making any calls to all Threads API endpoints.threads_manage_insights
— Required for making GET
calls to insights endpoints.since
and until
parameters do not work for dates before April 13, 2024 (Unix timestamp 1712991600
).To retrieve the available insights metrics, send a GET
request to the /{threads-media-id}/insights
endpoint with the metric
parameter containing a comma-separated list of metrics to be returned.
Note:
REPOST_FACADE
posts because it is a post made by another user.Name | Description |
---|---|
|
The number of times the post was viewed. Note:This metric is in development . |
|
The number of likes on the post. |
|
The number of replies on the post. Note:This number includes only top-level replies. |
|
The number of times the post was reposted. |
|
The number of times the post was quoted. |
curl -s -X GET \ -F "metric=likes,replies" \ -F "access_token=<THREADS_ACCESS_TOKEN>" "https://graph.threads.net/v1.0/<THREADS_MEDIA_ID>/insights"
{ "data": [ { "name": "likes", "period": "lifetime", "values": [ { "value": 100 } ], "title": "Likes", "description": "The number of likes on your post.", "id": "<media_id>/insights/likes/lifetime" }, { "name": "replies", "period": "lifetime", "values": [ { "value": 10 } ], "title": "Replies", "description": "The number of replies on your post.", "id": "<media_id>/insights/replies/lifetime" } ] }
To retrieve the available user insights metrics, send a GET
request to the /{threads-user-id}/threads_insights
endpoint with the metric
parameter, and optionally, the since
and until
parameters.
Name | Description |
---|---|
|
Optional. Format:Unix Timestamp |
|
Optional. Format:Unix Timestamp |
|
Required.A comma-separated list of the metrics to be returned. Must be at least one of the account metrics values. |
views
Time Series
The number of times your profile was viewed.
likes
Total Value
The number of likes on your posts.
replies
Total Value
The number of replies on your posts.
Note:This number includes only top-level replies.
reposts
Total Value
The number of times your posts were reposted.
quotes
Total Value
The number of times your posts were quoted.
followers_count
Total Value
Your total number of followers on Threads.
Note:
since
and until
parameters. follower_demographics
Total Value
The demographic characteristics of followers, including countries, cities, and gender distribution.
Note:
since
and until
parameters.breakdown
parameter equal to one of the following values: country
, city
, age
, or gender
.curl -s -X GET \ -F "metric=views" \ -F "access_token=<ACCESS_TOKEN>" \ "https://graph.threads.net/v1.0/<THREADS_USER_ID>/threads_insights"
{ "data": [ { "name": "views", "period": "day", "values": [ { "value": 10, "end_time": "1713789497" }, { "value": 20, "end_time": "1713789497" }, { "value": 30, "end_time": "1713789497" } ], "title": "views", "description": "The number of times your profile was viewed.", "id": "37602215421583/insights/views/day" } ] }
{ "data": [ { "name": "views", "period": "day", "total_value" : { “value”: 1 } "title": "views", "description": "The number of times your profile was viewed.", "id": "37602215421583/insights/views/day" } ] }