Skip to main content
POST
/
partner-sdk
/
token
/
bot
cURL
curl --request POST \
  --url https://discord.com/api/v10/partner-sdk/token/bot \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "external_user_id": "<string>",
  "preferred_global_name": "<string>"
}
'
{
  "token_type": "<string>",
  "access_token": "<string>",
  "expires_in": 123,
  "scope": "<string>",
  "id_token": "<string>",
  "refresh_token": "<string>",
  "scopes": [
    "<string>"
  ],
  "expires_at_s": 123
}

Authorizations

Authorization
string
header
required

Discord bot token

Body

application/json
external_user_id
string
required
Maximum string length: 1024
preferred_global_name
string | null
Required string length: 1 - 32

Response

200 response for bot_partner_sdk_token

token_type
string
required
access_token
string
required
expires_in
integer<int32>
required
scope
string
required
id_token
string
required
refresh_token
string | null
scopes
string[] | null
expires_at_s
integer<int32> | null