Sand AISand AI MAGI-2MAGI-2 现已上线 SandBase:支持原生音频的 1080p 视频立即试用

Instagram Post Details by ID

API 文档
https://api.sandbase.ai/v1/api/instagram/v1/post-by-id

Returns detailed information for a single Instagram post using its unique post identifier. Use this endpoint to look up post metadata and display resources.

价格
$0.001美元 / 次调用
方法
POST
响应
JSON
参数
1 个必填 · 0 个可选

Playground

输入
Post ID
输出示例
响应outputs · 7.2 KB · 128 行
[
  {
    "data": {
      "__typename": "GraphImage",
      "accessibility_caption": null,
      "attempts": "34",
      "can_see_insights_as_brand": false,
      "caption_is_edited": false,
      "coauthor_producers": [],
      "commenting_disabled_for_viewer": false,
      "comments_disabled": false,
      "dimensions": {
        "height": 1080,
        "width": 1080
      },
      "display_resources": [
        {
          "config_height": 480,
          "config_width": 360,
          "src": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-15/562815025_18601398793054956_8673755740587648163_n.jpg?stp=dst-jpg_e35_s480x480_sh2.08_tt6&_nc_cat=109&_nc_map=urlgen_bucketless&ig_cache_key=Mzc0MjYzNzg3MTExMjAzMjEwMA%3D%3D.3-ccb7-5&ccb=7-5&_nc_sid=58cdad&efg=eyJ2ZW5jb2RlX3RhZyI6IkZFRUQueHBpZHMuMTQ0MC5zZHIucmVndWxhcl9waG90by5DMyJ9&_nc_ohc=dKrxeuM_VmYQ7kNvwEo0FB8&_nc_oc=AdpZiZy2SQP3v4-JJu9FSErEcSlvXMg2CqsqZvyYUJb1lwCUkIsSMutRqtcLOEwdSL4&_nc_ad=z-m&_nc_cid=0&_nc_zt=23&_nc_ht=instagram.fbcn2-1.fna&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&_nc_ss=7a3ba&oh=00_AQPTodbxxcJgq_qw8CoeJx1jSL546kKQBuex6av5218gs…"
        },
        {
          "config_height": 1440,
          "config_width": 1080,
          "src": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-15/562815025_18601398793054956_8673755740587648163_n.jpg?stp=dst-jpg_e35_p1080x1080_sh2.08_tt6&_nc_cat=109&_nc_map=urlgen_bucketless&ig_cache_key=Mzc0MjYzNzg3MTExMjAzMjEwMA%3D%3D.3-ccb7-5&ccb=7-5&_nc_sid=58cdad&efg=eyJ2ZW5jb2RlX3RhZyI6IkZFRUQueHBpZHMuMTQ0MC5zZHIucmVndWxhcl9waG90by5DMyJ9&_nc_ohc=dKrxeuM_VmYQ7kNvwEo0FB8&_nc_oc=AdpZiZy2SQP3v4-JJu9FSErEcSlvXMg2CqsqZvyYUJb1lwCUkIsSMutRqtcLOEwdSL4&_nc_ad=z-m&_nc_cid=0&_nc_zt=23&_nc_ht=instagram.fbcn2-1.fna&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&_nc_ss=7a3ba&oh=00_AQPsA_52nMLrWBqPl1VlpZnuEO7NYChm2t-3jGniIPV…"
        },
        {
          "config_height": 1080,
          "config_width": 1080,
          "src": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-15/562815025_18601398793054956_8673755740587648163_n.jpg?stp=c0.240.1440.1440a_dst-jpg_e35_s1080x1080_sh2.08_tt6&_nc_ht=instagram.fbcn2-1.fna.fbcdn.net&_nc_cat=100&_nc_oc=Q6cZ2gEaFKXOPgA5Eg4aKQo1nUcg7qmKTCvGzTkLrEYJYIfyPcxILDD3_ghOiaPzvblQI5k&_nc_ohc=4mUaYQcnSSEQ7kNvwFutxrO&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&edm=AOmX9WgBAAAA&ccb=7-5&ig_cache_key=Mzc0MjYzNzg3MTExMjAzMjEwMA%3D%3D.3.c-ccb7-5&oh=00_AQNabE0Chb6xAz5UFrPNywynrcbwHvBqi4e1s5OsFopqzg&oe=6ACAABEF&_nc_sid=bfaa47"
        }
      ],
      "display_url": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-15/562815025_18601398793054956_8673755740587648163_n.jpg?stp=c0.240.1440.1440a_dst-jpg_e35_s1080x1080_sh2.08_tt6&_nc_ht=instagram.fbcn2-1.fna.fbcdn.net&_nc_cat=100&_nc_oc=Q6cZ2gEaFKXOPgA5Eg4aKQo1nUcg7qmKTCvGzTkLrEYJYIfyPcxILDD3_ghOiaPzvblQI5k&_nc_ohc=4mUaYQcnSSEQ7kNvwFutxrO&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&edm=AOmX9WgBAAAA&ccb=7-5&ig_cache_key=Mzc0MjYzNzg3MTExMjAzMjEwMA%3D%3D.3.c-ccb7-5&oh=00_AQNabE0Chb6xAz5UFrPNywynrcbwHvBqi4e1s5OsFopqzg&oe=6ACAABEF&_nc_sid=bfaa47",
      "edge_media_preview_comment": {
        "count": 0,
        "edges": []
      },
      "edge_media_preview_like": {
        "count": 3860655,
        "edges": []
      },
      "edge_media_to_caption": {
        "edges": [
          {
            "node": {
              "created_at": "1760377224",
              "id": "18084316565493094",
              "text": "I’ll never forget how excited I was in 2006 when my first album sold 40,000 copies in its first week. I was 16 and couldn’t even fathom that that many people would care enough about my music to invest their time and energy into it. Since then I’ve tried to meet and thank as many people as I could who have given me the chance to chase this insane dream. Here we are all these years later and a hundred times that many people showed up for me this week. I have 4 million thank you’s I want to send to the fans, and 4 million reasons to feel even more proud of this album than I already was. Thank you…"
            }
          }
        ]
      },
      "edge_media_to_hoisted_comment": {
        "edges": []
      },
      "edge_media_to_parent_comment": {
        "count": 0,
        "edges": [],
        "page_info": {
          "end_cursor": null,
          "has_next_page": false
        }
      },
      "edge_media_to_sponsor_user": {
        "edges": []
      },
      "edge_media_to_tagged_user": {
        "edges": []
      },
      "edge_web_media_to_related_media": {
        "edges": []
      },
      "fact_check_information": null,
      "fact_check_overall_rating": null,
      "gating_info": null,
      "has_ranked_comments": false,
      "id": "3742637871112032100",
      "is_ad": false,
      "is_affiliate": false,
      "is_paid_partnership": false,
      "is_video": false,
      "like_and_view_counts_disabled": false,
      "location": null,
      "media_overlay_info": null,
      "media_preview": null,
      "nft_asset_info": null,
      "owner": {
        "blocked_by_viewer": false,
        "edge_followed_by": {
          "count": 0
        },
        "edge_owner_to_timeline_media": {
          "count": 0
        },
        "followed_by_viewer": false,
        "full_name": "Taylor Swift",
        "has_blocked_viewer": false,
        "id": "11830955",
        "is_embeds_disabled": false,
        "is_private": false,
        "is_unpublished": false,
        "is_verified": true,
        "pass_tiering_recommendation": true,
        "profile_pic_url": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-19/811102599_18700319776054956_6854910356429154091_n.jpg?stp=dst-jpg_e0_s150x150_tt6&efg=eyJ2ZW5jb2RlX3RhZyI6InByb2ZpbGVfcGljLmRqYW5nby4xMDgwLmMyIn0&_nc_ht=instagram.fbcn2-1.fna.fbcdn.net&_nc_cat=1&_nc_oc=Q6cZ2gEaFKXOPgA5Eg4aKQo1nUcg7qmKTCvGzTkLrEYJYIfyPcxILDD3_ghOiaPzvblQI5k&_nc_ohc=m4ZgsTRvAdEQ7kNvwEwKjhZ&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&edm=AOmX9WgBAAAA&ccb=7-5&oh=00_AQPAW_l6CLTnlO2n55nii5pdldOlpu9IQJ6Ze_afARPtaA&oe=6ACAAE3E&_nc_sid=bfaa47",
        "requested_by_viewer": false,
        "restricted_by_viewer": null,
        "username": "taylorswift"
      },
      "pinned_for_users": [],
      "sensitivity_friction_info": null,
      "sharing_friction_info": {
        "bloks_app_url": null,
        "should_have_sharing_friction": false
      },
      "shortcode": "DPwhVB-jo9k",
      "status": true,
      "taken_at_timestamp": 1760377223,
      "thumbnail_src": "https://instagram.fbcn2-1.fna.fbcdn.net/v/t51.82787-15/562815025_18601398793054956_8673755740587648163_n.jpg?stp=dst-jpg_e35_s480x480_sh2.08_tt6&_nc_cat=109&_nc_map=urlgen_bucketless&ig_cache_key=Mzc0MjYzNzg3MTExMjAzMjEwMA%3D%3D.3-ccb7-5&ccb=7-5&_nc_sid=58cdad&efg=eyJ2ZW5jb2RlX3RhZyI6IkZFRUQueHBpZHMuMTQ0MC5zZHIucmVndWxhcl9waG90by5DMyJ9&_nc_ohc=dKrxeuM_VmYQ7kNvwEo0FB8&_nc_oc=AdpZiZy2SQP3v4-JJu9FSErEcSlvXMg2CqsqZvyYUJb1lwCUkIsSMutRqtcLOEwdSL4&_nc_ad=z-m&_nc_cid=0&_nc_zt=23&_nc_ht=instagram.fbcn2-1.fna&_nc_gid=vZMGa7aUKQ1axN7MqUb4XQ&_nc_ss=7a3ba&oh=00_AQPTodbxxcJgq_qw8CoeJx1jSL546kKQBuex6av5218gs…",
      "tracking_token": "eyJ2ZXJzaW9uIjo1LCJwYXlsb2FkIjp7ImlzX2FuYWx5dGljc190cmFja2VkIjp0cnVlLCJ1dWlkIjoiZTUxMGY1MTgxYjdiNDg3MmE0ZDlkNGIyYTRiZmFlZDIzNzQyNjM3ODcxMTEyMDMyMTAwIn0sInNpZ25hdHVyZSI6IiJ9",
      "upcoming_event": null,
      "viewer_can_reshare": true,
      "viewer_has_liked": false,
      "viewer_has_saved": false,
      "viewer_has_saved_to_collection": false,
      "viewer_in_photo_of_you": false
    }
  }
]

示例

选择一个示例,将其输入和结果加载到 playground 中。

API README

Instagram Post Details by ID API

Returns metadata for a single Instagram post, including media type, image sizes, caption, like count, and owner details. It needs one input, the numeric post_id of the post.

Use cases

  • Fetch the caption and posting time of a known Instagram post for a content archive.
  • Download the image URLs at different sizes to show a post preview in your own app.
  • Read the like count and owner account of a post to track a public figure's content.
  • Check whether a post is a video, an ad, or a paid partnership before you include it in a report.

Request

curl -X POST "https://api.sandbase.ai/v1/api/instagram/v1/post-by-id" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"post_id": "3742637871112032100"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
post_idstringYesPost ID

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "__typename": "GraphImage",
  "accessibility_caption": null,
  "attempts": "0",
  "can_see_insights_as_brand": false,
  "caption_is_edited": false,
  "coauthor_producers": [],
  "commenting_disabled_for_viewer": true,
  "comments_disabled": false,
  "dimensions": {
    "height": 1080,
    "width": 1080
  },
  "display_resources": [
    {
      "config_height": 640,
      "config_width": 480,
      "src": "https://scontent-mad1-1.cdninstagram.com/v/t39.30808-6/735018292_186723389410549…"
    }
  ],
  "display_url": "https://scontent-mad1-1.cdninstagram.com/v/t51.82787-15/562815025_18601398793054…",
  "edge_media_preview_comment": {
    "count": 0,
    "edges": []
  }
}

Response fields

FieldMeaning
id / shortcodeThe numeric post ID and the short code used in Instagram post URLs.
__typename / is_videoThe media type of the post (here GraphImage) and a flag that shows whether it is a video.
taken_at_timestampWhen the post was taken, as a Unix timestamp in seconds.
edge_media_to_caption.edges[].node.textThe caption text of the post. The node also has created_at and an id for the caption.
edge_media_preview_like.countThe number of likes on the post.
edge_media_to_parent_comment.countThe number of top-level comments. page_info.has_next_page and page_info.end_cursor in the same object show whether more comments exist.
display_urlThe URL of the main image of the post.
display_resources[].srcThe URL of one image rendition. config_width and config_height give its size.
dimensions.width / dimensions.heightThe size of the original media in pixels.
owner.username / owner.full_name / owner.idThe username, display name, and numeric ID of the account that published the post.
owner.is_verifiedShows whether the owner account is verified.
is_ad / is_paid_partnership / comments_disabledFlags that show whether the post is an ad, a paid partnership, or has comments turned off.

Notes

  • Use the id value from the response as post_id. The ID is a long numeric string, so send it as a string.
  • If you only have a post URL, call Instagram Post Details by URL instead.
  • To convert between the shortcode and the numeric ID, use Instagram Shortcode to Media ID.
  • In this example, owner.edge_followed_by.count is 0, so use a user profile API for follower numbers.

Pricing

$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

探索更多

相关 APIs

全部 APIs
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

问题

常见问题

如何使用 Instagram Post Details by ID API?

向 https://api.sandbase.ai/v1/api/instagram/v1/post-by-id 发送 POST 请求,在 Authorization 请求头中使用您的 SandBase API key(Bearer),并将参数作为 JSON 请求体传入。您也可以直接在本页的 Playground 中试用,无需编写代码。

Instagram Post Details by ID API 的价格是多少?

每次调用 $0.001,从您的 SandBase 余额中扣费。您只需为实际调用付费;无需订阅。

Instagram Post Details by ID API 接受哪些参数?

必填:post_id (string)。 Parameters 表和本页的 Playground 列出了每个字段。

Instagram Post Details by ID API 返回什么?

在同一个 HTTP 请求中返回的 JSON 响应(同步)。 本页的 README 包含一个示例响应。

我需要 Instagram 开发者账户或 API key 吗?

不需要。Instagram Post Details by ID 通过 SandBase 运行,因此一个 SandBase API key 即可覆盖此端点以及目录中的其他所有 API 和模型。您无需单独申请 Instagram API 访问权限。