user_idstringจำเป็น
Instagram user ID
https://api.sandbase.ai/v1/api/instagram/v1/user-postsReturns a paginated list of posts for a specified Instagram account. Results include captions, like counts, comment counts, and media details.
เอาต์พุตของคุณจะแสดงที่นี่
กรอกอินพุตให้ครบ แล้วคลิก Run
Returns a paginated list of posts for one Instagram account. You send the numeric user_id of the account. Each item includes the post code, caption data, comment_count, and media details such as carousel items and clip metadata.
comment_count across an account's recent posts to compare engagement.next_max_id to archive its posts.curl -X POST "https://api.sandbase.ai/v1/api/instagram/v1/user-posts" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"user_id": "25025320"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
user_id | string | Yes | Instagram user ID |
count | integer | No | Count per page, default 12 |
max_id | string | No | Pagination cursor, omit for first request |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"attempts": "79",
"items": [
{
"are_remixes_crosspostable": true,
"boost_unavailable_identifier": null,
"boost_unavailable_reason": null,
"boost_unavailable_reason_v2": null,
"can_see_insights_as_brand": false,
"can_viewer_reshare": true,
"can_viewer_save": true,
"caption": {
"bit_flags": 0,
"content_type": "comment",
"created_at": 1793647551,
"created_at_utc": 1793647551,
"did_report_as_spam": false,
"is_covered": false,
"is_ranked_comment": false,
"media_id": 4021726163100932870
},
"caption_is_edited": false,
"client_cache_key": "NDAyMTcyNjE2MzEwMDkzMjg3MA==.3",
"clips_metadata": {
"achievements_info": {
"num_earned_achievements": null,
"show_achievements": false
},
"additional_audio_info": {
"additional_audio_username": null,
"audio_reattribution_info": {
"should_allow_restore": false
}
},
"asset_recommendation_info": null,
"audio_ranking_info": {
"best_audio_cluster_id": "1079281138448348"
},
"audio_type": "original_sounds",
"basel_template_info_for_ig_app": {
"is_basel_template": null,
"original_template_media_id": null,
"should_show_reuse_setting_for_owner": false,
"use_template_deeplink": null
},
"branded_content_tag_info": {
"can_add_tag": false
},
"breaking_content_info": null
},
"clips_tab_pinned_user_ids": []
}
],
"more_available": true,
"next_max_id": "4007127383642387898_25025320"
}
| Field | Meaning |
|---|---|
items[] | List of posts for the account. Each entry is one post, which can be a single video, a clip, or a carousel. |
items[].code | Short post code, for example DfQCqMnhpsG. It is the shortcode used in Instagram post links. |
items[].comment_count | Number of comments on the post. |
items[].caption.created_at / items[].caption.created_at_utc | Unix timestamp in seconds for when the caption was created. In the sample both values are equal. |
items[].caption.media_id | Numeric ID of the media that the caption belongs to. |
items[].accessibility_caption | Text description of the image. It appears on image posts and carousel items, not on every post. |
items[].carousel_media[] | Child items of a carousel post. Each one has its own caption, carousel_parent_id, and commerciality_status. |
items[].carousel_media_count | Number of items in the carousel post. |
items[].coauthor_producers[] | Accounts that co-author the post. Each entry has full_name, pk, is_verified, and is_private. |
items[].clips_metadata.audio_type | Type of audio on a clip, for example original_sounds. |
more_available | true when more posts can be fetched after this page. |
next_max_id | Cursor for the next page. Pass it as max_id in the next request. |
next_max_id from the response as max_id to get the next page. Stop when more_available is false.count sets the page size from 1 to 50. The default is 12.user_id is the numeric Instagram account ID. Get it from Instagram User Info by Username if you only have a username.clips_metadata, and carousels include carousel_media. To read one post in full, use Instagram Post Details by ID.$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
เริ่มสร้าง
เอ็นด์พอยต์ของ Platform API ที่มีการยืนยันตัวตนและการติดตามการใช้งานแบบรวมศูนย์
curl -X POST "https://api.sandbase.ai/v1/api/instagram/v1/user-posts" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"count": 12,
"user_id": "25025320"
}'ตั้งค่า SandBase API key ของคุณในสภาพแวดล้อมฝั่งเซิร์ฟเวอร์ คำขอจะใช้การยืนยันตัวตนแบบ Bearer
export SANDBASE_API_KEY="YOUR_API_KEY"เก็บ key ไว้บนเซิร์ฟเวอร์ อย่าเปิดเผยในโค้ดฝั่งเบราว์เซอร์
user_idstringจำเป็นInstagram user ID
countintegerCount per page, default 12
ค่าเริ่มต้น: 12
max_idstringPagination cursor, omit for first request
บันทึกตัวอย่างการตอบกลับสำหรับ API นี้; จะไม่มีการส่งคำขอจริงเมื่อเปิดดู
ยังไม่มีการเผยแพร่การตอบกลับที่บันทึกไว้ ให้รัน API ใน Playground เพื่อดูการตอบกลับ
สำรวจเพิ่มเติม
| API | ราคา | การตอบกลับ |
|---|---|---|
Instagram User Posts (V1)API นี้ Instagram | $0.001 ต่อการเรียก | JSON |
Instagram | $0.001 ต่อการเรียก | JSON |
Instagram | $0.001 ต่อการเรียก | JSON |
Instagram | $0.001 ต่อการเรียก | JSON |
Instagram | $0.001 ต่อการเรียก | JSON |
Instagram | $0.001 ต่อการเรียก | JSON |
คู่มือ:Instagram API cost: official limits and per-call pricesBest Instagram API in 2026: Pricing Compared
คำถาม
ส่งคำขอ POST ไปที่ https://api.sandbase.ai/v1/api/instagram/v1/user-posts โดยใส่ SandBase API key ของคุณใน Authorization header (Bearer) และส่งพารามิเตอร์เป็น JSON body คุณยังสามารถลองใช้ได้ใน Playground บนหน้านี้โดยไม่ต้องเขียนโค้ด
$0.001 ต่อครั้ง ทุกองค์กรจะได้รับคำขอฟรี 100 ครั้งต่อวัน UTC โดยใช้ร่วมกันใน SandBase APIs ที่เข้าเงื่อนไขรวมถึงรายการนี้ หลังจากนั้นแต่ละคำขอจะคิดค่าบริการตามราคานี้จากยอดคงเหลือ SandBase ของคุณ ไม่มีค่าสมาชิกรายเดือน
ที่ต้องระบุ: user_id (string). ตัวเลือก: count (integer) และ max_id (string). ตาราง Parameters และ Playground ในหน้านี้แสดงทุกฟิลด์
การตอบกลับ JSON ที่ส่งกลับในคำขอ HTTP เดียวกัน (แบบซิงโครนัส) README บนหน้านี้มีตัวอย่างการตอบกลับ
ไม่จำเป็น Instagram User Posts (V1) ทำงานผ่าน SandBase ดังนั้น SandBase API key เดียวครอบคลุม endpoint นี้และทุก API กับโมเดลอื่นในแค็ตตาล็อก คุณไม่ต้องสมัครขอสิทธิ์เข้าถึง Instagram API แยกต่างหาก