GETInsights4–6 credits
Account stats
GET https://api.instagramapi.dev/v1/insights/profile/statsDerives an account's posting cadence (average gap between posts, posts/week) and content-format mix (photo / video / carousel share and average engagement per format, so you can see which format performs best). Pass `posts` (1–50, default 30) for the window. Cost: 4–6 credits depending on the window.
Build this with an AI agent
Paste this prompt into Claude, Codex, or any coding agent.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| handle | string | yes | An Instagram account. Accepts a username (`nike`), a numeric user id (`13460080`), or a full profile URL (`https://instagram.com/nike`). We resolve it automatically. |
| posts | number | no | Recent posts to analyze (1–50). Defaults to 30. |
Example request
curl "https://api.instagramapi.dev/v1/insights/profile/stats?handle=nike&posts=30" \
-H "Authorization: Bearer $INSTAGRAMAPI_KEY"Try it
Live request · uses 4 creditsExample responses
Switch tabs to see the body shape for success and each error status.
{
"data": {
"username": "nike",
"followers": 291952375,
"posts_analyzed": 30,
"avg_days_between_posts": 2.3,
"posts_per_week": 3,
"format_mix": [
{
"type": "carousel",
"posts": 14,
"share_pct": 46.7,
"avg_engagement": 512300
},
{
"type": "video",
"posts": 11,
"share_pct": 36.7,
"avg_engagement": 631200
},
{
"type": "photo",
"posts": 5,
"share_pct": 16.7,
"avg_engagement": 402100
}
],
"best_format": "video"
},
"meta": {
"endpoint": "insights/profile/stats",
"request_id": "req_3f8a1c9e",
"credits_charged": 4,
"credits_remaining": 4987,
"ms": 412
}
}Response fields
Fields returned under data on a 200 response. Every response also includes a meta object with billing info.
| Field | Type | Description |
|---|---|---|
| username | string | The account's @handle. |
| followers | number | Follower count at calculation time. |
| posts_analyzed | number | How many recent posts were analyzed. |
| avg_days_between_posts | number | Average number of days between consecutive posts. |
| posts_per_week | number | Average number of posts published per week. |
| format_mix | array<object> | Breakdown of content formats used, with share and engagement. |
| format_mix[].type | string | Content format: photo, video, or carousel. |
| format_mix[].posts | number | Number of analyzed posts in this format. |
| format_mix[].share_pct | number | Percentage of analyzed posts in this format. |
| format_mix[].avg_engagement | number | Average interactions (likes + comments) for posts in this format. |
| best_format | string | The format with the highest average engagement. |