API v2: OpenID Connect Configurationยถ

OpenID Connect related endpoints help to create, modify, list and delete OpenID Connect configurations.


Data Structuresยถ

OpenIDModelยถ

Attribute

Type

Required

Description

id

string

Read-only, unique object Identifier.

name

string

yes

Case-insensitive, unique name of the configuration.

enabled

boolean

yes

Enabling configuration.

bind_to

string

Bind address.

configuration_url

string

yes

This URL is specific for every Identity Provider and allows identifying one for correct configuration.

client_id

string

yes

Client id available after the registration on selected provider.

client_secret

string

yes

Client secret available after the registration on selected provider. Protected.

username_mapping

string

Username mapping is useful when users name has different naming convention.

email_mapping

string

Email mapping is useful when users name has different naming convention.

created_at

datetime

Read-only. Timestamp of creation.

modified_at

datetime

Read-only. Timestamp of modification.

removed

boolean

Read-only.

Retrieve Available Attributes of the OpenIDModelยถ

Request

Method

GET

Path

/api/v2/objspec/oidc

To check allowed methods, available URL parameters and possible responses please refer to the API Overview section.


Get Existing OpenID Connect Configurations Listยถ

Request

Method

GET

Path

/api/v2/oidc

Example Request

GET /api/v2/oidc`

curl -s -k -X GET \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  'https://10.0.214.98/api/v2/oidc'

Response

{
    "result": "success",
    "oidc": [
        {
            "id": "9124292845052624897",
            "name": "OKTA",
            "enabled": true,
            "bind_to": "0.0.0.0",
            "configuration_url": "https:\/\/okta.com",
            "client_id": "1234567",
            "created_at": "2024-06-19 07:51:42.988336-07",
            "modified_at": "2024-06-19 07:51:42.988336-07"
        }
    ]
}

Get Existing OpenID Connect Configuration by IDยถ

Request

Method

GET

Path

/api/v2/oidc/<id>

Example Request

GET /api/v2/oidc/<id>`

curl -s -k -X GET \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  'https://10.0.214.98/api/v2/oidc/9124292845052624897'

Response

{
    "result": "success",
    "oidc": [
        {
            "id": "9124292845052624897",
            "name": "OKTA",
            "enabled": true,
            "bind_to": "0.0.0.0",
            "configuration_url": "https:\/\/okta.com",
            "client_id": "1234567",
            "created_at": "2024-06-19 07:51:42.988336-07",
            "modified_at": "2024-06-19 07:51:42.988336-07"
        }
    ]
}

Defining OpenID Connect Configurationยถ

Request

Method

POST

Path

/api/v2/oidc

Headers

Content-Type: Application/json

Body

OpenIDModel

Example Request

POST /api/v2/oidc`

curl -s -k -X POST \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  -H 'Content-Type: application/json' \
  'https://10.0.214.98/api/v2/oidc' \
  -d'{"name": "OKTA","enabled": true,"configuration_url":"https:\/\/okta.com","client_id":"1234567","client_secret":"Secret"}'

Response

{
    "result": "success",
    "oidc": {
        "id": "9124292845052624898"
    }
}

Modify OpenID Connect Configurationยถ

Request

Method

PATCH

Path

/api/v2/oidc/<id>

Headers

Content-Type: Application/json

Body

OpenIDModel

Example Request

PATCH /api/v2/oidc/<id>`

curl -s -k -X PATCH \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  -H 'Content-Type: application/json' \
  'https://10.0.214.98/api/v2/oidc/9124292845052624898' \
  -d'{"client_id":"1234567","client_secret":"Secret"}'

Response

{
    "result": "success",
    "oidc": {
        "id": "9124292845052624898"
    }
}

Deleting OpenID Connect Configurationยถ

Request

Method

DELETE

Path

/api/v2/oidc/<id>

Example Request

DELETE /api/v2/oidc/<id>`

curl -s -k -X DELETE \
  -H 'Authorization: sgfeea6jsaz4mum9su8w6' \
  'https://10.0.214.98/api/v2/oidc/9124292845052624897'

Response

{
    "result": "success"
}