usernamestringจำเป็น
Instagram username/handle to fetch currently live stories for (without the @).
https://api.sandbase.ai/v1/api/instagram/stories-thinFetch a public Instagram account's currently live stories - media URL, owner, and posting time - by username. Lightweight projection; for media type, dimensions, and the 24h expiry time use instagram.stories_full.
เอาต์พุตของคุณจะแสดงที่นี่
กรอกอินพุตให้ครบ แล้วคลิก Run
This API returns the currently live stories for a public Instagram account. It needs one input, the account username without the @. Each story comes with a media URL, a permalink, the owner's name and a creation timestamp.
curl -X POST "https://api.sandbase.ai/v1/api/instagram/stories-thin" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"username": "nba"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
username | string | Yes | Instagram username/handle to fetch currently live stories for (without the @). |
requireFields | array | No | Optional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example durationSeconds, and it is served only by a source that returns ever |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"data": {
"items": [
{
"avatarUrl": "https://scontent-iad6-1.cdninstagram.com/v/t51.82787-19/870530727_18700682161024…",
"createdUtc": 1793641838,
"displayName": "NBA",
"durationSeconds": 15,
"id": "4021681708511308746",
"mediaUrl": "https://scontent-iad3-1.cdninstagram.com/o1/v/t2/f2/m78/AQN3hjdE6SuRgC6FGlEF0bff…",
"permalink": "https://www.instagram.com/reel/DfP4jTDgKvK/",
"username": "nba",
"verified": true
}
]
},
"found": true
}
| Field | Meaning |
|---|---|
found | true when the lookup returned a result. A lookup that finds nothing returns false. |
data.items[] | One entry per live story. The list holds every story the account currently has up. |
data.items[].id | Unique ID of the story, as a numeric string. |
data.items[].mediaUrl | Direct URL of the story's image or video file. |
data.items[].permalink | Instagram link to the story's post page. |
data.items[].createdUtc | Time the story was posted, as a Unix timestamp in seconds. |
data.items[].durationSeconds | Length of the story in seconds. It is null on the image story in the sample, so treat null as no duration. |
data.items[].username / data.items[].displayName | The handle and display name of the account that posted the story. |
data.items[].verified | true when the account is verified. |
data.items[].avatarUrl | URL of the account's profile picture. |
username, with no @.requireFields: ["durationSeconds"] to force a source that returns the duration. This can raise the price of the call.mediaUrl and avatarUrl values are long CDN links with query strings. Store the full string.Billed at the actual cost of each call, about $0.00188 for the request above. Failed calls are not charged.
เริ่มสร้าง
เอ็นด์พอยต์ของ Platform API ที่มีการยืนยันตัวตนและการติดตามการใช้งานแบบรวมศูนย์
curl -X POST "https://api.sandbase.ai/v1/api/instagram/stories-thin" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"username": "nba"
}'ตั้งค่า SandBase API key ของคุณในสภาพแวดล้อมฝั่งเซิร์ฟเวอร์ คำขอจะใช้การยืนยันตัวตนแบบ Bearer
export SANDBASE_API_KEY="YOUR_API_KEY"เก็บ key ไว้บนเซิร์ฟเวอร์ อย่าเปิดเผยในโค้ดฝั่งเบราว์เซอร์
usernamestringจำเป็นInstagram username/handle to fetch currently live stories for (without the @).
requireFieldsarrayOptional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example `durationSeconds`, and it is served only by a source that returns every one of them. Fields you do not name are still returned whenever the serving source has them. This can raise your price: when the cheapest source cannot return a named field, a dearer source serves, and you are quoted and charged its price. A named field can still be absent on a story that genuinely lacks it. Naming a combination that no single source returns together is refused as invalid input, with no charge.
บันทึกตัวอย่างการตอบกลับสำหรับ API นี้; จะไม่มีการส่งคำขอจริงเมื่อเปิดดู
ยังไม่มีการเผยแพร่การตอบกลับที่บันทึกไว้ ให้รัน API ใน Playground เพื่อดูการตอบกลับ
สำรวจเพิ่มเติม
| API | ราคา | การตอบกลับ |
|---|---|---|
Instagram Stories (basic)API นี้ Instagram | เริ่มต้นที่ $0.00188 ต่อครั้ง | JSON |
Instagram | เริ่มต้นที่ $0.0011 ต่อครั้ง | JSON |
Instagram | เริ่มต้นที่ $0.001 ต่อครั้ง | JSON |
Instagram | เริ่มต้นที่ $0.0011 ต่อครั้ง | JSON |
Instagram | เริ่มต้นที่ $0.0012 ต่อครั้ง | JSON |
Instagram | เริ่มต้นที่ $0.0011 ต่อครั้ง | JSON |
คู่มือ:Instagram API cost: official limits and per-call pricesBest Instagram API in 2026: Pricing Compared
คำถาม
ส่งคำขอ POST ไปที่ https://api.sandbase.ai/v1/api/instagram/stories-thin โดยใส่ SandBase API key ของคุณใน Authorization header (Bearer) และส่งพารามิเตอร์เป็น JSON body คุณยังสามารถลองใช้ได้ใน Playground บนหน้านี้โดยไม่ต้องเขียนโค้ด
เริ่มต้นที่ $0.00188 ต่อครั้ง คิดจากยอดคงเหลือ SandBase ของคุณ คุณจะถูกเรียกเก็บเฉพาะคำขอที่คุณส่งเท่านั้น ไม่มีค่าสมาชิกรายเดือน
ที่ต้องระบุ: username (string). ตัวเลือก: requireFields (array). ตาราง Parameters และ Playground ในหน้านี้แสดงทุกฟิลด์
การตอบกลับ JSON ที่ส่งกลับในคำขอ HTTP เดียวกัน (แบบซิงโครนัส) README บนหน้านี้มีตัวอย่างการตอบกลับ
ไม่จำเป็น Instagram Stories (basic) ทำงานผ่าน SandBase ดังนั้น SandBase API key เดียวครอบคลุม endpoint นี้และทุก API กับโมเดลอื่นในแค็ตตาล็อก คุณไม่ต้องสมัครขอสิทธิ์เข้าถึง Instagram API แยกต่างหาก