コンテンツにスキップ

Exchange a pre-authorized code for a credential access token.

POST
/vci/token
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/vci/token \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data grant_type=urn:ietf:params:oauth:grant-type:pre-authorized_code \
--data pre-authorized_code=g1:apac:3:co_550e8400-e29b-41d4-a716-446655440000:secret \
--data tx_code=123456
Media type application/x-www-form-urlencoded
object
grant_type
required
string
Allowed values: urn:ietf:params:oauth:grant-type:pre-authorized_code
pre-authorized_code
required
string
Example
g1:apac:3:co_550e8400-e29b-41d4-a716-446655440000:secret
tx_code
string
Example
123456

VCI token response.

Media type application/json
object
access_token
required
string
token_type
required
string
Allowed values: Bearer
expires_in
required
integer
c_nonce
required
string
c_nonce_expires_in
required
integer
authorization_details
required
Array<object>
object
type
required
string
credential_configuration_id
required
string
Example
{
"access_token": "eyJhbGciOiJFUzI1NiIsInR5cCI6IkpXVCJ9...",
"token_type": "Bearer",
"expires_in": 3600,
"c_nonce": "nonce_1234567890",
"c_nonce_expires_in": 300,
"authorization_details": [
{
"type": "openid_credential",
"credential_configuration_id": "AuthrimIdentityCredential"
}
]
}

Error response.

Media type application/json
object
error
required
string
error_description
required
string
Example
{
"error": "invalid_request",
"error_description": "The request is invalid."
}

Error response.

Media type application/json
object
error
required
string
error_description
required
string
Example
{
"error": "invalid_request",
"error_description": "The request is invalid."
}