Authentication

Obtain a new access token

Obtain a new access token

post/oauth/token

Request

  • Base URL
    https://account-name.talkdeskid.com
  • URL
    https://account-name.talkdeskid.com/oauth/token
  • Auth
    none declared

Headers

Authorizationstring

Authorization header containing the client authentication, supported via HTTP Basic Auth with the client’s client_id and client_secret. Required if not using a signed JWT assertion (as per the "private_key_jwt" mechanism of OpenID Connect)

Request body application/x-www-form-urlencoded

grant_type'client_credentials' | 'authorization_code' | 'refresh_token' required

The grant type used for authentication

codestring

Authorization code received from the "/oauth/authorize" request in the redirect URI. Required only when using "authorization_code" grant type

redirect_uristring

Redirect URI included in the "/oauth/authorize" request. Optional, used when grant type is "authorization_code"

refresh_tokenstring

Refresh token previously issued in the authorization code flow. Required only when using "refresh_token" grant type

token_type'opaque'

Defaults to jwt. Required only for Service Tokens emission.

expires_ininteger

Lifetime of the requested token, expressed in seconds. Optional, and only applicable when requesting service tokens. Min: 1 day (86400 seconds). Max: 1 year (31556952 seconds)

scopestring

A space-separated list of scopes (URL encoded) the client is requesting access to. Optional, used only when requesting with "client_credentials" and "refresh_token" grant types. Whenever a new access token is being issued using "refresh_token" grant type, the requested scope must not include additional scopes that were not issued in the original access token and, if omitted, the new access token will be issued with the same scope as was previously issued

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

The type of signed JWT assertion (it must be "urn:ietf:params:oauth:client-assertion-type:jwt-bearer"). Required if not using HTTP Basic Auth in the Authorization header

client_assertionstring

Signed JWT assertion (as per the "private_key_jwt" mechanism of OpenID Connect). Required if not using HTTP Basic Auth in the Authorization header

Response

The access token (and optional refresh token) generated, along with some additional properties about the authorization

access_tokenstring required

The access token

token_typestring required

The type of token to be specified in the Authorization header

expires_ininteger required

Duration of time (seconds) the access token is granted for

scopestring required

A space-separated list of scopes (URL encoded) the client requested access to. If "scope" parameter was not provided in the request body parameter, the returned value will be the list of scopes the client granted

refresh_tokenstring

The refresh token used to obtain another access token. Required only when using "authorization_code" and "refresh_token" grant types

sidstring

The session ID of the user authenticated during the authorization code flow. Required only when using "authorization_code" and "refresh_token" grant types

id_tokenstring

The ID token (OpenID Connect functionality to return information about the authentication performed during the authorization code flow). Required only when using "authorization_code" grant type and if "openid" scope was included in the "scope" parameter provided in the "/oauth/authorize" request query parameter

Changes

No recorded changes to this operation across all 1 revision of this API.