Your Instagram posts — captions, likes, comments
instagram.instagram.user.postsList your Instagram posts with captions, permalinks and like/comment counts
- 价格
- free按供应商原价
- 成功率
- —暂无成功率数据暂无成功率数据
- 延迟 p50
- ——
- 最后验证
- 2026年7月28日实测可用
GEThttps://toolswitch.dev/v1/tools/instagram.instagram.user.posts?limit=2&fields=id%2Ccaption%2Cmedia_type%2Cpermalink%2Ctimestamp%2Clike_count%2Ccomments_count预览在线试用即将上线供应商文档 ↗
- 可用平台额度调用
- 同步返回
- 读取公开数据
参数
media_type is IMAGE | VIDEO | CAROUSEL_ALBUM; a carousel's frames come from the children{media_url} sub-field. Stories are a different edge (/stories) and expire after 24h
| 参数 | 类型 | 必填 | 说明 | 示例 |
|---|---|---|---|---|
| 路径参数 | ||||
ig_user_id | 字符串 | 必填 | 17841400000000000 | |
| 查询参数 | ||||
limit | 整数 | 可选 | default 25 | 25 |
since | 字符串 | 可选 | Unix timestamp | |
until | 字符串 | 可选 | ||
fields | 字符串 | 必填 | id,caption,media_type,media_url,permalink,thumbnail_url,timestamp,like_count,comments_count | |
- 路径参数
ig_user_id字符串必填示例:
17841400000000000- 查询参数
limit整数可选default 25
示例:
25since字符串可选Unix timestamp
until字符串可选fields字符串必填示例:
id,caption,media_type,media_url,permalink,thumbnail_url,timestamp,like_count,comments_count
代码示例
将 $TOOLSWITCH_KEY 替换为你在控制台创建的密钥。
预览
curl -X GET 'https://toolswitch.dev/v1/tools/instagram.instagram.user.posts?limit=2&fields=id%2Ccaption%2Cmedia_type%2Cpermalink%2Ctimestamp%2Clike_count%2Ccomments_count' \
-H "X-Toolswitch-Key: $TOOLSWITCH_KEY"import os
import requests
response = requests.request(
"GET",
"https://toolswitch.dev/v1/tools/instagram.instagram.user.posts?limit=2&fields=id%2Ccaption%2Cmedia_type%2Cpermalink%2Ctimestamp%2Clike_count%2Ccomments_count",
headers={"X-Toolswitch-Key": os.environ["TOOLSWITCH_KEY"]},
)
response.raise_for_status()
print(response.text)const response = await fetch("https://toolswitch.dev/v1/tools/instagram.instagram.user.posts?limit=2&fields=id%2Ccaption%2Cmedia_type%2Cpermalink%2Ctimestamp%2Clike_count%2Ccomments_count", {
method: "GET",
headers: {
"X-Toolswitch-Key": process.env.TOOLSWITCH_KEY ?? "",
},
});
if (!response.ok) throw new Error(`Request failed: ${response.status}`);
console.log(await response.text());网关接口为预览版,地址与鉴权方式可能调整。 示例参数仅为样例数据。 调用按 free 计费,已含服务费。