トークンを交換
POST
/oauth/token
authorization_code と refresh_token の両方に対応します。authorization_code では client_id が必須です。refresh_token では client_id は任意ですが、指定する場合はそのリフレッシュトークンに紐づくクライアントと一致している必要があります。
リクエストボディ
application/x-www-form-urlencoded
grant_type
string
必須
有効な値
"authorization_code""refresh_token"client_id
string
Required for authorization_code. Optional for refresh_token; if provided, it must match the client bound to the refresh token.
フォーマット
"uuid"code
string
Required when grant_type=authorization_code.
redirect_uri
string
Required when grant_type=authorization_code. Must exactly match the application's registered redirect URI.
フォーマット
"uri"code_verifier
string
Required when grant_type=authorization_code.
refresh_token
string
Required when grant_type=refresh_token.
レスポンス
OAuth tokens
application/json
{
}
