Skip to main content

获取或刷新token

POST 

/auth/v1/token

错误处理:invalid_grant refresh token 不正确或已过期 (退出) internal:系统错误,请请稍后重试 unauthorized_client 客户端秘钥不正确 unsupported_grant_type grant_type 不支持 invalid_scope scope 不支持 invalid_argument:参数错误或用户输入的信息不正确。 invalid_client 客户端不存在 permission_denied 客户端不存在或权限不足 resource_exhausted 用户请求超过频次限制

Request

Body

required
    grant_type string
    code grant_type 为 authorization_code 时使用 (string)
    refresh_token refresh_token 刷新token时, 使用 (string)
    username grant_type 为 password时使用 (string)
    password grant_type 为 password时使用 (string)
    scope scope,可选 (string)
    nonce 随机字符串, 可选 (string)
    code_verifier PKCE: code_verifier (string)
    device_code Device Code Flow https://tools.ietf.org/html/rfc8628 (string)

Responses

A successful response.

Schema
    token_type string
    access_token string
    refresh_token string
    id_token string
    expires_in int32
    scope string
    sub string
    groups string[]
    need_weda_resource boolean
Loading...