Instagram Posts Scraper API
Extract posts, 12 by default as structured JSON from public Instagram Posts targets. Queue a request, then retrieve the result with its responseId.
Decide before you build
- Endpoint
- POST /scrape/data-scraper
- Scrapers
- instagramPost
- Cost
- 30 credits / call
- Free plan
- 1,000 credits / month
- Call pattern
- async, POST then GET
- On failure
- credits refunded
- Response format
- JSON
- Concurrency
- by plan tier
Launching a Social Media scrape costs 30 credits. Retrieving a pending result costs nothing; failed scrapes are refunded.
Try the Instagram Posts scraper on your own targetRun a request against a public target and inspect the JSON before you integrate.
Open the live testWhat you get back
instagramPostSingle post
Use instagramPost to retrieve single post data from a public Instagram target.
- Required input: url
- No optional input parameters
- Structured JSON once the result is ready
- Public data only; no account login is used
Call the Instagram Posts scraper
Send the scraper name with the input required by that scraper. The POST returns a responseId to poll for the final JSON.
# POST - queue a public social media scrape
curl -X POST "https://api.scraping-bot.io/scrape/data-scraper" \
-u "yourUsername:yourApiKey" \
-H "Content-Type: application/json" \
-d '{
"scraper": "instagramPost",
"url": "https://example.com/public-page"
}'# GET - retrieve the result after the POST returns a responseId
curl -G "https://api.scraping-bot.io/scrape/data-scraper-response" \
-u "yourUsername:yourApiKey" \
--data-urlencode "responseId=RESPONSE_ID" \
--data-urlencode "scraper=instagramPost"Code example
Authenticate with your ScrapingBot username and API key, then poll until the queued result is ready.
const auth = "Basic " + Buffer.from(
"yourUsername:yourApiKey",
).toString("base64");
const queued = await fetch("https://api.scraping-bot.io/scrape/data-scraper", {
method: "POST",
headers: { "Content-Type": "application/json", Authorization: auth },
body: JSON.stringify({
"scraper": "instagramPost",
"url": "https://example.com/public-page"
}),
});
const { responseId } = await queued.json();
let result;
do {
await new Promise((resolve) => setTimeout(resolve, 5000));
result = await fetch(
"https://api.scraping-bot.io/scrape/data-scraper-response?" +
new URLSearchParams({ responseId, scraper: "instagramPost" }),
{ headers: { Authorization: auth } },
).then((response) => response.json());
} while (result.status === "pending");Run this call in two minutesCreate an account, copy your API key, then use the example above.
Get your API keyRequest parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
scraper | string | — | One of the scraper names supported by this endpoint. |
url | string | — | Public page URL, including https://. |
Response example
Example returned by the legacy Instagram Posts scraper documentation.
{
"url": "https://www.instagram.com/p/CQd4lfnNwvV/",
"profile": {
"id": "2025001897",
"is_verified": true,
"profile_pic_url": "https://instagram.foua1-1.fna.fbcdn.net/v/t51.2885-19/207696833_1423225411377790_7822892350095029405_n.jpg?stp=dst-jpg_s150x150&_nc_ht=instagram.foua1-1.fna.fbcdn.net&_nc_cat=110&_nc_ohc=_itKYFRyEToAX9O499i&edm=AP_V10EBAAAA&ccb=7-5&oh=00_AfDeca8P-Mr9RDPrDK-vPy2aflRnpEP6H__ST4tEcSx-gQ&oe=644BDA12&_nc_sid=4f375e",
"username": "windows",
"blocked_by_viewer": false,
"restricted_by_viewer": null,
"followed_by_viewer": false,
"full_name": "Windows",
"has_blocked_viewer": false,
"is_embeds_disabled": false,
"is_private": false,
"is_unpublished": false,
"requested_by_viewer": false,
"pass_tiering_recommendation": true,
"edge_owner_to_timeline_media": {
"count": 827
},
"edge_followed_by": {
"count": 1978302
}
},
"media_url": "https://instagram.foua1-1.fna.fbcdn.net/v/t51.2885-15/204751774_954721708710290_3071819698407734088_n.jpg?stp=dst-jpg_e15_fr_s1080x1080&_nc_ht=instagram.foua1-1.fna.fbcdn.net&_nc_cat=102&_nc_ohc=RilscmimvHcAX_OEC3N&edm=AP_V10EBAAAA&ccb=7-5&oh=00_AfBYBBwVdgPmlcSsh-Y8dfrBYC51RrjbwTmWfrpfEC9c6Q&oe=6447D905&_nc_sid=4f375e",
"video_url": "https://instagram.foua1-1.fna.fbcdn.net/v/t50.2886-16/205672842_561535201649323_578508725279520310_n.mp4?efg=eyJ2ZW5jb2RlX3RhZyI6InZ0c192b2RfdXJsZ2VuLjk2MC5mZWVkLmRlZmF1bHQiLCJxZV9ncm91cHMiOiJbXCJpZ193ZWJfZGVsaXZlcnlfdnRzX290ZlwiXSJ9&_nc_ht=instagram.foua1-1.fna.fbcdn.net&_nc_cat=107&_nc_ohc=Qz52sR7m2fsAX-qkhwA&edm=AP_V10EBAAAA&vs=17890644809201097_451212220&_nc_vs=HBksFQAYJEdJcFJRZ3lySWptYXR2NEJBRGIydjkyZVJnY0lia1lMQUFBRhUAAsgBABUAGCRHQjJ2T0F6ek1SaVZxeVFCQUNOMjJqUWszNkpsYmtZTEFBQUYVAgLIAQAoABgAGwAVAAAm2rWQ1oW9vD8VAigCQzMsF0AjMzMzMzMzGBJkYXNoX2Jhc2VsaW5lXzFfdjERAHXqBwA%3D&ccb=7-5&oh=00_AfA1tmoKs9GrAgYLRw6C0j-AP3HUFxBLydp8HprmwEDb2w&oe=6447C993&_nc_sid=4f375e",
"video_view_count": 92809,
"video_play_count": "N/A",
"post_text": "Set a reminder to experience what’s new, live, June 24th at 11 am ET 📅 Link in bio.",
"likes_amount": 18790,
"post_timestamp": 1624460446,
"sponsor": "N/A",
"sponsor_link": "N/A",
"comments": [
{
"name": "jstn.wgnr",
"text": "Okay so y'all playing @prettylights"
},
{
"name": "jstn.wgnr",
"text": "Okay so y'all playing @prettylights"
},
{
"name": "yurytupikov",
"text": "🔥😍👏"
},
{
"name": "newfashion8605",
"text": "Sem dúvidas o Windows mais bonito.😍"
},
{
"name": "kimxpcomputerservices",
"text": "Amazing"
},
{
"name": "kimxpcomputerservices",
"text": "Amazing"
},
{
"name": "_mustafa_farooq_",
"text": "@heres_maaz @_hamza__syed_"
},
{
"name": "irf_oualla",
"text": "@amine_dnt"
}
],
"comments_count": 417,
"media": [
{
"src": "https://instagram.foua1-1.fna.fbcdn.net/v/t51.2885-15/204751774_954721708710290_3071819698407734088_n.jpg?stp=dst-jpg_e15_fr_s1080x1080&_nc_ht=instagram.foua1-1.fna.fbcdn.net&_nc_cat=102&_nc_ohc=RilscmimvHcAX_OEC3N&edm=AP_V10EBAAAA&ccb=7-5&oh=00_AfBYBBwVdgPmlcSsh-Y8dfrBYC51RrjbwTmWfrpfEC9c6Q&oe=6447D905&_nc_sid=4f375e",
"config_width": 1080,
"config_height": 1080
}
],
"id": "2602485026859191253",
"external_url": "",
"display_url": "",
"biography": "N/A"
}Credits, failures and limits
| Case | Credits | Notes |
|---|---|---|
| Launch a scrape | 30 credits | Consumed when a result is ready. |
| Result not ready | Not consumed | The API returns a pending status; retry after a few seconds. |
| Failed, blocked or timed-out scrape | Refunded | Credits are returned for an unsuccessful request. |
Instagram Posts API or Raw HTML scraper?
| Instagram Posts API | Raw HTML scraper | |
|---|---|---|
| Endpoint | /scrape/data-scraper | /scrape/raw-html |
| Returns | Posts, 12 by default JSON | Rendered page HTML |
| Flow | Asynchronous: POST then GET | One synchronous request |
| Starting cost | 30 credits | 1 credit |
| Use it when | You need parsed Instagram Posts data | You need your own extraction logic |
Questions about the Instagram Posts API
- Which Instagram Posts scraper names can I use?
- This page supports instagramPost. Send the exact name in the scraper field.
- Why does the API return a responseId?
- Social Media requests are asynchronous. The responseId lets you retrieve the result without holding the initial request open.
- What if the result is still pending?
- Wait a few seconds and repeat the GET request. A pending response does not consume credits.
- Does this scraper access private account data?
- No. It is intended for public pages and does not sign in to a social media account to access private data.
Source: ScrapingBot API documentation.
Other social media scrapers
Browse the Social Media category for the complete list of guides, or visit the ScrapingBot blog for implementation guides.
Trusted by developers and social media teams.
Customer reviews apply to ScrapingBot's service overall, not specifically to this scraper.
Start scraping Instagram Posts today
1,000 free credits every month. No card required, cancel anytime.
