Skip to main content
POST
Exchange an authorization code for a bot token

Authorizations

Authorization
string
header
required

The App's client_id and client_secret, for the OAuth endpoints

Body

Code exchange

An authorization-code exchange. Send client_id and client_secret here or as HTTP Basic credentials.

code
string
required

The code from the consent redirect

grant_type
enum<string>
required
Available options:
authorization_code
redirect_uri
string<uri>
required

The redirect_uri of the authorization request, exactly

client_id
string
client_secret
string

Response

The bot token

A non-expiring bot token for the installation.

access_token
string
required

wc_bot_live_… or wc_bot_test_…

bot_user_id
string
required

The bot's user id, usr_ prefixed

scope
string
required

Granted scopes, space-separated

token_type
enum<string>
required
Available options:
Bearer
workspace
object
required