All Products
Search
Document Center

:GetOAuthAuthorizationSession

Last Updated:Jul 30, 2026

Queries the current status and authorization result of an OAuth authorization session.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request syntax

POST /v2/{instanceId}/oauthAuthorizationSessions/_/actions/get HTTP/1.1

Path Parameters

Parameter

Type

Required

Description

Example

instanceId

string

Yes

The instance ID.

idaas_ue2jvisn35ea5lmthk267xxxxx

Request parameters

Parameter

Type

Required

Description

Example

Authorization

string

Yes

The authentication information. Format: Bearer ${access_token}.

Note

Enter the Access Token issued by IDaaS.

Bearer xxxxxx

body

object

No

The request body.

sessionUri

string

Yes

The authorization session URI.

Note

Returned by the FetchOAuthAuthenticationToken call.

urn:ietf:params:oauth:request_uri:atpoas_01l6ljnvrpc5niakl3gj3amxxxxxx

Response elements

Element

Type

Description

Example

object

The OAuth authorization session details.

instanceId

string

The instance ID.

idaas_ue2jvisn35ea5lmthk267xxxxx

sessionId

string

The authorization session ID.

atpoas_01l6losojlojbbv01adsq56xxxxx

sessionUri

string

The authorization session URI.

urn:ietf:params:oauth:request_uri:atpoas_01l6ljnvrpc5niakl3gj3amxxxxxx

sessionStatus

string

The authorization session status.

Valid values:

  • expired :

    expired

  • pending :

    pending

  • completed :

    completed

  • failed :

    failed

  • callback_received :

    callback_received

pending

credentialProviderIdentifier

string

The credential provider business identifier.

test_example_identifier

consumerType

string

The authentication token consumer type.

Valid values:

  • application :

    application

  • custom :

    custom

application

consumerId

string

The authentication token consumer ID.

app_ngtkgrrxxxxktg5eao6z4xxxxx

creatorType

string

The authentication token creator type.

Valid values:

  • application :

    application

application

creatorId

string

The authentication token creator ID.

app_ngtkgrrxxxxktg5eao6z4xxxxx

authorizationUrl

string

The user authorization URL.

https://login.dingtalk.com/oauth2/auth?client_id=...

expirationTime

integer

The authentication token expiration time. UNIX timestamp in milliseconds.

1704153600000

authenticationTokenId

string

The authentication token ID.

atntkn_01l6lot7o4e4r77oelp6qtuxxxxx

errorCode

string

The error code.

access_denied

errorDescription

string

The error description.

The user denied the authorization request

Examples

Success response

JSON format

{
  "instanceId": "idaas_ue2jvisn35ea5lmthk267xxxxx",
  "sessionId": "atpoas_01l6losojlojbbv01adsq56xxxxx",
  "sessionUri": "urn:ietf:params:oauth:request_uri:atpoas_01l6ljnvrpc5niakl3gj3amxxxxxx",
  "sessionStatus": "pending",
  "credentialProviderIdentifier": "test_example_identifier",
  "consumerType": "application",
  "consumerId": "app_ngtkgrrxxxxktg5eao6z4xxxxx\n",
  "creatorType": "application",
  "creatorId": "app_ngtkgrrxxxxktg5eao6z4xxxxx",
  "authorizationUrl": "https://login.dingtalk.com/oauth2/auth?client_id=...",
  "expirationTime": 1704153600000,
  "authenticationTokenId": "atntkn_01l6lot7o4e4r77oelp6qtuxxxxx",
  "errorCode": "access_denied",
  "errorDescription": "The user denied the authorization request"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.