Instagram 用戶

代表 Instagram 商業帳戶Instagram 創作者帳戶

在整個文件中,我們會交替使用「Instagram 用戶」和「Instagram 帳戶」,兩者均代表您應用程式用戶的 Instagram 專業帳戶。

Requirements

Instagram API with Instagram LoginInstagram API with Facebook Login

Access Tokens

  • Instagram User user access token

Host URL

graph.instagram.com

graph.facebook.com

Login Type

Business Login for Instagram

Facebook Login for Business

Permissions
  • instagram_business_basic
  • instagram_basic
  • pages_read_engagement

If the app user was granted a role via the Business Manager on the Page connected to the targeted IG User, you will also need one of:

  • ads_management
  • ads_read

If you are requesting the shopping_product_tag_eligibility field for product tagging, you will also need:

  • catalog_management
  • instagram_shopping_tag_products

Business Roles

Not applicable.

If you are requesting the shopping_product_tag_eligibility field for product tagging, the app user must have an admin role on the Business Manager that owns the IG User's Instagram Shop.

Instagram Shop

Not applicable.

If you are requesting the shopping_product_tag_eligibility field for product tagging, the IG User must have an approved Instagram Shop with a product catalog containing products.

建立

不支援這項操作。

讀取

GET /<IG_USER_ID>

獲取 Instagram 商業帳戶或創作者帳戶的欄位和關係連線。

If you are migrating from Marketing API Instagram Ads endpoints to Instagram Platform endpoints, be aware that some field names are different.

要求語法

GET https://graph.facebook.com/<API_VERSION>/<IG_USER_ID>
  ?fields=<LIST_OF_FIELDS>
  &access_token=<ACCESS_TOKEN>

路徑參數

預留位置

<API_VERSION>

API 版本

<IG_USER_ID>

此為必要項目。Instagram 用戶編號。

查詢字串參數

鍵值預留位置

access_token

<ACCESS_TOKEN>

此為必要項目。應用程式用戶的用戶存取憑證。

fields

<LIST_OF_FIELDS>

您希望系統傳回的 Instagram 用戶欄位逗號分隔清單,當中列有結果組合中每個 Instagram 用戶的欄位。

欄位

公開欄位可由關係連線使用欄位擴充傳回。存取由專頁支援的 Instagram 帳戶時,只有部分欄位可供使用。

欄位名稱說明

alt_text
公開

圖像說明文字,用於提升無障礙體驗。

biography
公開

個人檔案的個人簡介文字。

followers_count
公開

追蹤特定用戶的 Instagram 用戶總數。

follows_count

特定用戶追蹤的 Instagram 用戶總數。

has_profile_pic

表示您應用程式用戶的 Instagram 專業帳戶是否有大頭貼。

id
公開

應用程式範圍用戶編號。適用於由專頁支援的 Instagram 帳戶。

is_published

表示您應用程式用戶的 Instagram 帳戶是否已發佈。適用於由專頁支援的 Instagram 帳戶。

legacy_instagram_user_id

為 v21.0 及以下版本的推廣 API 端點建立的應用程式用戶之 Instagram 編號。適用於由專頁支援的 Instagram 帳戶。

media_count
公開

您應用程式用戶的 Instagram 帳戶所發佈的媒體總數。

name

您應用程式用戶的 Instagram 個人檔案名稱。

profile_picture_url

您應用程式用戶的 Instagram 大頭貼網址。

collaborative_media_search

依編號查找特定協作影音內容。透過欄位擴充存取。僅適用於設有 Facebook 登入功能的 Instagram API。

shopping_product_tag_eligibility

如果應用程式用戶已開設 Instagram 商店並因此符合商品標籤資格,則會傳回 true,否則傳回 false

username
公開

您應用程式用戶的 Instagram 個人檔案用戶名稱。

website
公開

您應用程式用戶的網站網址。

關係連線

關係連線說明

agencies

可為此 Instagram 專業帳戶刊登廣告的企業清單。

authorized_adaccounts

可為此 Instagram 專業帳戶刊登廣告的廣告帳戶。

business_discovery

獲取關於其他 Instagram 商業或 Instagram 創作者 Instagram 用戶的數據。

connected_threads_user

代表與 Instagram 帳戶連結的 Threads 帳戶。

content_publishing_limit

代表 Instagram 用戶目前的內容發佈功能使用情況。

insights

代表 Instagram 用戶的社交互動衡量數據。

instagram_backed_threads_user

代表受 Instagram 帳戶支援的 Threads 帳戶。

live_media

代表 Instagram 用戶上的一系列直播視像 Instagram 媒體

media

代表特定 Instagram 用戶上的一系列 Instagram 媒體

media_publish

在 Instagram Business 的 Instagram 用戶上發佈 Instagram 容器

mentions

在特定 Instagram 用戶被另一名 Instagram 用戶以 @ 提及的 Instagram 留言或附有說明文字的 Instagram 媒體上,建立 Instagram 留言

mentioned_comment

獲取特定 Instagram 留言的數據,而這個留言建立在特定 Instagram 用戶被另一位 Instagram 用戶以 @提及的內容之上。

mentioned_media

獲取特定 Instagram 媒體的數據,而這個媒體建立在特定 Instagram 用戶被另一位 Instagram 用戶以 @提及的說明文字之上。

recently_searched_hashtags

獲取特定 Instagram 用戶過去 7 天內搜尋過的 Instagram 主題標籤

stories

代表特定 Instagram 用戶上的一系列限時動態 Instagram 媒體物件。

tags

代表一系列特定 Instagram 媒體,而此類媒體建立在特定 Instagram 用戶被另一位 Instagram 用戶標註的內容以上。

upcoming_events

此 Instagram 專業帳戶主辦的活動清單。

collaboration_invites

代表 Instagram 用戶獲邀展開協作的 IG Media 物件屬性(media_id、media_owner_username、caption、media_url)集合。

collaborative_media

代表一系列 Instagram 影音內容,而 Instagram 用戶為獲接受的協作者。不包括用戶直接擁有的影音內容。僅適用於設有 Facebook 登入功能的 Instagram API。

回應

JSON 格式的物件包含預設和要求獲取的欄位關係連線

{
  "<FIELD>":"<VALUE>",
  ...
}

cURL 範例

要求

curl -X GET \
  'https://graph.facebook.com/v26.0/17841405822304914?fields=biography%2Cid%2Cusername%2Cwebsite&access_token=EAACwX...'

回應

{
  "biography": "Dino data crunching app",
  "id": "17841405822304914",
  "username": "metricsaurus",
  "website": "http://www.metricsaurus.com/"
}

更新

不支援這項操作。

刪除

不支援這項操作。