POST
/
oauth-providers
/
{provider_id}
/
client-types
Create a new client type of an OAuth2.0 Identity Provider
curl --request POST \
  --url http://localhost:3001/portal-api/oauth-providers/{provider_id}/client-types \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '{
  "Name": "Server-side application",
  "Description": "Use this client configuration to create server-side applications that don'\''t act on behalf of end-users",
  "ResponseTypes": "code,token",
  "GrantType": "authorization_code,refresh_token,password",
  "TokenEndpointAuthMethod": "client_secret_basic",
  "OktaAppType": "web"
}'
{
  "Name": "Server-side application",
  "Description": "Use this client configuration to create server-side applications that don't act on behalf of end-users",
  "ResponseTypes": "code,token",
  "GrantType": "authorization_code,refresh_token,password",
  "TokenEndpointAuthMethod": "client_secret_basic",
  "OktaAppType": "web",
  "ID": 1,
  "CreatedAt": "2023-06-25 13:37",
  "UpdatedAt": "2023-06-25 13:37"
}

Authorizations

Authorization
string
header
required

Path Parameters

provider_id
integer
required

UID of this OAuth2.0 provider

Example:

1

Body

application/json
Name
string
required

Name of this Client type

Examples:

"Server-side application"

ResponseTypes
enum<string>
required

The OAuth 2.0 response type(s) the client is permitted to use, determining how it receives authorization responses from the Identity Provider. Format as CSV and Specify at least one.

Available options:
code,
token,
it_token,
none
Examples:

"code,token"

GrantType
enum<string>
required

The OAuth 2.0 grant types the client is permitted to use, determining how it obtains access tokens from the authorization server. Format as CSV and Specify at least one.

Available options:
authorization_code,
pkce,
client_credentials,
device_code,
refresh_token,
password,
implicit
Examples:

"authorization_code,refresh_token,password"

Description
string

Description of this Client type

Examples:

"Use this client configuration to create server-side applications that don't act on behalf of end-users"

TokenEndpointAuthMethod
enum<string>

The authentication method a client can use at the token endpoint, ensuring secure communication with the authorization server during the OAuth 2.0 authentication.

Available options:
client_secret_basic,
client_secret_post
Examples:

"client_secret_basic"

"client_secret_post"

OktaAppType
enum<string>

Dictates how an application will authenticate and interact with Okta's authorization servers, including whether it operates as a web, native, single-page, or service application. This setting is required to register Okta Identity Providers and not required for other Identity Provider. Please note that Okta overwrites values of the TokenEndpointAuthMethod, GrantType, and ResponseTypes properties and fills them based on the value of the OktaAppType property.

Available options:
web,
native,
browser,
service
Examples:

"web"

"native"

"browser"

"service"

Response

OK

Name
string
required

Name of this Client type

Examples:

"Server-side application"

ResponseTypes
enum<string>
required

The OAuth 2.0 response type(s) the client is permitted to use, determining how it receives authorization responses from the Identity Provider. Format as CSV and Specify at least one.

Available options:
code,
token,
it_token,
none
Examples:

"code,token"

GrantType
enum<string>
required

The OAuth 2.0 grant types the client is permitted to use, determining how it obtains access tokens from the authorization server. Format as CSV and Specify at least one.

Available options:
authorization_code,
pkce,
client_credentials,
device_code,
refresh_token,
password,
implicit
Examples:

"authorization_code,refresh_token,password"

Description
string

Description of this Client type

Examples:

"Use this client configuration to create server-side applications that don't act on behalf of end-users"

TokenEndpointAuthMethod
enum<string>

The authentication method a client can use at the token endpoint, ensuring secure communication with the authorization server during the OAuth 2.0 authentication.

Available options:
client_secret_basic,
client_secret_post
Examples:

"client_secret_basic"

"client_secret_post"

OktaAppType
enum<string>

Dictates how an application will authenticate and interact with Okta's authorization servers, including whether it operates as a web, native, single-page, or service application. This setting is required to register Okta Identity Providers and not required for other Identity Provider. Please note that Okta overwrites values of the TokenEndpointAuthMethod, GrantType, and ResponseTypes properties and fills them based on the value of the OktaAppType property.

Available options:
web,
native,
browser,
service
Examples:

"web"

"native"

"browser"

"service"

ID
integer

UID of this client type

Examples:

1

CreatedAt
string

Timestamp of when this client type was created

Examples:

"2023-06-25 13:37"

UpdatedAt
string

Timestamp of when this client type was created

Examples:

"2023-06-25 13:37"