This endpoint allows you to exchange short-lived Instagram User Access Tokens for long-lived Instagram User Access Tokens.
This operation is not supported.
GET /access_token
Exchange a short-lived Instagram User Access Token for a long-lived Instagram User Access Token.
Requests for long-lived tokens include your app secret so should only be made in server-side code, never in client-side code or in an app binary that could be decompiled. Do not share your app secret with anyone, expose it in code, send it to a client, or store it in a device.
Type | Requirement |
---|---|
GET https://graph.instagram.com/access_token ?grant_type=ig_exchange_token &client_secret={instagram-app-secret} &access_token={short-lived-access-token}
Include the following query string parameters to augment the request.
Key | Value |
---|---|
| Your Instagram app's secret, displayed in the App Dashboard > Products > Instagram > Basic Display > Instagram App Secret field. |
| Set this to |
| The valid (unexpired) short-lived Instagram User Access Token that you want to exchange for a long-lived token. |
A JSON-formatted object containing the following properties and values.
{ "access_token": "{access-token}", "token_type": "{token-type}", "expires_in": {expires-in} }
Response Contents
Value Placeholder | Value |
---|---|
| A long-lived Instagram User Access Token. |
|
|
| The number of seconds until the long-lived token expires. |
curl -X GET \ 'https://graph.instagram.com/access_token?grant_type=ig_exchange_token&&client_secret=eb87G...&access_token=IGQVJ...'
{ "access_token": "lZAfb2dhVW...", "token_type": "bearer", "expires_in": 5183944 }
This operation is not supported.
This operation is not supported.