Skip to content

API

Query your data from anywhere

Everything nilometrics tracks is available over a plain REST API: followers, posts, reels and their full engagement history. No dashboard required.

Authentication

Create a key under Dashboard → API keys. The secret is shown once, so store it somewhere safe. Send it as a bearer token:

curl https://api.nilometrics.com/v1/accounts \
  -H "Authorization: Bearer igt_live_..."

API access is included whenever you have credits. A key on an account with no credits is refused with 403.

Endpoints

GET/v1/me

Your plan, credit balance and what your tracking costs per week.

{
  "email": "[email protected]",
  "plan": "PAID",
  "credit_balance_cents": 480,
  "tracked_accounts": 3,
  "active_accounts": 3,
  "weekly_cost_cents": 60
}
GET/v1/accounts

Every account you track, with its latest metrics and daily follower change.

{
  "data": [
    {
      "username": "nasa",
      "display_name": "NASA",
      "status": "ACTIVE",
      "followers": 98450120,
      "following": 78,
      "posts_count": 4210,
      "followers_delta": 12043,
      "last_scraped_at": "2026-07-11T03:00:00Z",
      "tracked_since": "2026-06-02T10:14:00Z"
    }
  ],
  "total": 1,
  "limit": 50,
  "offset": 0
}
GET/v1/accounts/{username}

A single tracked account.

{
  "username": "nasa",
  "followers": 98450120,
  "followers_delta": 12043,
  "status": "ACTIVE"
}
GET/v1/accounts/{username}/history

Follower history, oldest first, ready to plot. Filter with ?since= and ?until= (ISO-8601).

[
  { "captured_at": "2026-07-09T03:00:00Z", "followers": 98420000, "following": 78, "posts_count": 4208 },
  { "captured_at": "2026-07-10T03:00:00Z", "followers": 98438077, "following": 78, "posts_count": 4209 },
  { "captured_at": "2026-07-11T03:00:00Z", "followers": 98450120, "following": 78, "posts_count": 4210 }
]
GET/v1/accounts/{username}/posts

Posts and reels with their latest likes, comments and views.

{
  "data": [
    {
      "shortcode": "C8xK2pQr1Ab",
      "type": "REEL",
      "caption": "Launch day.",
      "posted_at": "2026-07-09T16:30:00Z",
      "likes": 812004,
      "comments": 9120,
      "views": 24500000,
      "last_captured_at": "2026-07-11T03:00:00Z"
    }
  ],
  "total": 1,
  "limit": 50,
  "offset": 0
}
GET/v1/accounts/{username}/posts/{shortcode}/history

How one post's engagement grew, day by day.

[
  { "captured_at": "2026-07-10T03:00:00Z", "likes": 640221, "comments": 7011, "views": 18900000 },
  { "captured_at": "2026-07-11T03:00:00Z", "likes": 812004, "comments": 9120, "views": 24500000 }
]

Rate limits

Requests are limited per key. Every response carries X-RateLimit-Limit and X-RateLimit-Remaining. Going over returns 429 with a Retry-After header telling you how long to wait.

Freshness

Accounts are scraped every 24 hours. followers is null until the first scrape lands, and last_scraped_at always tells you exactly when the numbers were captured, so you never have to guess how old a figure is.

Full reference

An OpenAPI schema and an interactive explorer are served by the API itself.

Open the API explorer