Skip to content
This repository has been archived by the owner on Oct 11, 2023. It is now read-only.

Latest commit

 

History

History
264 lines (189 loc) · 6.01 KB

oidc_provider.md

File metadata and controls

264 lines (189 loc) · 6.01 KB

Entity with the OIDC Client configuration to use in Authentication Middleware

Attributes

Name Type Description Example
name string Identifier associated to this OIDC Client for the OIDC Provider "client-api-identifier"

Entity with the OIDC Provider configuration to use in Authentication Middleware

Attributes

Name Type Description Example
clients array OIDC Clients associated [{"name":"client-api-identifier"}]
createAt date-time OIDC Provider creation date "2015-01-01T12:00:00Z"
id uuid Unique OIDC Provider identifier "01234567-89ab-cdef-0123-456789abcdef"
issuerUrl string The issuer URL which issues the tokens "https://accounts.google.com"
name string OIDC Provider name "Example"
path string OIDC Provider location "/example/admin/"
updateAt date-time The date timestamp of the last update "2015-01-01T12:00:00Z"
urn string Uniform Resource Name "urn:iws:auth::oidc/example/admin/Example"

OIDC Provider Create

Create a new OIDC Provider.

POST /api/v1/admin/auth/oidc/providers

Required Parameters

Name Type Description Example
clients array OIDC Client identifiers associated ["client-api-identifier"]
issuerUrl string The issuer URL which issues the tokens "https://accounts.google.com"
name string OIDC Provider name "Example"
path string OIDC Provider location "/example/admin/"

Curl Example

$ curl -n -X POST /api/v1/admin/auth/oidc/providers \
  -d '{
  "name": "Example",
  "path": "/example/admin/",
  "issuerUrl": "https://accounts.google.com",
  "clients": [
    "client-api-identifier"
  ]
}' \
  -H "Content-Type: application/json" \
  -H "Authorization: Basic or Bearer XXX"

Response Example

HTTP/1.1 201 Created
{
  "id": "01234567-89ab-cdef-0123-456789abcdef",
  "name": "Example",
  "path": "/example/admin/",
  "createAt": "2015-01-01T12:00:00Z",
  "updateAt": "2015-01-01T12:00:00Z",
  "issuerUrl": "https://accounts.google.com",
  "urn": "urn:iws:auth::oidc/example/admin/Example",
  "clients": [
    {
      "name": "client-api-identifier"
    }
  ]
}

OIDC Provider Update

Update an existing OIDC Provider.

PUT /api/v1/admin/auth/oidc/providers/{oidc_provider_name}

Required Parameters

Name Type Description Example
clients array OIDC Client identifiers associated ["client-api-identifier"]
issuerUrl string The issuer URL which issues the tokens "https://accounts.google.com"
name string OIDC Provider name "Example"
path string OIDC Provider location "/example/admin/"

Curl Example

$ curl -n -X PUT /api/v1/admin/auth/oidc/providers/$OIDC_PROVIDER_NAME \
  -d '{
  "name": "Example",
  "path": "/example/admin/",
  "issuerUrl": "https://accounts.google.com",
  "clients": [
    "client-api-identifier"
  ]
}' \
  -H "Content-Type: application/json" \
  -H "Authorization: Basic or Bearer XXX"

Response Example

HTTP/1.1 200 OK
{
  "id": "01234567-89ab-cdef-0123-456789abcdef",
  "name": "Example",
  "path": "/example/admin/",
  "createAt": "2015-01-01T12:00:00Z",
  "updateAt": "2015-01-01T12:00:00Z",
  "issuerUrl": "https://accounts.google.com",
  "urn": "urn:iws:auth::oidc/example/admin/Example",
  "clients": [
    {
      "name": "client-api-identifier"
    }
  ]
}

OIDC Provider Delete

Delete an existing OIDC Provider.

DELETE /api/v1/admin/auth/oidc/providers/{oidc_provider_name}

Curl Example

$ curl -n -X DELETE /api/v1/admin/auth/oidc/providers/$OIDC_PROVIDER_NAME \
  -H "Content-Type: application/json" \
  -H "Authorization: Basic or Bearer XXX"

Response Example

HTTP/1.1 202 Accepted

OIDC Provider Get

Get an existing OIDC Provider.

GET /api/v1/admin/auth/oidc/providers/{oidc_provider_name}

Curl Example

$ curl -n /api/v1/admin/auth/oidc/providers/$OIDC_PROVIDER_NAME \
  -H "Authorization: Basic or Bearer XXX"

Response Example

HTTP/1.1 200 OK
{
  "id": "01234567-89ab-cdef-0123-456789abcdef",
  "name": "Example",
  "path": "/example/admin/",
  "createAt": "2015-01-01T12:00:00Z",
  "updateAt": "2015-01-01T12:00:00Z",
  "issuerUrl": "https://accounts.google.com",
  "urn": "urn:iws:auth::oidc/example/admin/Example",
  "clients": [
    {
      "name": "client-api-identifier"
    }
  ]
}

Attributes

Name Type Description Example
limit integer The maximum number of items in the response (as set in the query or by default) 20
offset integer The offset of the items returned (as set in the query or by default) 0
providers array OIDC Provider identifiers ["google","keycloak"]
total integer The total number of items available to return 2

OIDC Provider List All

List all OIDC Providers, using optional query parameters.

GET /api/v1/admin/auth/oidc/providers?PathPrefix={optional_path_prefix}&Offset={optional_offset}&Limit={optional_limit}&OrderBy={columnName-desc}

Curl Example

$ curl -n /api/v1/admin/auth/oidc/providers?PathPrefix=$OPTIONAL_PATH_PREFIX&Offset=$OPTIONAL_OFFSET&Limit=$OPTIONAL_LIMIT&OrderBy=$COLUMNNAME-DESC \
  -H "Authorization: Basic or Bearer XXX"

Response Example

HTTP/1.1 200 OK
{
  "providers": [
    "google",
    "keycloak"
  ],
  "offset": 0,
  "limit": 20,
  "total": 2
}