【发布时间】:2021-07-16 03:38:11
【问题描述】:
我正在尝试根据从先前对 instagram 的请求收到的短期令牌执行基本的获取请求。我知道短期访问令牌是有效的。 我正在测试的帐户是测试用户,并且该应用程序在 facebooks 端处于开发模式。此外,应用程序审查目前正在等待中,但我认为这不是问题,因为我正在测试的帐户是一个测试帐户,并且再次 - 登录功能设置为开发模式。
当我根据文档提出请求时:
https://developers.facebook.com/docs/instagram-basic-display-api/guides/long-lived-access-tokens/
我收到以下状态码为 400 的响应:
抱歉,此内容目前不可用
基于此请求格式:
https://graph.instagram.com/access_token
?grant_type=ig_exchange_token
&client_secret={instagram-app-secret}
&access_token={short-lived-access-token}
以下是完整回复:
HTTP/1.1 400 Bad Request
X-Frame-Options: DENY
X-Content-Type-Options: nosniff
X-XSS-Protection: 0
Vary: Origin
Content-Type: application/json; charset=UTF-8
WWW-Authenticate: OAuth "Facebook Platform" "invalid_token" "Invalid OAuth access token."
Access-Control-Allow-Origin: *
Strict-Transport-Security: max-age=15552000
Pragma: no-cache
Cache-Control: no-store
Expires: Sat, 01 Jan 2000 00:00:00 GMT
x-fb-request-id: Al1knRjoI2Qw1XEVlh4b3Ku
x-fb-trace-id: GasPh1zh4bl
x-fb-rev: 1004118369
X-FB-Debug: 73PsZ2YPe6C2obr8nIdox2r2YOtNoVsuva4y2rRLvd70l06oV8kfdjOzLRhPvLDvpsmc1+5gP42Hc4Pi4AUHLw==
Date: Fri, 16 Jul 2021 04:19:09 GMT
X-FB-TRIP-ID: 1512268381
Connection: keep-alive
Content-Length: 45
Sorry, this content isn't available right now
【问题讨论】:
标签: instagram instagram-api instagram-graph-api