Docs · Profile
Profile
A public profile's biography, links and follower counts.
https://api.lurkapi.com/v1/instagram/profileWhen to use this
Pass a username or profile URL. Follower and following counts come from public profile data. Post count and higher resolution images depend on what Instagram returns; missing fields are null.
Parameters
All parameters go in the query string.
| Parameter | Description |
|---|---|
usernamestringoptional | Instagram username, with or without @, or a profile URL. Required unless url is given.
|
urlstringoptional | An instagram.com profile URL. Required unless username is given. |
Example request
Replace YOUR_API_KEY with your key, or set LURKAPI_KEY for the code. Get a free key.
curl "https://api.lurkapi.com/v1/instagram/profile?username=nike" \
-H "x-api-key: YOUR_API_KEY"const params = new URLSearchParams({
username: "nike",
});
const res = await fetch(`https://api.lurkapi.com/v1/instagram/profile?${params}`, {
headers: { "x-api-key": process.env.LURKAPI_KEY },
});
const data = await res.json();
if (!data.success) throw new Error(`${data.code}: ${data.error}`);
console.log(data);import os
import requests
res = requests.get(
"https://api.lurkapi.com/v1/instagram/profile",
params={
"username": "nike",
},
headers={"x-api-key": os.environ["LURKAPI_KEY"]},
timeout=60,
)
data = res.json()
if not data["success"]:
raise RuntimeError(f"{data['code']}: {data['error']}")
print(data)Example response
A real response from this endpoint, captured from the live API and trimmed to a couple of items. Strings over 96 characters (mostly signed media URLs) are cut short and end in ….
Show the example response (1 KB)Hide
{
"success": true,
"credits_remaining": 99,
"credits_charged": 1,
"data": {
"pk": "13460080",
"id": "17841400602400210",
"username": "nike",
"url": "https://www.instagram.com/nike/",
"full_name": "Nike",
"biography": "Just Do It.",
"profile_pic_url": "https://scontent-iad6-1.cdninstagram.com/v/t51.82787-19/551608484_185671…",
"profile_pic_url_hd": "https://scontent-iad6-1.cdninstagram.com/v/t51.82787-19/551608484_185671…",
"is_private": false,
"is_verified": true,
"follower_count": 291074487,
"following_count": 266,
"media_count": null,
"external_url": "http://empli.fi/nike",
"bio_links": [
{
"url": "http://empli.fi/nike",
"title": ""
}
],
"pronouns": [],
"account_type": 2,
"category": "",
"total_clips_count": 1
}
}Response fields
Every field of a successful response. [] marks a list: a[].b is the b of each item in a. nullable fields can be null; optional fields can be missing.
Show all 25 fieldsHide
| Field | Type | Description |
|---|---|---|
| success | true | Always true here; errors have success: false. |
| credits_remaining | number | Your balance after this call. On anonymous playground calls: free tries left today. |
| credits_charged | number | Credits this call cost; 0 on free endpoints. On anonymous playground calls: tries used (1). |
| data | object | Profile details. |
| data.pk | string | Numeric Instagram user id, represented as a string. |
| data.id | stringnullable | Instagram's separate GraphQL profile id; null when not returned. |
| data.username | string | Instagram username, without @. |
| data.url | string | Canonical Instagram profile URL. |
| data.full_name | stringnullable | Display name; null when not returned. |
| data.biography | stringnullable | Biography, preserving line breaks; null when not returned. |
| data.profile_pic_url | stringnullable | Profile image URL; CDN links can expire; null when not returned. |
| data.profile_pic_url_hd | stringnullable | Higher resolution profile image URL, when available; null when not returned. |
| data.is_private | booleannullable | Whether the account is private; null when not returned. |
| data.is_verified | booleannullable | Whether Instagram shows a verified badge; null when not returned. |
| data.follower_count | numbernullable | Follower count; null when not shown or returned. A null count is not zero. |
| data.following_count | numbernullable | Number of accounts followed; null when not shown or returned. A null count is not zero. |
| data.media_count | numbernullable | Number of posts; public GraphQL frequently omits this count; null when not shown or returned. A null count is not zero. |
| data.external_url | stringnullable | Main website link in the profile; null when not returned. |
| data.bio_links | object[]nullable | Links listed in the bio, in Instagram's order; null when not returned. |
| data.bio_links[].url | string | The link's destination URL. |
| data.bio_links[].title | stringnullable | Link title; an empty title means none was set; null when not returned. |
| data.pronouns | string[]nullable | Pronouns the user set; null when not returned, empty when none are set. |
| data.account_type | numbernullable | Instagram's account type code, e.g. 2; null when not shown or returned. A null count is not zero. |
| data.category | stringnullable | Category label; an empty string means Instagram returned no label; null when not returned. |
| data.total_clips_count | numbernullable | Reel count returned by Instagram; it may differ from the number visible in the reels tab; null when not shown or returned. A null count is not zero. |
Caching and freshness
Responses are cached for up to 10 minutes, so a repeat call within that window can return the same data. It still costs 1 credit.
Errors
Errors return { success: false, error, code, docs } with the HTTP status below. Validation errors, 401/402/429 rejections and 5xx failures are free; not_found is charged (how charging works). All error codes.
| Status | Code | Meaning |
|---|---|---|
| 401 | missing_api_key | No API key. Send it in the x-api-key header. |
| 401 | invalid_api_key | The key is unknown or was revoked. |
| 402 | insufficient_credits | Not enough credits for this call. Buy a pack or wait for tomorrow's top-up. |
| 404 | not_found | The endpoint, or the thing you asked for (ad, post, subreddit), doesn't exist. Charged when the platform was checked. |
| 405 | method_not_allowed | Endpoints take GET with query params. |
| 429 | rate_limited | Too many calls at once. Wait for the retry-after seconds, then retry. |
| 500 | internal_error | Something broke on our side. Retry; 5xx errors are free. |
| 502 | upstream_error | The platform didn't give a usable answer. Retry; 5xx errors are free. |
| 503 | upstream_busy | All our connections to the platform are busy. Retry in a few seconds; 5xx errors are free. |
| 504 | upstream_timeout | The platform took over 30 seconds to answer. Retry; timeouts are free. |
Use it in Claude
Once LurkAPI is connected to Claude, this endpoint is the instagram_profile tool. Ask in plain English, for example:
Use LurkAPI's instagram_profile with username "nike" and summarize what you find.Claude calls instagram_profile with arguments like these, and each call costs 1 credit:
{
"username": "nike"
}Tool results skip nulls and empty lists to save tokens.