Join us on May 20th for the Content + AI Virtual Summit. Register now
curl -i -X POST "https://api.box.com/oauth2/token" \
-H "content-type: application/x-www-form-urlencoded" \
-d "client_id=[CLIENT_ID]" \
-d "client_secret=[CLIENT_SECRET]" \
-d "refresh_token=[REFRESH_TOKEN]" \
-d "grant_type=refresh_token"{
"access_token": "c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ",
"expires_in": 3600,
"token_type": "bearer",
"restricted_to": [
{
"scope": "item_download",
"object": {
"id": "12345",
"type": "folder",
"etag": "1",
"sequence_id": "3",
"name": "Contracts"
}
}
],
"refresh_token": "c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ",
"issued_token_type": "urn:ietf:params:oauth:token-type:access_token"
}Refresh an Access Token using its client ID, secret, and refresh token.
curl -i -X POST "https://api.box.com/oauth2/token" \
-H "content-type: application/x-www-form-urlencoded" \
-d "client_id=[CLIENT_ID]" \
-d "client_secret=[CLIENT_SECRET]" \
-d "refresh_token=[REFRESH_TOKEN]" \
-d "grant_type=refresh_token"{
"access_token": "c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ",
"expires_in": 3600,
"token_type": "bearer",
"restricted_to": [
{
"scope": "item_download",
"object": {
"id": "12345",
"type": "folder",
"etag": "1",
"sequence_id": "3",
"name": "Contracts"
}
}
],
"refresh_token": "c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ",
"issued_token_type": "urn:ietf:params:oauth:token-type:access_token"
}Documentation Index
Fetch the complete documentation index at: https://developer.box.com/llms.txt
Use this file to discover all available pages before exploring further.
A request to refresh an Access Token. Use this API to refresh an expired Access Token using a valid Refresh Token.
The type of request being made, in this case a refresh request.
refresh_token "refresh_token"
The client ID of the application requesting to refresh the token.
"ly1nj6n11vionaie65emwzk575hnnmrk"
The client secret of the application requesting to refresh the token.
"hOzsTeFlT6ko0dme22uGbQal04SBPYc1"
The refresh token to refresh.
"c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ"
Returns a new Access Token that can be used to make authenticated API calls by passing along the token in a authorization header as follows Authorization: Bearer <Token>.
A token that can be used to make authenticated API calls.
The requested access token.
"c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ"
The time in seconds by which this token will expire.
3600
The type of access token returned.
bearer "bearer"
The permissions that this access token permits, providing a list of resources (files, folders, etc) and the scopes permitted for each of those resources.
Show child attributes
The refresh token for this access token, which can be used to request a new access token when the current one expires.
"c3FIOG9vSGV4VHo4QzAyg5T1JvNnJoZ3ExaVNyQWw6WjRsanRKZG5lQk9qUE1BVQ"
The type of downscoped access token returned. This is only returned if an access token has been downscoped.
urn:ietf:params:oauth:token-type:access_token "urn:ietf:params:oauth:token-type:access_token"
Was this page helpful?