Skip to main content

authorization_servers

Creates, updates, deletes, gets or lists an authorization_servers resource.

Overview​

Nameauthorization_servers
TypeResource
Idokta.authorizationservers.authorization_servers

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringThe ID of the custom authorization server
namestringThe name of the custom authorization server
_linksobjectSpecifies link relations (see Web Linking) available using the JSON Hypertext Application Language specification. This object is used for dynamic discovery of related resources and lifecycle operations.
accessTokenEncryptedResponseAlgorithmstringThe algorithm for encrypting access tokens issued by this authorization server. If this is requested, the response is signed, and then encrypted. The result is a nested JWT. The default, if omitted, is that no encryption is performed. (RSA-OAEP-256, RSA-OAEP-384, RSA-OAEP-512)
audiencesarrayThe recipients that the tokens are intended for. This becomes the aud claim in an access token. Okta currently supports only one audience.
createdstring (date-time)
credentialsobject
descriptionstringThe description of the custom authorization server
issuerstringThe complete URL for the custom authorization server. This becomes the iss claim in an access token.
issuerModestringIndicates which value is specified in the issuer of the tokens that a custom authorization server returns: the Okta org domain URL or a custom domain URL. issuerMode is visible if you have a custom URL domain configured or the Dynamic Issuer Mode feature enabled. If you have a custom URL domain configured, you can set a custom domain URL in a custom authorization server, and this property is returned in the appropriate responses. When set to ORG_URL, then in responses, issuer is the Okta org domain URL: https://${yourOktaDomain}. When set to CUSTOM_URL, then in responses, issuer is the custom domain URL configured in the administration user interface. When set to DYNAMIC, then in responses, issuer is the custom domain URL if the OAuth 2.0 request was sent to the custom domain, or is the Okta org's domain URL if the OAuth 2.0 request was sent to the original Okta org domain. After you configure a custom URL domain, all new custom authorization servers use CUSTOM_URL by default. If the Dynamic Issuer Mode feature is enabled, then all new custom authorization servers use DYNAMIC by default. All existing custom authorization servers continue to use the original value until they're changed using the Admin Console or the API. This way, existing integrations with the client and resource server continue to work after the feature is enabled.
jwksobjectA JSON Web Key Set for encrypting JWTs minted by the custom authorization server
jwks_uristringURL string that references a JSON Web Key Set for encrypting JWTs minted by the custom authorization server
lastUpdatedstring (date-time)
statusstring (ACTIVE, INACTIVE)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_authorization_serverselectauthServerId, subdomainRetrieves an authorization server
list_authorization_serversselectsubdomainq, limit, afterLists all custom authorization servers in the org
create_authorization_serverinsertsubdomainCreates an authorization server
replace_authorization_serverreplaceauthServerId, subdomainReplaces an authorization server
delete_authorization_serverdeleteauthServerId, subdomainDeletes an authorization server
activate_authorization_serverexecauthServerId, subdomainActivates an authorization server
deactivate_authorization_serverexecauthServerId, subdomainDeactivates an authorization server

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
authServerIdstringid of the Authorization Server
subdomainstring(default: my-org)
afterstringSpecifies the pagination cursor for the next page of authorization servers. Treat as an opaque value and obtain through the next link relationship.
limitinteger (int32)Specifies the number of authorization server results on a page. Maximum value: 200
qstringSearches the name and audiences of authorization servers for matching values (example: customasone)

SELECT examples​

Retrieves an authorization server

SELECT
id,
name,
_links,
accessTokenEncryptedResponseAlgorithm,
audiences,
created,
credentials,
description,
issuer,
issuerMode,
jwks,
jwks_uri,
lastUpdated,
status
FROM okta.authorizationservers.authorization_servers
WHERE authServerId = '{{ authServerId }}' -- required
AND subdomain = '{{ subdomain }}' -- required
;

INSERT examples​

Creates an authorization server

INSERT INTO okta.authorizationservers.authorization_servers (
accessTokenEncryptedResponseAlgorithm,
audiences,
credentials,
description,
issuer,
issuerMode,
jwks,
jwks_uri,
name,
status,
subdomain
)
SELECT
'{{ accessTokenEncryptedResponseAlgorithm }}',
'{{ audiences }}',
'{{ credentials }}',
'{{ description }}',
'{{ issuer }}',
'{{ issuerMode }}',
'{{ jwks }}',
'{{ jwks_uri }}',
'{{ name }}',
'{{ status }}',
'{{ subdomain }}'
RETURNING
id,
name,
_links,
accessTokenEncryptedResponseAlgorithm,
audiences,
created,
credentials,
description,
issuer,
issuerMode,
jwks,
jwks_uri,
lastUpdated,
status
;

REPLACE examples​

Replaces an authorization server

REPLACE okta.authorizationservers.authorization_servers
SET
accessTokenEncryptedResponseAlgorithm = '{{ accessTokenEncryptedResponseAlgorithm }}',
audiences = '{{ audiences }}',
credentials = '{{ credentials }}',
description = '{{ description }}',
issuer = '{{ issuer }}',
issuerMode = '{{ issuerMode }}',
jwks = '{{ jwks }}',
jwks_uri = '{{ jwks_uri }}',
name = '{{ name }}',
status = '{{ status }}'
WHERE
authServerId = '{{ authServerId }}' --required
AND subdomain = '{{ subdomain }}' --required
RETURNING
id,
name,
_links,
accessTokenEncryptedResponseAlgorithm,
audiences,
created,
credentials,
description,
issuer,
issuerMode,
jwks,
jwks_uri,
lastUpdated,
status;

DELETE examples​

Deletes an authorization server

DELETE FROM okta.authorizationservers.authorization_servers
WHERE authServerId = '{{ authServerId }}' --required
AND subdomain = '{{ subdomain }}' --required
;

Lifecycle Methods​

Activates an authorization server

EXEC okta.authorizationservers.authorization_servers.activate_authorization_server
@authServerId='{{ authServerId }}' --required,
@subdomain='{{ subdomain }}' --required
;