Authorization Detail Type Management API
Authorization detail types in ThunderID register the RFC 9396 type values clients may request through the authorization_details parameter, each with the JSON Schema its details conform to, the consent summary shown to the user, and an optional processor that authorizes and enriches the details. Types are not bound to a resource server, so a request may ask for any registered type; the access token audience comes from the resource parameter, or the default resource server when there is none, as for permission scopes.
Download the OpenAPI definition (YAML)
Security schemes
OAuth2: oauth2
authorizationCode flow, token URL https://localhost:8090/oauth2/token, authorization URL https://localhost:8090/oauth2/authorize
1 scopes
| Scope | Description |
|---|---|
system | Access to system management APIs |
clientCredentials flow, token URL https://localhost:8090/oauth2/token
1 scopes
| Scope | Description |
|---|---|
system | Access to system management APIs |
Authorization Detail Types
Register RFC 9396 authorization details types that clients request through the authorization_details parameter.
List authorization details types
GET /authorization-detail-types
Returns the registered RFC 9396 authorization details types, a page at a time, ordered by type value.
Scopes: system
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
limit | query | integer | Maximum number of records to return. Must be between 1 and 100 inclusive. Default: | |
offset | query | integer | Number of records to skip for pagination Default: |
Responses
| Code | Description | Schema |
|---|---|---|
200 | List of authorization details types | AuthorizationDetailTypeListResponse |
400 | Invalid limit or offset, or too many types to list in composite mode | Error |
500 | Internal server error | Error |
Register an authorization details type
POST /authorization-detail-types
Registers an RFC 9396 authorization details type. The new type starts at version 1. Any client can request it through the authorization_details parameter. A type is not bound to a resource server: the access token audience comes from the request's resource parameter, or the default resource server when there is none, as for permission scopes.
Validation rules:
typeis required, at most 512 characters of printable ASCII without spaces, and unique across the deployment.nameis required and at most 100 characters.schemais required, at most 64 KiB, and must be a JSON Schema 2020-12 schema that describes an object.$schema, when present, must behttps://json-schema.org/draft/2020-12/schema. Keywords must be well typed and patterns must compile;$refand$defsare refused. Limits must be satisfiable: a lower bound cannot exceed its upper bound, lengths and item counts cannot be negative, andmultipleOfmust be greater than 0. Aconstorenumon thetypemember must include the registeredtypevalue.- Property names must not contain a dot, since field paths and consent template placeholders separate names with one.
consentTemplateis at most 1000 bytes, and each{{...}}in it must be a placeholder naming a property the schema declares, ortype.- A property's
policymust use the settings described on theschemafield, spelled exactly. A policy that is not valid makes the schema invalid. A schema error says what is wrong in its description. processor.endpointmust be an absolute HTTPS URL with a valid host and port and no user information (HTTP is accepted only on a loopback host). A processor call times out afteroauth.authorization_details.processor_timeoutseconds (5 by default, at most 30).- A type without a processor can be requested only with a signed-in user who consents. A
client_credentialstoken request for it is refused withinvalid_authorization_details. - The request body is at most 1 MiB.
Scopes: system
Request body (required): application/json
Schema: AuthorizationDetailTypeRequest
10 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Ignored; a create generates the id and an update takes it from the path. | |
version | integer | Ignored; the server sets the version. | |
isReadOnly | boolean | Ignored; a type declared in a file is read-only. | |
type | string | Yes | RFC 9396 |
name | string | Yes | Display name of the type, shown in the Console |
description | string | Optional description of the type | |
schema | object | Yes | JSON Schema 2020-12 schema that every requested detail of this type must conform to. It must describe an object. |
consentTemplate | string | Summary shown on the consent prompt, at most 1000 bytes. Each | |
processor | AuthorizationDetailProcessor | Endpoint that authorizes and enriches the details of this type. ThunderID posts every detail served by the same endpoint in one batched call. The call is specified in | |
reuse | boolean | Whether an earlier approval may stand in for the consent prompt. Default: |
Responses
| Code | Description | Schema |
|---|---|---|
201 | Authorization details type created | AuthorizationDetailTypeResponse |
400 | Bad request | Error |
409 | Conflict | Error |
500 | Internal server error | Error |
Get an authorization details type
GET /authorization-detail-types/{id}
Returns a registered authorization details type.
Scopes: system
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | Authorization details type ID |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Authorization details type | AuthorizationDetailTypeResponse |
404 | Authorization details type not found | Error |
500 | Internal server error | Error |
Update an authorization details type
PUT /authorization-detail-types/{id}
Replaces the definition of an authorization details type. The type value is immutable and must match the registered value. version increments when the update changes the schema, the consent template or reuse, or adds or removes the processor, since earlier approvals only count for the version they were given on; other changes keep it, and an update that changes nothing is not saved. The same validation rules as registration apply.
Scopes: system
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | Authorization details type ID |
Request body (required): application/json
Schema: AuthorizationDetailTypeRequest
10 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Ignored; a create generates the id and an update takes it from the path. | |
version | integer | Ignored; the server sets the version. | |
isReadOnly | boolean | Ignored; a type declared in a file is read-only. | |
type | string | Yes | RFC 9396 |
name | string | Yes | Display name of the type, shown in the Console |
description | string | Optional description of the type | |
schema | object | Yes | JSON Schema 2020-12 schema that every requested detail of this type must conform to. It must describe an object. |
consentTemplate | string | Summary shown on the consent prompt, at most 1000 bytes. Each | |
processor | AuthorizationDetailProcessor | Endpoint that authorizes and enriches the details of this type. ThunderID posts every detail served by the same endpoint in one batched call. The call is specified in | |
reuse | boolean | Whether an earlier approval may stand in for the consent prompt. Default: |
Responses
| Code | Description | Schema |
|---|---|---|
200 | Authorization details type updated | AuthorizationDetailTypeResponse |
400 | Bad request | Error |
404 | Authorization details type not found | Error |
409 | The type changed while it was being updated | Error |
500 | Internal server error | Error |
Delete an authorization details type
DEL /authorization-detail-types/{id}
Deletes an authorization details type. Clients can no longer request it, and it is removed from authorization_details_types_supported in the authorization server metadata. Deleting a type that does not exist succeeds.
Scopes: system
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
id | path | string | Yes | Authorization details type ID |
Responses
| Code | Description | Schema |
|---|---|---|
204 | Authorization details type deleted, or no type has the ID | |
400 | Bad request | Error |
500 | Internal server error | Error |
Schemas
AuthorizationDetailTypeRequest
Type: object
Unknown members are refused, here and in processor. The read-only members a read returns (id, version and isReadOnly) are accepted and ignored, so a fetched type can be sent back as an update.
10 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Ignored; a create generates the id and an update takes it from the path. | |
version | integer | Ignored; the server sets the version. | |
isReadOnly | boolean | Ignored; a type declared in a file is read-only. | |
type | string | Yes | RFC 9396 |
name | string | Yes | Display name of the type, shown in the Console |
description | string | Optional description of the type | |
schema | object | Yes | JSON Schema 2020-12 schema that every requested detail of this type must conform to. It must describe an object. |
consentTemplate | string | Summary shown on the consent prompt, at most 1000 bytes. Each | |
processor | AuthorizationDetailProcessor | Endpoint that authorizes and enriches the details of this type. ThunderID posts every detail served by the same endpoint in one batched call. The call is specified in | |
reuse | boolean | Whether an earlier approval may stand in for the consent prompt. Default: |
AuthorizationDetailTypeResponse
Type: object
10 properties
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | Unique identifier of the type, used in management API paths |
type | string | Yes | RFC 9396 |
name | string | Yes | Display name of the type, shown in the Console |
description | string | Optional description of the type | |
version | integer | Yes | Version of the type definition. Starts at 1 and increments when an update changes the schema, the consent template or |
schema | object | Yes | JSON Schema 2020-12 schema as registered |
consentTemplate | string | Summary template shown on the consent prompt | |
processor | AuthorizationDetailProcessor | Endpoint that authorizes and enriches the details of this type. ThunderID posts every detail served by the same endpoint in one batched call. The call is specified in | |
reuse | boolean | Yes | Whether earlier approvals are reused, always returned. See the request field. |
isReadOnly | boolean | Yes | Whether the type is defined in declarative configuration. A read-only type cannot be updated or deleted through the API. |
AuthorizationDetailTypeListResponse
Type: object
5 properties
| Name | Type | Required | Description |
|---|---|---|---|
totalResults | integer | Yes | Number of registered types |
startIndex | integer | Yes | Index of the first element of the page, which will be equal to offset + 1 |
count | integer | Yes | Number of elements in the returned page |
types | array of AuthorizationDetailTypeResponse | Yes | |
links | array of Link | Yes |
AuthorizationDetailProcessor
Type: object
Endpoint that authorizes and enriches the details of this type. ThunderID posts every detail served by the same endpoint in one batched call. The call is specified in api/extensions/authorization-details-processor.yaml, authenticated with authentication; details are batched per endpoint and credential, so a type's credential is never sent with another type's details. Redirects are not followed. Only a false decision refuses a detail. A processor that cannot be reached, times out, answers with a status other than 200 (a redirect included) or a body that cannot be decoded, leaves a detail without a decision, answers one twice, or patches a field its policy does not let it change, fails the request; details are never let through unchecked.
2 properties
| Name | Type | Required | Description |
|---|---|---|---|
endpoint | string (uri) | Yes | Absolute HTTPS URL of the processor, with a valid host and port and no user information. HTTP is accepted only on a loopback host. |
authentication | OutboundAuthentication | How ThunderID authenticates itself to the processor: Credential values are stored encrypted and returned as |
OutboundAuthentication
Type: object
How ThunderID authenticates itself to the processor: none, bearer, basic or api_key. The type selects the method and properties carries that method's fields, as for a connection's outbound authentication.
Credential values are stored encrypted and returned as "******". On update, a masked value or an omitted authentication block keeps the stored credential while the endpoint is unchanged; when the endpoint changes, the credential must be given again (RAR-1009). Setting type to none removes authentication.
2 properties
| Name | Type | Required | Description |
|---|---|---|---|
type | string | Yes | The authentication method. |
properties | object | The selected method's field values, keyed by field name. |
Error
Type: object
3 properties
| Name | Type | Required | Description |
|---|---|---|---|
code | string | Yes | Error code. Codes follow the RAR-XXXX convention. |
message | I18nMessage | Yes | Internationalized message with translation key and default value. |
description | I18nMessage | Internationalized message with translation key and default value. |
I18nMessage
Type: object
Internationalized message with translation key and default value.
2 properties
| Name | Type | Required | Description |
|---|---|---|---|
key | string | Yes | Translation key for fetching localized message. |
defaultValue | string | Yes | Default message in English (fallback). |
Was this page helpful?