全部產品
Search
文件中心

Identity as a Service:GenerateTokenByAuthorizationServer - 通過執行個體級授權伺服器產生應用認證 token

更新時間:Mar 17, 2026

執行個體級授權伺服器 Token 端點

調試

您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。

調試

授權資訊

當前API暫無授權資訊透出。

請求文法

POST /v2/{instanceId}/authorizationServer/{authorizationServerId}/oauth2/token HTTP/1.1

路徑參數

名稱

類型

必填

描述

樣本值

instanceId

string

執行個體 ID。

idaas_ue2jvisn35ea5lmthk267xxxxx

authorizationServerId

string

授權伺服器 ID。

iauths_system

請求參數

名稱

類型

必填

描述

樣本值

grant_type

string

授與類型。

authorization_code

client_id

string

用戶端識別碼。

app_mkv7rgt4d7i4u7zqtzev2mxxxx

code

string

授權 code 碼,傳入情境: grant_type=authorization_code 授權碼模式時,必填參數。

CO541xY59EsKniV2wvWDXZ4jiKxxxxx

username

string

使用者名稱。

userxxxxx

password

string

使用者密碼。

testxxxxx

device_code

string

裝置 code 碼,傳入情境: grant_type=urn:ietf:params:oauth:grant-type:device_code 即裝置流模式時,必填參數。

DCxxxxxx

redirect_uri

string

重新導向 URI,傳入情境: grant_type=authorization_code 授權碼模式時,必須參數,與擷取授權碼請求中的重新導向 URI 必須是一致的。

https://example.com/xxxxx

refresh_token

string

重新整理憑證。

RTxxxxx

scope

string

scope 範圍。

openid

code_verifier

string

驗證 code。

xxxxx

client_assertion

string

用戶端斷言。

eyJraWQiOiJLRVlLZ0Iyxxxxx

client_assertion_type

string

用戶端斷言的類型。

urn:ietf:params:oauth:client-assertion-type:jwt-bearer

application_federated_credential_name

string

應用聯邦憑證名稱。

testxxxxx

client_x509

string

終端認證。

testxxxxx

client_x509_chain

string

中間認證列表。

testxxxxx

client_secret

string

用戶端密鑰。

CSEHDcHcrUKHw1CuxkJEHPveWRxxxxx

返回參數

名稱

類型

描述

樣本值

object

token 資訊

token_type

string

憑證類型。

Bearer

access_token

string

訪問憑證。

eyJraWQiOiJLRVlLZ0Iyxxxxx

refresh_token

string

重新整理憑證。

ATxxxxx

expires_in

integer

訪問憑證的有效時間長度,單位為秒。

1200

expires_at

integer

訪問憑證的失效時間,格式為 Unix 時間戳記,單位為秒。

1653288641

id_token

string

身份憑證。

eyJraWQiOiJLRVlLZ0Iyxxxxx

scope

string

scope 範圍。

openid

樣本

正常返回樣本

JSON格式

{
  "token_type": "Bearer",
  "access_token": "eyJraWQiOiJLRVlLZ0Iyxxxxx\n",
  "refresh_token": "ATxxxxx",
  "expires_in": 1200,
  "expires_at": 1653288641,
  "id_token": "eyJraWQiOiJLRVlLZ0Iyxxxxx\n",
  "scope": "openid"
}

錯誤碼

訪問錯誤中心查看更多錯誤碼。

變更歷史

更多資訊,參考變更詳情