From 40eb1da3798a742e6534a5b4bb84610af2e8189c Mon Sep 17 00:00:00 2001 From: Julian Cuni Date: Wed, 7 Sep 2022 02:47:37 +0200 Subject: [PATCH] Axios again. Done. Registration flow seems ok. --- .../kc-client/apis/AttackDetectionApi.ts | 157 - .../apis/AuthenticationManagementApi.ts | 1606 --- .../apis/ClientAttributeCertificateApi.ts | 359 - .../kc-client/apis/ClientInitialAccessApi.ts | 165 - .../apis/ClientRegistrationPolicyApi.ts | 65 - .../kc-client/apis/ClientRoleMappingsApi.ts | 586 -- .../kc-client/apis/ClientScopesApi.ts | 266 - backend/keycloak/kc-client/apis/ClientsApi.ts | 1780 ---- .../keycloak/kc-client/apis/ComponentApi.ts | 323 - backend/keycloak/kc-client/apis/GroupsApi.ts | 555 - .../kc-client/apis/IdentityProvidersApi.ts | 822 -- backend/keycloak/kc-client/apis/KeyApi.ts | 68 - .../kc-client/apis/ProtocolMappersApi.ts | 766 -- .../keycloak/kc-client/apis/RealmsAdminApi.ts | 2252 ---- .../keycloak/kc-client/apis/RoleMapperApi.ts | 633 -- backend/keycloak/kc-client/apis/RolesApi.ts | 1567 --- .../keycloak/kc-client/apis/RolesByIDApi.ts | 549 - backend/keycloak/kc-client/apis/RootApi.ts | 62 - .../kc-client/apis/ScopeMappingsApi.ts | 1094 -- .../kc-client/apis/UserStorageProviderApi.ts | 318 - backend/keycloak/kc-client/apis/UsersApi.ts | 1708 --- backend/keycloak/kc-client/apis/index.ts | 21 - backend/keycloak/kc-client/index.ts | 19 +- .../keycloak/kc-client/models/AccessToken.ts | 434 - .../kc-client/models/AccessTokenAccess.ts | 65 - .../models/AccessTokenAuthorization.ts | 64 - .../kc-client/models/AccessTokenCertConf.ts | 57 - .../kc-client/models/AddressClaimSet.ts | 97 - ...enticationExecutionExportRepresentation.ts | 105 - ...thenticationExecutionInfoRepresentation.ts | 153 - .../AuthenticationExecutionRepresentation.ts | 113 - .../AuthenticationFlowRepresentation.ts | 112 - .../AuthenticatorConfigInfoRepresentation.ts | 88 - .../AuthenticatorConfigRepresentation.ts | 73 - .../models/CertificateRepresentation.ts | 81 - .../ClientInitialAccessCreatePresentation.ts | 65 - .../models/ClientInitialAccessPresentation.ts | 97 - .../models/ClientMappingsRepresentation.ts | 80 - .../models/ClientPoliciesRepresentation.ts | 64 - .../ClientPolicyConditionRepresentation.ts | 72 - .../ClientPolicyExecutorRepresentation.ts | 72 - .../models/ClientPolicyRepresentation.ts | 96 - .../models/ClientProfileRepresentation.ts | 80 - .../models/ClientProfilesRepresentation.ts | 72 - .../kc-client/models/ClientRepresentation.ts | 364 - ...eProtocolMapperEvaluationRepresentation.ts | 97 - .../models/ClientScopeRepresentation.ts | 104 - .../models/ComponentExportRepresentation.ts | 104 - .../models/ComponentRepresentation.ts | 112 - .../models/ConfigPropertyRepresentation.ts | 113 - .../models/CredentialRepresentation.ts | 121 - .../models/FederatedIdentityRepresentation.ts | 73 - .../kc-client/models/GlobalRequestResult.ts | 65 - .../kc-client/models/GroupRepresentation.ts | 113 - backend/keycloak/kc-client/models/IDToken.ts | 374 - .../IdentityProviderMapperRepresentation.ts | 89 - .../models/IdentityProviderRepresentation.ts | 145 - backend/keycloak/kc-client/models/JsonNode.ts | 241 - .../kc-client/models/KeyStoreConfig.ts | 97 - .../models/KeysMetadataRepresentation.ts | 72 - ...RepresentationKeyMetadataRepresentation.ts | 130 - .../models/ManagementPermissionReference.ts | 73 - .../models/MappingsRepresentation.ts | 72 - .../models/MemoryInfoRepresentation.ts | 105 - .../kc-client/models/MultivaluedHashMap.ts | 73 - .../models/PartialImportRepresentation.ts | 138 - .../PasswordPolicyTypeRepresentation.ts | 89 - .../keycloak/kc-client/models/Permission.ts | 81 - .../kc-client/models/PolicyRepresentation.ts | 182 - .../models/ProfileInfoRepresentation.ts | 81 - .../models/ProtocolMapperRepresentation.ts | 89 - .../models/ProviderRepresentation.ts | 65 - .../models/RealmEventsConfigRepresentation.ts | 97 - .../kc-client/models/RealmRepresentation.ts | 1104 -- .../RequiredActionProviderRepresentation.ts | 105 - .../models/ResourceRepresentation.ts | 128 - .../models/ResourceServerRepresentation.ts | 155 - .../kc-client/models/RoleRepresentation.ts | 120 - .../models/RoleRepresentationComposites.ts | 65 - .../kc-client/models/RolesRepresentation.ts | 72 - .../models/ScopeMappingRepresentation.ts | 81 - .../kc-client/models/ScopeRepresentation.ts | 108 - .../models/ServerInfoRepresentation.ts | 180 - .../kc-client/models/SpiInfoRepresentation.ts | 65 - .../kc-client/models/SynchronizationResult.ts | 97 - .../models/SystemInfoRepresentation.ts | 193 - .../TestLdapConnectionRepresentation.ts | 121 - .../models/UserConsentRepresentation.ts | 81 - .../UserFederationMapperRepresentation.ts | 89 - .../UserFederationProviderRepresentation.ts | 113 - .../kc-client/models/UserRepresentation.ts | 248 - backend/keycloak/kc-client/models/index.ts | 68 - backend/keycloak/kc-client/runtime.ts | 316 - backend/keycloak/openapi.specs.yml | 9368 +++++++++++++++++ backend/keycloak/openapi.yaml | 9318 ++++++++++++++++ backend/package.json | 2 + .../src/auth/register/register.controller.ts | 22 +- backend/src/auth/register/register.service.ts | 89 +- backend/yarn.lock | 267 +- 99 files changed, 19053 insertions(+), 24962 deletions(-) delete mode 100644 backend/keycloak/kc-client/apis/AttackDetectionApi.ts delete mode 100644 backend/keycloak/kc-client/apis/AuthenticationManagementApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientAttributeCertificateApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientInitialAccessApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientRegistrationPolicyApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientRoleMappingsApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientScopesApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ClientsApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ComponentApi.ts delete mode 100644 backend/keycloak/kc-client/apis/GroupsApi.ts delete mode 100644 backend/keycloak/kc-client/apis/IdentityProvidersApi.ts delete mode 100644 backend/keycloak/kc-client/apis/KeyApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ProtocolMappersApi.ts delete mode 100644 backend/keycloak/kc-client/apis/RealmsAdminApi.ts delete mode 100644 backend/keycloak/kc-client/apis/RoleMapperApi.ts delete mode 100644 backend/keycloak/kc-client/apis/RolesApi.ts delete mode 100644 backend/keycloak/kc-client/apis/RolesByIDApi.ts delete mode 100644 backend/keycloak/kc-client/apis/RootApi.ts delete mode 100644 backend/keycloak/kc-client/apis/ScopeMappingsApi.ts delete mode 100644 backend/keycloak/kc-client/apis/UserStorageProviderApi.ts delete mode 100644 backend/keycloak/kc-client/apis/UsersApi.ts delete mode 100644 backend/keycloak/kc-client/apis/index.ts delete mode 100644 backend/keycloak/kc-client/models/AccessToken.ts delete mode 100644 backend/keycloak/kc-client/models/AccessTokenAccess.ts delete mode 100644 backend/keycloak/kc-client/models/AccessTokenAuthorization.ts delete mode 100644 backend/keycloak/kc-client/models/AccessTokenCertConf.ts delete mode 100644 backend/keycloak/kc-client/models/AddressClaimSet.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticationExecutionExportRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticationExecutionInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticationExecutionRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticationFlowRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticatorConfigInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/AuthenticatorConfigRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/CertificateRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientInitialAccessCreatePresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientInitialAccessPresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientMappingsRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientPoliciesRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientPolicyConditionRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientPolicyExecutorRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientPolicyRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientProfileRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientProfilesRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ClientScopeRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ComponentExportRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ComponentRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ConfigPropertyRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/CredentialRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/FederatedIdentityRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/GlobalRequestResult.ts delete mode 100644 backend/keycloak/kc-client/models/GroupRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/IDToken.ts delete mode 100644 backend/keycloak/kc-client/models/IdentityProviderMapperRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/IdentityProviderRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/JsonNode.ts delete mode 100644 backend/keycloak/kc-client/models/KeyStoreConfig.ts delete mode 100644 backend/keycloak/kc-client/models/KeysMetadataRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/KeysMetadataRepresentationKeyMetadataRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ManagementPermissionReference.ts delete mode 100644 backend/keycloak/kc-client/models/MappingsRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/MemoryInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/MultivaluedHashMap.ts delete mode 100644 backend/keycloak/kc-client/models/PartialImportRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/PasswordPolicyTypeRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/Permission.ts delete mode 100644 backend/keycloak/kc-client/models/PolicyRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ProfileInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ProtocolMapperRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ProviderRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/RealmEventsConfigRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/RealmRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/RequiredActionProviderRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ResourceRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ResourceServerRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/RoleRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/RoleRepresentationComposites.ts delete mode 100644 backend/keycloak/kc-client/models/RolesRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ScopeMappingRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ScopeRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/ServerInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/SpiInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/SynchronizationResult.ts delete mode 100644 backend/keycloak/kc-client/models/SystemInfoRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/TestLdapConnectionRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/UserConsentRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/UserFederationMapperRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/UserFederationProviderRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/UserRepresentation.ts delete mode 100644 backend/keycloak/kc-client/models/index.ts delete mode 100644 backend/keycloak/kc-client/runtime.ts create mode 100644 backend/keycloak/openapi.specs.yml create mode 100644 backend/keycloak/openapi.yaml diff --git a/backend/keycloak/kc-client/apis/AttackDetectionApi.ts b/backend/keycloak/kc-client/apis/AttackDetectionApi.ts deleted file mode 100644 index 4c4219e..0000000 --- a/backend/keycloak/kc-client/apis/AttackDetectionApi.ts +++ /dev/null @@ -1,157 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; - -export interface RealmAttackDetectionBruteForceUsersDeleteRequest { - realm: string; -} - -export interface RealmAttackDetectionBruteForceUsersUserIdDeleteRequest { - realm: string; - userId: string; -} - -export interface RealmAttackDetectionBruteForceUsersUserIdGetRequest { - realm: string; - userId: string; -} - -/** - * - */ -export class AttackDetectionApi extends runtime.BaseAPI { - - /** - * Clear any user login failures for all users This can release temporary disabled users - */ - async realmAttackDetectionBruteForceUsersDeleteRaw(requestParameters: RealmAttackDetectionBruteForceUsersDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAttackDetectionBruteForceUsersDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/attack-detection/brute-force/users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Clear any user login failures for all users This can release temporary disabled users - */ - async realmAttackDetectionBruteForceUsersDelete(requestParameters: RealmAttackDetectionBruteForceUsersDeleteRequest): Promise { - await this.realmAttackDetectionBruteForceUsersDeleteRaw(requestParameters); - } - - /** - * Clear any user login failures for the user This can release temporary disabled user - */ - async realmAttackDetectionBruteForceUsersUserIdDeleteRaw(requestParameters: RealmAttackDetectionBruteForceUsersUserIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAttackDetectionBruteForceUsersUserIdDelete.'); - } - - if (requestParameters.userId === null || requestParameters.userId === undefined) { - throw new runtime.RequiredError('userId','Required parameter requestParameters.userId was null or undefined when calling realmAttackDetectionBruteForceUsersUserIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/attack-detection/brute-force/users/{userId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"userId"}}`, encodeURIComponent(String(requestParameters.userId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Clear any user login failures for the user This can release temporary disabled user - */ - async realmAttackDetectionBruteForceUsersUserIdDelete(requestParameters: RealmAttackDetectionBruteForceUsersUserIdDeleteRequest): Promise { - await this.realmAttackDetectionBruteForceUsersUserIdDeleteRaw(requestParameters); - } - - /** - * Get status of a username in brute force detection - */ - async realmAttackDetectionBruteForceUsersUserIdGetRaw(requestParameters: RealmAttackDetectionBruteForceUsersUserIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAttackDetectionBruteForceUsersUserIdGet.'); - } - - if (requestParameters.userId === null || requestParameters.userId === undefined) { - throw new runtime.RequiredError('userId','Required parameter requestParameters.userId was null or undefined when calling realmAttackDetectionBruteForceUsersUserIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/attack-detection/brute-force/users/{userId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"userId"}}`, encodeURIComponent(String(requestParameters.userId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get status of a username in brute force detection - */ - async realmAttackDetectionBruteForceUsersUserIdGet(requestParameters: RealmAttackDetectionBruteForceUsersUserIdGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmAttackDetectionBruteForceUsersUserIdGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/AuthenticationManagementApi.ts b/backend/keycloak/kc-client/apis/AuthenticationManagementApi.ts deleted file mode 100644 index d4410fd..0000000 --- a/backend/keycloak/kc-client/apis/AuthenticationManagementApi.ts +++ /dev/null @@ -1,1606 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - AuthenticationExecutionInfoRepresentation, - AuthenticationExecutionInfoRepresentationFromJSON, - AuthenticationExecutionInfoRepresentationToJSON, - AuthenticationExecutionRepresentation, - AuthenticationExecutionRepresentationFromJSON, - AuthenticationExecutionRepresentationToJSON, - AuthenticationFlowRepresentation, - AuthenticationFlowRepresentationFromJSON, - AuthenticationFlowRepresentationToJSON, - AuthenticatorConfigInfoRepresentation, - AuthenticatorConfigInfoRepresentationFromJSON, - AuthenticatorConfigInfoRepresentationToJSON, - AuthenticatorConfigRepresentation, - AuthenticatorConfigRepresentationFromJSON, - AuthenticatorConfigRepresentationToJSON, - RequiredActionProviderRepresentation, - RequiredActionProviderRepresentationFromJSON, - RequiredActionProviderRepresentationToJSON, -} from '../models'; - -export interface RealmAuthenticationAuthenticatorProvidersGetRequest { - realm: string; -} - -export interface RealmAuthenticationClientAuthenticatorProvidersGetRequest { - realm: string; -} - -export interface RealmAuthenticationConfigDescriptionProviderIdGetRequest { - realm: string; - providerId: string; -} - -export interface RealmAuthenticationConfigIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmAuthenticationConfigIdGetRequest { - realm: string; - id: string; -} - -export interface RealmAuthenticationConfigIdPutRequest { - realm: string; - id: string; - authenticatorConfigRepresentation: AuthenticatorConfigRepresentation; -} - -export interface RealmAuthenticationExecutionsExecutionIdConfigPostRequest { - realm: string; - executionId: string; - authenticatorConfigRepresentation: AuthenticatorConfigRepresentation; -} - -export interface RealmAuthenticationExecutionsExecutionIdDeleteRequest { - realm: string; - executionId: string; -} - -export interface RealmAuthenticationExecutionsExecutionIdGetRequest { - realm: string; - executionId: string; -} - -export interface RealmAuthenticationExecutionsExecutionIdLowerPriorityPostRequest { - realm: string; - executionId: string; -} - -export interface RealmAuthenticationExecutionsExecutionIdRaisePriorityPostRequest { - realm: string; - executionId: string; -} - -export interface RealmAuthenticationExecutionsPostRequest { - realm: string; - authenticationExecutionRepresentation: AuthenticationExecutionRepresentation; -} - -export interface RealmAuthenticationFlowsFlowAliasCopyPostRequest { - realm: string; - flowAlias: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmAuthenticationFlowsFlowAliasExecutionsExecutionPostRequest { - realm: string; - flowAlias: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmAuthenticationFlowsFlowAliasExecutionsFlowPostRequest { - realm: string; - flowAlias: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmAuthenticationFlowsFlowAliasExecutionsGetRequest { - realm: string; - flowAlias: string; -} - -export interface RealmAuthenticationFlowsFlowAliasExecutionsPutRequest { - realm: string; - flowAlias: string; - authenticationExecutionInfoRepresentation: AuthenticationExecutionInfoRepresentation; -} - -export interface RealmAuthenticationFlowsGetRequest { - realm: string; -} - -export interface RealmAuthenticationFlowsIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmAuthenticationFlowsIdGetRequest { - realm: string; - id: string; -} - -export interface RealmAuthenticationFlowsIdPutRequest { - realm: string; - id: string; - authenticationFlowRepresentation: AuthenticationFlowRepresentation; -} - -export interface RealmAuthenticationFlowsPostRequest { - realm: string; - authenticationFlowRepresentation: AuthenticationFlowRepresentation; -} - -export interface RealmAuthenticationFormActionProvidersGetRequest { - realm: string; -} - -export interface RealmAuthenticationFormProvidersGetRequest { - realm: string; -} - -export interface RealmAuthenticationPerClientConfigDescriptionGetRequest { - realm: string; -} - -export interface RealmAuthenticationRegisterRequiredActionPostRequest { - realm: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmAuthenticationRequiredActionsAliasDeleteRequest { - realm: string; - alias: string; -} - -export interface RealmAuthenticationRequiredActionsAliasGetRequest { - realm: string; - alias: string; -} - -export interface RealmAuthenticationRequiredActionsAliasLowerPriorityPostRequest { - realm: string; - alias: string; -} - -export interface RealmAuthenticationRequiredActionsAliasPutRequest { - realm: string; - alias: string; - requiredActionProviderRepresentation: RequiredActionProviderRepresentation; -} - -export interface RealmAuthenticationRequiredActionsAliasRaisePriorityPostRequest { - realm: string; - alias: string; -} - -export interface RealmAuthenticationRequiredActionsGetRequest { - realm: string; -} - -export interface RealmAuthenticationUnregisteredRequiredActionsGetRequest { - realm: string; -} - -/** - * - */ -export class AuthenticationManagementApi extends runtime.BaseAPI { - - /** - * Get authenticator providers Returns a stream of authenticator providers. - */ - async realmAuthenticationAuthenticatorProvidersGetRaw(requestParameters: RealmAuthenticationAuthenticatorProvidersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationAuthenticatorProvidersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/authenticator-providers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get authenticator providers Returns a stream of authenticator providers. - */ - async realmAuthenticationAuthenticatorProvidersGet(requestParameters: RealmAuthenticationAuthenticatorProvidersGetRequest): Promise> { - const response = await this.realmAuthenticationAuthenticatorProvidersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get client authenticator providers Returns a stream of client authenticator providers. - */ - async realmAuthenticationClientAuthenticatorProvidersGetRaw(requestParameters: RealmAuthenticationClientAuthenticatorProvidersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationClientAuthenticatorProvidersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/client-authenticator-providers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client authenticator providers Returns a stream of client authenticator providers. - */ - async realmAuthenticationClientAuthenticatorProvidersGet(requestParameters: RealmAuthenticationClientAuthenticatorProvidersGetRequest): Promise> { - const response = await this.realmAuthenticationClientAuthenticatorProvidersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get authenticator provider’s configuration description - */ - async realmAuthenticationConfigDescriptionProviderIdGetRaw(requestParameters: RealmAuthenticationConfigDescriptionProviderIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationConfigDescriptionProviderIdGet.'); - } - - if (requestParameters.providerId === null || requestParameters.providerId === undefined) { - throw new runtime.RequiredError('providerId','Required parameter requestParameters.providerId was null or undefined when calling realmAuthenticationConfigDescriptionProviderIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/config-description/{providerId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"providerId"}}`, encodeURIComponent(String(requestParameters.providerId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => AuthenticatorConfigInfoRepresentationFromJSON(jsonValue)); - } - - /** - * Get authenticator provider’s configuration description - */ - async realmAuthenticationConfigDescriptionProviderIdGet(requestParameters: RealmAuthenticationConfigDescriptionProviderIdGetRequest): Promise { - const response = await this.realmAuthenticationConfigDescriptionProviderIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete authenticator configuration - */ - async realmAuthenticationConfigIdDeleteRaw(requestParameters: RealmAuthenticationConfigIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationConfigIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationConfigIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/config/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete authenticator configuration - */ - async realmAuthenticationConfigIdDelete(requestParameters: RealmAuthenticationConfigIdDeleteRequest): Promise { - await this.realmAuthenticationConfigIdDeleteRaw(requestParameters); - } - - /** - * Get authenticator configuration - */ - async realmAuthenticationConfigIdGetRaw(requestParameters: RealmAuthenticationConfigIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationConfigIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationConfigIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/config/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => AuthenticatorConfigRepresentationFromJSON(jsonValue)); - } - - /** - * Get authenticator configuration - */ - async realmAuthenticationConfigIdGet(requestParameters: RealmAuthenticationConfigIdGetRequest): Promise { - const response = await this.realmAuthenticationConfigIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update authenticator configuration - */ - async realmAuthenticationConfigIdPutRaw(requestParameters: RealmAuthenticationConfigIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationConfigIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationConfigIdPut.'); - } - - if (requestParameters.authenticatorConfigRepresentation === null || requestParameters.authenticatorConfigRepresentation === undefined) { - throw new runtime.RequiredError('authenticatorConfigRepresentation','Required parameter requestParameters.authenticatorConfigRepresentation was null or undefined when calling realmAuthenticationConfigIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/config/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: AuthenticatorConfigRepresentationToJSON(requestParameters.authenticatorConfigRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update authenticator configuration - */ - async realmAuthenticationConfigIdPut(requestParameters: RealmAuthenticationConfigIdPutRequest): Promise { - await this.realmAuthenticationConfigIdPutRaw(requestParameters); - } - - /** - * Update execution with new configuration - */ - async realmAuthenticationExecutionsExecutionIdConfigPostRaw(requestParameters: RealmAuthenticationExecutionsExecutionIdConfigPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsExecutionIdConfigPost.'); - } - - if (requestParameters.executionId === null || requestParameters.executionId === undefined) { - throw new runtime.RequiredError('executionId','Required parameter requestParameters.executionId was null or undefined when calling realmAuthenticationExecutionsExecutionIdConfigPost.'); - } - - if (requestParameters.authenticatorConfigRepresentation === null || requestParameters.authenticatorConfigRepresentation === undefined) { - throw new runtime.RequiredError('authenticatorConfigRepresentation','Required parameter requestParameters.authenticatorConfigRepresentation was null or undefined when calling realmAuthenticationExecutionsExecutionIdConfigPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions/{executionId}/config`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"executionId"}}`, encodeURIComponent(String(requestParameters.executionId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: AuthenticatorConfigRepresentationToJSON(requestParameters.authenticatorConfigRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update execution with new configuration - */ - async realmAuthenticationExecutionsExecutionIdConfigPost(requestParameters: RealmAuthenticationExecutionsExecutionIdConfigPostRequest): Promise { - await this.realmAuthenticationExecutionsExecutionIdConfigPostRaw(requestParameters); - } - - /** - * Delete execution - */ - async realmAuthenticationExecutionsExecutionIdDeleteRaw(requestParameters: RealmAuthenticationExecutionsExecutionIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsExecutionIdDelete.'); - } - - if (requestParameters.executionId === null || requestParameters.executionId === undefined) { - throw new runtime.RequiredError('executionId','Required parameter requestParameters.executionId was null or undefined when calling realmAuthenticationExecutionsExecutionIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions/{executionId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"executionId"}}`, encodeURIComponent(String(requestParameters.executionId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete execution - */ - async realmAuthenticationExecutionsExecutionIdDelete(requestParameters: RealmAuthenticationExecutionsExecutionIdDeleteRequest): Promise { - await this.realmAuthenticationExecutionsExecutionIdDeleteRaw(requestParameters); - } - - /** - * Get Single Execution - */ - async realmAuthenticationExecutionsExecutionIdGetRaw(requestParameters: RealmAuthenticationExecutionsExecutionIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsExecutionIdGet.'); - } - - if (requestParameters.executionId === null || requestParameters.executionId === undefined) { - throw new runtime.RequiredError('executionId','Required parameter requestParameters.executionId was null or undefined when calling realmAuthenticationExecutionsExecutionIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions/{executionId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"executionId"}}`, encodeURIComponent(String(requestParameters.executionId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Get Single Execution - */ - async realmAuthenticationExecutionsExecutionIdGet(requestParameters: RealmAuthenticationExecutionsExecutionIdGetRequest): Promise { - await this.realmAuthenticationExecutionsExecutionIdGetRaw(requestParameters); - } - - /** - * Lower execution’s priority - */ - async realmAuthenticationExecutionsExecutionIdLowerPriorityPostRaw(requestParameters: RealmAuthenticationExecutionsExecutionIdLowerPriorityPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsExecutionIdLowerPriorityPost.'); - } - - if (requestParameters.executionId === null || requestParameters.executionId === undefined) { - throw new runtime.RequiredError('executionId','Required parameter requestParameters.executionId was null or undefined when calling realmAuthenticationExecutionsExecutionIdLowerPriorityPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions/{executionId}/lower-priority`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"executionId"}}`, encodeURIComponent(String(requestParameters.executionId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Lower execution’s priority - */ - async realmAuthenticationExecutionsExecutionIdLowerPriorityPost(requestParameters: RealmAuthenticationExecutionsExecutionIdLowerPriorityPostRequest): Promise { - await this.realmAuthenticationExecutionsExecutionIdLowerPriorityPostRaw(requestParameters); - } - - /** - * Raise execution’s priority - */ - async realmAuthenticationExecutionsExecutionIdRaisePriorityPostRaw(requestParameters: RealmAuthenticationExecutionsExecutionIdRaisePriorityPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsExecutionIdRaisePriorityPost.'); - } - - if (requestParameters.executionId === null || requestParameters.executionId === undefined) { - throw new runtime.RequiredError('executionId','Required parameter requestParameters.executionId was null or undefined when calling realmAuthenticationExecutionsExecutionIdRaisePriorityPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions/{executionId}/raise-priority`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"executionId"}}`, encodeURIComponent(String(requestParameters.executionId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Raise execution’s priority - */ - async realmAuthenticationExecutionsExecutionIdRaisePriorityPost(requestParameters: RealmAuthenticationExecutionsExecutionIdRaisePriorityPostRequest): Promise { - await this.realmAuthenticationExecutionsExecutionIdRaisePriorityPostRaw(requestParameters); - } - - /** - * Add new authentication execution - */ - async realmAuthenticationExecutionsPostRaw(requestParameters: RealmAuthenticationExecutionsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationExecutionsPost.'); - } - - if (requestParameters.authenticationExecutionRepresentation === null || requestParameters.authenticationExecutionRepresentation === undefined) { - throw new runtime.RequiredError('authenticationExecutionRepresentation','Required parameter requestParameters.authenticationExecutionRepresentation was null or undefined when calling realmAuthenticationExecutionsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/executions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: AuthenticationExecutionRepresentationToJSON(requestParameters.authenticationExecutionRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add new authentication execution - */ - async realmAuthenticationExecutionsPost(requestParameters: RealmAuthenticationExecutionsPostRequest): Promise { - await this.realmAuthenticationExecutionsPostRaw(requestParameters); - } - - /** - * Copy existing authentication flow under a new name The new name is given as \'newName\' attribute of the passed JSON object - */ - async realmAuthenticationFlowsFlowAliasCopyPostRaw(requestParameters: RealmAuthenticationFlowsFlowAliasCopyPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsFlowAliasCopyPost.'); - } - - if (requestParameters.flowAlias === null || requestParameters.flowAlias === undefined) { - throw new runtime.RequiredError('flowAlias','Required parameter requestParameters.flowAlias was null or undefined when calling realmAuthenticationFlowsFlowAliasCopyPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmAuthenticationFlowsFlowAliasCopyPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{flowAlias}/copy`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"flowAlias"}}`, encodeURIComponent(String(requestParameters.flowAlias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Copy existing authentication flow under a new name The new name is given as \'newName\' attribute of the passed JSON object - */ - async realmAuthenticationFlowsFlowAliasCopyPost(requestParameters: RealmAuthenticationFlowsFlowAliasCopyPostRequest): Promise { - await this.realmAuthenticationFlowsFlowAliasCopyPostRaw(requestParameters); - } - - /** - * Add new authentication execution to a flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsExecutionPostRaw(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsExecutionPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsExecutionPost.'); - } - - if (requestParameters.flowAlias === null || requestParameters.flowAlias === undefined) { - throw new runtime.RequiredError('flowAlias','Required parameter requestParameters.flowAlias was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsExecutionPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsExecutionPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{flowAlias}/executions/execution`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"flowAlias"}}`, encodeURIComponent(String(requestParameters.flowAlias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add new authentication execution to a flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsExecutionPost(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsExecutionPostRequest): Promise { - await this.realmAuthenticationFlowsFlowAliasExecutionsExecutionPostRaw(requestParameters); - } - - /** - * Add new flow with new execution to existing flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsFlowPostRaw(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsFlowPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsFlowPost.'); - } - - if (requestParameters.flowAlias === null || requestParameters.flowAlias === undefined) { - throw new runtime.RequiredError('flowAlias','Required parameter requestParameters.flowAlias was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsFlowPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsFlowPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{flowAlias}/executions/flow`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"flowAlias"}}`, encodeURIComponent(String(requestParameters.flowAlias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add new flow with new execution to existing flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsFlowPost(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsFlowPostRequest): Promise { - await this.realmAuthenticationFlowsFlowAliasExecutionsFlowPostRaw(requestParameters); - } - - /** - * Get authentication executions for a flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsGetRaw(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsGet.'); - } - - if (requestParameters.flowAlias === null || requestParameters.flowAlias === undefined) { - throw new runtime.RequiredError('flowAlias','Required parameter requestParameters.flowAlias was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{flowAlias}/executions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"flowAlias"}}`, encodeURIComponent(String(requestParameters.flowAlias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Get authentication executions for a flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsGet(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsGetRequest): Promise { - await this.realmAuthenticationFlowsFlowAliasExecutionsGetRaw(requestParameters); - } - - /** - * Update authentication executions of a Flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsPutRaw(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsPut.'); - } - - if (requestParameters.flowAlias === null || requestParameters.flowAlias === undefined) { - throw new runtime.RequiredError('flowAlias','Required parameter requestParameters.flowAlias was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsPut.'); - } - - if (requestParameters.authenticationExecutionInfoRepresentation === null || requestParameters.authenticationExecutionInfoRepresentation === undefined) { - throw new runtime.RequiredError('authenticationExecutionInfoRepresentation','Required parameter requestParameters.authenticationExecutionInfoRepresentation was null or undefined when calling realmAuthenticationFlowsFlowAliasExecutionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{flowAlias}/executions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"flowAlias"}}`, encodeURIComponent(String(requestParameters.flowAlias))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: AuthenticationExecutionInfoRepresentationToJSON(requestParameters.authenticationExecutionInfoRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update authentication executions of a Flow - */ - async realmAuthenticationFlowsFlowAliasExecutionsPut(requestParameters: RealmAuthenticationFlowsFlowAliasExecutionsPutRequest): Promise { - await this.realmAuthenticationFlowsFlowAliasExecutionsPutRaw(requestParameters); - } - - /** - * Get authentication flows Returns a stream of authentication flows. - */ - async realmAuthenticationFlowsGetRaw(requestParameters: RealmAuthenticationFlowsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get authentication flows Returns a stream of authentication flows. - */ - async realmAuthenticationFlowsGet(requestParameters: RealmAuthenticationFlowsGetRequest): Promise> { - const response = await this.realmAuthenticationFlowsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete an authentication flow - */ - async realmAuthenticationFlowsIdDeleteRaw(requestParameters: RealmAuthenticationFlowsIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationFlowsIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete an authentication flow - */ - async realmAuthenticationFlowsIdDelete(requestParameters: RealmAuthenticationFlowsIdDeleteRequest): Promise { - await this.realmAuthenticationFlowsIdDeleteRaw(requestParameters); - } - - /** - * Get authentication flow for id - */ - async realmAuthenticationFlowsIdGetRaw(requestParameters: RealmAuthenticationFlowsIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationFlowsIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => AuthenticationFlowRepresentationFromJSON(jsonValue)); - } - - /** - * Get authentication flow for id - */ - async realmAuthenticationFlowsIdGet(requestParameters: RealmAuthenticationFlowsIdGetRequest): Promise { - const response = await this.realmAuthenticationFlowsIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update an authentication flow - */ - async realmAuthenticationFlowsIdPutRaw(requestParameters: RealmAuthenticationFlowsIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmAuthenticationFlowsIdPut.'); - } - - if (requestParameters.authenticationFlowRepresentation === null || requestParameters.authenticationFlowRepresentation === undefined) { - throw new runtime.RequiredError('authenticationFlowRepresentation','Required parameter requestParameters.authenticationFlowRepresentation was null or undefined when calling realmAuthenticationFlowsIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: AuthenticationFlowRepresentationToJSON(requestParameters.authenticationFlowRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update an authentication flow - */ - async realmAuthenticationFlowsIdPut(requestParameters: RealmAuthenticationFlowsIdPutRequest): Promise { - await this.realmAuthenticationFlowsIdPutRaw(requestParameters); - } - - /** - * Create a new authentication flow - */ - async realmAuthenticationFlowsPostRaw(requestParameters: RealmAuthenticationFlowsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFlowsPost.'); - } - - if (requestParameters.authenticationFlowRepresentation === null || requestParameters.authenticationFlowRepresentation === undefined) { - throw new runtime.RequiredError('authenticationFlowRepresentation','Required parameter requestParameters.authenticationFlowRepresentation was null or undefined when calling realmAuthenticationFlowsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/flows`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: AuthenticationFlowRepresentationToJSON(requestParameters.authenticationFlowRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new authentication flow - */ - async realmAuthenticationFlowsPost(requestParameters: RealmAuthenticationFlowsPostRequest): Promise { - await this.realmAuthenticationFlowsPostRaw(requestParameters); - } - - /** - * Get form action providers Returns a stream of form action providers. - */ - async realmAuthenticationFormActionProvidersGetRaw(requestParameters: RealmAuthenticationFormActionProvidersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFormActionProvidersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/form-action-providers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get form action providers Returns a stream of form action providers. - */ - async realmAuthenticationFormActionProvidersGet(requestParameters: RealmAuthenticationFormActionProvidersGetRequest): Promise> { - const response = await this.realmAuthenticationFormActionProvidersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get form providers Returns a stream of form providers. - */ - async realmAuthenticationFormProvidersGetRaw(requestParameters: RealmAuthenticationFormProvidersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationFormProvidersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/form-providers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get form providers Returns a stream of form providers. - */ - async realmAuthenticationFormProvidersGet(requestParameters: RealmAuthenticationFormProvidersGetRequest): Promise> { - const response = await this.realmAuthenticationFormProvidersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get configuration descriptions for all clients - */ - async realmAuthenticationPerClientConfigDescriptionGetRaw(requestParameters: RealmAuthenticationPerClientConfigDescriptionGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationPerClientConfigDescriptionGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/per-client-config-description`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get configuration descriptions for all clients - */ - async realmAuthenticationPerClientConfigDescriptionGet(requestParameters: RealmAuthenticationPerClientConfigDescriptionGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmAuthenticationPerClientConfigDescriptionGetRaw(requestParameters); - return await response.value(); - } - - /** - * Register a new required actions - */ - async realmAuthenticationRegisterRequiredActionPostRaw(requestParameters: RealmAuthenticationRegisterRequiredActionPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRegisterRequiredActionPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmAuthenticationRegisterRequiredActionPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/register-required-action`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Register a new required actions - */ - async realmAuthenticationRegisterRequiredActionPost(requestParameters: RealmAuthenticationRegisterRequiredActionPostRequest): Promise { - await this.realmAuthenticationRegisterRequiredActionPostRaw(requestParameters); - } - - /** - * Delete required action - */ - async realmAuthenticationRequiredActionsAliasDeleteRaw(requestParameters: RealmAuthenticationRequiredActionsAliasDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsAliasDelete.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmAuthenticationRequiredActionsAliasDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete required action - */ - async realmAuthenticationRequiredActionsAliasDelete(requestParameters: RealmAuthenticationRequiredActionsAliasDeleteRequest): Promise { - await this.realmAuthenticationRequiredActionsAliasDeleteRaw(requestParameters); - } - - /** - * Get required action for alias - */ - async realmAuthenticationRequiredActionsAliasGetRaw(requestParameters: RealmAuthenticationRequiredActionsAliasGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsAliasGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmAuthenticationRequiredActionsAliasGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RequiredActionProviderRepresentationFromJSON(jsonValue)); - } - - /** - * Get required action for alias - */ - async realmAuthenticationRequiredActionsAliasGet(requestParameters: RealmAuthenticationRequiredActionsAliasGetRequest): Promise { - const response = await this.realmAuthenticationRequiredActionsAliasGetRaw(requestParameters); - return await response.value(); - } - - /** - * Lower required action’s priority - */ - async realmAuthenticationRequiredActionsAliasLowerPriorityPostRaw(requestParameters: RealmAuthenticationRequiredActionsAliasLowerPriorityPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsAliasLowerPriorityPost.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmAuthenticationRequiredActionsAliasLowerPriorityPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions/{alias}/lower-priority`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Lower required action’s priority - */ - async realmAuthenticationRequiredActionsAliasLowerPriorityPost(requestParameters: RealmAuthenticationRequiredActionsAliasLowerPriorityPostRequest): Promise { - await this.realmAuthenticationRequiredActionsAliasLowerPriorityPostRaw(requestParameters); - } - - /** - * Update required action - */ - async realmAuthenticationRequiredActionsAliasPutRaw(requestParameters: RealmAuthenticationRequiredActionsAliasPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsAliasPut.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmAuthenticationRequiredActionsAliasPut.'); - } - - if (requestParameters.requiredActionProviderRepresentation === null || requestParameters.requiredActionProviderRepresentation === undefined) { - throw new runtime.RequiredError('requiredActionProviderRepresentation','Required parameter requestParameters.requiredActionProviderRepresentation was null or undefined when calling realmAuthenticationRequiredActionsAliasPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RequiredActionProviderRepresentationToJSON(requestParameters.requiredActionProviderRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update required action - */ - async realmAuthenticationRequiredActionsAliasPut(requestParameters: RealmAuthenticationRequiredActionsAliasPutRequest): Promise { - await this.realmAuthenticationRequiredActionsAliasPutRaw(requestParameters); - } - - /** - * Raise required action’s priority - */ - async realmAuthenticationRequiredActionsAliasRaisePriorityPostRaw(requestParameters: RealmAuthenticationRequiredActionsAliasRaisePriorityPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsAliasRaisePriorityPost.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmAuthenticationRequiredActionsAliasRaisePriorityPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions/{alias}/raise-priority`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Raise required action’s priority - */ - async realmAuthenticationRequiredActionsAliasRaisePriorityPost(requestParameters: RealmAuthenticationRequiredActionsAliasRaisePriorityPostRequest): Promise { - await this.realmAuthenticationRequiredActionsAliasRaisePriorityPostRaw(requestParameters); - } - - /** - * Get required actions Returns a stream of required actions. - */ - async realmAuthenticationRequiredActionsGetRaw(requestParameters: RealmAuthenticationRequiredActionsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationRequiredActionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/required-actions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get required actions Returns a stream of required actions. - */ - async realmAuthenticationRequiredActionsGet(requestParameters: RealmAuthenticationRequiredActionsGetRequest): Promise> { - const response = await this.realmAuthenticationRequiredActionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get unregistered required actions Returns a stream of unregistered required actions. - */ - async realmAuthenticationUnregisteredRequiredActionsGetRaw(requestParameters: RealmAuthenticationUnregisteredRequiredActionsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAuthenticationUnregisteredRequiredActionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/authentication/unregistered-required-actions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get unregistered required actions Returns a stream of unregistered required actions. - */ - async realmAuthenticationUnregisteredRequiredActionsGet(requestParameters: RealmAuthenticationUnregisteredRequiredActionsGetRequest): Promise> { - const response = await this.realmAuthenticationUnregisteredRequiredActionsGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientAttributeCertificateApi.ts b/backend/keycloak/kc-client/apis/ClientAttributeCertificateApi.ts deleted file mode 100644 index 6e96eed..0000000 --- a/backend/keycloak/kc-client/apis/ClientAttributeCertificateApi.ts +++ /dev/null @@ -1,359 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - CertificateRepresentation, - CertificateRepresentationFromJSON, - CertificateRepresentationToJSON, - KeyStoreConfig, - KeyStoreConfigFromJSON, - KeyStoreConfigToJSON, -} from '../models'; - -export interface RealmClientsIdCertificatesAttrDownloadPostRequest { - realm: string; - id: string; - attr: string; - keyStoreConfig: KeyStoreConfig; -} - -export interface RealmClientsIdCertificatesAttrGenerateAndDownloadPostRequest { - realm: string; - id: string; - attr: string; - keyStoreConfig: KeyStoreConfig; -} - -export interface RealmClientsIdCertificatesAttrGeneratePostRequest { - realm: string; - id: string; - attr: string; -} - -export interface RealmClientsIdCertificatesAttrGetRequest { - realm: string; - id: string; - attr: string; -} - -export interface RealmClientsIdCertificatesAttrUploadCertificatePostRequest { - realm: string; - id: string; - attr: string; -} - -export interface RealmClientsIdCertificatesAttrUploadPostRequest { - realm: string; - id: string; - attr: string; -} - -/** - * - */ -export class ClientAttributeCertificateApi extends runtime.BaseAPI { - - /** - * Get a keystore file for the client, containing private key and public certificate - */ - async realmClientsIdCertificatesAttrDownloadPostRaw(requestParameters: RealmClientsIdCertificatesAttrDownloadPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrDownloadPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrDownloadPost.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrDownloadPost.'); - } - - if (requestParameters.keyStoreConfig === null || requestParameters.keyStoreConfig === undefined) { - throw new runtime.RequiredError('keyStoreConfig','Required parameter requestParameters.keyStoreConfig was null or undefined when calling realmClientsIdCertificatesAttrDownloadPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}/download`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: KeyStoreConfigToJSON(requestParameters.keyStoreConfig), - }); - - return new runtime.TextApiResponse(response) as any; - } - - /** - * Get a keystore file for the client, containing private key and public certificate - */ - async realmClientsIdCertificatesAttrDownloadPost(requestParameters: RealmClientsIdCertificatesAttrDownloadPostRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrDownloadPostRaw(requestParameters); - return await response.value(); - } - - /** - * Generate a new keypair and certificate, and get the private key file Generates a keypair and certificate and serves the private key in a specified keystore format. - */ - async realmClientsIdCertificatesAttrGenerateAndDownloadPostRaw(requestParameters: RealmClientsIdCertificatesAttrGenerateAndDownloadPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrGenerateAndDownloadPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrGenerateAndDownloadPost.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrGenerateAndDownloadPost.'); - } - - if (requestParameters.keyStoreConfig === null || requestParameters.keyStoreConfig === undefined) { - throw new runtime.RequiredError('keyStoreConfig','Required parameter requestParameters.keyStoreConfig was null or undefined when calling realmClientsIdCertificatesAttrGenerateAndDownloadPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}/generate-and-download`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: KeyStoreConfigToJSON(requestParameters.keyStoreConfig), - }); - - return new runtime.TextApiResponse(response) as any; - } - - /** - * Generate a new keypair and certificate, and get the private key file Generates a keypair and certificate and serves the private key in a specified keystore format. - */ - async realmClientsIdCertificatesAttrGenerateAndDownloadPost(requestParameters: RealmClientsIdCertificatesAttrGenerateAndDownloadPostRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrGenerateAndDownloadPostRaw(requestParameters); - return await response.value(); - } - - /** - * Generate a new certificate with new key pair - */ - async realmClientsIdCertificatesAttrGeneratePostRaw(requestParameters: RealmClientsIdCertificatesAttrGeneratePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrGeneratePost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrGeneratePost.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrGeneratePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}/generate`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CertificateRepresentationFromJSON(jsonValue)); - } - - /** - * Generate a new certificate with new key pair - */ - async realmClientsIdCertificatesAttrGeneratePost(requestParameters: RealmClientsIdCertificatesAttrGeneratePostRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrGeneratePostRaw(requestParameters); - return await response.value(); - } - - /** - * Get key info - */ - async realmClientsIdCertificatesAttrGetRaw(requestParameters: RealmClientsIdCertificatesAttrGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrGet.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CertificateRepresentationFromJSON(jsonValue)); - } - - /** - * Get key info - */ - async realmClientsIdCertificatesAttrGet(requestParameters: RealmClientsIdCertificatesAttrGetRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrGetRaw(requestParameters); - return await response.value(); - } - - /** - * Upload only certificate, not private key - */ - async realmClientsIdCertificatesAttrUploadCertificatePostRaw(requestParameters: RealmClientsIdCertificatesAttrUploadCertificatePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrUploadCertificatePost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrUploadCertificatePost.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrUploadCertificatePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}/upload-certificate`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CertificateRepresentationFromJSON(jsonValue)); - } - - /** - * Upload only certificate, not private key - */ - async realmClientsIdCertificatesAttrUploadCertificatePost(requestParameters: RealmClientsIdCertificatesAttrUploadCertificatePostRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrUploadCertificatePostRaw(requestParameters); - return await response.value(); - } - - /** - * Upload certificate and eventually private key - */ - async realmClientsIdCertificatesAttrUploadPostRaw(requestParameters: RealmClientsIdCertificatesAttrUploadPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdCertificatesAttrUploadPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdCertificatesAttrUploadPost.'); - } - - if (requestParameters.attr === null || requestParameters.attr === undefined) { - throw new runtime.RequiredError('attr','Required parameter requestParameters.attr was null or undefined when calling realmClientsIdCertificatesAttrUploadPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/certificates/{attr}/upload`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"attr"}}`, encodeURIComponent(String(requestParameters.attr))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CertificateRepresentationFromJSON(jsonValue)); - } - - /** - * Upload certificate and eventually private key - */ - async realmClientsIdCertificatesAttrUploadPost(requestParameters: RealmClientsIdCertificatesAttrUploadPostRequest): Promise { - const response = await this.realmClientsIdCertificatesAttrUploadPostRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientInitialAccessApi.ts b/backend/keycloak/kc-client/apis/ClientInitialAccessApi.ts deleted file mode 100644 index ff620d5..0000000 --- a/backend/keycloak/kc-client/apis/ClientInitialAccessApi.ts +++ /dev/null @@ -1,165 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ClientInitialAccessCreatePresentation, - ClientInitialAccessCreatePresentationFromJSON, - ClientInitialAccessCreatePresentationToJSON, - ClientInitialAccessPresentation, - ClientInitialAccessPresentationFromJSON, - ClientInitialAccessPresentationToJSON, -} from '../models'; - -export interface RealmClientsInitialAccessGetRequest { - realm: string; -} - -export interface RealmClientsInitialAccessIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmClientsInitialAccessPostRequest { - realm: string; - clientInitialAccessCreatePresentation: ClientInitialAccessCreatePresentation; -} - -/** - * - */ -export class ClientInitialAccessApi extends runtime.BaseAPI { - - /** - */ - async realmClientsInitialAccessGetRaw(requestParameters: RealmClientsInitialAccessGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsInitialAccessGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients-initial-access`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmClientsInitialAccessGet(requestParameters: RealmClientsInitialAccessGetRequest): Promise> { - const response = await this.realmClientsInitialAccessGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientsInitialAccessIdDeleteRaw(requestParameters: RealmClientsInitialAccessIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsInitialAccessIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsInitialAccessIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients-initial-access/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsInitialAccessIdDelete(requestParameters: RealmClientsInitialAccessIdDeleteRequest): Promise { - await this.realmClientsInitialAccessIdDeleteRaw(requestParameters); - } - - /** - * Create a new initial access token. - */ - async realmClientsInitialAccessPostRaw(requestParameters: RealmClientsInitialAccessPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsInitialAccessPost.'); - } - - if (requestParameters.clientInitialAccessCreatePresentation === null || requestParameters.clientInitialAccessCreatePresentation === undefined) { - throw new runtime.RequiredError('clientInitialAccessCreatePresentation','Required parameter requestParameters.clientInitialAccessCreatePresentation was null or undefined when calling realmClientsInitialAccessPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients-initial-access`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ClientInitialAccessCreatePresentationToJSON(requestParameters.clientInitialAccessCreatePresentation), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientInitialAccessPresentationFromJSON(jsonValue)); - } - - /** - * Create a new initial access token. - */ - async realmClientsInitialAccessPost(requestParameters: RealmClientsInitialAccessPostRequest): Promise { - const response = await this.realmClientsInitialAccessPostRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientRegistrationPolicyApi.ts b/backend/keycloak/kc-client/apis/ClientRegistrationPolicyApi.ts deleted file mode 100644 index 5fd3959..0000000 --- a/backend/keycloak/kc-client/apis/ClientRegistrationPolicyApi.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; - -export interface RealmClientRegistrationPolicyProvidersGetRequest { - realm: string; -} - -/** - * - */ -export class ClientRegistrationPolicyApi extends runtime.BaseAPI { - - /** - * Base path for retrieve providers with the configProperties properly filled - */ - async realmClientRegistrationPolicyProvidersGetRaw(requestParameters: RealmClientRegistrationPolicyProvidersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientRegistrationPolicyProvidersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-registration-policy/providers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Base path for retrieve providers with the configProperties properly filled - */ - async realmClientRegistrationPolicyProvidersGet(requestParameters: RealmClientRegistrationPolicyProvidersGetRequest): Promise> { - const response = await this.realmClientRegistrationPolicyProvidersGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientRoleMappingsApi.ts b/backend/keycloak/kc-client/apis/ClientRoleMappingsApi.ts deleted file mode 100644 index 03be047..0000000 --- a/backend/keycloak/kc-client/apis/ClientRoleMappingsApi.ts +++ /dev/null @@ -1,586 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationToJSON, -} from '../models'; - -export interface RealmGroupsIdRoleMappingsClientsClientAvailableGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmGroupsIdRoleMappingsClientsClientCompositeGetRequest { - realm: string; - id: string; - client: string; - briefRepresentation?: boolean; -} - -export interface RealmGroupsIdRoleMappingsClientsClientDeleteRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmGroupsIdRoleMappingsClientsClientGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmGroupsIdRoleMappingsClientsClientPostRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmUsersIdRoleMappingsClientsClientAvailableGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmUsersIdRoleMappingsClientsClientCompositeGetRequest { - realm: string; - id: string; - client: string; - briefRepresentation?: boolean; -} - -export interface RealmUsersIdRoleMappingsClientsClientDeleteRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmUsersIdRoleMappingsClientsClientGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmUsersIdRoleMappingsClientsClientPostRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -/** - * - */ -export class ClientRoleMappingsApi extends runtime.BaseAPI { - - /** - * Get available client-level roles that can be mapped to the user - */ - async realmGroupsIdRoleMappingsClientsClientAvailableGetRaw(requestParameters: RealmGroupsIdRoleMappingsClientsClientAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmGroupsIdRoleMappingsClientsClientAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/clients/{client}/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get available client-level roles that can be mapped to the user - */ - async realmGroupsIdRoleMappingsClientsClientAvailableGet(requestParameters: RealmGroupsIdRoleMappingsClientsClientAvailableGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsClientsClientAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective client-level role mappings This recurses any composite roles - */ - async realmGroupsIdRoleMappingsClientsClientCompositeGetRaw(requestParameters: RealmGroupsIdRoleMappingsClientsClientCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmGroupsIdRoleMappingsClientsClientCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/clients/{client}/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective client-level role mappings This recurses any composite roles - */ - async realmGroupsIdRoleMappingsClientsClientCompositeGet(requestParameters: RealmGroupsIdRoleMappingsClientsClientCompositeGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsClientsClientCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete client-level roles from user role mapping - */ - async realmGroupsIdRoleMappingsClientsClientDeleteRaw(requestParameters: RealmGroupsIdRoleMappingsClientsClientDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmGroupsIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmGroupsIdRoleMappingsClientsClientDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete client-level roles from user role mapping - */ - async realmGroupsIdRoleMappingsClientsClientDelete(requestParameters: RealmGroupsIdRoleMappingsClientsClientDeleteRequest): Promise { - await this.realmGroupsIdRoleMappingsClientsClientDeleteRaw(requestParameters); - } - - /** - * Get client-level role mappings for the user, and the app - */ - async realmGroupsIdRoleMappingsClientsClientGetRaw(requestParameters: RealmGroupsIdRoleMappingsClientsClientGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsClientsClientGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsClientsClientGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmGroupsIdRoleMappingsClientsClientGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client-level role mappings for the user, and the app - */ - async realmGroupsIdRoleMappingsClientsClientGet(requestParameters: RealmGroupsIdRoleMappingsClientsClientGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsClientsClientGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add client-level roles to the user role mapping - */ - async realmGroupsIdRoleMappingsClientsClientPostRaw(requestParameters: RealmGroupsIdRoleMappingsClientsClientPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmGroupsIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmGroupsIdRoleMappingsClientsClientPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add client-level roles to the user role mapping - */ - async realmGroupsIdRoleMappingsClientsClientPost(requestParameters: RealmGroupsIdRoleMappingsClientsClientPostRequest): Promise { - await this.realmGroupsIdRoleMappingsClientsClientPostRaw(requestParameters); - } - - /** - * Get available client-level roles that can be mapped to the user - */ - async realmUsersIdRoleMappingsClientsClientAvailableGetRaw(requestParameters: RealmUsersIdRoleMappingsClientsClientAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdRoleMappingsClientsClientAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/clients/{client}/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get available client-level roles that can be mapped to the user - */ - async realmUsersIdRoleMappingsClientsClientAvailableGet(requestParameters: RealmUsersIdRoleMappingsClientsClientAvailableGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsClientsClientAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective client-level role mappings This recurses any composite roles - */ - async realmUsersIdRoleMappingsClientsClientCompositeGetRaw(requestParameters: RealmUsersIdRoleMappingsClientsClientCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdRoleMappingsClientsClientCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/clients/{client}/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective client-level role mappings This recurses any composite roles - */ - async realmUsersIdRoleMappingsClientsClientCompositeGet(requestParameters: RealmUsersIdRoleMappingsClientsClientCompositeGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsClientsClientCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete client-level roles from user role mapping - */ - async realmUsersIdRoleMappingsClientsClientDeleteRaw(requestParameters: RealmUsersIdRoleMappingsClientsClientDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdRoleMappingsClientsClientDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmUsersIdRoleMappingsClientsClientDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete client-level roles from user role mapping - */ - async realmUsersIdRoleMappingsClientsClientDelete(requestParameters: RealmUsersIdRoleMappingsClientsClientDeleteRequest): Promise { - await this.realmUsersIdRoleMappingsClientsClientDeleteRaw(requestParameters); - } - - /** - * Get client-level role mappings for the user, and the app - */ - async realmUsersIdRoleMappingsClientsClientGetRaw(requestParameters: RealmUsersIdRoleMappingsClientsClientGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsClientsClientGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsClientsClientGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdRoleMappingsClientsClientGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client-level role mappings for the user, and the app - */ - async realmUsersIdRoleMappingsClientsClientGet(requestParameters: RealmUsersIdRoleMappingsClientsClientGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsClientsClientGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add client-level roles to the user role mapping - */ - async realmUsersIdRoleMappingsClientsClientPostRaw(requestParameters: RealmUsersIdRoleMappingsClientsClientPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdRoleMappingsClientsClientPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmUsersIdRoleMappingsClientsClientPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add client-level roles to the user role mapping - */ - async realmUsersIdRoleMappingsClientsClientPost(requestParameters: RealmUsersIdRoleMappingsClientsClientPostRequest): Promise { - await this.realmUsersIdRoleMappingsClientsClientPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientScopesApi.ts b/backend/keycloak/kc-client/apis/ClientScopesApi.ts deleted file mode 100644 index 3a132d0..0000000 --- a/backend/keycloak/kc-client/apis/ClientScopesApi.ts +++ /dev/null @@ -1,266 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ClientScopeRepresentation, - ClientScopeRepresentationFromJSON, - ClientScopeRepresentationToJSON, -} from '../models'; - -export interface RealmClientScopesGetRequest { - realm: string; -} - -export interface RealmClientScopesIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmClientScopesIdGetRequest { - realm: string; - id: string; -} - -export interface RealmClientScopesIdPutRequest { - realm: string; - id: string; - clientScopeRepresentation: ClientScopeRepresentation; -} - -export interface RealmClientScopesPostRequest { - realm: string; - clientScopeRepresentation: ClientScopeRepresentation; -} - -/** - * - */ -export class ClientScopesApi extends runtime.BaseAPI { - - /** - * Get client scopes belonging to the realm Returns a list of client scopes belonging to the realm - */ - async realmClientScopesGetRaw(requestParameters: RealmClientScopesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client scopes belonging to the realm Returns a list of client scopes belonging to the realm - */ - async realmClientScopesGet(requestParameters: RealmClientScopesGetRequest): Promise> { - const response = await this.realmClientScopesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the client scope - */ - async realmClientScopesIdDeleteRaw(requestParameters: RealmClientScopesIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the client scope - */ - async realmClientScopesIdDelete(requestParameters: RealmClientScopesIdDeleteRequest): Promise { - await this.realmClientScopesIdDeleteRaw(requestParameters); - } - - /** - * Get representation of the client scope - */ - async realmClientScopesIdGetRaw(requestParameters: RealmClientScopesIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientScopeRepresentationFromJSON(jsonValue)); - } - - /** - * Get representation of the client scope - */ - async realmClientScopesIdGet(requestParameters: RealmClientScopesIdGetRequest): Promise { - const response = await this.realmClientScopesIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update the client scope - */ - async realmClientScopesIdPutRaw(requestParameters: RealmClientScopesIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdPut.'); - } - - if (requestParameters.clientScopeRepresentation === null || requestParameters.clientScopeRepresentation === undefined) { - throw new runtime.RequiredError('clientScopeRepresentation','Required parameter requestParameters.clientScopeRepresentation was null or undefined when calling realmClientScopesIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ClientScopeRepresentationToJSON(requestParameters.clientScopeRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the client scope - */ - async realmClientScopesIdPut(requestParameters: RealmClientScopesIdPutRequest): Promise { - await this.realmClientScopesIdPutRaw(requestParameters); - } - - /** - * Create a new client scope Client Scope’s name must be unique! - */ - async realmClientScopesPostRaw(requestParameters: RealmClientScopesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesPost.'); - } - - if (requestParameters.clientScopeRepresentation === null || requestParameters.clientScopeRepresentation === undefined) { - throw new runtime.RequiredError('clientScopeRepresentation','Required parameter requestParameters.clientScopeRepresentation was null or undefined when calling realmClientScopesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ClientScopeRepresentationToJSON(requestParameters.clientScopeRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new client scope Client Scope’s name must be unique! - */ - async realmClientScopesPost(requestParameters: RealmClientScopesPostRequest): Promise { - await this.realmClientScopesPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/ClientsApi.ts b/backend/keycloak/kc-client/apis/ClientsApi.ts deleted file mode 100644 index f20d359..0000000 --- a/backend/keycloak/kc-client/apis/ClientsApi.ts +++ /dev/null @@ -1,1780 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - AccessToken, - AccessTokenFromJSON, - AccessTokenToJSON, - ClientRepresentation, - ClientRepresentationFromJSON, - ClientRepresentationToJSON, - CredentialRepresentation, - CredentialRepresentationFromJSON, - CredentialRepresentationToJSON, - GlobalRequestResult, - GlobalRequestResultFromJSON, - GlobalRequestResultToJSON, - IDToken, - IDTokenFromJSON, - IDTokenToJSON, - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, - UserRepresentation, - UserRepresentationFromJSON, - UserRepresentationToJSON, -} from '../models'; - -export interface RealmClientsGetRequest { - realm: string; - clientId?: string; - first?: number; - max?: number; - q?: string; - search?: boolean; - viewableOnly?: boolean; -} - -export interface RealmClientsIdClientSecretGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdClientSecretPostRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdClientSecretRotatedDeleteRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdClientSecretRotatedGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdDefaultClientScopesClientScopeIdDeleteRequest { - realm: string; - id: string; - clientScopeId: string; -} - -export interface RealmClientsIdDefaultClientScopesClientScopeIdPutRequest { - realm: string; - id: string; - clientScopeId: string; -} - -export interface RealmClientsIdDefaultClientScopesGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdEvaluateScopesGenerateExampleAccessTokenGetRequest { - realm: string; - id: string; - scope?: string; - userId?: string; -} - -export interface RealmClientsIdEvaluateScopesGenerateExampleIdTokenGetRequest { - realm: string; - id: string; - scope?: string; - userId?: string; -} - -export interface RealmClientsIdEvaluateScopesGenerateExampleUserinfoGetRequest { - realm: string; - id: string; - scope?: string; - userId?: string; -} - -export interface RealmClientsIdEvaluateScopesProtocolMappersGetRequest { - realm: string; - id: string; - scope?: string; -} - -export interface RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGetRequest { - realm: string; - id: string; - roleContainerId: string; - scope?: string; -} - -export interface RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGetRequest { - realm: string; - id: string; - roleContainerId: string; - scope?: string; -} - -export interface RealmClientsIdGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdInstallationProvidersProviderIdGetRequest { - realm: string; - id: string; - providerId: string; -} - -export interface RealmClientsIdManagementPermissionsGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdManagementPermissionsPutRequest { - realm: string; - id: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmClientsIdNodesNodeDeleteRequest { - realm: string; - id: string; - node: string; -} - -export interface RealmClientsIdNodesPostRequest { - realm: string; - id: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmClientsIdOfflineSessionCountGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdOfflineSessionsGetRequest { - realm: string; - id: string; - first?: number; - max?: number; -} - -export interface RealmClientsIdOptionalClientScopesClientScopeIdDeleteRequest { - realm: string; - id: string; - clientScopeId: string; -} - -export interface RealmClientsIdOptionalClientScopesClientScopeIdPutRequest { - realm: string; - id: string; - clientScopeId: string; -} - -export interface RealmClientsIdOptionalClientScopesGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdPushRevocationPostRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdPutRequest { - realm: string; - id: string; - clientRepresentation: ClientRepresentation; -} - -export interface RealmClientsIdRegistrationAccessTokenPostRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdServiceAccountUserGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdSessionCountGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdTestNodesAvailableGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdUserSessionsGetRequest { - realm: string; - id: string; - first?: number; - max?: number; -} - -export interface RealmClientsPostRequest { - realm: string; - clientRepresentation: ClientRepresentation; -} - -/** - * - */ -export class ClientsApi extends runtime.BaseAPI { - - /** - * Get clients belonging to the realm. - */ - async realmClientsGetRaw(requestParameters: RealmClientsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.clientId !== undefined) { - queryParameters['clientId'] = requestParameters.clientId; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.q !== undefined) { - queryParameters['q'] = requestParameters.q; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - if (requestParameters.viewableOnly !== undefined) { - queryParameters['viewableOnly'] = requestParameters.viewableOnly; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get clients belonging to the realm. - */ - async realmClientsGet(requestParameters: RealmClientsGetRequest): Promise> { - const response = await this.realmClientsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get the client secret - */ - async realmClientsIdClientSecretGetRaw(requestParameters: RealmClientsIdClientSecretGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdClientSecretGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdClientSecretGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/client-secret`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CredentialRepresentationFromJSON(jsonValue)); - } - - /** - * Get the client secret - */ - async realmClientsIdClientSecretGet(requestParameters: RealmClientsIdClientSecretGetRequest): Promise { - const response = await this.realmClientsIdClientSecretGetRaw(requestParameters); - return await response.value(); - } - - /** - * Generate a new secret for the client - */ - async realmClientsIdClientSecretPostRaw(requestParameters: RealmClientsIdClientSecretPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdClientSecretPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdClientSecretPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/client-secret`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CredentialRepresentationFromJSON(jsonValue)); - } - - /** - * Generate a new secret for the client - */ - async realmClientsIdClientSecretPost(requestParameters: RealmClientsIdClientSecretPostRequest): Promise { - const response = await this.realmClientsIdClientSecretPostRaw(requestParameters); - return await response.value(); - } - - /** - * Invalidate the rotated secret for the client - */ - async realmClientsIdClientSecretRotatedDeleteRaw(requestParameters: RealmClientsIdClientSecretRotatedDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdClientSecretRotatedDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdClientSecretRotatedDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/client-secret/rotated`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Invalidate the rotated secret for the client - */ - async realmClientsIdClientSecretRotatedDelete(requestParameters: RealmClientsIdClientSecretRotatedDeleteRequest): Promise { - await this.realmClientsIdClientSecretRotatedDeleteRaw(requestParameters); - } - - /** - * Get the rotated client secret - */ - async realmClientsIdClientSecretRotatedGetRaw(requestParameters: RealmClientsIdClientSecretRotatedGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdClientSecretRotatedGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdClientSecretRotatedGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/client-secret/rotated`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => CredentialRepresentationFromJSON(jsonValue)); - } - - /** - * Get the rotated client secret - */ - async realmClientsIdClientSecretRotatedGet(requestParameters: RealmClientsIdClientSecretRotatedGetRequest): Promise { - const response = await this.realmClientsIdClientSecretRotatedGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientsIdDefaultClientScopesClientScopeIdDeleteRaw(requestParameters: RealmClientsIdDefaultClientScopesClientScopeIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/default-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsIdDefaultClientScopesClientScopeIdDelete(requestParameters: RealmClientsIdDefaultClientScopesClientScopeIdDeleteRequest): Promise { - await this.realmClientsIdDefaultClientScopesClientScopeIdDeleteRaw(requestParameters); - } - - /** - */ - async realmClientsIdDefaultClientScopesClientScopeIdPutRaw(requestParameters: RealmClientsIdDefaultClientScopesClientScopeIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdPut.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmClientsIdDefaultClientScopesClientScopeIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/default-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsIdDefaultClientScopesClientScopeIdPut(requestParameters: RealmClientsIdDefaultClientScopesClientScopeIdPutRequest): Promise { - await this.realmClientsIdDefaultClientScopesClientScopeIdPutRaw(requestParameters); - } - - /** - * Get default client scopes. - */ - async realmClientsIdDefaultClientScopesGetRaw(requestParameters: RealmClientsIdDefaultClientScopesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdDefaultClientScopesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdDefaultClientScopesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/default-client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get default client scopes. - */ - async realmClientsIdDefaultClientScopesGet(requestParameters: RealmClientsIdDefaultClientScopesGetRequest): Promise> { - const response = await this.realmClientsIdDefaultClientScopesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the client - */ - async realmClientsIdDeleteRaw(requestParameters: RealmClientsIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the client - */ - async realmClientsIdDelete(requestParameters: RealmClientsIdDeleteRequest): Promise { - await this.realmClientsIdDeleteRaw(requestParameters); - } - - /** - * Create JSON with payload of example access token - */ - async realmClientsIdEvaluateScopesGenerateExampleAccessTokenGetRaw(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleAccessTokenGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleAccessTokenGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleAccessTokenGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - if (requestParameters.userId !== undefined) { - queryParameters['userId'] = requestParameters.userId; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/generate-example-access-token`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => AccessTokenFromJSON(jsonValue)); - } - - /** - * Create JSON with payload of example access token - */ - async realmClientsIdEvaluateScopesGenerateExampleAccessTokenGet(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleAccessTokenGetRequest): Promise { - const response = await this.realmClientsIdEvaluateScopesGenerateExampleAccessTokenGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create JSON with payload of example id token - */ - async realmClientsIdEvaluateScopesGenerateExampleIdTokenGetRaw(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleIdTokenGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleIdTokenGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleIdTokenGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - if (requestParameters.userId !== undefined) { - queryParameters['userId'] = requestParameters.userId; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/generate-example-id-token`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => IDTokenFromJSON(jsonValue)); - } - - /** - * Create JSON with payload of example id token - */ - async realmClientsIdEvaluateScopesGenerateExampleIdTokenGet(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleIdTokenGetRequest): Promise { - const response = await this.realmClientsIdEvaluateScopesGenerateExampleIdTokenGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create JSON with payload of example user info - */ - async realmClientsIdEvaluateScopesGenerateExampleUserinfoGetRaw(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleUserinfoGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleUserinfoGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesGenerateExampleUserinfoGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - if (requestParameters.userId !== undefined) { - queryParameters['userId'] = requestParameters.userId; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/generate-example-userinfo`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Create JSON with payload of example user info - */ - async realmClientsIdEvaluateScopesGenerateExampleUserinfoGet(requestParameters: RealmClientsIdEvaluateScopesGenerateExampleUserinfoGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmClientsIdEvaluateScopesGenerateExampleUserinfoGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return list of all protocol mappers, which will be used when generating tokens issued for particular client. - */ - async realmClientsIdEvaluateScopesProtocolMappersGetRaw(requestParameters: RealmClientsIdEvaluateScopesProtocolMappersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesProtocolMappersGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesProtocolMappersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/protocol-mappers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Return list of all protocol mappers, which will be used when generating tokens issued for particular client. - */ - async realmClientsIdEvaluateScopesProtocolMappersGet(requestParameters: RealmClientsIdEvaluateScopesProtocolMappersGetRequest): Promise> { - const response = await this.realmClientsIdEvaluateScopesProtocolMappersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective scope mapping of all roles of particular role container, which this client is defacto allowed to have in the accessToken issued for him. - */ - async realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGetRaw(requestParameters: RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGet.'); - } - - if (requestParameters.roleContainerId === null || requestParameters.roleContainerId === undefined) { - throw new runtime.RequiredError('roleContainerId','Required parameter requestParameters.roleContainerId was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/granted`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"roleContainerId"}}`, encodeURIComponent(String(requestParameters.roleContainerId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective scope mapping of all roles of particular role container, which this client is defacto allowed to have in the accessToken issued for him. - */ - async realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGet(requestParameters: RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGetRequest): Promise> { - const response = await this.realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdGrantedGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get roles, which this client doesn’t have scope for and can’t have them in the accessToken issued for him. - */ - async realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGetRaw(requestParameters: RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGet.'); - } - - if (requestParameters.roleContainerId === null || requestParameters.roleContainerId === undefined) { - throw new runtime.RequiredError('roleContainerId','Required parameter requestParameters.roleContainerId was null or undefined when calling realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.scope !== undefined) { - queryParameters['scope'] = requestParameters.scope; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/not-granted`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"roleContainerId"}}`, encodeURIComponent(String(requestParameters.roleContainerId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get roles, which this client doesn’t have scope for and can’t have them in the accessToken issued for him. - */ - async realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGet(requestParameters: RealmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGetRequest): Promise> { - const response = await this.realmClientsIdEvaluateScopesScopeMappingsRoleContainerIdNotGrantedGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get representation of the client - */ - async realmClientsIdGetRaw(requestParameters: RealmClientsIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientRepresentationFromJSON(jsonValue)); - } - - /** - * Get representation of the client - */ - async realmClientsIdGet(requestParameters: RealmClientsIdGetRequest): Promise { - const response = await this.realmClientsIdGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientsIdInstallationProvidersProviderIdGetRaw(requestParameters: RealmClientsIdInstallationProvidersProviderIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdInstallationProvidersProviderIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdInstallationProvidersProviderIdGet.'); - } - - if (requestParameters.providerId === null || requestParameters.providerId === undefined) { - throw new runtime.RequiredError('providerId','Required parameter requestParameters.providerId was null or undefined when calling realmClientsIdInstallationProvidersProviderIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/installation/providers/{providerId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"providerId"}}`, encodeURIComponent(String(requestParameters.providerId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsIdInstallationProvidersProviderIdGet(requestParameters: RealmClientsIdInstallationProvidersProviderIdGetRequest): Promise { - await this.realmClientsIdInstallationProvidersProviderIdGetRaw(requestParameters); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdManagementPermissionsGetRaw(requestParameters: RealmClientsIdManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdManagementPermissionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdManagementPermissionsGet(requestParameters: RealmClientsIdManagementPermissionsGetRequest): Promise { - const response = await this.realmClientsIdManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdManagementPermissionsPutRaw(requestParameters: RealmClientsIdManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdManagementPermissionsPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmClientsIdManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdManagementPermissionsPut(requestParameters: RealmClientsIdManagementPermissionsPutRequest): Promise { - const response = await this.realmClientsIdManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Unregister a cluster node from the client - */ - async realmClientsIdNodesNodeDeleteRaw(requestParameters: RealmClientsIdNodesNodeDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdNodesNodeDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdNodesNodeDelete.'); - } - - if (requestParameters.node === null || requestParameters.node === undefined) { - throw new runtime.RequiredError('node','Required parameter requestParameters.node was null or undefined when calling realmClientsIdNodesNodeDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/nodes/{node}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"node"}}`, encodeURIComponent(String(requestParameters.node))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Unregister a cluster node from the client - */ - async realmClientsIdNodesNodeDelete(requestParameters: RealmClientsIdNodesNodeDeleteRequest): Promise { - await this.realmClientsIdNodesNodeDeleteRaw(requestParameters); - } - - /** - * Register a cluster node with the client Manually register cluster node to this client - usually it’s not needed to call this directly as adapter should handle by sending registration request to Keycloak - */ - async realmClientsIdNodesPostRaw(requestParameters: RealmClientsIdNodesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdNodesPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdNodesPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmClientsIdNodesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/nodes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Register a cluster node with the client Manually register cluster node to this client - usually it’s not needed to call this directly as adapter should handle by sending registration request to Keycloak - */ - async realmClientsIdNodesPost(requestParameters: RealmClientsIdNodesPostRequest): Promise { - await this.realmClientsIdNodesPostRaw(requestParameters); - } - - /** - * Get application offline session count Returns a number of offline user sessions associated with this client { \"count\": number } - */ - async realmClientsIdOfflineSessionCountGetRaw(requestParameters: RealmClientsIdOfflineSessionCountGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdOfflineSessionCountGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdOfflineSessionCountGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/offline-session-count`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get application offline session count Returns a number of offline user sessions associated with this client { \"count\": number } - */ - async realmClientsIdOfflineSessionCountGet(requestParameters: RealmClientsIdOfflineSessionCountGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmClientsIdOfflineSessionCountGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get offline sessions for client Returns a list of offline user sessions associated with this client - */ - async realmClientsIdOfflineSessionsGetRaw(requestParameters: RealmClientsIdOfflineSessionsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdOfflineSessionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdOfflineSessionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/offline-sessions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get offline sessions for client Returns a list of offline user sessions associated with this client - */ - async realmClientsIdOfflineSessionsGet(requestParameters: RealmClientsIdOfflineSessionsGetRequest): Promise> { - const response = await this.realmClientsIdOfflineSessionsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientsIdOptionalClientScopesClientScopeIdDeleteRaw(requestParameters: RealmClientsIdOptionalClientScopesClientScopeIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/optional-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsIdOptionalClientScopesClientScopeIdDelete(requestParameters: RealmClientsIdOptionalClientScopesClientScopeIdDeleteRequest): Promise { - await this.realmClientsIdOptionalClientScopesClientScopeIdDeleteRaw(requestParameters); - } - - /** - */ - async realmClientsIdOptionalClientScopesClientScopeIdPutRaw(requestParameters: RealmClientsIdOptionalClientScopesClientScopeIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdPut.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmClientsIdOptionalClientScopesClientScopeIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/optional-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientsIdOptionalClientScopesClientScopeIdPut(requestParameters: RealmClientsIdOptionalClientScopesClientScopeIdPutRequest): Promise { - await this.realmClientsIdOptionalClientScopesClientScopeIdPutRaw(requestParameters); - } - - /** - * Get optional client scopes. - */ - async realmClientsIdOptionalClientScopesGetRaw(requestParameters: RealmClientsIdOptionalClientScopesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdOptionalClientScopesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdOptionalClientScopesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/optional-client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get optional client scopes. - */ - async realmClientsIdOptionalClientScopesGet(requestParameters: RealmClientsIdOptionalClientScopesGetRequest): Promise> { - const response = await this.realmClientsIdOptionalClientScopesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Push the client’s revocation policy to its admin URL If the client has an admin URL, push revocation policy to it. - */ - async realmClientsIdPushRevocationPostRaw(requestParameters: RealmClientsIdPushRevocationPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdPushRevocationPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdPushRevocationPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/push-revocation`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => GlobalRequestResultFromJSON(jsonValue)); - } - - /** - * Push the client’s revocation policy to its admin URL If the client has an admin URL, push revocation policy to it. - */ - async realmClientsIdPushRevocationPost(requestParameters: RealmClientsIdPushRevocationPostRequest): Promise { - const response = await this.realmClientsIdPushRevocationPostRaw(requestParameters); - return await response.value(); - } - - /** - * Update the client - */ - async realmClientsIdPutRaw(requestParameters: RealmClientsIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdPut.'); - } - - if (requestParameters.clientRepresentation === null || requestParameters.clientRepresentation === undefined) { - throw new runtime.RequiredError('clientRepresentation','Required parameter requestParameters.clientRepresentation was null or undefined when calling realmClientsIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ClientRepresentationToJSON(requestParameters.clientRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the client - */ - async realmClientsIdPut(requestParameters: RealmClientsIdPutRequest): Promise { - await this.realmClientsIdPutRaw(requestParameters); - } - - /** - * Generate a new registration access token for the client - */ - async realmClientsIdRegistrationAccessTokenPostRaw(requestParameters: RealmClientsIdRegistrationAccessTokenPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRegistrationAccessTokenPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRegistrationAccessTokenPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/registration-access-token`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientRepresentationFromJSON(jsonValue)); - } - - /** - * Generate a new registration access token for the client - */ - async realmClientsIdRegistrationAccessTokenPost(requestParameters: RealmClientsIdRegistrationAccessTokenPostRequest): Promise { - const response = await this.realmClientsIdRegistrationAccessTokenPostRaw(requestParameters); - return await response.value(); - } - - /** - * Get a user dedicated to the service account - */ - async realmClientsIdServiceAccountUserGetRaw(requestParameters: RealmClientsIdServiceAccountUserGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdServiceAccountUserGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdServiceAccountUserGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/service-account-user`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => UserRepresentationFromJSON(jsonValue)); - } - - /** - * Get a user dedicated to the service account - */ - async realmClientsIdServiceAccountUserGet(requestParameters: RealmClientsIdServiceAccountUserGetRequest): Promise { - const response = await this.realmClientsIdServiceAccountUserGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get application session count Returns a number of user sessions associated with this client { \"count\": number } - */ - async realmClientsIdSessionCountGetRaw(requestParameters: RealmClientsIdSessionCountGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdSessionCountGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdSessionCountGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/session-count`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get application session count Returns a number of user sessions associated with this client { \"count\": number } - */ - async realmClientsIdSessionCountGet(requestParameters: RealmClientsIdSessionCountGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmClientsIdSessionCountGetRaw(requestParameters); - return await response.value(); - } - - /** - * Test if registered cluster nodes are available Tests availability by sending \'ping\' request to all cluster nodes. - */ - async realmClientsIdTestNodesAvailableGetRaw(requestParameters: RealmClientsIdTestNodesAvailableGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdTestNodesAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdTestNodesAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/test-nodes-available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => GlobalRequestResultFromJSON(jsonValue)); - } - - /** - * Test if registered cluster nodes are available Tests availability by sending \'ping\' request to all cluster nodes. - */ - async realmClientsIdTestNodesAvailableGet(requestParameters: RealmClientsIdTestNodesAvailableGetRequest): Promise { - const response = await this.realmClientsIdTestNodesAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get user sessions for client Returns a list of user sessions associated with this client - */ - async realmClientsIdUserSessionsGetRaw(requestParameters: RealmClientsIdUserSessionsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdUserSessionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdUserSessionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/user-sessions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get user sessions for client Returns a list of user sessions associated with this client - */ - async realmClientsIdUserSessionsGet(requestParameters: RealmClientsIdUserSessionsGetRequest): Promise> { - const response = await this.realmClientsIdUserSessionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a new client Client’s client_id must be unique! - */ - async realmClientsPostRaw(requestParameters: RealmClientsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsPost.'); - } - - if (requestParameters.clientRepresentation === null || requestParameters.clientRepresentation === undefined) { - throw new runtime.RequiredError('clientRepresentation','Required parameter requestParameters.clientRepresentation was null or undefined when calling realmClientsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ClientRepresentationToJSON(requestParameters.clientRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new client Client’s client_id must be unique! - */ - async realmClientsPost(requestParameters: RealmClientsPostRequest): Promise { - await this.realmClientsPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/ComponentApi.ts b/backend/keycloak/kc-client/apis/ComponentApi.ts deleted file mode 100644 index 09856eb..0000000 --- a/backend/keycloak/kc-client/apis/ComponentApi.ts +++ /dev/null @@ -1,323 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ComponentRepresentation, - ComponentRepresentationFromJSON, - ComponentRepresentationToJSON, -} from '../models'; - -export interface RealmComponentsGetRequest { - realm: string; - name?: string; - parent?: string; - type?: string; -} - -export interface RealmComponentsIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmComponentsIdGetRequest { - realm: string; - id: string; -} - -export interface RealmComponentsIdPutRequest { - realm: string; - id: string; - componentRepresentation: ComponentRepresentation; -} - -export interface RealmComponentsIdSubComponentTypesGetRequest { - realm: string; - id: string; - type?: string; -} - -export interface RealmComponentsPostRequest { - realm: string; - componentRepresentation: ComponentRepresentation; -} - -/** - * - */ -export class ComponentApi extends runtime.BaseAPI { - - /** - */ - async realmComponentsGetRaw(requestParameters: RealmComponentsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.name !== undefined) { - queryParameters['name'] = requestParameters.name; - } - - if (requestParameters.parent !== undefined) { - queryParameters['parent'] = requestParameters.parent; - } - - if (requestParameters.type !== undefined) { - queryParameters['type'] = requestParameters.type; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmComponentsGet(requestParameters: RealmComponentsGetRequest): Promise> { - const response = await this.realmComponentsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmComponentsIdDeleteRaw(requestParameters: RealmComponentsIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmComponentsIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmComponentsIdDelete(requestParameters: RealmComponentsIdDeleteRequest): Promise { - await this.realmComponentsIdDeleteRaw(requestParameters); - } - - /** - */ - async realmComponentsIdGetRaw(requestParameters: RealmComponentsIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmComponentsIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ComponentRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmComponentsIdGet(requestParameters: RealmComponentsIdGetRequest): Promise { - const response = await this.realmComponentsIdGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmComponentsIdPutRaw(requestParameters: RealmComponentsIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmComponentsIdPut.'); - } - - if (requestParameters.componentRepresentation === null || requestParameters.componentRepresentation === undefined) { - throw new runtime.RequiredError('componentRepresentation','Required parameter requestParameters.componentRepresentation was null or undefined when calling realmComponentsIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ComponentRepresentationToJSON(requestParameters.componentRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmComponentsIdPut(requestParameters: RealmComponentsIdPutRequest): Promise { - await this.realmComponentsIdPutRaw(requestParameters); - } - - /** - * List of subcomponent types that are available to configure for a particular parent component. - */ - async realmComponentsIdSubComponentTypesGetRaw(requestParameters: RealmComponentsIdSubComponentTypesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsIdSubComponentTypesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmComponentsIdSubComponentTypesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.type !== undefined) { - queryParameters['type'] = requestParameters.type; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components/{id}/sub-component-types`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * List of subcomponent types that are available to configure for a particular parent component. - */ - async realmComponentsIdSubComponentTypesGet(requestParameters: RealmComponentsIdSubComponentTypesGetRequest): Promise> { - const response = await this.realmComponentsIdSubComponentTypesGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmComponentsPostRaw(requestParameters: RealmComponentsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmComponentsPost.'); - } - - if (requestParameters.componentRepresentation === null || requestParameters.componentRepresentation === undefined) { - throw new runtime.RequiredError('componentRepresentation','Required parameter requestParameters.componentRepresentation was null or undefined when calling realmComponentsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/components`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ComponentRepresentationToJSON(requestParameters.componentRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmComponentsPost(requestParameters: RealmComponentsPostRequest): Promise { - await this.realmComponentsPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/GroupsApi.ts b/backend/keycloak/kc-client/apis/GroupsApi.ts deleted file mode 100644 index 19af73f..0000000 --- a/backend/keycloak/kc-client/apis/GroupsApi.ts +++ /dev/null @@ -1,555 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - GroupRepresentation, - GroupRepresentationFromJSON, - GroupRepresentationToJSON, - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, -} from '../models'; - -export interface RealmGroupsCountGetRequest { - realm: string; - search?: string; - top?: boolean; -} - -export interface RealmGroupsGetRequest { - realm: string; - briefRepresentation?: boolean; - first?: number; - max?: number; - search?: string; -} - -export interface RealmGroupsIdChildrenPostRequest { - realm: string; - id: string; - groupRepresentation: GroupRepresentation; -} - -export interface RealmGroupsIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdGetRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdManagementPermissionsGetRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdManagementPermissionsPutRequest { - realm: string; - id: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmGroupsIdMembersGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; - first?: number; - max?: number; -} - -export interface RealmGroupsIdPutRequest { - realm: string; - id: string; - groupRepresentation: GroupRepresentation; -} - -export interface RealmGroupsPostRequest { - realm: string; - groupRepresentation: GroupRepresentation; -} - -/** - * - */ -export class GroupsApi extends runtime.BaseAPI { - - /** - * Returns the groups counts. - */ - async realmGroupsCountGetRaw(requestParameters: RealmGroupsCountGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsCountGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - if (requestParameters.top !== undefined) { - queryParameters['top'] = requestParameters.top; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/count`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Returns the groups counts. - */ - async realmGroupsCountGet(requestParameters: RealmGroupsCountGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmGroupsCountGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get group hierarchy. - */ - async realmGroupsGetRaw(requestParameters: RealmGroupsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get group hierarchy. - */ - async realmGroupsGet(requestParameters: RealmGroupsGetRequest): Promise> { - const response = await this.realmGroupsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Set or create child. - */ - async realmGroupsIdChildrenPostRaw(requestParameters: RealmGroupsIdChildrenPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdChildrenPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdChildrenPost.'); - } - - if (requestParameters.groupRepresentation === null || requestParameters.groupRepresentation === undefined) { - throw new runtime.RequiredError('groupRepresentation','Required parameter requestParameters.groupRepresentation was null or undefined when calling realmGroupsIdChildrenPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/children`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: GroupRepresentationToJSON(requestParameters.groupRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Set or create child. - */ - async realmGroupsIdChildrenPost(requestParameters: RealmGroupsIdChildrenPostRequest): Promise { - await this.realmGroupsIdChildrenPostRaw(requestParameters); - } - - /** - */ - async realmGroupsIdDeleteRaw(requestParameters: RealmGroupsIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmGroupsIdDelete(requestParameters: RealmGroupsIdDeleteRequest): Promise { - await this.realmGroupsIdDeleteRaw(requestParameters); - } - - /** - */ - async realmGroupsIdGetRaw(requestParameters: RealmGroupsIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => GroupRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmGroupsIdGet(requestParameters: RealmGroupsIdGetRequest): Promise { - const response = await this.realmGroupsIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmGroupsIdManagementPermissionsGetRaw(requestParameters: RealmGroupsIdManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdManagementPermissionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmGroupsIdManagementPermissionsGet(requestParameters: RealmGroupsIdManagementPermissionsGetRequest): Promise { - const response = await this.realmGroupsIdManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmGroupsIdManagementPermissionsPutRaw(requestParameters: RealmGroupsIdManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdManagementPermissionsPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmGroupsIdManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmGroupsIdManagementPermissionsPut(requestParameters: RealmGroupsIdManagementPermissionsPutRequest): Promise { - const response = await this.realmGroupsIdManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Get users Returns a stream of users, filtered according to query parameters - */ - async realmGroupsIdMembersGetRaw(requestParameters: RealmGroupsIdMembersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdMembersGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdMembersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/members`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get users Returns a stream of users, filtered according to query parameters - */ - async realmGroupsIdMembersGet(requestParameters: RealmGroupsIdMembersGetRequest): Promise> { - const response = await this.realmGroupsIdMembersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update group, ignores subgroups. - */ - async realmGroupsIdPutRaw(requestParameters: RealmGroupsIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdPut.'); - } - - if (requestParameters.groupRepresentation === null || requestParameters.groupRepresentation === undefined) { - throw new runtime.RequiredError('groupRepresentation','Required parameter requestParameters.groupRepresentation was null or undefined when calling realmGroupsIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: GroupRepresentationToJSON(requestParameters.groupRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update group, ignores subgroups. - */ - async realmGroupsIdPut(requestParameters: RealmGroupsIdPutRequest): Promise { - await this.realmGroupsIdPutRaw(requestParameters); - } - - /** - * create or add a top level realm groupSet or create child. - */ - async realmGroupsPostRaw(requestParameters: RealmGroupsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsPost.'); - } - - if (requestParameters.groupRepresentation === null || requestParameters.groupRepresentation === undefined) { - throw new runtime.RequiredError('groupRepresentation','Required parameter requestParameters.groupRepresentation was null or undefined when calling realmGroupsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: GroupRepresentationToJSON(requestParameters.groupRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * create or add a top level realm groupSet or create child. - */ - async realmGroupsPost(requestParameters: RealmGroupsPostRequest): Promise { - await this.realmGroupsPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/IdentityProvidersApi.ts b/backend/keycloak/kc-client/apis/IdentityProvidersApi.ts deleted file mode 100644 index c6c1aa6..0000000 --- a/backend/keycloak/kc-client/apis/IdentityProvidersApi.ts +++ /dev/null @@ -1,822 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - IdentityProviderMapperRepresentation, - IdentityProviderMapperRepresentationFromJSON, - IdentityProviderMapperRepresentationToJSON, - IdentityProviderRepresentation, - IdentityProviderRepresentationFromJSON, - IdentityProviderRepresentationToJSON, - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, -} from '../models'; - -export interface RealmIdentityProviderImportConfigPostRequest { - realm: string; -} - -export interface RealmIdentityProviderInstancesAliasDeleteRequest { - realm: string; - alias: string; -} - -export interface RealmIdentityProviderInstancesAliasExportGetRequest { - realm: string; - alias: string; - format?: string; -} - -export interface RealmIdentityProviderInstancesAliasGetRequest { - realm: string; - alias: string; -} - -export interface RealmIdentityProviderInstancesAliasManagementPermissionsGetRequest { - realm: string; - alias: string; -} - -export interface RealmIdentityProviderInstancesAliasManagementPermissionsPutRequest { - realm: string; - alias: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmIdentityProviderInstancesAliasMapperTypesGetRequest { - realm: string; - alias: string; -} - -export interface RealmIdentityProviderInstancesAliasMappersGetRequest { - realm: string; - alias: string; -} - -export interface RealmIdentityProviderInstancesAliasMappersIdDeleteRequest { - realm: string; - alias: string; - id: string; -} - -export interface RealmIdentityProviderInstancesAliasMappersIdGetRequest { - realm: string; - alias: string; - id: string; -} - -export interface RealmIdentityProviderInstancesAliasMappersIdPutRequest { - realm: string; - alias: string; - id: string; - identityProviderMapperRepresentation: IdentityProviderMapperRepresentation; -} - -export interface RealmIdentityProviderInstancesAliasMappersPostRequest { - realm: string; - alias: string; - identityProviderMapperRepresentation: IdentityProviderMapperRepresentation; -} - -export interface RealmIdentityProviderInstancesAliasPutRequest { - realm: string; - alias: string; - identityProviderRepresentation: IdentityProviderRepresentation; -} - -export interface RealmIdentityProviderInstancesGetRequest { - realm: string; -} - -export interface RealmIdentityProviderInstancesPostRequest { - realm: string; - identityProviderRepresentation: IdentityProviderRepresentation; -} - -export interface RealmIdentityProviderProvidersProviderIdGetRequest { - realm: string; - providerId: string; -} - -/** - * - */ -export class IdentityProvidersApi extends runtime.BaseAPI { - - /** - * Import identity provider from uploaded JSON file - */ - async realmIdentityProviderImportConfigPostRaw(requestParameters: RealmIdentityProviderImportConfigPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderImportConfigPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/import-config`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Import identity provider from uploaded JSON file - */ - async realmIdentityProviderImportConfigPost(requestParameters: RealmIdentityProviderImportConfigPostRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmIdentityProviderImportConfigPostRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the identity provider - */ - async realmIdentityProviderInstancesAliasDeleteRaw(requestParameters: RealmIdentityProviderInstancesAliasDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasDelete.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the identity provider - */ - async realmIdentityProviderInstancesAliasDelete(requestParameters: RealmIdentityProviderInstancesAliasDeleteRequest): Promise { - await this.realmIdentityProviderInstancesAliasDeleteRaw(requestParameters); - } - - /** - * Export public broker configuration for identity provider - */ - async realmIdentityProviderInstancesAliasExportGetRaw(requestParameters: RealmIdentityProviderInstancesAliasExportGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasExportGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasExportGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.format !== undefined) { - queryParameters['format'] = requestParameters.format; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/export`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Export public broker configuration for identity provider - */ - async realmIdentityProviderInstancesAliasExportGet(requestParameters: RealmIdentityProviderInstancesAliasExportGetRequest): Promise { - await this.realmIdentityProviderInstancesAliasExportGetRaw(requestParameters); - } - - /** - * Get the identity provider - */ - async realmIdentityProviderInstancesAliasGetRaw(requestParameters: RealmIdentityProviderInstancesAliasGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => IdentityProviderRepresentationFromJSON(jsonValue)); - } - - /** - * Get the identity provider - */ - async realmIdentityProviderInstancesAliasGet(requestParameters: RealmIdentityProviderInstancesAliasGetRequest): Promise { - const response = await this.realmIdentityProviderInstancesAliasGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmIdentityProviderInstancesAliasManagementPermissionsGetRaw(requestParameters: RealmIdentityProviderInstancesAliasManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasManagementPermissionsGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmIdentityProviderInstancesAliasManagementPermissionsGet(requestParameters: RealmIdentityProviderInstancesAliasManagementPermissionsGetRequest): Promise { - const response = await this.realmIdentityProviderInstancesAliasManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmIdentityProviderInstancesAliasManagementPermissionsPutRaw(requestParameters: RealmIdentityProviderInstancesAliasManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasManagementPermissionsPut.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmIdentityProviderInstancesAliasManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether client Authorization permissions have been initialized or not and a reference - */ - async realmIdentityProviderInstancesAliasManagementPermissionsPut(requestParameters: RealmIdentityProviderInstancesAliasManagementPermissionsPutRequest): Promise { - const response = await this.realmIdentityProviderInstancesAliasManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Get mapper types for identity provider - */ - async realmIdentityProviderInstancesAliasMapperTypesGetRaw(requestParameters: RealmIdentityProviderInstancesAliasMapperTypesGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMapperTypesGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMapperTypesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mapper-types`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Get mapper types for identity provider - */ - async realmIdentityProviderInstancesAliasMapperTypesGet(requestParameters: RealmIdentityProviderInstancesAliasMapperTypesGetRequest): Promise { - await this.realmIdentityProviderInstancesAliasMapperTypesGetRaw(requestParameters); - } - - /** - * Get mappers for identity provider - */ - async realmIdentityProviderInstancesAliasMappersGetRaw(requestParameters: RealmIdentityProviderInstancesAliasMappersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMappersGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMappersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mappers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get mappers for identity provider - */ - async realmIdentityProviderInstancesAliasMappersGet(requestParameters: RealmIdentityProviderInstancesAliasMappersGetRequest): Promise> { - const response = await this.realmIdentityProviderInstancesAliasMappersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete a mapper for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdDeleteRaw(requestParameters: RealmIdentityProviderInstancesAliasMappersIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdDelete.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mappers/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete a mapper for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdDelete(requestParameters: RealmIdentityProviderInstancesAliasMappersIdDeleteRequest): Promise { - await this.realmIdentityProviderInstancesAliasMappersIdDeleteRaw(requestParameters); - } - - /** - * Get mapper by id for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdGetRaw(requestParameters: RealmIdentityProviderInstancesAliasMappersIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdGet.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mappers/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => IdentityProviderMapperRepresentationFromJSON(jsonValue)); - } - - /** - * Get mapper by id for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdGet(requestParameters: RealmIdentityProviderInstancesAliasMappersIdGetRequest): Promise { - const response = await this.realmIdentityProviderInstancesAliasMappersIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update a mapper for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdPutRaw(requestParameters: RealmIdentityProviderInstancesAliasMappersIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdPut.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdPut.'); - } - - if (requestParameters.identityProviderMapperRepresentation === null || requestParameters.identityProviderMapperRepresentation === undefined) { - throw new runtime.RequiredError('identityProviderMapperRepresentation','Required parameter requestParameters.identityProviderMapperRepresentation was null or undefined when calling realmIdentityProviderInstancesAliasMappersIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mappers/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: IdentityProviderMapperRepresentationToJSON(requestParameters.identityProviderMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update a mapper for the identity provider - */ - async realmIdentityProviderInstancesAliasMappersIdPut(requestParameters: RealmIdentityProviderInstancesAliasMappersIdPutRequest): Promise { - await this.realmIdentityProviderInstancesAliasMappersIdPutRaw(requestParameters); - } - - /** - * Add a mapper to identity provider - */ - async realmIdentityProviderInstancesAliasMappersPostRaw(requestParameters: RealmIdentityProviderInstancesAliasMappersPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasMappersPost.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasMappersPost.'); - } - - if (requestParameters.identityProviderMapperRepresentation === null || requestParameters.identityProviderMapperRepresentation === undefined) { - throw new runtime.RequiredError('identityProviderMapperRepresentation','Required parameter requestParameters.identityProviderMapperRepresentation was null or undefined when calling realmIdentityProviderInstancesAliasMappersPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}/mappers`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: IdentityProviderMapperRepresentationToJSON(requestParameters.identityProviderMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a mapper to identity provider - */ - async realmIdentityProviderInstancesAliasMappersPost(requestParameters: RealmIdentityProviderInstancesAliasMappersPostRequest): Promise { - await this.realmIdentityProviderInstancesAliasMappersPostRaw(requestParameters); - } - - /** - * Update the identity provider - */ - async realmIdentityProviderInstancesAliasPutRaw(requestParameters: RealmIdentityProviderInstancesAliasPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesAliasPut.'); - } - - if (requestParameters.alias === null || requestParameters.alias === undefined) { - throw new runtime.RequiredError('alias','Required parameter requestParameters.alias was null or undefined when calling realmIdentityProviderInstancesAliasPut.'); - } - - if (requestParameters.identityProviderRepresentation === null || requestParameters.identityProviderRepresentation === undefined) { - throw new runtime.RequiredError('identityProviderRepresentation','Required parameter requestParameters.identityProviderRepresentation was null or undefined when calling realmIdentityProviderInstancesAliasPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances/{alias}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"alias"}}`, encodeURIComponent(String(requestParameters.alias))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: IdentityProviderRepresentationToJSON(requestParameters.identityProviderRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the identity provider - */ - async realmIdentityProviderInstancesAliasPut(requestParameters: RealmIdentityProviderInstancesAliasPutRequest): Promise { - await this.realmIdentityProviderInstancesAliasPutRaw(requestParameters); - } - - /** - * Get identity providers - */ - async realmIdentityProviderInstancesGetRaw(requestParameters: RealmIdentityProviderInstancesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get identity providers - */ - async realmIdentityProviderInstancesGet(requestParameters: RealmIdentityProviderInstancesGetRequest): Promise> { - const response = await this.realmIdentityProviderInstancesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a new identity provider - */ - async realmIdentityProviderInstancesPostRaw(requestParameters: RealmIdentityProviderInstancesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderInstancesPost.'); - } - - if (requestParameters.identityProviderRepresentation === null || requestParameters.identityProviderRepresentation === undefined) { - throw new runtime.RequiredError('identityProviderRepresentation','Required parameter requestParameters.identityProviderRepresentation was null or undefined when calling realmIdentityProviderInstancesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/instances`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: IdentityProviderRepresentationToJSON(requestParameters.identityProviderRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new identity provider - */ - async realmIdentityProviderInstancesPost(requestParameters: RealmIdentityProviderInstancesPostRequest): Promise { - await this.realmIdentityProviderInstancesPostRaw(requestParameters); - } - - /** - * Get identity providers - */ - async realmIdentityProviderProvidersProviderIdGetRaw(requestParameters: RealmIdentityProviderProvidersProviderIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmIdentityProviderProvidersProviderIdGet.'); - } - - if (requestParameters.providerId === null || requestParameters.providerId === undefined) { - throw new runtime.RequiredError('providerId','Required parameter requestParameters.providerId was null or undefined when calling realmIdentityProviderProvidersProviderIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/identity-provider/providers/{provider_id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"provider_id"}}`, encodeURIComponent(String(requestParameters.providerId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Get identity providers - */ - async realmIdentityProviderProvidersProviderIdGet(requestParameters: RealmIdentityProviderProvidersProviderIdGetRequest): Promise { - await this.realmIdentityProviderProvidersProviderIdGetRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/KeyApi.ts b/backend/keycloak/kc-client/apis/KeyApi.ts deleted file mode 100644 index 05b8439..0000000 --- a/backend/keycloak/kc-client/apis/KeyApi.ts +++ /dev/null @@ -1,68 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - KeysMetadataRepresentation, - KeysMetadataRepresentationFromJSON, - KeysMetadataRepresentationToJSON, -} from '../models'; - -export interface RealmKeysGetRequest { - realm: string; -} - -/** - * - */ -export class KeyApi extends runtime.BaseAPI { - - /** - */ - async realmKeysGetRaw(requestParameters: RealmKeysGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmKeysGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/keys`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => KeysMetadataRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmKeysGet(requestParameters: RealmKeysGetRequest): Promise { - const response = await this.realmKeysGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ProtocolMappersApi.ts b/backend/keycloak/kc-client/apis/ProtocolMappersApi.ts deleted file mode 100644 index b710199..0000000 --- a/backend/keycloak/kc-client/apis/ProtocolMappersApi.ts +++ /dev/null @@ -1,766 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ProtocolMapperRepresentation, - ProtocolMapperRepresentationFromJSON, - ProtocolMapperRepresentationToJSON, -} from '../models'; - -export interface RealmClientScopesId1ProtocolMappersModelsId2DeleteRequest { - realm: string; - id1: string; - id2: string; -} - -export interface RealmClientScopesId1ProtocolMappersModelsId2GetRequest { - realm: string; - id1: string; - id2: string; -} - -export interface RealmClientScopesId1ProtocolMappersModelsId2PutRequest { - realm: string; - id1: string; - id2: string; - protocolMapperRepresentation: ProtocolMapperRepresentation; -} - -export interface RealmClientScopesIdProtocolMappersAddModelsPostRequest { - realm: string; - id: string; - protocolMapperRepresentation: Array; -} - -export interface RealmClientScopesIdProtocolMappersModelsGetRequest { - realm: string; - id: string; -} - -export interface RealmClientScopesIdProtocolMappersModelsPostRequest { - realm: string; - id: string; - protocolMapperRepresentation: ProtocolMapperRepresentation; -} - -export interface RealmClientScopesIdProtocolMappersProtocolProtocolGetRequest { - realm: string; - id: string; - protocol: string; -} - -export interface RealmClientsId1ProtocolMappersModelsId2DeleteRequest { - realm: string; - id1: string; - id2: string; -} - -export interface RealmClientsId1ProtocolMappersModelsId2GetRequest { - realm: string; - id1: string; - id2: string; -} - -export interface RealmClientsId1ProtocolMappersModelsId2PutRequest { - realm: string; - id1: string; - id2: string; - protocolMapperRepresentation: ProtocolMapperRepresentation; -} - -export interface RealmClientsIdProtocolMappersAddModelsPostRequest { - realm: string; - id: string; - protocolMapperRepresentation: Array; -} - -export interface RealmClientsIdProtocolMappersModelsGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdProtocolMappersModelsPostRequest { - realm: string; - id: string; - protocolMapperRepresentation: ProtocolMapperRepresentation; -} - -export interface RealmClientsIdProtocolMappersProtocolProtocolGetRequest { - realm: string; - id: string; - protocol: string; -} - -/** - * - */ -export class ProtocolMappersApi extends runtime.BaseAPI { - - /** - * Delete the mapper - */ - async realmClientScopesId1ProtocolMappersModelsId2DeleteRaw(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2DeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Delete.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Delete.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Delete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the mapper - */ - async realmClientScopesId1ProtocolMappersModelsId2Delete(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2DeleteRequest): Promise { - await this.realmClientScopesId1ProtocolMappersModelsId2DeleteRaw(requestParameters); - } - - /** - * Get mapper by id - */ - async realmClientScopesId1ProtocolMappersModelsId2GetRaw(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2GetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Get.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Get.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Get.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ProtocolMapperRepresentationFromJSON(jsonValue)); - } - - /** - * Get mapper by id - */ - async realmClientScopesId1ProtocolMappersModelsId2Get(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2GetRequest): Promise { - const response = await this.realmClientScopesId1ProtocolMappersModelsId2GetRaw(requestParameters); - return await response.value(); - } - - /** - * Update the mapper - */ - async realmClientScopesId1ProtocolMappersModelsId2PutRaw(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2PutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientScopesId1ProtocolMappersModelsId2Put.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ProtocolMapperRepresentationToJSON(requestParameters.protocolMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the mapper - */ - async realmClientScopesId1ProtocolMappersModelsId2Put(requestParameters: RealmClientScopesId1ProtocolMappersModelsId2PutRequest): Promise { - await this.realmClientScopesId1ProtocolMappersModelsId2PutRaw(requestParameters); - } - - /** - * Create multiple mappers - */ - async realmClientScopesIdProtocolMappersAddModelsPostRaw(requestParameters: RealmClientScopesIdProtocolMappersAddModelsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdProtocolMappersAddModelsPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdProtocolMappersAddModelsPost.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientScopesIdProtocolMappersAddModelsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/protocol-mappers/add-models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.protocolMapperRepresentation.map(ProtocolMapperRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create multiple mappers - */ - async realmClientScopesIdProtocolMappersAddModelsPost(requestParameters: RealmClientScopesIdProtocolMappersAddModelsPostRequest): Promise { - await this.realmClientScopesIdProtocolMappersAddModelsPostRaw(requestParameters); - } - - /** - * Get mappers - */ - async realmClientScopesIdProtocolMappersModelsGetRaw(requestParameters: RealmClientScopesIdProtocolMappersModelsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdProtocolMappersModelsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdProtocolMappersModelsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/protocol-mappers/models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get mappers - */ - async realmClientScopesIdProtocolMappersModelsGet(requestParameters: RealmClientScopesIdProtocolMappersModelsGetRequest): Promise> { - const response = await this.realmClientScopesIdProtocolMappersModelsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a mapper - */ - async realmClientScopesIdProtocolMappersModelsPostRaw(requestParameters: RealmClientScopesIdProtocolMappersModelsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdProtocolMappersModelsPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdProtocolMappersModelsPost.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientScopesIdProtocolMappersModelsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/protocol-mappers/models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ProtocolMapperRepresentationToJSON(requestParameters.protocolMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a mapper - */ - async realmClientScopesIdProtocolMappersModelsPost(requestParameters: RealmClientScopesIdProtocolMappersModelsPostRequest): Promise { - await this.realmClientScopesIdProtocolMappersModelsPostRaw(requestParameters); - } - - /** - * Get mappers by name for a specific protocol - */ - async realmClientScopesIdProtocolMappersProtocolProtocolGetRaw(requestParameters: RealmClientScopesIdProtocolMappersProtocolProtocolGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdProtocolMappersProtocolProtocolGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdProtocolMappersProtocolProtocolGet.'); - } - - if (requestParameters.protocol === null || requestParameters.protocol === undefined) { - throw new runtime.RequiredError('protocol','Required parameter requestParameters.protocol was null or undefined when calling realmClientScopesIdProtocolMappersProtocolProtocolGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/protocol-mappers/protocol/{protocol}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"protocol"}}`, encodeURIComponent(String(requestParameters.protocol))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get mappers by name for a specific protocol - */ - async realmClientScopesIdProtocolMappersProtocolProtocolGet(requestParameters: RealmClientScopesIdProtocolMappersProtocolProtocolGetRequest): Promise> { - const response = await this.realmClientScopesIdProtocolMappersProtocolProtocolGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the mapper - */ - async realmClientsId1ProtocolMappersModelsId2DeleteRaw(requestParameters: RealmClientsId1ProtocolMappersModelsId2DeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Delete.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Delete.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Delete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the mapper - */ - async realmClientsId1ProtocolMappersModelsId2Delete(requestParameters: RealmClientsId1ProtocolMappersModelsId2DeleteRequest): Promise { - await this.realmClientsId1ProtocolMappersModelsId2DeleteRaw(requestParameters); - } - - /** - * Get mapper by id - */ - async realmClientsId1ProtocolMappersModelsId2GetRaw(requestParameters: RealmClientsId1ProtocolMappersModelsId2GetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Get.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Get.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Get.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ProtocolMapperRepresentationFromJSON(jsonValue)); - } - - /** - * Get mapper by id - */ - async realmClientsId1ProtocolMappersModelsId2Get(requestParameters: RealmClientsId1ProtocolMappersModelsId2GetRequest): Promise { - const response = await this.realmClientsId1ProtocolMappersModelsId2GetRaw(requestParameters); - return await response.value(); - } - - /** - * Update the mapper - */ - async realmClientsId1ProtocolMappersModelsId2PutRaw(requestParameters: RealmClientsId1ProtocolMappersModelsId2PutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.id1 === null || requestParameters.id1 === undefined) { - throw new runtime.RequiredError('id1','Required parameter requestParameters.id1 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.id2 === null || requestParameters.id2 === undefined) { - throw new runtime.RequiredError('id2','Required parameter requestParameters.id2 was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Put.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientsId1ProtocolMappersModelsId2Put.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id1}/protocol-mappers/models/{id2}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id1"}}`, encodeURIComponent(String(requestParameters.id1))).replace(`{${"id2"}}`, encodeURIComponent(String(requestParameters.id2))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ProtocolMapperRepresentationToJSON(requestParameters.protocolMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the mapper - */ - async realmClientsId1ProtocolMappersModelsId2Put(requestParameters: RealmClientsId1ProtocolMappersModelsId2PutRequest): Promise { - await this.realmClientsId1ProtocolMappersModelsId2PutRaw(requestParameters); - } - - /** - * Create multiple mappers - */ - async realmClientsIdProtocolMappersAddModelsPostRaw(requestParameters: RealmClientsIdProtocolMappersAddModelsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdProtocolMappersAddModelsPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdProtocolMappersAddModelsPost.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientsIdProtocolMappersAddModelsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/protocol-mappers/add-models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.protocolMapperRepresentation.map(ProtocolMapperRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create multiple mappers - */ - async realmClientsIdProtocolMappersAddModelsPost(requestParameters: RealmClientsIdProtocolMappersAddModelsPostRequest): Promise { - await this.realmClientsIdProtocolMappersAddModelsPostRaw(requestParameters); - } - - /** - * Get mappers - */ - async realmClientsIdProtocolMappersModelsGetRaw(requestParameters: RealmClientsIdProtocolMappersModelsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdProtocolMappersModelsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdProtocolMappersModelsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/protocol-mappers/models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get mappers - */ - async realmClientsIdProtocolMappersModelsGet(requestParameters: RealmClientsIdProtocolMappersModelsGetRequest): Promise> { - const response = await this.realmClientsIdProtocolMappersModelsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a mapper - */ - async realmClientsIdProtocolMappersModelsPostRaw(requestParameters: RealmClientsIdProtocolMappersModelsPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdProtocolMappersModelsPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdProtocolMappersModelsPost.'); - } - - if (requestParameters.protocolMapperRepresentation === null || requestParameters.protocolMapperRepresentation === undefined) { - throw new runtime.RequiredError('protocolMapperRepresentation','Required parameter requestParameters.protocolMapperRepresentation was null or undefined when calling realmClientsIdProtocolMappersModelsPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/protocol-mappers/models`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: ProtocolMapperRepresentationToJSON(requestParameters.protocolMapperRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a mapper - */ - async realmClientsIdProtocolMappersModelsPost(requestParameters: RealmClientsIdProtocolMappersModelsPostRequest): Promise { - await this.realmClientsIdProtocolMappersModelsPostRaw(requestParameters); - } - - /** - * Get mappers by name for a specific protocol - */ - async realmClientsIdProtocolMappersProtocolProtocolGetRaw(requestParameters: RealmClientsIdProtocolMappersProtocolProtocolGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdProtocolMappersProtocolProtocolGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdProtocolMappersProtocolProtocolGet.'); - } - - if (requestParameters.protocol === null || requestParameters.protocol === undefined) { - throw new runtime.RequiredError('protocol','Required parameter requestParameters.protocol was null or undefined when calling realmClientsIdProtocolMappersProtocolProtocolGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/protocol-mappers/protocol/{protocol}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"protocol"}}`, encodeURIComponent(String(requestParameters.protocol))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get mappers by name for a specific protocol - */ - async realmClientsIdProtocolMappersProtocolProtocolGet(requestParameters: RealmClientsIdProtocolMappersProtocolProtocolGetRequest): Promise> { - const response = await this.realmClientsIdProtocolMappersProtocolProtocolGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/RealmsAdminApi.ts b/backend/keycloak/kc-client/apis/RealmsAdminApi.ts deleted file mode 100644 index 4710992..0000000 --- a/backend/keycloak/kc-client/apis/RealmsAdminApi.ts +++ /dev/null @@ -1,2252 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ClientPoliciesRepresentation, - ClientPoliciesRepresentationFromJSON, - ClientPoliciesRepresentationToJSON, - ClientProfilesRepresentation, - ClientProfilesRepresentationFromJSON, - ClientProfilesRepresentationToJSON, - ClientRepresentation, - ClientRepresentationFromJSON, - ClientRepresentationToJSON, - GlobalRequestResult, - GlobalRequestResultFromJSON, - GlobalRequestResultToJSON, - GroupRepresentation, - GroupRepresentationFromJSON, - GroupRepresentationToJSON, - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, - PartialImportRepresentation, - PartialImportRepresentationFromJSON, - PartialImportRepresentationToJSON, - RealmEventsConfigRepresentation, - RealmEventsConfigRepresentationFromJSON, - RealmEventsConfigRepresentationToJSON, - RealmRepresentation, - RealmRepresentationFromJSON, - RealmRepresentationToJSON, - TestLdapConnectionRepresentation, - TestLdapConnectionRepresentationFromJSON, - TestLdapConnectionRepresentationToJSON, -} from '../models'; - -export interface RealmAdminEventsDeleteRequest { - realm: string; -} - -export interface RealmAdminEventsGetRequest { - realm: string; - authClient?: string; - authIpAddress?: string; - authRealm?: string; - authUser?: string; - dateFrom?: string; - dateTo?: string; - first?: number; - max?: number; - operationTypes?: Array; - resourcePath?: string; - resourceTypes?: Array; -} - -export interface RealmClearKeysCachePostRequest { - realm: string; -} - -export interface RealmClearRealmCachePostRequest { - realm: string; -} - -export interface RealmClearUserCachePostRequest { - realm: string; -} - -export interface RealmClientDescriptionConverterPostRequest { - realm: string; - body: string; -} - -export interface RealmClientPoliciesPoliciesGetRequest { - realm: string; -} - -export interface RealmClientPoliciesPoliciesPutRequest { - realm: string; - clientPoliciesRepresentation: ClientPoliciesRepresentation; -} - -export interface RealmClientPoliciesProfilesGetRequest { - realm: string; - includeGlobalProfiles?: boolean; -} - -export interface RealmClientPoliciesProfilesPutRequest { - realm: string; - clientProfilesRepresentation: ClientProfilesRepresentation; -} - -export interface RealmClientSessionStatsGetRequest { - realm: string; -} - -export interface RealmCredentialRegistratorsGetRequest { - realm: string; -} - -export interface RealmDefaultDefaultClientScopesClientScopeIdDeleteRequest { - realm: string; - clientScopeId: string; -} - -export interface RealmDefaultDefaultClientScopesClientScopeIdPutRequest { - realm: string; - clientScopeId: string; -} - -export interface RealmDefaultDefaultClientScopesGetRequest { - realm: string; -} - -export interface RealmDefaultGroupsGetRequest { - realm: string; -} - -export interface RealmDefaultGroupsGroupIdDeleteRequest { - realm: string; - groupId: string; -} - -export interface RealmDefaultGroupsGroupIdPutRequest { - realm: string; - groupId: string; -} - -export interface RealmDefaultOptionalClientScopesClientScopeIdDeleteRequest { - realm: string; - clientScopeId: string; -} - -export interface RealmDefaultOptionalClientScopesClientScopeIdPutRequest { - realm: string; - clientScopeId: string; -} - -export interface RealmDefaultOptionalClientScopesGetRequest { - realm: string; -} - -export interface RealmDeleteRequest { - realm: string; -} - -export interface RealmEventsConfigGetRequest { - realm: string; -} - -export interface RealmEventsConfigPutRequest { - realm: string; - realmEventsConfigRepresentation: RealmEventsConfigRepresentation; -} - -export interface RealmEventsDeleteRequest { - realm: string; -} - -export interface RealmEventsGetRequest { - realm: string; - client?: string; - dateFrom?: string; - dateTo?: string; - first?: number; - ipAddress?: string; - max?: number; - type?: Array; - user?: string; -} - -export interface RealmGetRequest { - realm: string; -} - -export interface RealmGroupByPathPathGetRequest { - realm: string; - path: string; -} - -export interface RealmLdapServerCapabilitiesPostRequest { - realm: string; - testLdapConnectionRepresentation: TestLdapConnectionRepresentation; -} - -export interface RealmLocalizationGetRequest { - realm: string; -} - -export interface RealmLocalizationLocaleDeleteRequest { - realm: string; - locale: string; -} - -export interface RealmLocalizationLocaleGetRequest { - realm: string; - locale: string; -} - -export interface RealmLocalizationLocaleKeyDeleteRequest { - realm: string; - locale: string; - key: string; -} - -export interface RealmLocalizationLocaleKeyGetRequest { - realm: string; - locale: string; - key: string; -} - -export interface RealmLocalizationLocaleKeyPutRequest { - realm: string; - locale: string; - key: string; - body: string; -} - -export interface RealmLocalizationLocalePostRequest { - realm: string; - locale: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmLogoutAllPostRequest { - realm: string; -} - -export interface RealmPartialExportPostRequest { - realm: string; - exportClients?: boolean; - exportGroupsAndRoles?: boolean; -} - -export interface RealmPartialImportPostRequest { - realm: string; - partialImportRepresentation: PartialImportRepresentation; -} - -export interface RealmPushRevocationPostRequest { - realm: string; -} - -export interface RealmPutRequest { - realm: string; - realmRepresentation: RealmRepresentation; -} - -export interface RealmSessionsSessionDeleteRequest { - realm: string; - session: string; -} - -export interface RealmTestLDAPConnectionPostRequest { - realm: string; - testLdapConnectionRepresentation: TestLdapConnectionRepresentation; -} - -export interface RealmTestSMTPConnectionPostRequest { - realm: string; - requestBody: { [key: string]: object; }; -} - -export interface RealmUsersManagementPermissionsGetRequest { - realm: string; -} - -export interface RealmUsersManagementPermissionsPutRequest { - realm: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RootPostRequest { - realmRepresentation: RealmRepresentation; -} - -/** - * - */ -export class RealmsAdminApi extends runtime.BaseAPI { - - /** - * Delete all admin events - */ - async realmAdminEventsDeleteRaw(requestParameters: RealmAdminEventsDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAdminEventsDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/admin-events`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete all admin events - */ - async realmAdminEventsDelete(requestParameters: RealmAdminEventsDeleteRequest): Promise { - await this.realmAdminEventsDeleteRaw(requestParameters); - } - - /** - * Get admin events Returns all admin events, or filters events based on URL query parameters listed here - */ - async realmAdminEventsGetRaw(requestParameters: RealmAdminEventsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmAdminEventsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.authClient !== undefined) { - queryParameters['authClient'] = requestParameters.authClient; - } - - if (requestParameters.authIpAddress !== undefined) { - queryParameters['authIpAddress'] = requestParameters.authIpAddress; - } - - if (requestParameters.authRealm !== undefined) { - queryParameters['authRealm'] = requestParameters.authRealm; - } - - if (requestParameters.authUser !== undefined) { - queryParameters['authUser'] = requestParameters.authUser; - } - - if (requestParameters.dateFrom !== undefined) { - queryParameters['dateFrom'] = requestParameters.dateFrom; - } - - if (requestParameters.dateTo !== undefined) { - queryParameters['dateTo'] = requestParameters.dateTo; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.operationTypes) { - queryParameters['operationTypes'] = requestParameters.operationTypes; - } - - if (requestParameters.resourcePath !== undefined) { - queryParameters['resourcePath'] = requestParameters.resourcePath; - } - - if (requestParameters.resourceTypes) { - queryParameters['resourceTypes'] = requestParameters.resourceTypes; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/admin-events`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get admin events Returns all admin events, or filters events based on URL query parameters listed here - */ - async realmAdminEventsGet(requestParameters: RealmAdminEventsGetRequest): Promise> { - const response = await this.realmAdminEventsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Clear cache of external public keys (Public keys of clients or Identity providers) - */ - async realmClearKeysCachePostRaw(requestParameters: RealmClearKeysCachePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClearKeysCachePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clear-keys-cache`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Clear cache of external public keys (Public keys of clients or Identity providers) - */ - async realmClearKeysCachePost(requestParameters: RealmClearKeysCachePostRequest): Promise { - await this.realmClearKeysCachePostRaw(requestParameters); - } - - /** - * Clear realm cache - */ - async realmClearRealmCachePostRaw(requestParameters: RealmClearRealmCachePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClearRealmCachePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clear-realm-cache`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Clear realm cache - */ - async realmClearRealmCachePost(requestParameters: RealmClearRealmCachePostRequest): Promise { - await this.realmClearRealmCachePostRaw(requestParameters); - } - - /** - * Clear user cache - */ - async realmClearUserCachePostRaw(requestParameters: RealmClearUserCachePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClearUserCachePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clear-user-cache`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Clear user cache - */ - async realmClearUserCachePost(requestParameters: RealmClearUserCachePostRequest): Promise { - await this.realmClearUserCachePostRaw(requestParameters); - } - - /** - * Base path for importing clients under this realm. - */ - async realmClientDescriptionConverterPostRaw(requestParameters: RealmClientDescriptionConverterPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientDescriptionConverterPost.'); - } - - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling realmClientDescriptionConverterPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'text/plain'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-description-converter`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.body as any, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientRepresentationFromJSON(jsonValue)); - } - - /** - * Base path for importing clients under this realm. - */ - async realmClientDescriptionConverterPost(requestParameters: RealmClientDescriptionConverterPostRequest): Promise { - const response = await this.realmClientDescriptionConverterPostRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientPoliciesPoliciesGetRaw(requestParameters: RealmClientPoliciesPoliciesGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientPoliciesPoliciesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-policies/policies`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientPoliciesRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmClientPoliciesPoliciesGet(requestParameters: RealmClientPoliciesPoliciesGetRequest): Promise { - const response = await this.realmClientPoliciesPoliciesGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientPoliciesPoliciesPutRaw(requestParameters: RealmClientPoliciesPoliciesPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientPoliciesPoliciesPut.'); - } - - if (requestParameters.clientPoliciesRepresentation === null || requestParameters.clientPoliciesRepresentation === undefined) { - throw new runtime.RequiredError('clientPoliciesRepresentation','Required parameter requestParameters.clientPoliciesRepresentation was null or undefined when calling realmClientPoliciesPoliciesPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-policies/policies`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ClientPoliciesRepresentationToJSON(requestParameters.clientPoliciesRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientPoliciesPoliciesPut(requestParameters: RealmClientPoliciesPoliciesPutRequest): Promise { - await this.realmClientPoliciesPoliciesPutRaw(requestParameters); - } - - /** - */ - async realmClientPoliciesProfilesGetRaw(requestParameters: RealmClientPoliciesProfilesGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientPoliciesProfilesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.includeGlobalProfiles !== undefined) { - queryParameters['include-global-profiles'] = requestParameters.includeGlobalProfiles; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-policies/profiles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ClientProfilesRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmClientPoliciesProfilesGet(requestParameters: RealmClientPoliciesProfilesGetRequest): Promise { - const response = await this.realmClientPoliciesProfilesGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmClientPoliciesProfilesPutRaw(requestParameters: RealmClientPoliciesProfilesPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientPoliciesProfilesPut.'); - } - - if (requestParameters.clientProfilesRepresentation === null || requestParameters.clientProfilesRepresentation === undefined) { - throw new runtime.RequiredError('clientProfilesRepresentation','Required parameter requestParameters.clientProfilesRepresentation was null or undefined when calling realmClientPoliciesProfilesPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-policies/profiles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ClientProfilesRepresentationToJSON(requestParameters.clientProfilesRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmClientPoliciesProfilesPut(requestParameters: RealmClientPoliciesProfilesPutRequest): Promise { - await this.realmClientPoliciesProfilesPutRaw(requestParameters); - } - - /** - * Get client session stats Returns a JSON map. - */ - async realmClientSessionStatsGetRaw(requestParameters: RealmClientSessionStatsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientSessionStatsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-session-stats`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client session stats Returns a JSON map. - */ - async realmClientSessionStatsGet(requestParameters: RealmClientSessionStatsGetRequest): Promise> { - const response = await this.realmClientSessionStatsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmCredentialRegistratorsGetRaw(requestParameters: RealmCredentialRegistratorsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmCredentialRegistratorsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/credential-registrators`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmCredentialRegistratorsGet(requestParameters: RealmCredentialRegistratorsGetRequest): Promise> { - const response = await this.realmCredentialRegistratorsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmDefaultDefaultClientScopesClientScopeIdDeleteRaw(requestParameters: RealmDefaultDefaultClientScopesClientScopeIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultDefaultClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmDefaultDefaultClientScopesClientScopeIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-default-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultDefaultClientScopesClientScopeIdDelete(requestParameters: RealmDefaultDefaultClientScopesClientScopeIdDeleteRequest): Promise { - await this.realmDefaultDefaultClientScopesClientScopeIdDeleteRaw(requestParameters); - } - - /** - */ - async realmDefaultDefaultClientScopesClientScopeIdPutRaw(requestParameters: RealmDefaultDefaultClientScopesClientScopeIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultDefaultClientScopesClientScopeIdPut.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmDefaultDefaultClientScopesClientScopeIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-default-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultDefaultClientScopesClientScopeIdPut(requestParameters: RealmDefaultDefaultClientScopesClientScopeIdPutRequest): Promise { - await this.realmDefaultDefaultClientScopesClientScopeIdPutRaw(requestParameters); - } - - /** - * Get realm default client scopes. - */ - async realmDefaultDefaultClientScopesGetRaw(requestParameters: RealmDefaultDefaultClientScopesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultDefaultClientScopesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-default-client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm default client scopes. - */ - async realmDefaultDefaultClientScopesGet(requestParameters: RealmDefaultDefaultClientScopesGetRequest): Promise> { - const response = await this.realmDefaultDefaultClientScopesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get group hierarchy. - */ - async realmDefaultGroupsGetRaw(requestParameters: RealmDefaultGroupsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultGroupsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get group hierarchy. - */ - async realmDefaultGroupsGet(requestParameters: RealmDefaultGroupsGetRequest): Promise> { - const response = await this.realmDefaultGroupsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmDefaultGroupsGroupIdDeleteRaw(requestParameters: RealmDefaultGroupsGroupIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultGroupsGroupIdDelete.'); - } - - if (requestParameters.groupId === null || requestParameters.groupId === undefined) { - throw new runtime.RequiredError('groupId','Required parameter requestParameters.groupId was null or undefined when calling realmDefaultGroupsGroupIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-groups/{groupId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"groupId"}}`, encodeURIComponent(String(requestParameters.groupId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultGroupsGroupIdDelete(requestParameters: RealmDefaultGroupsGroupIdDeleteRequest): Promise { - await this.realmDefaultGroupsGroupIdDeleteRaw(requestParameters); - } - - /** - */ - async realmDefaultGroupsGroupIdPutRaw(requestParameters: RealmDefaultGroupsGroupIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultGroupsGroupIdPut.'); - } - - if (requestParameters.groupId === null || requestParameters.groupId === undefined) { - throw new runtime.RequiredError('groupId','Required parameter requestParameters.groupId was null or undefined when calling realmDefaultGroupsGroupIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-groups/{groupId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"groupId"}}`, encodeURIComponent(String(requestParameters.groupId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultGroupsGroupIdPut(requestParameters: RealmDefaultGroupsGroupIdPutRequest): Promise { - await this.realmDefaultGroupsGroupIdPutRaw(requestParameters); - } - - /** - */ - async realmDefaultOptionalClientScopesClientScopeIdDeleteRaw(requestParameters: RealmDefaultOptionalClientScopesClientScopeIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultOptionalClientScopesClientScopeIdDelete.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmDefaultOptionalClientScopesClientScopeIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-optional-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultOptionalClientScopesClientScopeIdDelete(requestParameters: RealmDefaultOptionalClientScopesClientScopeIdDeleteRequest): Promise { - await this.realmDefaultOptionalClientScopesClientScopeIdDeleteRaw(requestParameters); - } - - /** - */ - async realmDefaultOptionalClientScopesClientScopeIdPutRaw(requestParameters: RealmDefaultOptionalClientScopesClientScopeIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultOptionalClientScopesClientScopeIdPut.'); - } - - if (requestParameters.clientScopeId === null || requestParameters.clientScopeId === undefined) { - throw new runtime.RequiredError('clientScopeId','Required parameter requestParameters.clientScopeId was null or undefined when calling realmDefaultOptionalClientScopesClientScopeIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-optional-client-scopes/{clientScopeId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"clientScopeId"}}`, encodeURIComponent(String(requestParameters.clientScopeId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmDefaultOptionalClientScopesClientScopeIdPut(requestParameters: RealmDefaultOptionalClientScopesClientScopeIdPutRequest): Promise { - await this.realmDefaultOptionalClientScopesClientScopeIdPutRaw(requestParameters); - } - - /** - * Get realm optional client scopes. - */ - async realmDefaultOptionalClientScopesGetRaw(requestParameters: RealmDefaultOptionalClientScopesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDefaultOptionalClientScopesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/default-optional-client-scopes`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm optional client scopes. - */ - async realmDefaultOptionalClientScopesGet(requestParameters: RealmDefaultOptionalClientScopesGetRequest): Promise> { - const response = await this.realmDefaultOptionalClientScopesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the realm - */ - async realmDeleteRaw(requestParameters: RealmDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the realm - */ - async realmDelete(requestParameters: RealmDeleteRequest): Promise { - await this.realmDeleteRaw(requestParameters); - } - - /** - * Get the events provider configuration Returns JSON object with events provider configuration - */ - async realmEventsConfigGetRaw(requestParameters: RealmEventsConfigGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmEventsConfigGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/events/config`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RealmEventsConfigRepresentationFromJSON(jsonValue)); - } - - /** - * Get the events provider configuration Returns JSON object with events provider configuration - */ - async realmEventsConfigGet(requestParameters: RealmEventsConfigGetRequest): Promise { - const response = await this.realmEventsConfigGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update the events provider Change the events provider and/or its configuration - */ - async realmEventsConfigPutRaw(requestParameters: RealmEventsConfigPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmEventsConfigPut.'); - } - - if (requestParameters.realmEventsConfigRepresentation === null || requestParameters.realmEventsConfigRepresentation === undefined) { - throw new runtime.RequiredError('realmEventsConfigRepresentation','Required parameter requestParameters.realmEventsConfigRepresentation was null or undefined when calling realmEventsConfigPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/events/config`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RealmEventsConfigRepresentationToJSON(requestParameters.realmEventsConfigRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the events provider Change the events provider and/or its configuration - */ - async realmEventsConfigPut(requestParameters: RealmEventsConfigPutRequest): Promise { - await this.realmEventsConfigPutRaw(requestParameters); - } - - /** - * Delete all events - */ - async realmEventsDeleteRaw(requestParameters: RealmEventsDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmEventsDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/events`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete all events - */ - async realmEventsDelete(requestParameters: RealmEventsDeleteRequest): Promise { - await this.realmEventsDeleteRaw(requestParameters); - } - - /** - * Get events Returns all events, or filters them based on URL query parameters listed here - */ - async realmEventsGetRaw(requestParameters: RealmEventsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmEventsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.client !== undefined) { - queryParameters['client'] = requestParameters.client; - } - - if (requestParameters.dateFrom !== undefined) { - queryParameters['dateFrom'] = requestParameters.dateFrom; - } - - if (requestParameters.dateTo !== undefined) { - queryParameters['dateTo'] = requestParameters.dateTo; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.ipAddress !== undefined) { - queryParameters['ipAddress'] = requestParameters.ipAddress; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.type) { - queryParameters['type'] = requestParameters.type; - } - - if (requestParameters.user !== undefined) { - queryParameters['user'] = requestParameters.user; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/events`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get events Returns all events, or filters them based on URL query parameters listed here - */ - async realmEventsGet(requestParameters: RealmEventsGetRequest): Promise> { - const response = await this.realmEventsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get the top-level representation of the realm It will not include nested information like User and Client representations. - */ - async realmGetRaw(requestParameters: RealmGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RealmRepresentationFromJSON(jsonValue)); - } - - /** - * Get the top-level representation of the realm It will not include nested information like User and Client representations. - */ - async realmGet(requestParameters: RealmGetRequest): Promise { - const response = await this.realmGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmGroupByPathPathGetRaw(requestParameters: RealmGroupByPathPathGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupByPathPathGet.'); - } - - if (requestParameters.path === null || requestParameters.path === undefined) { - throw new runtime.RequiredError('path','Required parameter requestParameters.path was null or undefined when calling realmGroupByPathPathGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/group-by-path/{path}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"path"}}`, encodeURIComponent(String(requestParameters.path))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => GroupRepresentationFromJSON(jsonValue)); - } - - /** - */ - async realmGroupByPathPathGet(requestParameters: RealmGroupByPathPathGetRequest): Promise { - const response = await this.realmGroupByPathPathGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get LDAP supported extensions. - */ - async realmLdapServerCapabilitiesPostRaw(requestParameters: RealmLdapServerCapabilitiesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLdapServerCapabilitiesPost.'); - } - - if (requestParameters.testLdapConnectionRepresentation === null || requestParameters.testLdapConnectionRepresentation === undefined) { - throw new runtime.RequiredError('testLdapConnectionRepresentation','Required parameter requestParameters.testLdapConnectionRepresentation was null or undefined when calling realmLdapServerCapabilitiesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/ldap-server-capabilities`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: TestLdapConnectionRepresentationToJSON(requestParameters.testLdapConnectionRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Get LDAP supported extensions. - */ - async realmLdapServerCapabilitiesPost(requestParameters: RealmLdapServerCapabilitiesPostRequest): Promise { - await this.realmLdapServerCapabilitiesPostRaw(requestParameters); - } - - /** - */ - async realmLocalizationGetRaw(requestParameters: RealmLocalizationGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmLocalizationGet(requestParameters: RealmLocalizationGetRequest): Promise> { - const response = await this.realmLocalizationGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmLocalizationLocaleDeleteRaw(requestParameters: RealmLocalizationLocaleDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocaleDelete.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocaleDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmLocalizationLocaleDelete(requestParameters: RealmLocalizationLocaleDeleteRequest): Promise { - await this.realmLocalizationLocaleDeleteRaw(requestParameters); - } - - /** - */ - async realmLocalizationLocaleGetRaw(requestParameters: RealmLocalizationLocaleGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocaleGet.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocaleGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmLocalizationLocaleGet(requestParameters: RealmLocalizationLocaleGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmLocalizationLocaleGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmLocalizationLocaleKeyDeleteRaw(requestParameters: RealmLocalizationLocaleKeyDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocaleKeyDelete.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocaleKeyDelete.'); - } - - if (requestParameters.key === null || requestParameters.key === undefined) { - throw new runtime.RequiredError('key','Required parameter requestParameters.key was null or undefined when calling realmLocalizationLocaleKeyDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}/{key}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))).replace(`{${"key"}}`, encodeURIComponent(String(requestParameters.key))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmLocalizationLocaleKeyDelete(requestParameters: RealmLocalizationLocaleKeyDeleteRequest): Promise { - await this.realmLocalizationLocaleKeyDeleteRaw(requestParameters); - } - - /** - */ - async realmLocalizationLocaleKeyGetRaw(requestParameters: RealmLocalizationLocaleKeyGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocaleKeyGet.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocaleKeyGet.'); - } - - if (requestParameters.key === null || requestParameters.key === undefined) { - throw new runtime.RequiredError('key','Required parameter requestParameters.key was null or undefined when calling realmLocalizationLocaleKeyGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}/{key}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))).replace(`{${"key"}}`, encodeURIComponent(String(requestParameters.key))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.TextApiResponse(response) as any; - } - - /** - */ - async realmLocalizationLocaleKeyGet(requestParameters: RealmLocalizationLocaleKeyGetRequest): Promise { - const response = await this.realmLocalizationLocaleKeyGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmLocalizationLocaleKeyPutRaw(requestParameters: RealmLocalizationLocaleKeyPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocaleKeyPut.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocaleKeyPut.'); - } - - if (requestParameters.key === null || requestParameters.key === undefined) { - throw new runtime.RequiredError('key','Required parameter requestParameters.key was null or undefined when calling realmLocalizationLocaleKeyPut.'); - } - - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling realmLocalizationLocaleKeyPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'text/plain'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}/{key}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))).replace(`{${"key"}}`, encodeURIComponent(String(requestParameters.key))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: requestParameters.body as any, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmLocalizationLocaleKeyPut(requestParameters: RealmLocalizationLocaleKeyPutRequest): Promise { - await this.realmLocalizationLocaleKeyPutRaw(requestParameters); - } - - /** - */ - async realmLocalizationLocalePostRaw(requestParameters: RealmLocalizationLocalePostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLocalizationLocalePost.'); - } - - if (requestParameters.locale === null || requestParameters.locale === undefined) { - throw new runtime.RequiredError('locale','Required parameter requestParameters.locale was null or undefined when calling realmLocalizationLocalePost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmLocalizationLocalePost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/localization/{locale}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"locale"}}`, encodeURIComponent(String(requestParameters.locale))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmLocalizationLocalePost(requestParameters: RealmLocalizationLocalePostRequest): Promise { - await this.realmLocalizationLocalePostRaw(requestParameters); - } - - /** - * Removes all user sessions. - */ - async realmLogoutAllPostRaw(requestParameters: RealmLogoutAllPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmLogoutAllPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/logout-all`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => GlobalRequestResultFromJSON(jsonValue)); - } - - /** - * Removes all user sessions. - */ - async realmLogoutAllPost(requestParameters: RealmLogoutAllPostRequest): Promise { - const response = await this.realmLogoutAllPostRaw(requestParameters); - return await response.value(); - } - - /** - * Partial export of existing realm into a JSON file. - */ - async realmPartialExportPostRaw(requestParameters: RealmPartialExportPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmPartialExportPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.exportClients !== undefined) { - queryParameters['exportClients'] = requestParameters.exportClients; - } - - if (requestParameters.exportGroupsAndRoles !== undefined) { - queryParameters['exportGroupsAndRoles'] = requestParameters.exportGroupsAndRoles; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/partial-export`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RealmRepresentationFromJSON(jsonValue)); - } - - /** - * Partial export of existing realm into a JSON file. - */ - async realmPartialExportPost(requestParameters: RealmPartialExportPostRequest): Promise { - const response = await this.realmPartialExportPostRaw(requestParameters); - return await response.value(); - } - - /** - * Partial import from a JSON file to an existing realm. - */ - async realmPartialImportPostRaw(requestParameters: RealmPartialImportPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmPartialImportPost.'); - } - - if (requestParameters.partialImportRepresentation === null || requestParameters.partialImportRepresentation === undefined) { - throw new runtime.RequiredError('partialImportRepresentation','Required parameter requestParameters.partialImportRepresentation was null or undefined when calling realmPartialImportPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/partialImport`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: PartialImportRepresentationToJSON(requestParameters.partialImportRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Partial import from a JSON file to an existing realm. - */ - async realmPartialImportPost(requestParameters: RealmPartialImportPostRequest): Promise { - await this.realmPartialImportPostRaw(requestParameters); - } - - /** - * Push the realm’s revocation policy to any client that has an admin url associated with it. - */ - async realmPushRevocationPostRaw(requestParameters: RealmPushRevocationPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmPushRevocationPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/push-revocation`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Push the realm’s revocation policy to any client that has an admin url associated with it. - */ - async realmPushRevocationPost(requestParameters: RealmPushRevocationPostRequest): Promise { - await this.realmPushRevocationPostRaw(requestParameters); - } - - /** - * Update the top-level information of the realm Any user, roles or client information in the representation will be ignored. - */ - async realmPutRaw(requestParameters: RealmPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmPut.'); - } - - if (requestParameters.realmRepresentation === null || requestParameters.realmRepresentation === undefined) { - throw new runtime.RequiredError('realmRepresentation','Required parameter requestParameters.realmRepresentation was null or undefined when calling realmPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RealmRepresentationToJSON(requestParameters.realmRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the top-level information of the realm Any user, roles or client information in the representation will be ignored. - */ - async realmPut(requestParameters: RealmPutRequest): Promise { - await this.realmPutRaw(requestParameters); - } - - /** - * Remove a specific user session. - */ - async realmSessionsSessionDeleteRaw(requestParameters: RealmSessionsSessionDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmSessionsSessionDelete.'); - } - - if (requestParameters.session === null || requestParameters.session === undefined) { - throw new runtime.RequiredError('session','Required parameter requestParameters.session was null or undefined when calling realmSessionsSessionDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/sessions/{session}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"session"}}`, encodeURIComponent(String(requestParameters.session))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a specific user session. - */ - async realmSessionsSessionDelete(requestParameters: RealmSessionsSessionDeleteRequest): Promise { - await this.realmSessionsSessionDeleteRaw(requestParameters); - } - - /** - * Test LDAP connection - */ - async realmTestLDAPConnectionPostRaw(requestParameters: RealmTestLDAPConnectionPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmTestLDAPConnectionPost.'); - } - - if (requestParameters.testLdapConnectionRepresentation === null || requestParameters.testLdapConnectionRepresentation === undefined) { - throw new runtime.RequiredError('testLdapConnectionRepresentation','Required parameter requestParameters.testLdapConnectionRepresentation was null or undefined when calling realmTestLDAPConnectionPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/testLDAPConnection`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: TestLdapConnectionRepresentationToJSON(requestParameters.testLdapConnectionRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Test LDAP connection - */ - async realmTestLDAPConnectionPost(requestParameters: RealmTestLDAPConnectionPostRequest): Promise { - await this.realmTestLDAPConnectionPostRaw(requestParameters); - } - - /** - */ - async realmTestSMTPConnectionPostRaw(requestParameters: RealmTestSMTPConnectionPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmTestSMTPConnectionPost.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmTestSMTPConnectionPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/testSMTPConnection`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmTestSMTPConnectionPost(requestParameters: RealmTestSMTPConnectionPostRequest): Promise { - await this.realmTestSMTPConnectionPostRaw(requestParameters); - } - - /** - */ - async realmUsersManagementPermissionsGetRaw(requestParameters: RealmUsersManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users-management-permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - */ - async realmUsersManagementPermissionsGet(requestParameters: RealmUsersManagementPermissionsGetRequest): Promise { - const response = await this.realmUsersManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmUsersManagementPermissionsPutRaw(requestParameters: RealmUsersManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmUsersManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users-management-permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - */ - async realmUsersManagementPermissionsPut(requestParameters: RealmUsersManagementPermissionsPutRequest): Promise { - const response = await this.realmUsersManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Import a realm Imports a realm from a full representation of that realm. - */ - async rootPostRaw(requestParameters: RootPostRequest): Promise> { - if (requestParameters.realmRepresentation === null || requestParameters.realmRepresentation === undefined) { - throw new runtime.RequiredError('realmRepresentation','Required parameter requestParameters.realmRepresentation was null or undefined when calling rootPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/`, - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: RealmRepresentationToJSON(requestParameters.realmRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Import a realm Imports a realm from a full representation of that realm. - */ - async rootPost(requestParameters: RootPostRequest): Promise { - await this.rootPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/RoleMapperApi.ts b/backend/keycloak/kc-client/apis/RoleMapperApi.ts deleted file mode 100644 index ec1cd2f..0000000 --- a/backend/keycloak/kc-client/apis/RoleMapperApi.ts +++ /dev/null @@ -1,633 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - MappingsRepresentation, - MappingsRepresentationFromJSON, - MappingsRepresentationToJSON, - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationToJSON, -} from '../models'; - -export interface RealmGroupsIdRoleMappingsGetRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdRoleMappingsRealmAvailableGetRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdRoleMappingsRealmCompositeGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; -} - -export interface RealmGroupsIdRoleMappingsRealmDeleteRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmGroupsIdRoleMappingsRealmGetRequest { - realm: string; - id: string; -} - -export interface RealmGroupsIdRoleMappingsRealmPostRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmUsersIdRoleMappingsGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdRoleMappingsRealmAvailableGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdRoleMappingsRealmCompositeGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; -} - -export interface RealmUsersIdRoleMappingsRealmDeleteRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmUsersIdRoleMappingsRealmGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdRoleMappingsRealmPostRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -/** - * - */ -export class RoleMapperApi extends runtime.BaseAPI { - - /** - * Get role mappings - */ - async realmGroupsIdRoleMappingsGetRaw(requestParameters: RealmGroupsIdRoleMappingsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => MappingsRepresentationFromJSON(jsonValue)); - } - - /** - * Get role mappings - */ - async realmGroupsIdRoleMappingsGet(requestParameters: RealmGroupsIdRoleMappingsGetRequest): Promise { - const response = await this.realmGroupsIdRoleMappingsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get realm-level roles that can be mapped - */ - async realmGroupsIdRoleMappingsRealmAvailableGetRaw(requestParameters: RealmGroupsIdRoleMappingsRealmAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsRealmAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsRealmAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/realm/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles that can be mapped - */ - async realmGroupsIdRoleMappingsRealmAvailableGet(requestParameters: RealmGroupsIdRoleMappingsRealmAvailableGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsRealmAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective realm-level role mappings This will recurse all composite roles to get the result. - */ - async realmGroupsIdRoleMappingsRealmCompositeGetRaw(requestParameters: RealmGroupsIdRoleMappingsRealmCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsRealmCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsRealmCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/realm/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective realm-level role mappings This will recurse all composite roles to get the result. - */ - async realmGroupsIdRoleMappingsRealmCompositeGet(requestParameters: RealmGroupsIdRoleMappingsRealmCompositeGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsRealmCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete realm-level role mappings - */ - async realmGroupsIdRoleMappingsRealmDeleteRaw(requestParameters: RealmGroupsIdRoleMappingsRealmDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsRealmDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsRealmDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmGroupsIdRoleMappingsRealmDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete realm-level role mappings - */ - async realmGroupsIdRoleMappingsRealmDelete(requestParameters: RealmGroupsIdRoleMappingsRealmDeleteRequest): Promise { - await this.realmGroupsIdRoleMappingsRealmDeleteRaw(requestParameters); - } - - /** - * Get realm-level role mappings - */ - async realmGroupsIdRoleMappingsRealmGetRaw(requestParameters: RealmGroupsIdRoleMappingsRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsRealmGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level role mappings - */ - async realmGroupsIdRoleMappingsRealmGet(requestParameters: RealmGroupsIdRoleMappingsRealmGetRequest): Promise> { - const response = await this.realmGroupsIdRoleMappingsRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add realm-level role mappings to the user - */ - async realmGroupsIdRoleMappingsRealmPostRaw(requestParameters: RealmGroupsIdRoleMappingsRealmPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmGroupsIdRoleMappingsRealmPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmGroupsIdRoleMappingsRealmPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmGroupsIdRoleMappingsRealmPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/groups/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add realm-level role mappings to the user - */ - async realmGroupsIdRoleMappingsRealmPost(requestParameters: RealmGroupsIdRoleMappingsRealmPostRequest): Promise { - await this.realmGroupsIdRoleMappingsRealmPostRaw(requestParameters); - } - - /** - * Get role mappings - */ - async realmUsersIdRoleMappingsGetRaw(requestParameters: RealmUsersIdRoleMappingsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => MappingsRepresentationFromJSON(jsonValue)); - } - - /** - * Get role mappings - */ - async realmUsersIdRoleMappingsGet(requestParameters: RealmUsersIdRoleMappingsGetRequest): Promise { - const response = await this.realmUsersIdRoleMappingsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get realm-level roles that can be mapped - */ - async realmUsersIdRoleMappingsRealmAvailableGetRaw(requestParameters: RealmUsersIdRoleMappingsRealmAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsRealmAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsRealmAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/realm/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles that can be mapped - */ - async realmUsersIdRoleMappingsRealmAvailableGet(requestParameters: RealmUsersIdRoleMappingsRealmAvailableGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsRealmAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective realm-level role mappings This will recurse all composite roles to get the result. - */ - async realmUsersIdRoleMappingsRealmCompositeGetRaw(requestParameters: RealmUsersIdRoleMappingsRealmCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsRealmCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsRealmCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/realm/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective realm-level role mappings This will recurse all composite roles to get the result. - */ - async realmUsersIdRoleMappingsRealmCompositeGet(requestParameters: RealmUsersIdRoleMappingsRealmCompositeGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsRealmCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete realm-level role mappings - */ - async realmUsersIdRoleMappingsRealmDeleteRaw(requestParameters: RealmUsersIdRoleMappingsRealmDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsRealmDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsRealmDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmUsersIdRoleMappingsRealmDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete realm-level role mappings - */ - async realmUsersIdRoleMappingsRealmDelete(requestParameters: RealmUsersIdRoleMappingsRealmDeleteRequest): Promise { - await this.realmUsersIdRoleMappingsRealmDeleteRaw(requestParameters); - } - - /** - * Get realm-level role mappings - */ - async realmUsersIdRoleMappingsRealmGetRaw(requestParameters: RealmUsersIdRoleMappingsRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsRealmGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level role mappings - */ - async realmUsersIdRoleMappingsRealmGet(requestParameters: RealmUsersIdRoleMappingsRealmGetRequest): Promise> { - const response = await this.realmUsersIdRoleMappingsRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add realm-level role mappings to the user - */ - async realmUsersIdRoleMappingsRealmPostRaw(requestParameters: RealmUsersIdRoleMappingsRealmPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdRoleMappingsRealmPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdRoleMappingsRealmPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmUsersIdRoleMappingsRealmPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/role-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add realm-level role mappings to the user - */ - async realmUsersIdRoleMappingsRealmPost(requestParameters: RealmUsersIdRoleMappingsRealmPostRequest): Promise { - await this.realmUsersIdRoleMappingsRealmPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/RolesApi.ts b/backend/keycloak/kc-client/apis/RolesApi.ts deleted file mode 100644 index cd017ce..0000000 --- a/backend/keycloak/kc-client/apis/RolesApi.ts +++ /dev/null @@ -1,1567 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationToJSON, -} from '../models'; - -export interface RealmClientsIdRolesGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; - first?: number; - max?: number; - search?: string; -} - -export interface RealmClientsIdRolesPostRequest { - realm: string; - id: string; - roleRepresentation: RoleRepresentation; -} - -export interface RealmClientsIdRolesRoleNameCompositesClientsClientUuidGetRequest { - realm: string; - id: string; - roleName: string; - clientUuid: string; -} - -export interface RealmClientsIdRolesRoleNameCompositesDeleteRequest { - realm: string; - id: string; - roleName: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdRolesRoleNameCompositesGetRequest { - realm: string; - id: string; - roleName: string; -} - -export interface RealmClientsIdRolesRoleNameCompositesPostRequest { - realm: string; - id: string; - roleName: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdRolesRoleNameCompositesRealmGetRequest { - realm: string; - id: string; - roleName: string; -} - -export interface RealmClientsIdRolesRoleNameDeleteRequest { - realm: string; - id: string; - roleName: string; -} - -export interface RealmClientsIdRolesRoleNameGetRequest { - realm: string; - id: string; - roleName: string; -} - -export interface RealmClientsIdRolesRoleNameGroupsGetRequest { - realm: string; - id: string; - roleName: string; - briefRepresentation?: boolean; - first?: number; - max?: number; -} - -export interface RealmClientsIdRolesRoleNameManagementPermissionsGetRequest { - realm: string; - id: string; - roleName: string; -} - -export interface RealmClientsIdRolesRoleNameManagementPermissionsPutRequest { - realm: string; - id: string; - roleName: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmClientsIdRolesRoleNamePutRequest { - realm: string; - id: string; - roleName: string; - roleRepresentation: RoleRepresentation; -} - -export interface RealmClientsIdRolesRoleNameUsersGetRequest { - realm: string; - id: string; - roleName: string; - first?: number; - max?: number; -} - -export interface RealmRolesGetRequest { - realm: string; - briefRepresentation?: boolean; - first?: number; - max?: number; - search?: string; -} - -export interface RealmRolesPostRequest { - realm: string; - roleRepresentation: RoleRepresentation; -} - -export interface RealmRolesRoleNameCompositesClientsClientUuidGetRequest { - realm: string; - roleName: string; - clientUuid: string; -} - -export interface RealmRolesRoleNameCompositesDeleteRequest { - realm: string; - roleName: string; - roleRepresentation: Array; -} - -export interface RealmRolesRoleNameCompositesGetRequest { - realm: string; - roleName: string; -} - -export interface RealmRolesRoleNameCompositesPostRequest { - realm: string; - roleName: string; - roleRepresentation: Array; -} - -export interface RealmRolesRoleNameCompositesRealmGetRequest { - realm: string; - roleName: string; -} - -export interface RealmRolesRoleNameDeleteRequest { - realm: string; - roleName: string; -} - -export interface RealmRolesRoleNameGetRequest { - realm: string; - roleName: string; -} - -export interface RealmRolesRoleNameGroupsGetRequest { - realm: string; - roleName: string; - briefRepresentation?: boolean; - first?: number; - max?: number; -} - -export interface RealmRolesRoleNameManagementPermissionsGetRequest { - realm: string; - roleName: string; -} - -export interface RealmRolesRoleNameManagementPermissionsPutRequest { - realm: string; - roleName: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmRolesRoleNamePutRequest { - realm: string; - roleName: string; - roleRepresentation: RoleRepresentation; -} - -export interface RealmRolesRoleNameUsersGetRequest { - realm: string; - roleName: string; - first?: number; - max?: number; -} - -/** - * - */ -export class RolesApi extends runtime.BaseAPI { - - /** - * Get all roles for the realm or client - */ - async realmClientsIdRolesGetRaw(requestParameters: RealmClientsIdRolesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get all roles for the realm or client - */ - async realmClientsIdRolesGet(requestParameters: RealmClientsIdRolesGetRequest): Promise> { - const response = await this.realmClientsIdRolesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a new role for the realm or client - */ - async realmClientsIdRolesPostRaw(requestParameters: RealmClientsIdRolesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdRolesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: RoleRepresentationToJSON(requestParameters.roleRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new role for the realm or client - */ - async realmClientsIdRolesPost(requestParameters: RealmClientsIdRolesPostRequest): Promise { - await this.realmClientsIdRolesPostRaw(requestParameters); - } - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesClientsClientUuidGetRaw(requestParameters: RealmClientsIdRolesRoleNameCompositesClientsClientUuidGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameCompositesClientsClientUuidGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameCompositesClientsClientUuidGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameCompositesClientsClientUuidGet.'); - } - - if (requestParameters.clientUuid === null || requestParameters.clientUuid === undefined) { - throw new runtime.RequiredError('clientUuid','Required parameter requestParameters.clientUuid was null or undefined when calling realmClientsIdRolesRoleNameCompositesClientsClientUuidGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/composites/clients/{clientUuid}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))).replace(`{${"clientUuid"}}`, encodeURIComponent(String(requestParameters.clientUuid))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesClientsClientUuidGet(requestParameters: RealmClientsIdRolesRoleNameCompositesClientsClientUuidGetRequest): Promise> { - const response = await this.realmClientsIdRolesRoleNameCompositesClientsClientUuidGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove roles from the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesDeleteRaw(requestParameters: RealmClientsIdRolesRoleNameCompositesDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameCompositesDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameCompositesDelete.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameCompositesDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdRolesRoleNameCompositesDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove roles from the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesDelete(requestParameters: RealmClientsIdRolesRoleNameCompositesDeleteRequest): Promise { - await this.realmClientsIdRolesRoleNameCompositesDeleteRaw(requestParameters); - } - - /** - * Get composites of the role - */ - async realmClientsIdRolesRoleNameCompositesGetRaw(requestParameters: RealmClientsIdRolesRoleNameCompositesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameCompositesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameCompositesGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameCompositesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get composites of the role - */ - async realmClientsIdRolesRoleNameCompositesGet(requestParameters: RealmClientsIdRolesRoleNameCompositesGetRequest): Promise> { - const response = await this.realmClientsIdRolesRoleNameCompositesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add a composite to the role - */ - async realmClientsIdRolesRoleNameCompositesPostRaw(requestParameters: RealmClientsIdRolesRoleNameCompositesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameCompositesPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameCompositesPost.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameCompositesPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdRolesRoleNameCompositesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a composite to the role - */ - async realmClientsIdRolesRoleNameCompositesPost(requestParameters: RealmClientsIdRolesRoleNameCompositesPostRequest): Promise { - await this.realmClientsIdRolesRoleNameCompositesPostRaw(requestParameters); - } - - /** - * Get realm-level roles of the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesRealmGetRaw(requestParameters: RealmClientsIdRolesRoleNameCompositesRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameCompositesRealmGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameCompositesRealmGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameCompositesRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/composites/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles of the role’s composite - */ - async realmClientsIdRolesRoleNameCompositesRealmGet(requestParameters: RealmClientsIdRolesRoleNameCompositesRealmGetRequest): Promise> { - const response = await this.realmClientsIdRolesRoleNameCompositesRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete a role by name - */ - async realmClientsIdRolesRoleNameDeleteRaw(requestParameters: RealmClientsIdRolesRoleNameDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameDelete.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete a role by name - */ - async realmClientsIdRolesRoleNameDelete(requestParameters: RealmClientsIdRolesRoleNameDeleteRequest): Promise { - await this.realmClientsIdRolesRoleNameDeleteRaw(requestParameters); - } - - /** - * Get a role by name - */ - async realmClientsIdRolesRoleNameGetRaw(requestParameters: RealmClientsIdRolesRoleNameGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RoleRepresentationFromJSON(jsonValue)); - } - - /** - * Get a role by name - */ - async realmClientsIdRolesRoleNameGet(requestParameters: RealmClientsIdRolesRoleNameGetRequest): Promise { - const response = await this.realmClientsIdRolesRoleNameGetRaw(requestParameters); - return await response.value(); - } - - /** - * Returns a stream of groups that have the specified role name - */ - async realmClientsIdRolesRoleNameGroupsGetRaw(requestParameters: RealmClientsIdRolesRoleNameGroupsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameGroupsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameGroupsGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameGroupsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Returns a stream of groups that have the specified role name - */ - async realmClientsIdRolesRoleNameGroupsGet(requestParameters: RealmClientsIdRolesRoleNameGroupsGetRequest): Promise> { - const response = await this.realmClientsIdRolesRoleNameGroupsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdRolesRoleNameManagementPermissionsGetRaw(requestParameters: RealmClientsIdRolesRoleNameManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdRolesRoleNameManagementPermissionsGet(requestParameters: RealmClientsIdRolesRoleNameManagementPermissionsGetRequest): Promise { - const response = await this.realmClientsIdRolesRoleNameManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdRolesRoleNameManagementPermissionsPutRaw(requestParameters: RealmClientsIdRolesRoleNameManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsPut.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmClientsIdRolesRoleNameManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmClientsIdRolesRoleNameManagementPermissionsPut(requestParameters: RealmClientsIdRolesRoleNameManagementPermissionsPutRequest): Promise { - const response = await this.realmClientsIdRolesRoleNameManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Update a role by name - */ - async realmClientsIdRolesRoleNamePutRaw(requestParameters: RealmClientsIdRolesRoleNamePutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNamePut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNamePut.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNamePut.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdRolesRoleNamePut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RoleRepresentationToJSON(requestParameters.roleRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update a role by name - */ - async realmClientsIdRolesRoleNamePut(requestParameters: RealmClientsIdRolesRoleNamePutRequest): Promise { - await this.realmClientsIdRolesRoleNamePutRaw(requestParameters); - } - - /** - * Returns a stream of users that have the specified role name. - */ - async realmClientsIdRolesRoleNameUsersGetRaw(requestParameters: RealmClientsIdRolesRoleNameUsersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdRolesRoleNameUsersGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdRolesRoleNameUsersGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmClientsIdRolesRoleNameUsersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/roles/{role-name}/users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Returns a stream of users that have the specified role name. - */ - async realmClientsIdRolesRoleNameUsersGet(requestParameters: RealmClientsIdRolesRoleNameUsersGetRequest): Promise> { - const response = await this.realmClientsIdRolesRoleNameUsersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get all roles for the realm or client - */ - async realmRolesGetRaw(requestParameters: RealmRolesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get all roles for the realm or client - */ - async realmRolesGet(requestParameters: RealmRolesGetRequest): Promise> { - const response = await this.realmRolesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a new role for the realm or client - */ - async realmRolesPostRaw(requestParameters: RealmRolesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: RoleRepresentationToJSON(requestParameters.roleRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new role for the realm or client - */ - async realmRolesPost(requestParameters: RealmRolesPostRequest): Promise { - await this.realmRolesPostRaw(requestParameters); - } - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmRolesRoleNameCompositesClientsClientUuidGetRaw(requestParameters: RealmRolesRoleNameCompositesClientsClientUuidGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameCompositesClientsClientUuidGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameCompositesClientsClientUuidGet.'); - } - - if (requestParameters.clientUuid === null || requestParameters.clientUuid === undefined) { - throw new runtime.RequiredError('clientUuid','Required parameter requestParameters.clientUuid was null or undefined when calling realmRolesRoleNameCompositesClientsClientUuidGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/composites/clients/{clientUuid}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))).replace(`{${"clientUuid"}}`, encodeURIComponent(String(requestParameters.clientUuid))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmRolesRoleNameCompositesClientsClientUuidGet(requestParameters: RealmRolesRoleNameCompositesClientsClientUuidGetRequest): Promise> { - const response = await this.realmRolesRoleNameCompositesClientsClientUuidGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove roles from the role’s composite - */ - async realmRolesRoleNameCompositesDeleteRaw(requestParameters: RealmRolesRoleNameCompositesDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameCompositesDelete.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameCompositesDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesRoleNameCompositesDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove roles from the role’s composite - */ - async realmRolesRoleNameCompositesDelete(requestParameters: RealmRolesRoleNameCompositesDeleteRequest): Promise { - await this.realmRolesRoleNameCompositesDeleteRaw(requestParameters); - } - - /** - * Get composites of the role - */ - async realmRolesRoleNameCompositesGetRaw(requestParameters: RealmRolesRoleNameCompositesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameCompositesGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameCompositesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get composites of the role - */ - async realmRolesRoleNameCompositesGet(requestParameters: RealmRolesRoleNameCompositesGetRequest): Promise> { - const response = await this.realmRolesRoleNameCompositesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add a composite to the role - */ - async realmRolesRoleNameCompositesPostRaw(requestParameters: RealmRolesRoleNameCompositesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameCompositesPost.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameCompositesPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesRoleNameCompositesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a composite to the role - */ - async realmRolesRoleNameCompositesPost(requestParameters: RealmRolesRoleNameCompositesPostRequest): Promise { - await this.realmRolesRoleNameCompositesPostRaw(requestParameters); - } - - /** - * Get realm-level roles of the role’s composite - */ - async realmRolesRoleNameCompositesRealmGetRaw(requestParameters: RealmRolesRoleNameCompositesRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameCompositesRealmGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameCompositesRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/composites/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles of the role’s composite - */ - async realmRolesRoleNameCompositesRealmGet(requestParameters: RealmRolesRoleNameCompositesRealmGetRequest): Promise> { - const response = await this.realmRolesRoleNameCompositesRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete a role by name - */ - async realmRolesRoleNameDeleteRaw(requestParameters: RealmRolesRoleNameDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameDelete.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete a role by name - */ - async realmRolesRoleNameDelete(requestParameters: RealmRolesRoleNameDeleteRequest): Promise { - await this.realmRolesRoleNameDeleteRaw(requestParameters); - } - - /** - * Get a role by name - */ - async realmRolesRoleNameGetRaw(requestParameters: RealmRolesRoleNameGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RoleRepresentationFromJSON(jsonValue)); - } - - /** - * Get a role by name - */ - async realmRolesRoleNameGet(requestParameters: RealmRolesRoleNameGetRequest): Promise { - const response = await this.realmRolesRoleNameGetRaw(requestParameters); - return await response.value(); - } - - /** - * Returns a stream of groups that have the specified role name - */ - async realmRolesRoleNameGroupsGetRaw(requestParameters: RealmRolesRoleNameGroupsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameGroupsGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameGroupsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Returns a stream of groups that have the specified role name - */ - async realmRolesRoleNameGroupsGet(requestParameters: RealmRolesRoleNameGroupsGetRequest): Promise> { - const response = await this.realmRolesRoleNameGroupsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmRolesRoleNameManagementPermissionsGetRaw(requestParameters: RealmRolesRoleNameManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameManagementPermissionsGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmRolesRoleNameManagementPermissionsGet(requestParameters: RealmRolesRoleNameManagementPermissionsGetRequest): Promise { - const response = await this.realmRolesRoleNameManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmRolesRoleNameManagementPermissionsPutRaw(requestParameters: RealmRolesRoleNameManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameManagementPermissionsPut.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmRolesRoleNameManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authorization permissions have been initialized or not and a reference - */ - async realmRolesRoleNameManagementPermissionsPut(requestParameters: RealmRolesRoleNameManagementPermissionsPutRequest): Promise { - const response = await this.realmRolesRoleNameManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Update a role by name - */ - async realmRolesRoleNamePutRaw(requestParameters: RealmRolesRoleNamePutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNamePut.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNamePut.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesRoleNamePut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RoleRepresentationToJSON(requestParameters.roleRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update a role by name - */ - async realmRolesRoleNamePut(requestParameters: RealmRolesRoleNamePutRequest): Promise { - await this.realmRolesRoleNamePutRaw(requestParameters); - } - - /** - * Returns a stream of users that have the specified role name. - */ - async realmRolesRoleNameUsersGetRaw(requestParameters: RealmRolesRoleNameUsersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesRoleNameUsersGet.'); - } - - if (requestParameters.roleName === null || requestParameters.roleName === undefined) { - throw new runtime.RequiredError('roleName','Required parameter requestParameters.roleName was null or undefined when calling realmRolesRoleNameUsersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles/{role-name}/users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-name"}}`, encodeURIComponent(String(requestParameters.roleName))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Returns a stream of users that have the specified role name. - */ - async realmRolesRoleNameUsersGet(requestParameters: RealmRolesRoleNameUsersGetRequest): Promise> { - const response = await this.realmRolesRoleNameUsersGetRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/RolesByIDApi.ts b/backend/keycloak/kc-client/apis/RolesByIDApi.ts deleted file mode 100644 index 099bb8b..0000000 --- a/backend/keycloak/kc-client/apis/RolesByIDApi.ts +++ /dev/null @@ -1,549 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ManagementPermissionReference, - ManagementPermissionReferenceFromJSON, - ManagementPermissionReferenceToJSON, - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationToJSON, -} from '../models'; - -export interface RealmRolesByIdRoleIdCompositesClientsClientUuidGetRequest { - realm: string; - roleId: string; - clientUuid: string; -} - -export interface RealmRolesByIdRoleIdCompositesDeleteRequest { - realm: string; - roleId: string; - roleRepresentation: Array; -} - -export interface RealmRolesByIdRoleIdCompositesGetRequest { - realm: string; - roleId: string; - first?: number; - max?: number; - search?: string; -} - -export interface RealmRolesByIdRoleIdCompositesPostRequest { - realm: string; - roleId: string; - roleRepresentation: Array; -} - -export interface RealmRolesByIdRoleIdCompositesRealmGetRequest { - realm: string; - roleId: string; -} - -export interface RealmRolesByIdRoleIdDeleteRequest { - realm: string; - roleId: string; -} - -export interface RealmRolesByIdRoleIdGetRequest { - realm: string; - roleId: string; -} - -export interface RealmRolesByIdRoleIdManagementPermissionsGetRequest { - realm: string; - roleId: string; -} - -export interface RealmRolesByIdRoleIdManagementPermissionsPutRequest { - realm: string; - roleId: string; - managementPermissionReference: ManagementPermissionReference; -} - -export interface RealmRolesByIdRoleIdPutRequest { - realm: string; - roleId: string; - roleRepresentation: RoleRepresentation; -} - -/** - * - */ -export class RolesByIDApi extends runtime.BaseAPI { - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmRolesByIdRoleIdCompositesClientsClientUuidGetRaw(requestParameters: RealmRolesByIdRoleIdCompositesClientsClientUuidGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdCompositesClientsClientUuidGet.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdCompositesClientsClientUuidGet.'); - } - - if (requestParameters.clientUuid === null || requestParameters.clientUuid === undefined) { - throw new runtime.RequiredError('clientUuid','Required parameter requestParameters.clientUuid was null or undefined when calling realmRolesByIdRoleIdCompositesClientsClientUuidGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/composites/clients/{clientUuid}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))).replace(`{${"clientUuid"}}`, encodeURIComponent(String(requestParameters.clientUuid))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get client-level roles for the client that are in the role’s composite - */ - async realmRolesByIdRoleIdCompositesClientsClientUuidGet(requestParameters: RealmRolesByIdRoleIdCompositesClientsClientUuidGetRequest): Promise> { - const response = await this.realmRolesByIdRoleIdCompositesClientsClientUuidGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove a set of roles from the role’s composite - */ - async realmRolesByIdRoleIdCompositesDeleteRaw(requestParameters: RealmRolesByIdRoleIdCompositesDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdCompositesDelete.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdCompositesDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesByIdRoleIdCompositesDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a set of roles from the role’s composite - */ - async realmRolesByIdRoleIdCompositesDelete(requestParameters: RealmRolesByIdRoleIdCompositesDeleteRequest): Promise { - await this.realmRolesByIdRoleIdCompositesDeleteRaw(requestParameters); - } - - /** - * Get role’s children Returns a set of role’s children provided the role is a composite. - */ - async realmRolesByIdRoleIdCompositesGetRaw(requestParameters: RealmRolesByIdRoleIdCompositesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdCompositesGet.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdCompositesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get role’s children Returns a set of role’s children provided the role is a composite. - */ - async realmRolesByIdRoleIdCompositesGet(requestParameters: RealmRolesByIdRoleIdCompositesGetRequest): Promise> { - const response = await this.realmRolesByIdRoleIdCompositesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Make the role a composite role by associating some child roles - */ - async realmRolesByIdRoleIdCompositesPostRaw(requestParameters: RealmRolesByIdRoleIdCompositesPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdCompositesPost.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdCompositesPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesByIdRoleIdCompositesPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/composites`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Make the role a composite role by associating some child roles - */ - async realmRolesByIdRoleIdCompositesPost(requestParameters: RealmRolesByIdRoleIdCompositesPostRequest): Promise { - await this.realmRolesByIdRoleIdCompositesPostRaw(requestParameters); - } - - /** - * Get realm-level roles that are in the role’s composite - */ - async realmRolesByIdRoleIdCompositesRealmGetRaw(requestParameters: RealmRolesByIdRoleIdCompositesRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdCompositesRealmGet.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdCompositesRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/composites/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles that are in the role’s composite - */ - async realmRolesByIdRoleIdCompositesRealmGet(requestParameters: RealmRolesByIdRoleIdCompositesRealmGetRequest): Promise> { - const response = await this.realmRolesByIdRoleIdCompositesRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the role - */ - async realmRolesByIdRoleIdDeleteRaw(requestParameters: RealmRolesByIdRoleIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdDelete.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the role - */ - async realmRolesByIdRoleIdDelete(requestParameters: RealmRolesByIdRoleIdDeleteRequest): Promise { - await this.realmRolesByIdRoleIdDeleteRaw(requestParameters); - } - - /** - * Get a specific role’s representation - */ - async realmRolesByIdRoleIdGetRaw(requestParameters: RealmRolesByIdRoleIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdGet.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => RoleRepresentationFromJSON(jsonValue)); - } - - /** - * Get a specific role’s representation - */ - async realmRolesByIdRoleIdGet(requestParameters: RealmRolesByIdRoleIdGetRequest): Promise { - const response = await this.realmRolesByIdRoleIdGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authoirzation permissions have been initialized or not and a reference - */ - async realmRolesByIdRoleIdManagementPermissionsGetRaw(requestParameters: RealmRolesByIdRoleIdManagementPermissionsGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdManagementPermissionsGet.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdManagementPermissionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authoirzation permissions have been initialized or not and a reference - */ - async realmRolesByIdRoleIdManagementPermissionsGet(requestParameters: RealmRolesByIdRoleIdManagementPermissionsGetRequest): Promise { - const response = await this.realmRolesByIdRoleIdManagementPermissionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return object stating whether role Authoirzation permissions have been initialized or not and a reference - */ - async realmRolesByIdRoleIdManagementPermissionsPutRaw(requestParameters: RealmRolesByIdRoleIdManagementPermissionsPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdManagementPermissionsPut.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdManagementPermissionsPut.'); - } - - if (requestParameters.managementPermissionReference === null || requestParameters.managementPermissionReference === undefined) { - throw new runtime.RequiredError('managementPermissionReference','Required parameter requestParameters.managementPermissionReference was null or undefined when calling realmRolesByIdRoleIdManagementPermissionsPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}/management/permissions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: ManagementPermissionReferenceToJSON(requestParameters.managementPermissionReference), - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ManagementPermissionReferenceFromJSON(jsonValue)); - } - - /** - * Return object stating whether role Authoirzation permissions have been initialized or not and a reference - */ - async realmRolesByIdRoleIdManagementPermissionsPut(requestParameters: RealmRolesByIdRoleIdManagementPermissionsPutRequest): Promise { - const response = await this.realmRolesByIdRoleIdManagementPermissionsPutRaw(requestParameters); - return await response.value(); - } - - /** - * Update the role - */ - async realmRolesByIdRoleIdPutRaw(requestParameters: RealmRolesByIdRoleIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmRolesByIdRoleIdPut.'); - } - - if (requestParameters.roleId === null || requestParameters.roleId === undefined) { - throw new runtime.RequiredError('roleId','Required parameter requestParameters.roleId was null or undefined when calling realmRolesByIdRoleIdPut.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmRolesByIdRoleIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/roles-by-id/{role-id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"role-id"}}`, encodeURIComponent(String(requestParameters.roleId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: RoleRepresentationToJSON(requestParameters.roleRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the role - */ - async realmRolesByIdRoleIdPut(requestParameters: RealmRolesByIdRoleIdPutRequest): Promise { - await this.realmRolesByIdRoleIdPutRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/RootApi.ts b/backend/keycloak/kc-client/apis/RootApi.ts deleted file mode 100644 index 317811f..0000000 --- a/backend/keycloak/kc-client/apis/RootApi.ts +++ /dev/null @@ -1,62 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - ServerInfoRepresentation, - ServerInfoRepresentationFromJSON, - ServerInfoRepresentationToJSON, -} from '../models'; - -/** - * - */ -export class RootApi extends runtime.BaseAPI { - - /** - * Get themes, social providers, auth providers, and event listeners available on this server - */ - async rootGetRaw(): Promise> { - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/`, - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => ServerInfoRepresentationFromJSON(jsonValue)); - } - - /** - * Get themes, social providers, auth providers, and event listeners available on this server - */ - async rootGet(): Promise { - const response = await this.rootGetRaw(); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/ScopeMappingsApi.ts b/backend/keycloak/kc-client/apis/ScopeMappingsApi.ts deleted file mode 100644 index fc4b96d..0000000 --- a/backend/keycloak/kc-client/apis/ScopeMappingsApi.ts +++ /dev/null @@ -1,1094 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationToJSON, -} from '../models'; - -export interface RealmClientScopesIdScopeMappingsClientsClientAvailableGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmClientScopesIdScopeMappingsClientsClientCompositeGetRequest { - realm: string; - id: string; - client: string; - briefRepresentation?: boolean; -} - -export interface RealmClientScopesIdScopeMappingsClientsClientDeleteRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmClientScopesIdScopeMappingsClientsClientGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmClientScopesIdScopeMappingsClientsClientPostRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmClientScopesIdScopeMappingsRealmAvailableGetRequest { - realm: string; - id: string; -} - -export interface RealmClientScopesIdScopeMappingsRealmCompositeGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; -} - -export interface RealmClientScopesIdScopeMappingsRealmDeleteRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmClientScopesIdScopeMappingsRealmGetRequest { - realm: string; - id: string; -} - -export interface RealmClientScopesIdScopeMappingsRealmPostRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdScopeMappingsClientsClientAvailableGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmClientsIdScopeMappingsClientsClientCompositeGetRequest { - realm: string; - id: string; - client: string; - briefRepresentation?: boolean; -} - -export interface RealmClientsIdScopeMappingsClientsClientDeleteRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdScopeMappingsClientsClientGetRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmClientsIdScopeMappingsClientsClientPostRequest { - realm: string; - id: string; - client: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdScopeMappingsRealmAvailableGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdScopeMappingsRealmCompositeGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; -} - -export interface RealmClientsIdScopeMappingsRealmDeleteRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -export interface RealmClientsIdScopeMappingsRealmGetRequest { - realm: string; - id: string; -} - -export interface RealmClientsIdScopeMappingsRealmPostRequest { - realm: string; - id: string; - roleRepresentation: Array; -} - -/** - * - */ -export class ScopeMappingsApi extends runtime.BaseAPI { - - /** - * The available client-level roles Returns the roles for the client that can be associated with the client’s scope - */ - async realmClientScopesIdScopeMappingsClientsClientAvailableGetRaw(requestParameters: RealmClientScopesIdScopeMappingsClientsClientAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/clients/{client}/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * The available client-level roles Returns the roles for the client that can be associated with the client’s scope - */ - async realmClientScopesIdScopeMappingsClientsClientAvailableGet(requestParameters: RealmClientScopesIdScopeMappingsClientsClientAvailableGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsClientsClientAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective client roles Returns the roles for the client that are associated with the client’s scope. - */ - async realmClientScopesIdScopeMappingsClientsClientCompositeGetRaw(requestParameters: RealmClientScopesIdScopeMappingsClientsClientCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/clients/{client}/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective client roles Returns the roles for the client that are associated with the client’s scope. - */ - async realmClientScopesIdScopeMappingsClientsClientCompositeGet(requestParameters: RealmClientScopesIdScopeMappingsClientsClientCompositeGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsClientsClientCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove client-level roles from the client’s scope. - */ - async realmClientScopesIdScopeMappingsClientsClientDeleteRaw(requestParameters: RealmClientScopesIdScopeMappingsClientsClientDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove client-level roles from the client’s scope. - */ - async realmClientScopesIdScopeMappingsClientsClientDelete(requestParameters: RealmClientScopesIdScopeMappingsClientsClientDeleteRequest): Promise { - await this.realmClientScopesIdScopeMappingsClientsClientDeleteRaw(requestParameters); - } - - /** - * Get the roles associated with a client’s scope Returns roles for the client. - */ - async realmClientScopesIdScopeMappingsClientsClientGetRaw(requestParameters: RealmClientScopesIdScopeMappingsClientsClientGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get the roles associated with a client’s scope Returns roles for the client. - */ - async realmClientScopesIdScopeMappingsClientsClientGet(requestParameters: RealmClientScopesIdScopeMappingsClientsClientGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsClientsClientGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add client-level roles to the client’s scope - */ - async realmClientScopesIdScopeMappingsClientsClientPostRaw(requestParameters: RealmClientScopesIdScopeMappingsClientsClientPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientScopesIdScopeMappingsClientsClientPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add client-level roles to the client’s scope - */ - async realmClientScopesIdScopeMappingsClientsClientPost(requestParameters: RealmClientScopesIdScopeMappingsClientsClientPostRequest): Promise { - await this.realmClientScopesIdScopeMappingsClientsClientPostRaw(requestParameters); - } - - /** - * Get realm-level roles that are available to attach to this client’s scope - */ - async realmClientScopesIdScopeMappingsRealmAvailableGetRaw(requestParameters: RealmClientScopesIdScopeMappingsRealmAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsRealmAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsRealmAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/realm/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles that are available to attach to this client’s scope - */ - async realmClientScopesIdScopeMappingsRealmAvailableGet(requestParameters: RealmClientScopesIdScopeMappingsRealmAvailableGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsRealmAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective realm-level roles associated with the client’s scope What this does is recurse any composite roles associated with the client’s scope and adds the roles to this lists. - */ - async realmClientScopesIdScopeMappingsRealmCompositeGetRaw(requestParameters: RealmClientScopesIdScopeMappingsRealmCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsRealmCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsRealmCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/realm/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective realm-level roles associated with the client’s scope What this does is recurse any composite roles associated with the client’s scope and adds the roles to this lists. - */ - async realmClientScopesIdScopeMappingsRealmCompositeGet(requestParameters: RealmClientScopesIdScopeMappingsRealmCompositeGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsRealmCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove a set of realm-level roles from the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmDeleteRaw(requestParameters: RealmClientScopesIdScopeMappingsRealmDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsRealmDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsRealmDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientScopesIdScopeMappingsRealmDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a set of realm-level roles from the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmDelete(requestParameters: RealmClientScopesIdScopeMappingsRealmDeleteRequest): Promise { - await this.realmClientScopesIdScopeMappingsRealmDeleteRaw(requestParameters); - } - - /** - * Get realm-level roles associated with the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmGetRaw(requestParameters: RealmClientScopesIdScopeMappingsRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsRealmGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles associated with the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmGet(requestParameters: RealmClientScopesIdScopeMappingsRealmGetRequest): Promise> { - const response = await this.realmClientScopesIdScopeMappingsRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add a set of realm-level roles to the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmPostRaw(requestParameters: RealmClientScopesIdScopeMappingsRealmPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientScopesIdScopeMappingsRealmPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientScopesIdScopeMappingsRealmPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientScopesIdScopeMappingsRealmPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/client-scopes/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a set of realm-level roles to the client’s scope - */ - async realmClientScopesIdScopeMappingsRealmPost(requestParameters: RealmClientScopesIdScopeMappingsRealmPostRequest): Promise { - await this.realmClientScopesIdScopeMappingsRealmPostRaw(requestParameters); - } - - /** - * The available client-level roles Returns the roles for the client that can be associated with the client’s scope - */ - async realmClientsIdScopeMappingsClientsClientAvailableGetRaw(requestParameters: RealmClientsIdScopeMappingsClientsClientAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsClientsClientAvailableGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientsIdScopeMappingsClientsClientAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/clients/{client}/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * The available client-level roles Returns the roles for the client that can be associated with the client’s scope - */ - async realmClientsIdScopeMappingsClientsClientAvailableGet(requestParameters: RealmClientsIdScopeMappingsClientsClientAvailableGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsClientsClientAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective client roles Returns the roles for the client that are associated with the client’s scope. - */ - async realmClientsIdScopeMappingsClientsClientCompositeGetRaw(requestParameters: RealmClientsIdScopeMappingsClientsClientCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsClientsClientCompositeGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientsIdScopeMappingsClientsClientCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/clients/{client}/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective client roles Returns the roles for the client that are associated with the client’s scope. - */ - async realmClientsIdScopeMappingsClientsClientCompositeGet(requestParameters: RealmClientsIdScopeMappingsClientsClientCompositeGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsClientsClientCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove client-level roles from the client’s scope. - */ - async realmClientsIdScopeMappingsClientsClientDeleteRaw(requestParameters: RealmClientsIdScopeMappingsClientsClientDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientsIdScopeMappingsClientsClientDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdScopeMappingsClientsClientDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove client-level roles from the client’s scope. - */ - async realmClientsIdScopeMappingsClientsClientDelete(requestParameters: RealmClientsIdScopeMappingsClientsClientDeleteRequest): Promise { - await this.realmClientsIdScopeMappingsClientsClientDeleteRaw(requestParameters); - } - - /** - * Get the roles associated with a client’s scope Returns roles for the client. - */ - async realmClientsIdScopeMappingsClientsClientGetRaw(requestParameters: RealmClientsIdScopeMappingsClientsClientGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsClientsClientGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsClientsClientGet.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientsIdScopeMappingsClientsClientGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get the roles associated with a client’s scope Returns roles for the client. - */ - async realmClientsIdScopeMappingsClientsClientGet(requestParameters: RealmClientsIdScopeMappingsClientsClientGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsClientsClientGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add client-level roles to the client’s scope - */ - async realmClientsIdScopeMappingsClientsClientPostRaw(requestParameters: RealmClientsIdScopeMappingsClientsClientPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmClientsIdScopeMappingsClientsClientPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdScopeMappingsClientsClientPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/clients/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add client-level roles to the client’s scope - */ - async realmClientsIdScopeMappingsClientsClientPost(requestParameters: RealmClientsIdScopeMappingsClientsClientPostRequest): Promise { - await this.realmClientsIdScopeMappingsClientsClientPostRaw(requestParameters); - } - - /** - * Get realm-level roles that are available to attach to this client’s scope - */ - async realmClientsIdScopeMappingsRealmAvailableGetRaw(requestParameters: RealmClientsIdScopeMappingsRealmAvailableGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsRealmAvailableGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsRealmAvailableGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/realm/available`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles that are available to attach to this client’s scope - */ - async realmClientsIdScopeMappingsRealmAvailableGet(requestParameters: RealmClientsIdScopeMappingsRealmAvailableGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsRealmAvailableGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get effective realm-level roles associated with the client’s scope What this does is recurse any composite roles associated with the client’s scope and adds the roles to this lists. - */ - async realmClientsIdScopeMappingsRealmCompositeGetRaw(requestParameters: RealmClientsIdScopeMappingsRealmCompositeGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsRealmCompositeGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsRealmCompositeGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/realm/composite`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get effective realm-level roles associated with the client’s scope What this does is recurse any composite roles associated with the client’s scope and adds the roles to this lists. - */ - async realmClientsIdScopeMappingsRealmCompositeGet(requestParameters: RealmClientsIdScopeMappingsRealmCompositeGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsRealmCompositeGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove a set of realm-level roles from the client’s scope - */ - async realmClientsIdScopeMappingsRealmDeleteRaw(requestParameters: RealmClientsIdScopeMappingsRealmDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsRealmDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsRealmDelete.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdScopeMappingsRealmDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a set of realm-level roles from the client’s scope - */ - async realmClientsIdScopeMappingsRealmDelete(requestParameters: RealmClientsIdScopeMappingsRealmDeleteRequest): Promise { - await this.realmClientsIdScopeMappingsRealmDeleteRaw(requestParameters); - } - - /** - * Get realm-level roles associated with the client’s scope - */ - async realmClientsIdScopeMappingsRealmGetRaw(requestParameters: RealmClientsIdScopeMappingsRealmGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsRealmGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsRealmGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get realm-level roles associated with the client’s scope - */ - async realmClientsIdScopeMappingsRealmGet(requestParameters: RealmClientsIdScopeMappingsRealmGetRequest): Promise> { - const response = await this.realmClientsIdScopeMappingsRealmGetRaw(requestParameters); - return await response.value(); - } - - /** - * Add a set of realm-level roles to the client’s scope - */ - async realmClientsIdScopeMappingsRealmPostRaw(requestParameters: RealmClientsIdScopeMappingsRealmPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmClientsIdScopeMappingsRealmPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmClientsIdScopeMappingsRealmPost.'); - } - - if (requestParameters.roleRepresentation === null || requestParameters.roleRepresentation === undefined) { - throw new runtime.RequiredError('roleRepresentation','Required parameter requestParameters.roleRepresentation was null or undefined when calling realmClientsIdScopeMappingsRealmPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/clients/{id}/scope-mappings/realm`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: requestParameters.roleRepresentation.map(RoleRepresentationToJSON), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a set of realm-level roles to the client’s scope - */ - async realmClientsIdScopeMappingsRealmPost(requestParameters: RealmClientsIdScopeMappingsRealmPostRequest): Promise { - await this.realmClientsIdScopeMappingsRealmPostRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/UserStorageProviderApi.ts b/backend/keycloak/kc-client/apis/UserStorageProviderApi.ts deleted file mode 100644 index e8e7ee1..0000000 --- a/backend/keycloak/kc-client/apis/UserStorageProviderApi.ts +++ /dev/null @@ -1,318 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - SynchronizationResult, - SynchronizationResultFromJSON, - SynchronizationResultToJSON, -} from '../models'; - -export interface IdNameGetRequest { - id: string; -} - -export interface RealmUserStorageIdNameGetRequest { - realm: string; - id: string; -} - -export interface RealmUserStorageIdRemoveImportedUsersPostRequest { - realm: string; - id: string; -} - -export interface RealmUserStorageIdSyncPostRequest { - realm: string; - id: string; - action?: string; -} - -export interface RealmUserStorageIdUnlinkUsersPostRequest { - realm: string; - id: string; -} - -export interface RealmUserStorageParentIdMappersIdSyncPostRequest { - realm: string; - parentId: string; - id: string; - direction?: string; -} - -/** - * - */ -export class UserStorageProviderApi extends runtime.BaseAPI { - - /** - * Need this for admin console to display simple name of provider when displaying client detail KEYCLOAK-4328 - */ - async idNameGetRaw(requestParameters: IdNameGetRequest): Promise> { - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling idNameGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{id}/name`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Need this for admin console to display simple name of provider when displaying client detail KEYCLOAK-4328 - */ - async idNameGet(requestParameters: IdNameGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.idNameGetRaw(requestParameters); - return await response.value(); - } - - /** - * Need this for admin console to display simple name of provider when displaying user detail KEYCLOAK-4328 - */ - async realmUserStorageIdNameGetRaw(requestParameters: RealmUserStorageIdNameGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUserStorageIdNameGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUserStorageIdNameGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/user-storage/{id}/name`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Need this for admin console to display simple name of provider when displaying user detail KEYCLOAK-4328 - */ - async realmUserStorageIdNameGet(requestParameters: RealmUserStorageIdNameGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmUserStorageIdNameGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove imported users - */ - async realmUserStorageIdRemoveImportedUsersPostRaw(requestParameters: RealmUserStorageIdRemoveImportedUsersPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUserStorageIdRemoveImportedUsersPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUserStorageIdRemoveImportedUsersPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/user-storage/{id}/remove-imported-users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove imported users - */ - async realmUserStorageIdRemoveImportedUsersPost(requestParameters: RealmUserStorageIdRemoveImportedUsersPostRequest): Promise { - await this.realmUserStorageIdRemoveImportedUsersPostRaw(requestParameters); - } - - /** - * Trigger sync of users Action can be \"triggerFullSync\" or \"triggerChangedUsersSync\" - */ - async realmUserStorageIdSyncPostRaw(requestParameters: RealmUserStorageIdSyncPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUserStorageIdSyncPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUserStorageIdSyncPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.action !== undefined) { - queryParameters['action'] = requestParameters.action; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/user-storage/{id}/sync`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => SynchronizationResultFromJSON(jsonValue)); - } - - /** - * Trigger sync of users Action can be \"triggerFullSync\" or \"triggerChangedUsersSync\" - */ - async realmUserStorageIdSyncPost(requestParameters: RealmUserStorageIdSyncPostRequest): Promise { - const response = await this.realmUserStorageIdSyncPostRaw(requestParameters); - return await response.value(); - } - - /** - * Unlink imported users from a storage provider - */ - async realmUserStorageIdUnlinkUsersPostRaw(requestParameters: RealmUserStorageIdUnlinkUsersPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUserStorageIdUnlinkUsersPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUserStorageIdUnlinkUsersPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/user-storage/{id}/unlink-users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Unlink imported users from a storage provider - */ - async realmUserStorageIdUnlinkUsersPost(requestParameters: RealmUserStorageIdUnlinkUsersPostRequest): Promise { - await this.realmUserStorageIdUnlinkUsersPostRaw(requestParameters); - } - - /** - * Trigger sync of mapper data related to ldap mapper (roles, groups, …​) direction is \"fedToKeycloak\" or \"keycloakToFed\" - */ - async realmUserStorageParentIdMappersIdSyncPostRaw(requestParameters: RealmUserStorageParentIdMappersIdSyncPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUserStorageParentIdMappersIdSyncPost.'); - } - - if (requestParameters.parentId === null || requestParameters.parentId === undefined) { - throw new runtime.RequiredError('parentId','Required parameter requestParameters.parentId was null or undefined when calling realmUserStorageParentIdMappersIdSyncPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUserStorageParentIdMappersIdSyncPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.direction !== undefined) { - queryParameters['direction'] = requestParameters.direction; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/user-storage/{parentId}/mappers/{id}/sync`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"parentId"}}`, encodeURIComponent(String(requestParameters.parentId))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => SynchronizationResultFromJSON(jsonValue)); - } - - /** - * Trigger sync of mapper data related to ldap mapper (roles, groups, …​) direction is \"fedToKeycloak\" or \"keycloakToFed\" - */ - async realmUserStorageParentIdMappersIdSyncPost(requestParameters: RealmUserStorageParentIdMappersIdSyncPostRequest): Promise { - const response = await this.realmUserStorageParentIdMappersIdSyncPostRaw(requestParameters); - return await response.value(); - } - -} diff --git a/backend/keycloak/kc-client/apis/UsersApi.ts b/backend/keycloak/kc-client/apis/UsersApi.ts deleted file mode 100644 index 148d756..0000000 --- a/backend/keycloak/kc-client/apis/UsersApi.ts +++ /dev/null @@ -1,1708 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -import * as runtime from '../runtime'; -import { - CredentialRepresentation, - CredentialRepresentationFromJSON, - CredentialRepresentationToJSON, - FederatedIdentityRepresentation, - FederatedIdentityRepresentationFromJSON, - FederatedIdentityRepresentationToJSON, - UserRepresentation, - UserRepresentationFromJSON, - UserRepresentationToJSON, -} from '../models'; - -export interface RealmUsersCountGetRequest { - realm: string; - email?: string; - emailVerified?: boolean; - enabled?: boolean; - firstName?: string; - lastName?: string; - search?: string; - username?: string; -} - -export interface RealmUsersGetRequest { - realm: string; - briefRepresentation?: boolean; - email?: string; - emailVerified?: boolean; - enabled?: boolean; - exact?: boolean; - first?: number; - firstName?: string; - idpAlias?: string; - idpUserId?: string; - lastName?: string; - max?: number; - q?: string; - search?: string; - username?: string; -} - -export interface RealmUsersIdConfiguredUserStorageCredentialTypesGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdConsentsClientDeleteRequest { - realm: string; - id: string; - client: string; -} - -export interface RealmUsersIdConsentsGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdCredentialsCredentialIdDeleteRequest { - realm: string; - id: string; - credentialId: string; -} - -export interface RealmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPostRequest { - realm: string; - id: string; - credentialId: string; - newPreviousCredentialId: string; -} - -export interface RealmUsersIdCredentialsCredentialIdMoveToFirstPostRequest { - realm: string; - id: string; - credentialId: string; -} - -export interface RealmUsersIdCredentialsCredentialIdUserLabelPutRequest { - realm: string; - id: string; - credentialId: string; - body: string; -} - -export interface RealmUsersIdCredentialsGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdDeleteRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdDisableCredentialTypesPutRequest { - realm: string; - id: string; - requestBody: Array; -} - -export interface RealmUsersIdExecuteActionsEmailPutRequest { - realm: string; - id: string; - requestBody: Array; - clientId?: string; - lifespan?: number; - redirectUri?: string; -} - -export interface RealmUsersIdFederatedIdentityGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdFederatedIdentityProviderDeleteRequest { - realm: string; - id: string; - provider: string; -} - -export interface RealmUsersIdFederatedIdentityProviderPostRequest { - realm: string; - id: string; - provider: string; - federatedIdentityRepresentation: FederatedIdentityRepresentation; -} - -export interface RealmUsersIdGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdGroupsCountGetRequest { - realm: string; - id: string; - search?: string; -} - -export interface RealmUsersIdGroupsGetRequest { - realm: string; - id: string; - briefRepresentation?: boolean; - first?: number; - max?: number; - search?: string; -} - -export interface RealmUsersIdGroupsGroupIdDeleteRequest { - realm: string; - id: string; - groupId: string; -} - -export interface RealmUsersIdGroupsGroupIdPutRequest { - realm: string; - id: string; - groupId: string; -} - -export interface RealmUsersIdImpersonationPostRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdLogoutPostRequest { - realm: string; - id: string; -} - -export interface RealmUsersIdOfflineSessionsClientUuidGetRequest { - realm: string; - id: string; - clientUuid: string; -} - -export interface RealmUsersIdPutRequest { - realm: string; - id: string; - userRepresentation: UserRepresentation; -} - -export interface RealmUsersIdResetPasswordPutRequest { - realm: string; - id: string; - credentialRepresentation: CredentialRepresentation; -} - -export interface RealmUsersIdSendVerifyEmailPutRequest { - realm: string; - id: string; - clientId?: string; - redirectUri?: string; -} - -export interface RealmUsersIdSessionsGetRequest { - realm: string; - id: string; -} - -export interface RealmUsersPostRequest { - realm: string; - userRepresentation: UserRepresentation; -} - -export interface RealmUsersProfileGetRequest { - realm: string; -} - -export interface RealmUsersProfilePutRequest { - realm: string; - body: string; -} - -/** - * - */ -export class UsersApi extends runtime.BaseAPI { - - /** - * Returns the number of users that match the given criteria. - */ - async realmUsersCountGetRaw(requestParameters: RealmUsersCountGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersCountGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.email !== undefined) { - queryParameters['email'] = requestParameters.email; - } - - if (requestParameters.emailVerified !== undefined) { - queryParameters['emailVerified'] = requestParameters.emailVerified; - } - - if (requestParameters.enabled !== undefined) { - queryParameters['enabled'] = requestParameters.enabled; - } - - if (requestParameters.firstName !== undefined) { - queryParameters['firstName'] = requestParameters.firstName; - } - - if (requestParameters.lastName !== undefined) { - queryParameters['lastName'] = requestParameters.lastName; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - if (requestParameters.username !== undefined) { - queryParameters['username'] = requestParameters.username; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/count`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.TextApiResponse(response) as any; - } - - /** - * Returns the number of users that match the given criteria. - */ - async realmUsersCountGet(requestParameters: RealmUsersCountGetRequest): Promise { - const response = await this.realmUsersCountGetRaw(requestParameters); - return await response.value(); - } - - /** - * Get users Returns a stream of users, filtered according to query parameters. - */ - async realmUsersGetRaw(requestParameters: RealmUsersGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.email !== undefined) { - queryParameters['email'] = requestParameters.email; - } - - if (requestParameters.emailVerified !== undefined) { - queryParameters['emailVerified'] = requestParameters.emailVerified; - } - - if (requestParameters.enabled !== undefined) { - queryParameters['enabled'] = requestParameters.enabled; - } - - if (requestParameters.exact !== undefined) { - queryParameters['exact'] = requestParameters.exact; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.firstName !== undefined) { - queryParameters['firstName'] = requestParameters.firstName; - } - - if (requestParameters.idpAlias !== undefined) { - queryParameters['idpAlias'] = requestParameters.idpAlias; - } - - if (requestParameters.idpUserId !== undefined) { - queryParameters['idpUserId'] = requestParameters.idpUserId; - } - - if (requestParameters.lastName !== undefined) { - queryParameters['lastName'] = requestParameters.lastName; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.q !== undefined) { - queryParameters['q'] = requestParameters.q; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - if (requestParameters.username !== undefined) { - queryParameters['username'] = requestParameters.username; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get users Returns a stream of users, filtered according to query parameters. - */ - async realmUsersGet(requestParameters: RealmUsersGetRequest): Promise> { - const response = await this.realmUsersGetRaw(requestParameters); - return await response.value(); - } - - /** - * Return credential types, which are provided by the user storage where user is stored. - */ - async realmUsersIdConfiguredUserStorageCredentialTypesGetRaw(requestParameters: RealmUsersIdConfiguredUserStorageCredentialTypesGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdConfiguredUserStorageCredentialTypesGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdConfiguredUserStorageCredentialTypesGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/configured-user-storage-credential-types`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Return credential types, which are provided by the user storage where user is stored. - */ - async realmUsersIdConfiguredUserStorageCredentialTypesGet(requestParameters: RealmUsersIdConfiguredUserStorageCredentialTypesGetRequest): Promise> { - const response = await this.realmUsersIdConfiguredUserStorageCredentialTypesGetRaw(requestParameters); - return await response.value(); - } - - /** - * Revoke consent and offline tokens for particular client from user - */ - async realmUsersIdConsentsClientDeleteRaw(requestParameters: RealmUsersIdConsentsClientDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdConsentsClientDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdConsentsClientDelete.'); - } - - if (requestParameters.client === null || requestParameters.client === undefined) { - throw new runtime.RequiredError('client','Required parameter requestParameters.client was null or undefined when calling realmUsersIdConsentsClientDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/consents/{client}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"client"}}`, encodeURIComponent(String(requestParameters.client))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Revoke consent and offline tokens for particular client from user - */ - async realmUsersIdConsentsClientDelete(requestParameters: RealmUsersIdConsentsClientDeleteRequest): Promise { - await this.realmUsersIdConsentsClientDeleteRaw(requestParameters); - } - - /** - * Get consents granted by the user - */ - async realmUsersIdConsentsGetRaw(requestParameters: RealmUsersIdConsentsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdConsentsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdConsentsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/consents`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get consents granted by the user - */ - async realmUsersIdConsentsGet(requestParameters: RealmUsersIdConsentsGetRequest): Promise> { - const response = await this.realmUsersIdConsentsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove a credential for a user - */ - async realmUsersIdCredentialsCredentialIdDeleteRaw(requestParameters: RealmUsersIdCredentialsCredentialIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdCredentialsCredentialIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdCredentialsCredentialIdDelete.'); - } - - if (requestParameters.credentialId === null || requestParameters.credentialId === undefined) { - throw new runtime.RequiredError('credentialId','Required parameter requestParameters.credentialId was null or undefined when calling realmUsersIdCredentialsCredentialIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/credentials/{credentialId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"credentialId"}}`, encodeURIComponent(String(requestParameters.credentialId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a credential for a user - */ - async realmUsersIdCredentialsCredentialIdDelete(requestParameters: RealmUsersIdCredentialsCredentialIdDeleteRequest): Promise { - await this.realmUsersIdCredentialsCredentialIdDeleteRaw(requestParameters); - } - - /** - * Move a credential to a position behind another credential - */ - async realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPostRaw(requestParameters: RealmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPost.'); - } - - if (requestParameters.credentialId === null || requestParameters.credentialId === undefined) { - throw new runtime.RequiredError('credentialId','Required parameter requestParameters.credentialId was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPost.'); - } - - if (requestParameters.newPreviousCredentialId === null || requestParameters.newPreviousCredentialId === undefined) { - throw new runtime.RequiredError('newPreviousCredentialId','Required parameter requestParameters.newPreviousCredentialId was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/credentials/{credentialId}/moveAfter/{newPreviousCredentialId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"credentialId"}}`, encodeURIComponent(String(requestParameters.credentialId))).replace(`{${"newPreviousCredentialId"}}`, encodeURIComponent(String(requestParameters.newPreviousCredentialId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Move a credential to a position behind another credential - */ - async realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPost(requestParameters: RealmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPostRequest): Promise { - await this.realmUsersIdCredentialsCredentialIdMoveAfterNewPreviousCredentialIdPostRaw(requestParameters); - } - - /** - * Move a credential to a first position in the credentials list of the user - */ - async realmUsersIdCredentialsCredentialIdMoveToFirstPostRaw(requestParameters: RealmUsersIdCredentialsCredentialIdMoveToFirstPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveToFirstPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveToFirstPost.'); - } - - if (requestParameters.credentialId === null || requestParameters.credentialId === undefined) { - throw new runtime.RequiredError('credentialId','Required parameter requestParameters.credentialId was null or undefined when calling realmUsersIdCredentialsCredentialIdMoveToFirstPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/credentials/{credentialId}/moveToFirst`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"credentialId"}}`, encodeURIComponent(String(requestParameters.credentialId))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Move a credential to a first position in the credentials list of the user - */ - async realmUsersIdCredentialsCredentialIdMoveToFirstPost(requestParameters: RealmUsersIdCredentialsCredentialIdMoveToFirstPostRequest): Promise { - await this.realmUsersIdCredentialsCredentialIdMoveToFirstPostRaw(requestParameters); - } - - /** - * Update a credential label for a user - */ - async realmUsersIdCredentialsCredentialIdUserLabelPutRaw(requestParameters: RealmUsersIdCredentialsCredentialIdUserLabelPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdCredentialsCredentialIdUserLabelPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdCredentialsCredentialIdUserLabelPut.'); - } - - if (requestParameters.credentialId === null || requestParameters.credentialId === undefined) { - throw new runtime.RequiredError('credentialId','Required parameter requestParameters.credentialId was null or undefined when calling realmUsersIdCredentialsCredentialIdUserLabelPut.'); - } - - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling realmUsersIdCredentialsCredentialIdUserLabelPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'text/plain'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/credentials/{credentialId}/userLabel`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"credentialId"}}`, encodeURIComponent(String(requestParameters.credentialId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: requestParameters.body as any, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update a credential label for a user - */ - async realmUsersIdCredentialsCredentialIdUserLabelPut(requestParameters: RealmUsersIdCredentialsCredentialIdUserLabelPutRequest): Promise { - await this.realmUsersIdCredentialsCredentialIdUserLabelPutRaw(requestParameters); - } - - /** - */ - async realmUsersIdCredentialsGetRaw(requestParameters: RealmUsersIdCredentialsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdCredentialsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdCredentialsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/credentials`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmUsersIdCredentialsGet(requestParameters: RealmUsersIdCredentialsGetRequest): Promise> { - const response = await this.realmUsersIdCredentialsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Delete the user - */ - async realmUsersIdDeleteRaw(requestParameters: RealmUsersIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Delete the user - */ - async realmUsersIdDelete(requestParameters: RealmUsersIdDeleteRequest): Promise { - await this.realmUsersIdDeleteRaw(requestParameters); - } - - /** - * Disable all credentials for a user of a specific type - */ - async realmUsersIdDisableCredentialTypesPutRaw(requestParameters: RealmUsersIdDisableCredentialTypesPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdDisableCredentialTypesPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdDisableCredentialTypesPut.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmUsersIdDisableCredentialTypesPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/disable-credential-types`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Disable all credentials for a user of a specific type - */ - async realmUsersIdDisableCredentialTypesPut(requestParameters: RealmUsersIdDisableCredentialTypesPutRequest): Promise { - await this.realmUsersIdDisableCredentialTypesPutRaw(requestParameters); - } - - /** - * Send a update account email to the user An email contains a link the user can click to perform a set of required actions. - */ - async realmUsersIdExecuteActionsEmailPutRaw(requestParameters: RealmUsersIdExecuteActionsEmailPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdExecuteActionsEmailPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdExecuteActionsEmailPut.'); - } - - if (requestParameters.requestBody === null || requestParameters.requestBody === undefined) { - throw new runtime.RequiredError('requestBody','Required parameter requestParameters.requestBody was null or undefined when calling realmUsersIdExecuteActionsEmailPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.clientId !== undefined) { - queryParameters['client_id'] = requestParameters.clientId; - } - - if (requestParameters.lifespan !== undefined) { - queryParameters['lifespan'] = requestParameters.lifespan; - } - - if (requestParameters.redirectUri !== undefined) { - queryParameters['redirect_uri'] = requestParameters.redirectUri; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/execute-actions-email`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: requestParameters.requestBody, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Send a update account email to the user An email contains a link the user can click to perform a set of required actions. - */ - async realmUsersIdExecuteActionsEmailPut(requestParameters: RealmUsersIdExecuteActionsEmailPutRequest): Promise { - await this.realmUsersIdExecuteActionsEmailPutRaw(requestParameters); - } - - /** - * Get social logins associated with the user - */ - async realmUsersIdFederatedIdentityGetRaw(requestParameters: RealmUsersIdFederatedIdentityGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdFederatedIdentityGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdFederatedIdentityGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/federated-identity`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get social logins associated with the user - */ - async realmUsersIdFederatedIdentityGet(requestParameters: RealmUsersIdFederatedIdentityGetRequest): Promise> { - const response = await this.realmUsersIdFederatedIdentityGetRaw(requestParameters); - return await response.value(); - } - - /** - * Remove a social login provider from user - */ - async realmUsersIdFederatedIdentityProviderDeleteRaw(requestParameters: RealmUsersIdFederatedIdentityProviderDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdFederatedIdentityProviderDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdFederatedIdentityProviderDelete.'); - } - - if (requestParameters.provider === null || requestParameters.provider === undefined) { - throw new runtime.RequiredError('provider','Required parameter requestParameters.provider was null or undefined when calling realmUsersIdFederatedIdentityProviderDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/federated-identity/{provider}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"provider"}}`, encodeURIComponent(String(requestParameters.provider))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove a social login provider from user - */ - async realmUsersIdFederatedIdentityProviderDelete(requestParameters: RealmUsersIdFederatedIdentityProviderDeleteRequest): Promise { - await this.realmUsersIdFederatedIdentityProviderDeleteRaw(requestParameters); - } - - /** - * Add a social login provider to the user - */ - async realmUsersIdFederatedIdentityProviderPostRaw(requestParameters: RealmUsersIdFederatedIdentityProviderPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdFederatedIdentityProviderPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdFederatedIdentityProviderPost.'); - } - - if (requestParameters.provider === null || requestParameters.provider === undefined) { - throw new runtime.RequiredError('provider','Required parameter requestParameters.provider was null or undefined when calling realmUsersIdFederatedIdentityProviderPost.'); - } - - if (requestParameters.federatedIdentityRepresentation === null || requestParameters.federatedIdentityRepresentation === undefined) { - throw new runtime.RequiredError('federatedIdentityRepresentation','Required parameter requestParameters.federatedIdentityRepresentation was null or undefined when calling realmUsersIdFederatedIdentityProviderPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/federated-identity/{provider}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"provider"}}`, encodeURIComponent(String(requestParameters.provider))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: FederatedIdentityRepresentationToJSON(requestParameters.federatedIdentityRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Add a social login provider to the user - */ - async realmUsersIdFederatedIdentityProviderPost(requestParameters: RealmUsersIdFederatedIdentityProviderPostRequest): Promise { - await this.realmUsersIdFederatedIdentityProviderPostRaw(requestParameters); - } - - /** - * Get representation of the user - */ - async realmUsersIdGetRaw(requestParameters: RealmUsersIdGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response, (jsonValue) => UserRepresentationFromJSON(jsonValue)); - } - - /** - * Get representation of the user - */ - async realmUsersIdGet(requestParameters: RealmUsersIdGetRequest): Promise { - const response = await this.realmUsersIdGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmUsersIdGroupsCountGetRaw(requestParameters: RealmUsersIdGroupsCountGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdGroupsCountGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdGroupsCountGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/groups/count`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmUsersIdGroupsCountGet(requestParameters: RealmUsersIdGroupsCountGetRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmUsersIdGroupsCountGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmUsersIdGroupsGetRaw(requestParameters: RealmUsersIdGroupsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdGroupsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdGroupsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.briefRepresentation !== undefined) { - queryParameters['briefRepresentation'] = requestParameters.briefRepresentation; - } - - if (requestParameters.first !== undefined) { - queryParameters['first'] = requestParameters.first; - } - - if (requestParameters.max !== undefined) { - queryParameters['max'] = requestParameters.max; - } - - if (requestParameters.search !== undefined) { - queryParameters['search'] = requestParameters.search; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/groups`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - */ - async realmUsersIdGroupsGet(requestParameters: RealmUsersIdGroupsGetRequest): Promise> { - const response = await this.realmUsersIdGroupsGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmUsersIdGroupsGroupIdDeleteRaw(requestParameters: RealmUsersIdGroupsGroupIdDeleteRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdGroupsGroupIdDelete.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdGroupsGroupIdDelete.'); - } - - if (requestParameters.groupId === null || requestParameters.groupId === undefined) { - throw new runtime.RequiredError('groupId','Required parameter requestParameters.groupId was null or undefined when calling realmUsersIdGroupsGroupIdDelete.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/groups/{groupId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"groupId"}}`, encodeURIComponent(String(requestParameters.groupId))), - method: 'DELETE', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmUsersIdGroupsGroupIdDelete(requestParameters: RealmUsersIdGroupsGroupIdDeleteRequest): Promise { - await this.realmUsersIdGroupsGroupIdDeleteRaw(requestParameters); - } - - /** - */ - async realmUsersIdGroupsGroupIdPutRaw(requestParameters: RealmUsersIdGroupsGroupIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdGroupsGroupIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdGroupsGroupIdPut.'); - } - - if (requestParameters.groupId === null || requestParameters.groupId === undefined) { - throw new runtime.RequiredError('groupId','Required parameter requestParameters.groupId was null or undefined when calling realmUsersIdGroupsGroupIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/groups/{groupId}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"groupId"}}`, encodeURIComponent(String(requestParameters.groupId))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmUsersIdGroupsGroupIdPut(requestParameters: RealmUsersIdGroupsGroupIdPutRequest): Promise { - await this.realmUsersIdGroupsGroupIdPutRaw(requestParameters); - } - - /** - * Impersonate the user - */ - async realmUsersIdImpersonationPostRaw(requestParameters: RealmUsersIdImpersonationPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdImpersonationPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdImpersonationPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/impersonation`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Impersonate the user - */ - async realmUsersIdImpersonationPost(requestParameters: RealmUsersIdImpersonationPostRequest): Promise<{ [key: string]: object; }> { - const response = await this.realmUsersIdImpersonationPostRaw(requestParameters); - return await response.value(); - } - - /** - * Remove all user sessions associated with the user Also send notification to all clients that have an admin URL to invalidate the sessions for the particular user. - */ - async realmUsersIdLogoutPostRaw(requestParameters: RealmUsersIdLogoutPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdLogoutPost.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdLogoutPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/logout`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Remove all user sessions associated with the user Also send notification to all clients that have an admin URL to invalidate the sessions for the particular user. - */ - async realmUsersIdLogoutPost(requestParameters: RealmUsersIdLogoutPostRequest): Promise { - await this.realmUsersIdLogoutPostRaw(requestParameters); - } - - /** - * Get offline sessions associated with the user and client - */ - async realmUsersIdOfflineSessionsClientUuidGetRaw(requestParameters: RealmUsersIdOfflineSessionsClientUuidGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdOfflineSessionsClientUuidGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdOfflineSessionsClientUuidGet.'); - } - - if (requestParameters.clientUuid === null || requestParameters.clientUuid === undefined) { - throw new runtime.RequiredError('clientUuid','Required parameter requestParameters.clientUuid was null or undefined when calling realmUsersIdOfflineSessionsClientUuidGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/offline-sessions/{clientUuid}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))).replace(`{${"clientUuid"}}`, encodeURIComponent(String(requestParameters.clientUuid))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get offline sessions associated with the user and client - */ - async realmUsersIdOfflineSessionsClientUuidGet(requestParameters: RealmUsersIdOfflineSessionsClientUuidGetRequest): Promise> { - const response = await this.realmUsersIdOfflineSessionsClientUuidGetRaw(requestParameters); - return await response.value(); - } - - /** - * Update the user - */ - async realmUsersIdPutRaw(requestParameters: RealmUsersIdPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdPut.'); - } - - if (requestParameters.userRepresentation === null || requestParameters.userRepresentation === undefined) { - throw new runtime.RequiredError('userRepresentation','Required parameter requestParameters.userRepresentation was null or undefined when calling realmUsersIdPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: UserRepresentationToJSON(requestParameters.userRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Update the user - */ - async realmUsersIdPut(requestParameters: RealmUsersIdPutRequest): Promise { - await this.realmUsersIdPutRaw(requestParameters); - } - - /** - * Set up a new password for the user. - */ - async realmUsersIdResetPasswordPutRaw(requestParameters: RealmUsersIdResetPasswordPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdResetPasswordPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdResetPasswordPut.'); - } - - if (requestParameters.credentialRepresentation === null || requestParameters.credentialRepresentation === undefined) { - throw new runtime.RequiredError('credentialRepresentation','Required parameter requestParameters.credentialRepresentation was null or undefined when calling realmUsersIdResetPasswordPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/reset-password`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: CredentialRepresentationToJSON(requestParameters.credentialRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Set up a new password for the user. - */ - async realmUsersIdResetPasswordPut(requestParameters: RealmUsersIdResetPasswordPutRequest): Promise { - await this.realmUsersIdResetPasswordPutRaw(requestParameters); - } - - /** - * Send an email-verification email to the user An email contains a link the user can click to verify their email address. - */ - async realmUsersIdSendVerifyEmailPutRaw(requestParameters: RealmUsersIdSendVerifyEmailPutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdSendVerifyEmailPut.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdSendVerifyEmailPut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - if (requestParameters.clientId !== undefined) { - queryParameters['client_id'] = requestParameters.clientId; - } - - if (requestParameters.redirectUri !== undefined) { - queryParameters['redirect_uri'] = requestParameters.redirectUri; - } - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/send-verify-email`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Send an email-verification email to the user An email contains a link the user can click to verify their email address. - */ - async realmUsersIdSendVerifyEmailPut(requestParameters: RealmUsersIdSendVerifyEmailPutRequest): Promise { - await this.realmUsersIdSendVerifyEmailPutRaw(requestParameters); - } - - /** - * Get sessions associated with the user - */ - async realmUsersIdSessionsGetRaw(requestParameters: RealmUsersIdSessionsGetRequest): Promise>> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersIdSessionsGet.'); - } - - if (requestParameters.id === null || requestParameters.id === undefined) { - throw new runtime.RequiredError('id','Required parameter requestParameters.id was null or undefined when calling realmUsersIdSessionsGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/{id}/sessions`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))).replace(`{${"id"}}`, encodeURIComponent(String(requestParameters.id))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.JSONApiResponse(response); - } - - /** - * Get sessions associated with the user - */ - async realmUsersIdSessionsGet(requestParameters: RealmUsersIdSessionsGetRequest): Promise> { - const response = await this.realmUsersIdSessionsGetRaw(requestParameters); - return await response.value(); - } - - /** - * Create a new user Username must be unique. - */ - async realmUsersPostRaw(requestParameters: RealmUsersPostRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersPost.'); - } - - if (requestParameters.userRepresentation === null || requestParameters.userRepresentation === undefined) { - throw new runtime.RequiredError('userRepresentation','Required parameter requestParameters.userRepresentation was null or undefined when calling realmUsersPost.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'POST', - headers: headerParameters, - query: queryParameters, - body: UserRepresentationToJSON(requestParameters.userRepresentation), - }); - - return new runtime.VoidApiResponse(response); - } - - /** - * Create a new user Username must be unique. - */ - async realmUsersPost(requestParameters: RealmUsersPostRequest): Promise { - await this.realmUsersPostRaw(requestParameters); - } - - /** - */ - async realmUsersProfileGetRaw(requestParameters: RealmUsersProfileGetRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersProfileGet.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/profile`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'GET', - headers: headerParameters, - query: queryParameters, - }); - - return new runtime.TextApiResponse(response) as any; - } - - /** - */ - async realmUsersProfileGet(requestParameters: RealmUsersProfileGetRequest): Promise { - const response = await this.realmUsersProfileGetRaw(requestParameters); - return await response.value(); - } - - /** - */ - async realmUsersProfilePutRaw(requestParameters: RealmUsersProfilePutRequest): Promise> { - if (requestParameters.realm === null || requestParameters.realm === undefined) { - throw new runtime.RequiredError('realm','Required parameter requestParameters.realm was null or undefined when calling realmUsersProfilePut.'); - } - - if (requestParameters.body === null || requestParameters.body === undefined) { - throw new runtime.RequiredError('body','Required parameter requestParameters.body was null or undefined when calling realmUsersProfilePut.'); - } - - const queryParameters: runtime.HTTPQuery = {}; - - const headerParameters: runtime.HTTPHeaders = {}; - - headerParameters['Content-Type'] = 'application/json'; - - if (this.configuration && this.configuration.accessToken) { - const token = this.configuration.accessToken; - const tokenString = typeof token === 'function' ? token("access_token", []) : token; - - if (tokenString) { - headerParameters["Authorization"] = `Bearer ${tokenString}`; - } - } - const response = await this.request({ - path: `/{realm}/users/profile`.replace(`{${"realm"}}`, encodeURIComponent(String(requestParameters.realm))), - method: 'PUT', - headers: headerParameters, - query: queryParameters, - body: requestParameters.body as any, - }); - - return new runtime.VoidApiResponse(response); - } - - /** - */ - async realmUsersProfilePut(requestParameters: RealmUsersProfilePutRequest): Promise { - await this.realmUsersProfilePutRaw(requestParameters); - } - -} diff --git a/backend/keycloak/kc-client/apis/index.ts b/backend/keycloak/kc-client/apis/index.ts deleted file mode 100644 index ee673d8..0000000 --- a/backend/keycloak/kc-client/apis/index.ts +++ /dev/null @@ -1,21 +0,0 @@ -export * from './AttackDetectionApi'; -export * from './AuthenticationManagementApi'; -export * from './ClientAttributeCertificateApi'; -export * from './ClientInitialAccessApi'; -export * from './ClientRegistrationPolicyApi'; -export * from './ClientRoleMappingsApi'; -export * from './ClientScopesApi'; -export * from './ClientsApi'; -export * from './ComponentApi'; -export * from './GroupsApi'; -export * from './IdentityProvidersApi'; -export * from './KeyApi'; -export * from './ProtocolMappersApi'; -export * from './RealmsAdminApi'; -export * from './RoleMapperApi'; -export * from './RolesApi'; -export * from './RolesByIDApi'; -export * from './RootApi'; -export * from './ScopeMappingsApi'; -export * from './UserStorageProviderApi'; -export * from './UsersApi'; diff --git a/backend/keycloak/kc-client/index.ts b/backend/keycloak/kc-client/index.ts index 848ecfa..93d5e82 100644 --- a/backend/keycloak/kc-client/index.ts +++ b/backend/keycloak/kc-client/index.ts @@ -1,3 +1,16 @@ -export * from './runtime'; -export * from './apis'; -export * from './models'; +// tslint:disable +/** + * Keycloak Admin REST API + * This is a REST API reference for the Keycloak Admin + * + * The version of the OpenAPI document: 1 + * + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + + +export * from "./api"; +export * from "./configuration"; diff --git a/backend/keycloak/kc-client/models/AccessToken.ts b/backend/keycloak/kc-client/models/AccessToken.ts deleted file mode 100644 index 9119700..0000000 --- a/backend/keycloak/kc-client/models/AccessToken.ts +++ /dev/null @@ -1,434 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - AccessTokenAccess, - AccessTokenAccessFromJSON, - AccessTokenAccessFromJSONTyped, - AccessTokenAccessToJSON, - AccessTokenAuthorization, - AccessTokenAuthorizationFromJSON, - AccessTokenAuthorizationFromJSONTyped, - AccessTokenAuthorizationToJSON, - AccessTokenCertConf, - AccessTokenCertConfFromJSON, - AccessTokenCertConfFromJSONTyped, - AccessTokenCertConfToJSON, - AddressClaimSet, - AddressClaimSetFromJSON, - AddressClaimSetFromJSONTyped, - AddressClaimSetToJSON, -} from './'; - -/** - * - * @export - * @interface AccessToken - */ -export interface AccessToken { - /** - * - * @type {string} - * @memberof AccessToken - */ - acr?: string; - /** - * - * @type {AddressClaimSet} - * @memberof AccessToken - */ - address?: AddressClaimSet; - /** - * - * @type {Array} - * @memberof AccessToken - */ - allowedOrigins?: Array; - /** - * - * @type {string} - * @memberof AccessToken - */ - atHash?: string; - /** - * - * @type {number} - * @memberof AccessToken - */ - authTime?: number; - /** - * - * @type {AccessTokenAuthorization} - * @memberof AccessToken - */ - authorization?: AccessTokenAuthorization; - /** - * - * @type {string} - * @memberof AccessToken - */ - azp?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - birthdate?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - cHash?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - category?: AccessTokenCategoryEnum; - /** - * - * @type {string} - * @memberof AccessToken - */ - claimsLocales?: string; - /** - * - * @type {AccessTokenCertConf} - * @memberof AccessToken - */ - cnf?: AccessTokenCertConf; - /** - * - * @type {string} - * @memberof AccessToken - */ - email?: string; - /** - * - * @type {boolean} - * @memberof AccessToken - */ - emailVerified?: boolean; - /** - * - * @type {number} - * @memberof AccessToken - */ - exp?: number; - /** - * - * @type {string} - * @memberof AccessToken - */ - familyName?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - gender?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - givenName?: string; - /** - * - * @type {number} - * @memberof AccessToken - */ - iat?: number; - /** - * - * @type {string} - * @memberof AccessToken - */ - iss?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - jti?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - locale?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - middleName?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - name?: string; - /** - * - * @type {number} - * @memberof AccessToken - */ - nbf?: number; - /** - * - * @type {string} - * @memberof AccessToken - */ - nickname?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - nonce?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof AccessToken - */ - otherClaims?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof AccessToken - */ - phoneNumber?: string; - /** - * - * @type {boolean} - * @memberof AccessToken - */ - phoneNumberVerified?: boolean; - /** - * - * @type {string} - * @memberof AccessToken - */ - picture?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - preferredUsername?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - profile?: string; - /** - * - * @type {AccessTokenAccess} - * @memberof AccessToken - */ - realmAccess?: AccessTokenAccess; - /** - * - * @type {string} - * @memberof AccessToken - */ - sHash?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - scope?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - sessionState?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - sid?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - sub?: string; - /** - * - * @type {Array} - * @memberof AccessToken - */ - trustedCerts?: Array; - /** - * - * @type {string} - * @memberof AccessToken - */ - typ?: string; - /** - * - * @type {number} - * @memberof AccessToken - */ - updatedAt?: number; - /** - * - * @type {string} - * @memberof AccessToken - */ - website?: string; - /** - * - * @type {string} - * @memberof AccessToken - */ - zoneinfo?: string; -} - -export function AccessTokenFromJSON(json: any): AccessToken { - return AccessTokenFromJSONTyped(json, false); -} - -export function AccessTokenFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccessToken { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'acr': !exists(json, 'acr') ? undefined : json['acr'], - 'address': !exists(json, 'address') ? undefined : AddressClaimSetFromJSON(json['address']), - 'allowedOrigins': !exists(json, 'allowed-origins') ? undefined : json['allowed-origins'], - 'atHash': !exists(json, 'at_hash') ? undefined : json['at_hash'], - 'authTime': !exists(json, 'auth_time') ? undefined : json['auth_time'], - 'authorization': !exists(json, 'authorization') ? undefined : AccessTokenAuthorizationFromJSON(json['authorization']), - 'azp': !exists(json, 'azp') ? undefined : json['azp'], - 'birthdate': !exists(json, 'birthdate') ? undefined : json['birthdate'], - 'cHash': !exists(json, 'c_hash') ? undefined : json['c_hash'], - 'category': !exists(json, 'category') ? undefined : json['category'], - 'claimsLocales': !exists(json, 'claims_locales') ? undefined : json['claims_locales'], - 'cnf': !exists(json, 'cnf') ? undefined : AccessTokenCertConfFromJSON(json['cnf']), - 'email': !exists(json, 'email') ? undefined : json['email'], - 'emailVerified': !exists(json, 'email_verified') ? undefined : json['email_verified'], - 'exp': !exists(json, 'exp') ? undefined : json['exp'], - 'familyName': !exists(json, 'family_name') ? undefined : json['family_name'], - 'gender': !exists(json, 'gender') ? undefined : json['gender'], - 'givenName': !exists(json, 'given_name') ? undefined : json['given_name'], - 'iat': !exists(json, 'iat') ? undefined : json['iat'], - 'iss': !exists(json, 'iss') ? undefined : json['iss'], - 'jti': !exists(json, 'jti') ? undefined : json['jti'], - 'locale': !exists(json, 'locale') ? undefined : json['locale'], - 'middleName': !exists(json, 'middle_name') ? undefined : json['middle_name'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'nbf': !exists(json, 'nbf') ? undefined : json['nbf'], - 'nickname': !exists(json, 'nickname') ? undefined : json['nickname'], - 'nonce': !exists(json, 'nonce') ? undefined : json['nonce'], - 'otherClaims': !exists(json, 'otherClaims') ? undefined : json['otherClaims'], - 'phoneNumber': !exists(json, 'phone_number') ? undefined : json['phone_number'], - 'phoneNumberVerified': !exists(json, 'phone_number_verified') ? undefined : json['phone_number_verified'], - 'picture': !exists(json, 'picture') ? undefined : json['picture'], - 'preferredUsername': !exists(json, 'preferred_username') ? undefined : json['preferred_username'], - 'profile': !exists(json, 'profile') ? undefined : json['profile'], - 'realmAccess': !exists(json, 'realm_access') ? undefined : AccessTokenAccessFromJSON(json['realm_access']), - 'sHash': !exists(json, 's_hash') ? undefined : json['s_hash'], - 'scope': !exists(json, 'scope') ? undefined : json['scope'], - 'sessionState': !exists(json, 'session_state') ? undefined : json['session_state'], - 'sid': !exists(json, 'sid') ? undefined : json['sid'], - 'sub': !exists(json, 'sub') ? undefined : json['sub'], - 'trustedCerts': !exists(json, 'trusted-certs') ? undefined : json['trusted-certs'], - 'typ': !exists(json, 'typ') ? undefined : json['typ'], - 'updatedAt': !exists(json, 'updated_at') ? undefined : json['updated_at'], - 'website': !exists(json, 'website') ? undefined : json['website'], - 'zoneinfo': !exists(json, 'zoneinfo') ? undefined : json['zoneinfo'], - }; -} - -export function AccessTokenToJSON(value?: AccessToken | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'acr': value.acr, - 'address': AddressClaimSetToJSON(value.address), - 'allowed-origins': value.allowedOrigins, - 'at_hash': value.atHash, - 'auth_time': value.authTime, - 'authorization': AccessTokenAuthorizationToJSON(value.authorization), - 'azp': value.azp, - 'birthdate': value.birthdate, - 'c_hash': value.cHash, - 'category': value.category, - 'claims_locales': value.claimsLocales, - 'cnf': AccessTokenCertConfToJSON(value.cnf), - 'email': value.email, - 'email_verified': value.emailVerified, - 'exp': value.exp, - 'family_name': value.familyName, - 'gender': value.gender, - 'given_name': value.givenName, - 'iat': value.iat, - 'iss': value.iss, - 'jti': value.jti, - 'locale': value.locale, - 'middle_name': value.middleName, - 'name': value.name, - 'nbf': value.nbf, - 'nickname': value.nickname, - 'nonce': value.nonce, - 'otherClaims': value.otherClaims, - 'phone_number': value.phoneNumber, - 'phone_number_verified': value.phoneNumberVerified, - 'picture': value.picture, - 'preferred_username': value.preferredUsername, - 'profile': value.profile, - 'realm_access': AccessTokenAccessToJSON(value.realmAccess), - 's_hash': value.sHash, - 'scope': value.scope, - 'session_state': value.sessionState, - 'sid': value.sid, - 'sub': value.sub, - 'trusted-certs': value.trustedCerts, - 'typ': value.typ, - 'updated_at': value.updatedAt, - 'website': value.website, - 'zoneinfo': value.zoneinfo, - }; -} - -/** -* @export -* @enum {string} -*/ -export enum AccessTokenCategoryEnum { - INTERNAL = 'INTERNAL', - ACCESS = 'ACCESS', - ID = 'ID', - ADMIN = 'ADMIN', - USERINFO = 'USERINFO', - LOGOUT = 'LOGOUT', - AUTHORIZATIONRESPONSE = 'AUTHORIZATION_RESPONSE' -} - - diff --git a/backend/keycloak/kc-client/models/AccessTokenAccess.ts b/backend/keycloak/kc-client/models/AccessTokenAccess.ts deleted file mode 100644 index efb19b0..0000000 --- a/backend/keycloak/kc-client/models/AccessTokenAccess.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AccessTokenAccess - */ -export interface AccessTokenAccess { - /** - * - * @type {Array} - * @memberof AccessTokenAccess - */ - roles?: Array; - /** - * - * @type {boolean} - * @memberof AccessTokenAccess - */ - verifyCaller?: boolean; -} - -export function AccessTokenAccessFromJSON(json: any): AccessTokenAccess { - return AccessTokenAccessFromJSONTyped(json, false); -} - -export function AccessTokenAccessFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccessTokenAccess { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'roles': !exists(json, 'roles') ? undefined : json['roles'], - 'verifyCaller': !exists(json, 'verify_caller') ? undefined : json['verify_caller'], - }; -} - -export function AccessTokenAccessToJSON(value?: AccessTokenAccess | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'roles': value.roles, - 'verify_caller': value.verifyCaller, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AccessTokenAuthorization.ts b/backend/keycloak/kc-client/models/AccessTokenAuthorization.ts deleted file mode 100644 index fb2de1e..0000000 --- a/backend/keycloak/kc-client/models/AccessTokenAuthorization.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - Permission, - PermissionFromJSON, - PermissionFromJSONTyped, - PermissionToJSON, -} from './'; - -/** - * - * @export - * @interface AccessTokenAuthorization - */ -export interface AccessTokenAuthorization { - /** - * - * @type {Array} - * @memberof AccessTokenAuthorization - */ - permissions?: Array; -} - -export function AccessTokenAuthorizationFromJSON(json: any): AccessTokenAuthorization { - return AccessTokenAuthorizationFromJSONTyped(json, false); -} - -export function AccessTokenAuthorizationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccessTokenAuthorization { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'permissions': !exists(json, 'permissions') ? undefined : ((json['permissions'] as Array).map(PermissionFromJSON)), - }; -} - -export function AccessTokenAuthorizationToJSON(value?: AccessTokenAuthorization | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'permissions': value.permissions === undefined ? undefined : ((value.permissions as Array).map(PermissionToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/AccessTokenCertConf.ts b/backend/keycloak/kc-client/models/AccessTokenCertConf.ts deleted file mode 100644 index 7251731..0000000 --- a/backend/keycloak/kc-client/models/AccessTokenCertConf.ts +++ /dev/null @@ -1,57 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AccessTokenCertConf - */ -export interface AccessTokenCertConf { - /** - * - * @type {string} - * @memberof AccessTokenCertConf - */ - x5tS256?: string; -} - -export function AccessTokenCertConfFromJSON(json: any): AccessTokenCertConf { - return AccessTokenCertConfFromJSONTyped(json, false); -} - -export function AccessTokenCertConfFromJSONTyped(json: any, ignoreDiscriminator: boolean): AccessTokenCertConf { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'x5tS256': !exists(json, 'x5t#S256') ? undefined : json['x5t#S256'], - }; -} - -export function AccessTokenCertConfToJSON(value?: AccessTokenCertConf | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'x5t#S256': value.x5tS256, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AddressClaimSet.ts b/backend/keycloak/kc-client/models/AddressClaimSet.ts deleted file mode 100644 index b7e6fd4..0000000 --- a/backend/keycloak/kc-client/models/AddressClaimSet.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AddressClaimSet - */ -export interface AddressClaimSet { - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - country?: string; - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - formatted?: string; - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - locality?: string; - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - postalCode?: string; - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - region?: string; - /** - * - * @type {string} - * @memberof AddressClaimSet - */ - streetAddress?: string; -} - -export function AddressClaimSetFromJSON(json: any): AddressClaimSet { - return AddressClaimSetFromJSONTyped(json, false); -} - -export function AddressClaimSetFromJSONTyped(json: any, ignoreDiscriminator: boolean): AddressClaimSet { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'country': !exists(json, 'country') ? undefined : json['country'], - 'formatted': !exists(json, 'formatted') ? undefined : json['formatted'], - 'locality': !exists(json, 'locality') ? undefined : json['locality'], - 'postalCode': !exists(json, 'postal_code') ? undefined : json['postal_code'], - 'region': !exists(json, 'region') ? undefined : json['region'], - 'streetAddress': !exists(json, 'street_address') ? undefined : json['street_address'], - }; -} - -export function AddressClaimSetToJSON(value?: AddressClaimSet | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'country': value.country, - 'formatted': value.formatted, - 'locality': value.locality, - 'postal_code': value.postalCode, - 'region': value.region, - 'street_address': value.streetAddress, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticationExecutionExportRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticationExecutionExportRepresentation.ts deleted file mode 100644 index 573a776..0000000 --- a/backend/keycloak/kc-client/models/AuthenticationExecutionExportRepresentation.ts +++ /dev/null @@ -1,105 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AuthenticationExecutionExportRepresentation - */ -export interface AuthenticationExecutionExportRepresentation { - /** - * - * @type {string} - * @memberof AuthenticationExecutionExportRepresentation - */ - authenticator?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionExportRepresentation - */ - authenticatorConfig?: string; - /** - * - * @type {boolean} - * @memberof AuthenticationExecutionExportRepresentation - */ - authenticatorFlow?: boolean; - /** - * - * @type {string} - * @memberof AuthenticationExecutionExportRepresentation - */ - flowAlias?: string; - /** - * - * @type {number} - * @memberof AuthenticationExecutionExportRepresentation - */ - priority?: number; - /** - * - * @type {string} - * @memberof AuthenticationExecutionExportRepresentation - */ - requirement?: string; - /** - * - * @type {boolean} - * @memberof AuthenticationExecutionExportRepresentation - */ - userSetupAllowed?: boolean; -} - -export function AuthenticationExecutionExportRepresentationFromJSON(json: any): AuthenticationExecutionExportRepresentation { - return AuthenticationExecutionExportRepresentationFromJSONTyped(json, false); -} - -export function AuthenticationExecutionExportRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticationExecutionExportRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'authenticator': !exists(json, 'authenticator') ? undefined : json['authenticator'], - 'authenticatorConfig': !exists(json, 'authenticatorConfig') ? undefined : json['authenticatorConfig'], - 'authenticatorFlow': !exists(json, 'authenticatorFlow') ? undefined : json['authenticatorFlow'], - 'flowAlias': !exists(json, 'flowAlias') ? undefined : json['flowAlias'], - 'priority': !exists(json, 'priority') ? undefined : json['priority'], - 'requirement': !exists(json, 'requirement') ? undefined : json['requirement'], - 'userSetupAllowed': !exists(json, 'userSetupAllowed') ? undefined : json['userSetupAllowed'], - }; -} - -export function AuthenticationExecutionExportRepresentationToJSON(value?: AuthenticationExecutionExportRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'authenticator': value.authenticator, - 'authenticatorConfig': value.authenticatorConfig, - 'authenticatorFlow': value.authenticatorFlow, - 'flowAlias': value.flowAlias, - 'priority': value.priority, - 'requirement': value.requirement, - 'userSetupAllowed': value.userSetupAllowed, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticationExecutionInfoRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticationExecutionInfoRepresentation.ts deleted file mode 100644 index 44d132d..0000000 --- a/backend/keycloak/kc-client/models/AuthenticationExecutionInfoRepresentation.ts +++ /dev/null @@ -1,153 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AuthenticationExecutionInfoRepresentation - */ -export interface AuthenticationExecutionInfoRepresentation { - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - alias?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - authenticationConfig?: string; - /** - * - * @type {boolean} - * @memberof AuthenticationExecutionInfoRepresentation - */ - authenticationFlow?: boolean; - /** - * - * @type {boolean} - * @memberof AuthenticationExecutionInfoRepresentation - */ - configurable?: boolean; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - description?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - displayName?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - flowId?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - id?: string; - /** - * - * @type {number} - * @memberof AuthenticationExecutionInfoRepresentation - */ - index?: number; - /** - * - * @type {number} - * @memberof AuthenticationExecutionInfoRepresentation - */ - level?: number; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - providerId?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionInfoRepresentation - */ - requirement?: string; - /** - * - * @type {Array} - * @memberof AuthenticationExecutionInfoRepresentation - */ - requirementChoices?: Array; -} - -export function AuthenticationExecutionInfoRepresentationFromJSON(json: any): AuthenticationExecutionInfoRepresentation { - return AuthenticationExecutionInfoRepresentationFromJSONTyped(json, false); -} - -export function AuthenticationExecutionInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticationExecutionInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'alias': !exists(json, 'alias') ? undefined : json['alias'], - 'authenticationConfig': !exists(json, 'authenticationConfig') ? undefined : json['authenticationConfig'], - 'authenticationFlow': !exists(json, 'authenticationFlow') ? undefined : json['authenticationFlow'], - 'configurable': !exists(json, 'configurable') ? undefined : json['configurable'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'flowId': !exists(json, 'flowId') ? undefined : json['flowId'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'index': !exists(json, 'index') ? undefined : json['index'], - 'level': !exists(json, 'level') ? undefined : json['level'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'requirement': !exists(json, 'requirement') ? undefined : json['requirement'], - 'requirementChoices': !exists(json, 'requirementChoices') ? undefined : json['requirementChoices'], - }; -} - -export function AuthenticationExecutionInfoRepresentationToJSON(value?: AuthenticationExecutionInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'alias': value.alias, - 'authenticationConfig': value.authenticationConfig, - 'authenticationFlow': value.authenticationFlow, - 'configurable': value.configurable, - 'description': value.description, - 'displayName': value.displayName, - 'flowId': value.flowId, - 'id': value.id, - 'index': value.index, - 'level': value.level, - 'providerId': value.providerId, - 'requirement': value.requirement, - 'requirementChoices': value.requirementChoices, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticationExecutionRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticationExecutionRepresentation.ts deleted file mode 100644 index 1915be6..0000000 --- a/backend/keycloak/kc-client/models/AuthenticationExecutionRepresentation.ts +++ /dev/null @@ -1,113 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AuthenticationExecutionRepresentation - */ -export interface AuthenticationExecutionRepresentation { - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - authenticator?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - authenticatorConfig?: string; - /** - * - * @type {boolean} - * @memberof AuthenticationExecutionRepresentation - */ - authenticatorFlow?: boolean; - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - flowId?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - parentFlow?: string; - /** - * - * @type {number} - * @memberof AuthenticationExecutionRepresentation - */ - priority?: number; - /** - * - * @type {string} - * @memberof AuthenticationExecutionRepresentation - */ - requirement?: string; -} - -export function AuthenticationExecutionRepresentationFromJSON(json: any): AuthenticationExecutionRepresentation { - return AuthenticationExecutionRepresentationFromJSONTyped(json, false); -} - -export function AuthenticationExecutionRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticationExecutionRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'authenticator': !exists(json, 'authenticator') ? undefined : json['authenticator'], - 'authenticatorConfig': !exists(json, 'authenticatorConfig') ? undefined : json['authenticatorConfig'], - 'authenticatorFlow': !exists(json, 'authenticatorFlow') ? undefined : json['authenticatorFlow'], - 'flowId': !exists(json, 'flowId') ? undefined : json['flowId'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'parentFlow': !exists(json, 'parentFlow') ? undefined : json['parentFlow'], - 'priority': !exists(json, 'priority') ? undefined : json['priority'], - 'requirement': !exists(json, 'requirement') ? undefined : json['requirement'], - }; -} - -export function AuthenticationExecutionRepresentationToJSON(value?: AuthenticationExecutionRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'authenticator': value.authenticator, - 'authenticatorConfig': value.authenticatorConfig, - 'authenticatorFlow': value.authenticatorFlow, - 'flowId': value.flowId, - 'id': value.id, - 'parentFlow': value.parentFlow, - 'priority': value.priority, - 'requirement': value.requirement, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticationFlowRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticationFlowRepresentation.ts deleted file mode 100644 index 0cfb984..0000000 --- a/backend/keycloak/kc-client/models/AuthenticationFlowRepresentation.ts +++ /dev/null @@ -1,112 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - AuthenticationExecutionExportRepresentation, - AuthenticationExecutionExportRepresentationFromJSON, - AuthenticationExecutionExportRepresentationFromJSONTyped, - AuthenticationExecutionExportRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface AuthenticationFlowRepresentation - */ -export interface AuthenticationFlowRepresentation { - /** - * - * @type {string} - * @memberof AuthenticationFlowRepresentation - */ - alias?: string; - /** - * - * @type {Array} - * @memberof AuthenticationFlowRepresentation - */ - authenticationExecutions?: Array; - /** - * - * @type {boolean} - * @memberof AuthenticationFlowRepresentation - */ - builtIn?: boolean; - /** - * - * @type {string} - * @memberof AuthenticationFlowRepresentation - */ - description?: string; - /** - * - * @type {string} - * @memberof AuthenticationFlowRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof AuthenticationFlowRepresentation - */ - providerId?: string; - /** - * - * @type {boolean} - * @memberof AuthenticationFlowRepresentation - */ - topLevel?: boolean; -} - -export function AuthenticationFlowRepresentationFromJSON(json: any): AuthenticationFlowRepresentation { - return AuthenticationFlowRepresentationFromJSONTyped(json, false); -} - -export function AuthenticationFlowRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticationFlowRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'alias': !exists(json, 'alias') ? undefined : json['alias'], - 'authenticationExecutions': !exists(json, 'authenticationExecutions') ? undefined : ((json['authenticationExecutions'] as Array).map(AuthenticationExecutionExportRepresentationFromJSON)), - 'builtIn': !exists(json, 'builtIn') ? undefined : json['builtIn'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'topLevel': !exists(json, 'topLevel') ? undefined : json['topLevel'], - }; -} - -export function AuthenticationFlowRepresentationToJSON(value?: AuthenticationFlowRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'alias': value.alias, - 'authenticationExecutions': value.authenticationExecutions === undefined ? undefined : ((value.authenticationExecutions as Array).map(AuthenticationExecutionExportRepresentationToJSON)), - 'builtIn': value.builtIn, - 'description': value.description, - 'id': value.id, - 'providerId': value.providerId, - 'topLevel': value.topLevel, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticatorConfigInfoRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticatorConfigInfoRepresentation.ts deleted file mode 100644 index d542f05..0000000 --- a/backend/keycloak/kc-client/models/AuthenticatorConfigInfoRepresentation.ts +++ /dev/null @@ -1,88 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ConfigPropertyRepresentation, - ConfigPropertyRepresentationFromJSON, - ConfigPropertyRepresentationFromJSONTyped, - ConfigPropertyRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface AuthenticatorConfigInfoRepresentation - */ -export interface AuthenticatorConfigInfoRepresentation { - /** - * - * @type {string} - * @memberof AuthenticatorConfigInfoRepresentation - */ - helpText?: string; - /** - * - * @type {string} - * @memberof AuthenticatorConfigInfoRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof AuthenticatorConfigInfoRepresentation - */ - properties?: Array; - /** - * - * @type {string} - * @memberof AuthenticatorConfigInfoRepresentation - */ - providerId?: string; -} - -export function AuthenticatorConfigInfoRepresentationFromJSON(json: any): AuthenticatorConfigInfoRepresentation { - return AuthenticatorConfigInfoRepresentationFromJSONTyped(json, false); -} - -export function AuthenticatorConfigInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticatorConfigInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'helpText': !exists(json, 'helpText') ? undefined : json['helpText'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'properties': !exists(json, 'properties') ? undefined : ((json['properties'] as Array).map(ConfigPropertyRepresentationFromJSON)), - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - }; -} - -export function AuthenticatorConfigInfoRepresentationToJSON(value?: AuthenticatorConfigInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'helpText': value.helpText, - 'name': value.name, - 'properties': value.properties === undefined ? undefined : ((value.properties as Array).map(ConfigPropertyRepresentationToJSON)), - 'providerId': value.providerId, - }; -} - - diff --git a/backend/keycloak/kc-client/models/AuthenticatorConfigRepresentation.ts b/backend/keycloak/kc-client/models/AuthenticatorConfigRepresentation.ts deleted file mode 100644 index 0b3c0b8..0000000 --- a/backend/keycloak/kc-client/models/AuthenticatorConfigRepresentation.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface AuthenticatorConfigRepresentation - */ -export interface AuthenticatorConfigRepresentation { - /** - * - * @type {string} - * @memberof AuthenticatorConfigRepresentation - */ - alias?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof AuthenticatorConfigRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof AuthenticatorConfigRepresentation - */ - id?: string; -} - -export function AuthenticatorConfigRepresentationFromJSON(json: any): AuthenticatorConfigRepresentation { - return AuthenticatorConfigRepresentationFromJSONTyped(json, false); -} - -export function AuthenticatorConfigRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): AuthenticatorConfigRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'alias': !exists(json, 'alias') ? undefined : json['alias'], - 'config': !exists(json, 'config') ? undefined : json['config'], - 'id': !exists(json, 'id') ? undefined : json['id'], - }; -} - -export function AuthenticatorConfigRepresentationToJSON(value?: AuthenticatorConfigRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'alias': value.alias, - 'config': value.config, - 'id': value.id, - }; -} - - diff --git a/backend/keycloak/kc-client/models/CertificateRepresentation.ts b/backend/keycloak/kc-client/models/CertificateRepresentation.ts deleted file mode 100644 index 293684a..0000000 --- a/backend/keycloak/kc-client/models/CertificateRepresentation.ts +++ /dev/null @@ -1,81 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface CertificateRepresentation - */ -export interface CertificateRepresentation { - /** - * - * @type {string} - * @memberof CertificateRepresentation - */ - certificate?: string; - /** - * - * @type {string} - * @memberof CertificateRepresentation - */ - kid?: string; - /** - * - * @type {string} - * @memberof CertificateRepresentation - */ - privateKey?: string; - /** - * - * @type {string} - * @memberof CertificateRepresentation - */ - publicKey?: string; -} - -export function CertificateRepresentationFromJSON(json: any): CertificateRepresentation { - return CertificateRepresentationFromJSONTyped(json, false); -} - -export function CertificateRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): CertificateRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'certificate': !exists(json, 'certificate') ? undefined : json['certificate'], - 'kid': !exists(json, 'kid') ? undefined : json['kid'], - 'privateKey': !exists(json, 'privateKey') ? undefined : json['privateKey'], - 'publicKey': !exists(json, 'publicKey') ? undefined : json['publicKey'], - }; -} - -export function CertificateRepresentationToJSON(value?: CertificateRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'certificate': value.certificate, - 'kid': value.kid, - 'privateKey': value.privateKey, - 'publicKey': value.publicKey, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientInitialAccessCreatePresentation.ts b/backend/keycloak/kc-client/models/ClientInitialAccessCreatePresentation.ts deleted file mode 100644 index c177ba3..0000000 --- a/backend/keycloak/kc-client/models/ClientInitialAccessCreatePresentation.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ClientInitialAccessCreatePresentation - */ -export interface ClientInitialAccessCreatePresentation { - /** - * - * @type {number} - * @memberof ClientInitialAccessCreatePresentation - */ - count?: number; - /** - * - * @type {number} - * @memberof ClientInitialAccessCreatePresentation - */ - expiration?: number; -} - -export function ClientInitialAccessCreatePresentationFromJSON(json: any): ClientInitialAccessCreatePresentation { - return ClientInitialAccessCreatePresentationFromJSONTyped(json, false); -} - -export function ClientInitialAccessCreatePresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientInitialAccessCreatePresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'count': !exists(json, 'count') ? undefined : json['count'], - 'expiration': !exists(json, 'expiration') ? undefined : json['expiration'], - }; -} - -export function ClientInitialAccessCreatePresentationToJSON(value?: ClientInitialAccessCreatePresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'count': value.count, - 'expiration': value.expiration, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientInitialAccessPresentation.ts b/backend/keycloak/kc-client/models/ClientInitialAccessPresentation.ts deleted file mode 100644 index 5fde16e..0000000 --- a/backend/keycloak/kc-client/models/ClientInitialAccessPresentation.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ClientInitialAccessPresentation - */ -export interface ClientInitialAccessPresentation { - /** - * - * @type {number} - * @memberof ClientInitialAccessPresentation - */ - count?: number; - /** - * - * @type {number} - * @memberof ClientInitialAccessPresentation - */ - expiration?: number; - /** - * - * @type {string} - * @memberof ClientInitialAccessPresentation - */ - id?: string; - /** - * - * @type {number} - * @memberof ClientInitialAccessPresentation - */ - remainingCount?: number; - /** - * - * @type {number} - * @memberof ClientInitialAccessPresentation - */ - timestamp?: number; - /** - * - * @type {string} - * @memberof ClientInitialAccessPresentation - */ - token?: string; -} - -export function ClientInitialAccessPresentationFromJSON(json: any): ClientInitialAccessPresentation { - return ClientInitialAccessPresentationFromJSONTyped(json, false); -} - -export function ClientInitialAccessPresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientInitialAccessPresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'count': !exists(json, 'count') ? undefined : json['count'], - 'expiration': !exists(json, 'expiration') ? undefined : json['expiration'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'remainingCount': !exists(json, 'remainingCount') ? undefined : json['remainingCount'], - 'timestamp': !exists(json, 'timestamp') ? undefined : json['timestamp'], - 'token': !exists(json, 'token') ? undefined : json['token'], - }; -} - -export function ClientInitialAccessPresentationToJSON(value?: ClientInitialAccessPresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'count': value.count, - 'expiration': value.expiration, - 'id': value.id, - 'remainingCount': value.remainingCount, - 'timestamp': value.timestamp, - 'token': value.token, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientMappingsRepresentation.ts b/backend/keycloak/kc-client/models/ClientMappingsRepresentation.ts deleted file mode 100644 index 0fb03db..0000000 --- a/backend/keycloak/kc-client/models/ClientMappingsRepresentation.ts +++ /dev/null @@ -1,80 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationFromJSONTyped, - RoleRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientMappingsRepresentation - */ -export interface ClientMappingsRepresentation { - /** - * - * @type {string} - * @memberof ClientMappingsRepresentation - */ - client?: string; - /** - * - * @type {string} - * @memberof ClientMappingsRepresentation - */ - id?: string; - /** - * - * @type {Array} - * @memberof ClientMappingsRepresentation - */ - mappings?: Array; -} - -export function ClientMappingsRepresentationFromJSON(json: any): ClientMappingsRepresentation { - return ClientMappingsRepresentationFromJSONTyped(json, false); -} - -export function ClientMappingsRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientMappingsRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'client': !exists(json, 'client') ? undefined : json['client'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'mappings': !exists(json, 'mappings') ? undefined : ((json['mappings'] as Array).map(RoleRepresentationFromJSON)), - }; -} - -export function ClientMappingsRepresentationToJSON(value?: ClientMappingsRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'client': value.client, - 'id': value.id, - 'mappings': value.mappings === undefined ? undefined : ((value.mappings as Array).map(RoleRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientPoliciesRepresentation.ts b/backend/keycloak/kc-client/models/ClientPoliciesRepresentation.ts deleted file mode 100644 index 928df1c..0000000 --- a/backend/keycloak/kc-client/models/ClientPoliciesRepresentation.ts +++ /dev/null @@ -1,64 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ClientPolicyRepresentation, - ClientPolicyRepresentationFromJSON, - ClientPolicyRepresentationFromJSONTyped, - ClientPolicyRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientPoliciesRepresentation - */ -export interface ClientPoliciesRepresentation { - /** - * - * @type {Array} - * @memberof ClientPoliciesRepresentation - */ - policies?: Array; -} - -export function ClientPoliciesRepresentationFromJSON(json: any): ClientPoliciesRepresentation { - return ClientPoliciesRepresentationFromJSONTyped(json, false); -} - -export function ClientPoliciesRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientPoliciesRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'policies': !exists(json, 'policies') ? undefined : ((json['policies'] as Array).map(ClientPolicyRepresentationFromJSON)), - }; -} - -export function ClientPoliciesRepresentationToJSON(value?: ClientPoliciesRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'policies': value.policies === undefined ? undefined : ((value.policies as Array).map(ClientPolicyRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientPolicyConditionRepresentation.ts b/backend/keycloak/kc-client/models/ClientPolicyConditionRepresentation.ts deleted file mode 100644 index 670813e..0000000 --- a/backend/keycloak/kc-client/models/ClientPolicyConditionRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - JsonNode, - JsonNodeFromJSON, - JsonNodeFromJSONTyped, - JsonNodeToJSON, -} from './'; - -/** - * - * @export - * @interface ClientPolicyConditionRepresentation - */ -export interface ClientPolicyConditionRepresentation { - /** - * - * @type {string} - * @memberof ClientPolicyConditionRepresentation - */ - condition?: string; - /** - * - * @type {JsonNode} - * @memberof ClientPolicyConditionRepresentation - */ - _configuration?: JsonNode; -} - -export function ClientPolicyConditionRepresentationFromJSON(json: any): ClientPolicyConditionRepresentation { - return ClientPolicyConditionRepresentationFromJSONTyped(json, false); -} - -export function ClientPolicyConditionRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientPolicyConditionRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'condition': !exists(json, 'condition') ? undefined : json['condition'], - '_configuration': !exists(json, 'configuration') ? undefined : JsonNodeFromJSON(json['configuration']), - }; -} - -export function ClientPolicyConditionRepresentationToJSON(value?: ClientPolicyConditionRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'condition': value.condition, - 'configuration': JsonNodeToJSON(value._configuration), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientPolicyExecutorRepresentation.ts b/backend/keycloak/kc-client/models/ClientPolicyExecutorRepresentation.ts deleted file mode 100644 index e1e194e..0000000 --- a/backend/keycloak/kc-client/models/ClientPolicyExecutorRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - JsonNode, - JsonNodeFromJSON, - JsonNodeFromJSONTyped, - JsonNodeToJSON, -} from './'; - -/** - * - * @export - * @interface ClientPolicyExecutorRepresentation - */ -export interface ClientPolicyExecutorRepresentation { - /** - * - * @type {JsonNode} - * @memberof ClientPolicyExecutorRepresentation - */ - _configuration?: JsonNode; - /** - * - * @type {string} - * @memberof ClientPolicyExecutorRepresentation - */ - executor?: string; -} - -export function ClientPolicyExecutorRepresentationFromJSON(json: any): ClientPolicyExecutorRepresentation { - return ClientPolicyExecutorRepresentationFromJSONTyped(json, false); -} - -export function ClientPolicyExecutorRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientPolicyExecutorRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - '_configuration': !exists(json, 'configuration') ? undefined : JsonNodeFromJSON(json['configuration']), - 'executor': !exists(json, 'executor') ? undefined : json['executor'], - }; -} - -export function ClientPolicyExecutorRepresentationToJSON(value?: ClientPolicyExecutorRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'configuration': JsonNodeToJSON(value._configuration), - 'executor': value.executor, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientPolicyRepresentation.ts b/backend/keycloak/kc-client/models/ClientPolicyRepresentation.ts deleted file mode 100644 index c0f9e1a..0000000 --- a/backend/keycloak/kc-client/models/ClientPolicyRepresentation.ts +++ /dev/null @@ -1,96 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ClientPolicyConditionRepresentation, - ClientPolicyConditionRepresentationFromJSON, - ClientPolicyConditionRepresentationFromJSONTyped, - ClientPolicyConditionRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientPolicyRepresentation - */ -export interface ClientPolicyRepresentation { - /** - * - * @type {Array} - * @memberof ClientPolicyRepresentation - */ - conditions?: Array; - /** - * - * @type {string} - * @memberof ClientPolicyRepresentation - */ - description?: string; - /** - * - * @type {boolean} - * @memberof ClientPolicyRepresentation - */ - enabled?: boolean; - /** - * - * @type {string} - * @memberof ClientPolicyRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof ClientPolicyRepresentation - */ - profiles?: Array; -} - -export function ClientPolicyRepresentationFromJSON(json: any): ClientPolicyRepresentation { - return ClientPolicyRepresentationFromJSONTyped(json, false); -} - -export function ClientPolicyRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientPolicyRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'conditions': !exists(json, 'conditions') ? undefined : ((json['conditions'] as Array).map(ClientPolicyConditionRepresentationFromJSON)), - 'description': !exists(json, 'description') ? undefined : json['description'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'profiles': !exists(json, 'profiles') ? undefined : json['profiles'], - }; -} - -export function ClientPolicyRepresentationToJSON(value?: ClientPolicyRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'conditions': value.conditions === undefined ? undefined : ((value.conditions as Array).map(ClientPolicyConditionRepresentationToJSON)), - 'description': value.description, - 'enabled': value.enabled, - 'name': value.name, - 'profiles': value.profiles, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientProfileRepresentation.ts b/backend/keycloak/kc-client/models/ClientProfileRepresentation.ts deleted file mode 100644 index f07c7c2..0000000 --- a/backend/keycloak/kc-client/models/ClientProfileRepresentation.ts +++ /dev/null @@ -1,80 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ClientPolicyExecutorRepresentation, - ClientPolicyExecutorRepresentationFromJSON, - ClientPolicyExecutorRepresentationFromJSONTyped, - ClientPolicyExecutorRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientProfileRepresentation - */ -export interface ClientProfileRepresentation { - /** - * - * @type {string} - * @memberof ClientProfileRepresentation - */ - description?: string; - /** - * - * @type {Array} - * @memberof ClientProfileRepresentation - */ - executors?: Array; - /** - * - * @type {string} - * @memberof ClientProfileRepresentation - */ - name?: string; -} - -export function ClientProfileRepresentationFromJSON(json: any): ClientProfileRepresentation { - return ClientProfileRepresentationFromJSONTyped(json, false); -} - -export function ClientProfileRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientProfileRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'description': !exists(json, 'description') ? undefined : json['description'], - 'executors': !exists(json, 'executors') ? undefined : ((json['executors'] as Array).map(ClientPolicyExecutorRepresentationFromJSON)), - 'name': !exists(json, 'name') ? undefined : json['name'], - }; -} - -export function ClientProfileRepresentationToJSON(value?: ClientProfileRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'description': value.description, - 'executors': value.executors === undefined ? undefined : ((value.executors as Array).map(ClientPolicyExecutorRepresentationToJSON)), - 'name': value.name, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientProfilesRepresentation.ts b/backend/keycloak/kc-client/models/ClientProfilesRepresentation.ts deleted file mode 100644 index 9eeef1c..0000000 --- a/backend/keycloak/kc-client/models/ClientProfilesRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ClientProfileRepresentation, - ClientProfileRepresentationFromJSON, - ClientProfileRepresentationFromJSONTyped, - ClientProfileRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientProfilesRepresentation - */ -export interface ClientProfilesRepresentation { - /** - * - * @type {Array} - * @memberof ClientProfilesRepresentation - */ - globalProfiles?: Array; - /** - * - * @type {Array} - * @memberof ClientProfilesRepresentation - */ - profiles?: Array; -} - -export function ClientProfilesRepresentationFromJSON(json: any): ClientProfilesRepresentation { - return ClientProfilesRepresentationFromJSONTyped(json, false); -} - -export function ClientProfilesRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientProfilesRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'globalProfiles': !exists(json, 'globalProfiles') ? undefined : ((json['globalProfiles'] as Array).map(ClientProfileRepresentationFromJSON)), - 'profiles': !exists(json, 'profiles') ? undefined : ((json['profiles'] as Array).map(ClientProfileRepresentationFromJSON)), - }; -} - -export function ClientProfilesRepresentationToJSON(value?: ClientProfilesRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'globalProfiles': value.globalProfiles === undefined ? undefined : ((value.globalProfiles as Array).map(ClientProfileRepresentationToJSON)), - 'profiles': value.profiles === undefined ? undefined : ((value.profiles as Array).map(ClientProfileRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientRepresentation.ts b/backend/keycloak/kc-client/models/ClientRepresentation.ts deleted file mode 100644 index ff6bf29..0000000 --- a/backend/keycloak/kc-client/models/ClientRepresentation.ts +++ /dev/null @@ -1,364 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ProtocolMapperRepresentation, - ProtocolMapperRepresentationFromJSON, - ProtocolMapperRepresentationFromJSONTyped, - ProtocolMapperRepresentationToJSON, - ResourceServerRepresentation, - ResourceServerRepresentationFromJSON, - ResourceServerRepresentationFromJSONTyped, - ResourceServerRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientRepresentation - */ -export interface ClientRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof ClientRepresentation - */ - access?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - adminUrl?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - alwaysDisplayInConsole?: boolean; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ClientRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ClientRepresentation - */ - authenticationFlowBindingOverrides?: { [key: string]: object; }; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - authorizationServicesEnabled?: boolean; - /** - * - * @type {ResourceServerRepresentation} - * @memberof ClientRepresentation - */ - authorizationSettings?: ResourceServerRepresentation; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - baseUrl?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - bearerOnly?: boolean; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - clientAuthenticatorType?: string; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - clientId?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - consentRequired?: boolean; - /** - * - * @type {Array} - * @memberof ClientRepresentation - */ - defaultClientScopes?: Array; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - description?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - directAccessGrantsEnabled?: boolean; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - enabled?: boolean; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - frontchannelLogout?: boolean; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - fullScopeAllowed?: boolean; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - id?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - implicitFlowEnabled?: boolean; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - name?: string; - /** - * - * @type {number} - * @memberof ClientRepresentation - */ - nodeReRegistrationTimeout?: number; - /** - * - * @type {number} - * @memberof ClientRepresentation - */ - notBefore?: number; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - oauth2DeviceAuthorizationGrantEnabled?: boolean; - /** - * - * @type {Array} - * @memberof ClientRepresentation - */ - optionalClientScopes?: Array; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - origin?: string; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - protocol?: string; - /** - * - * @type {Array} - * @memberof ClientRepresentation - */ - protocolMappers?: Array; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - publicClient?: boolean; - /** - * - * @type {Array} - * @memberof ClientRepresentation - */ - redirectUris?: Array; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ClientRepresentation - */ - registeredNodes?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - registrationAccessToken?: string; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - rootUrl?: string; - /** - * - * @type {string} - * @memberof ClientRepresentation - */ - secret?: string; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - serviceAccountsEnabled?: boolean; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - standardFlowEnabled?: boolean; - /** - * - * @type {boolean} - * @memberof ClientRepresentation - */ - surrogateAuthRequired?: boolean; - /** - * - * @type {Array} - * @memberof ClientRepresentation - */ - webOrigins?: Array; -} - -export function ClientRepresentationFromJSON(json: any): ClientRepresentation { - return ClientRepresentationFromJSONTyped(json, false); -} - -export function ClientRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'access': !exists(json, 'access') ? undefined : json['access'], - 'adminUrl': !exists(json, 'adminUrl') ? undefined : json['adminUrl'], - 'alwaysDisplayInConsole': !exists(json, 'alwaysDisplayInConsole') ? undefined : json['alwaysDisplayInConsole'], - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'authenticationFlowBindingOverrides': !exists(json, 'authenticationFlowBindingOverrides') ? undefined : json['authenticationFlowBindingOverrides'], - 'authorizationServicesEnabled': !exists(json, 'authorizationServicesEnabled') ? undefined : json['authorizationServicesEnabled'], - 'authorizationSettings': !exists(json, 'authorizationSettings') ? undefined : ResourceServerRepresentationFromJSON(json['authorizationSettings']), - 'baseUrl': !exists(json, 'baseUrl') ? undefined : json['baseUrl'], - 'bearerOnly': !exists(json, 'bearerOnly') ? undefined : json['bearerOnly'], - 'clientAuthenticatorType': !exists(json, 'clientAuthenticatorType') ? undefined : json['clientAuthenticatorType'], - 'clientId': !exists(json, 'clientId') ? undefined : json['clientId'], - 'consentRequired': !exists(json, 'consentRequired') ? undefined : json['consentRequired'], - 'defaultClientScopes': !exists(json, 'defaultClientScopes') ? undefined : json['defaultClientScopes'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'directAccessGrantsEnabled': !exists(json, 'directAccessGrantsEnabled') ? undefined : json['directAccessGrantsEnabled'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'frontchannelLogout': !exists(json, 'frontchannelLogout') ? undefined : json['frontchannelLogout'], - 'fullScopeAllowed': !exists(json, 'fullScopeAllowed') ? undefined : json['fullScopeAllowed'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'implicitFlowEnabled': !exists(json, 'implicitFlowEnabled') ? undefined : json['implicitFlowEnabled'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'nodeReRegistrationTimeout': !exists(json, 'nodeReRegistrationTimeout') ? undefined : json['nodeReRegistrationTimeout'], - 'notBefore': !exists(json, 'notBefore') ? undefined : json['notBefore'], - 'oauth2DeviceAuthorizationGrantEnabled': !exists(json, 'oauth2DeviceAuthorizationGrantEnabled') ? undefined : json['oauth2DeviceAuthorizationGrantEnabled'], - 'optionalClientScopes': !exists(json, 'optionalClientScopes') ? undefined : json['optionalClientScopes'], - 'origin': !exists(json, 'origin') ? undefined : json['origin'], - 'protocol': !exists(json, 'protocol') ? undefined : json['protocol'], - 'protocolMappers': !exists(json, 'protocolMappers') ? undefined : ((json['protocolMappers'] as Array).map(ProtocolMapperRepresentationFromJSON)), - 'publicClient': !exists(json, 'publicClient') ? undefined : json['publicClient'], - 'redirectUris': !exists(json, 'redirectUris') ? undefined : json['redirectUris'], - 'registeredNodes': !exists(json, 'registeredNodes') ? undefined : json['registeredNodes'], - 'registrationAccessToken': !exists(json, 'registrationAccessToken') ? undefined : json['registrationAccessToken'], - 'rootUrl': !exists(json, 'rootUrl') ? undefined : json['rootUrl'], - 'secret': !exists(json, 'secret') ? undefined : json['secret'], - 'serviceAccountsEnabled': !exists(json, 'serviceAccountsEnabled') ? undefined : json['serviceAccountsEnabled'], - 'standardFlowEnabled': !exists(json, 'standardFlowEnabled') ? undefined : json['standardFlowEnabled'], - 'surrogateAuthRequired': !exists(json, 'surrogateAuthRequired') ? undefined : json['surrogateAuthRequired'], - 'webOrigins': !exists(json, 'webOrigins') ? undefined : json['webOrigins'], - }; -} - -export function ClientRepresentationToJSON(value?: ClientRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'access': value.access, - 'adminUrl': value.adminUrl, - 'alwaysDisplayInConsole': value.alwaysDisplayInConsole, - 'attributes': value.attributes, - 'authenticationFlowBindingOverrides': value.authenticationFlowBindingOverrides, - 'authorizationServicesEnabled': value.authorizationServicesEnabled, - 'authorizationSettings': ResourceServerRepresentationToJSON(value.authorizationSettings), - 'baseUrl': value.baseUrl, - 'bearerOnly': value.bearerOnly, - 'clientAuthenticatorType': value.clientAuthenticatorType, - 'clientId': value.clientId, - 'consentRequired': value.consentRequired, - 'defaultClientScopes': value.defaultClientScopes, - 'description': value.description, - 'directAccessGrantsEnabled': value.directAccessGrantsEnabled, - 'enabled': value.enabled, - 'frontchannelLogout': value.frontchannelLogout, - 'fullScopeAllowed': value.fullScopeAllowed, - 'id': value.id, - 'implicitFlowEnabled': value.implicitFlowEnabled, - 'name': value.name, - 'nodeReRegistrationTimeout': value.nodeReRegistrationTimeout, - 'notBefore': value.notBefore, - 'oauth2DeviceAuthorizationGrantEnabled': value.oauth2DeviceAuthorizationGrantEnabled, - 'optionalClientScopes': value.optionalClientScopes, - 'origin': value.origin, - 'protocol': value.protocol, - 'protocolMappers': value.protocolMappers === undefined ? undefined : ((value.protocolMappers as Array).map(ProtocolMapperRepresentationToJSON)), - 'publicClient': value.publicClient, - 'redirectUris': value.redirectUris, - 'registeredNodes': value.registeredNodes, - 'registrationAccessToken': value.registrationAccessToken, - 'rootUrl': value.rootUrl, - 'secret': value.secret, - 'serviceAccountsEnabled': value.serviceAccountsEnabled, - 'standardFlowEnabled': value.standardFlowEnabled, - 'surrogateAuthRequired': value.surrogateAuthRequired, - 'webOrigins': value.webOrigins, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation.ts b/backend/keycloak/kc-client/models/ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation.ts deleted file mode 100644 index f7d1576..0000000 --- a/backend/keycloak/kc-client/models/ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ -export interface ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation { - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - containerId?: string; - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - containerName?: string; - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - containerType?: string; - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - mapperId?: string; - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - mapperName?: string; - /** - * - * @type {string} - * @memberof ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation - */ - protocolMapper?: string; -} - -export function ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentationFromJSON(json: any): ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation { - return ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentationFromJSONTyped(json, false); -} - -export function ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'containerId': !exists(json, 'containerId') ? undefined : json['containerId'], - 'containerName': !exists(json, 'containerName') ? undefined : json['containerName'], - 'containerType': !exists(json, 'containerType') ? undefined : json['containerType'], - 'mapperId': !exists(json, 'mapperId') ? undefined : json['mapperId'], - 'mapperName': !exists(json, 'mapperName') ? undefined : json['mapperName'], - 'protocolMapper': !exists(json, 'protocolMapper') ? undefined : json['protocolMapper'], - }; -} - -export function ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentationToJSON(value?: ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'containerId': value.containerId, - 'containerName': value.containerName, - 'containerType': value.containerType, - 'mapperId': value.mapperId, - 'mapperName': value.mapperName, - 'protocolMapper': value.protocolMapper, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ClientScopeRepresentation.ts b/backend/keycloak/kc-client/models/ClientScopeRepresentation.ts deleted file mode 100644 index f04cdf6..0000000 --- a/backend/keycloak/kc-client/models/ClientScopeRepresentation.ts +++ /dev/null @@ -1,104 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ProtocolMapperRepresentation, - ProtocolMapperRepresentationFromJSON, - ProtocolMapperRepresentationFromJSONTyped, - ProtocolMapperRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ClientScopeRepresentation - */ -export interface ClientScopeRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof ClientScopeRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof ClientScopeRepresentation - */ - description?: string; - /** - * - * @type {string} - * @memberof ClientScopeRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ClientScopeRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof ClientScopeRepresentation - */ - protocol?: string; - /** - * - * @type {Array} - * @memberof ClientScopeRepresentation - */ - protocolMappers?: Array; -} - -export function ClientScopeRepresentationFromJSON(json: any): ClientScopeRepresentation { - return ClientScopeRepresentationFromJSONTyped(json, false); -} - -export function ClientScopeRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ClientScopeRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'protocol': !exists(json, 'protocol') ? undefined : json['protocol'], - 'protocolMappers': !exists(json, 'protocolMappers') ? undefined : ((json['protocolMappers'] as Array).map(ProtocolMapperRepresentationFromJSON)), - }; -} - -export function ClientScopeRepresentationToJSON(value?: ClientScopeRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'attributes': value.attributes, - 'description': value.description, - 'id': value.id, - 'name': value.name, - 'protocol': value.protocol, - 'protocolMappers': value.protocolMappers === undefined ? undefined : ((value.protocolMappers as Array).map(ProtocolMapperRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ComponentExportRepresentation.ts b/backend/keycloak/kc-client/models/ComponentExportRepresentation.ts deleted file mode 100644 index 469ef98..0000000 --- a/backend/keycloak/kc-client/models/ComponentExportRepresentation.ts +++ /dev/null @@ -1,104 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - MultivaluedHashMap, - MultivaluedHashMapFromJSON, - MultivaluedHashMapFromJSONTyped, - MultivaluedHashMapToJSON, -} from './'; - -/** - * - * @export - * @interface ComponentExportRepresentation - */ -export interface ComponentExportRepresentation { - /** - * - * @type {MultivaluedHashMap} - * @memberof ComponentExportRepresentation - */ - config?: MultivaluedHashMap; - /** - * - * @type {string} - * @memberof ComponentExportRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ComponentExportRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof ComponentExportRepresentation - */ - providerId?: string; - /** - * - * @type {MultivaluedHashMap} - * @memberof ComponentExportRepresentation - */ - subComponents?: MultivaluedHashMap; - /** - * - * @type {string} - * @memberof ComponentExportRepresentation - */ - subType?: string; -} - -export function ComponentExportRepresentationFromJSON(json: any): ComponentExportRepresentation { - return ComponentExportRepresentationFromJSONTyped(json, false); -} - -export function ComponentExportRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ComponentExportRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : MultivaluedHashMapFromJSON(json['config']), - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'subComponents': !exists(json, 'subComponents') ? undefined : MultivaluedHashMapFromJSON(json['subComponents']), - 'subType': !exists(json, 'subType') ? undefined : json['subType'], - }; -} - -export function ComponentExportRepresentationToJSON(value?: ComponentExportRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': MultivaluedHashMapToJSON(value.config), - 'id': value.id, - 'name': value.name, - 'providerId': value.providerId, - 'subComponents': MultivaluedHashMapToJSON(value.subComponents), - 'subType': value.subType, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ComponentRepresentation.ts b/backend/keycloak/kc-client/models/ComponentRepresentation.ts deleted file mode 100644 index 774f47d..0000000 --- a/backend/keycloak/kc-client/models/ComponentRepresentation.ts +++ /dev/null @@ -1,112 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - MultivaluedHashMap, - MultivaluedHashMapFromJSON, - MultivaluedHashMapFromJSONTyped, - MultivaluedHashMapToJSON, -} from './'; - -/** - * - * @export - * @interface ComponentRepresentation - */ -export interface ComponentRepresentation { - /** - * - * @type {MultivaluedHashMap} - * @memberof ComponentRepresentation - */ - config?: MultivaluedHashMap; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - parentId?: string; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - providerId?: string; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - providerType?: string; - /** - * - * @type {string} - * @memberof ComponentRepresentation - */ - subType?: string; -} - -export function ComponentRepresentationFromJSON(json: any): ComponentRepresentation { - return ComponentRepresentationFromJSONTyped(json, false); -} - -export function ComponentRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ComponentRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : MultivaluedHashMapFromJSON(json['config']), - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'parentId': !exists(json, 'parentId') ? undefined : json['parentId'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'providerType': !exists(json, 'providerType') ? undefined : json['providerType'], - 'subType': !exists(json, 'subType') ? undefined : json['subType'], - }; -} - -export function ComponentRepresentationToJSON(value?: ComponentRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': MultivaluedHashMapToJSON(value.config), - 'id': value.id, - 'name': value.name, - 'parentId': value.parentId, - 'providerId': value.providerId, - 'providerType': value.providerType, - 'subType': value.subType, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ConfigPropertyRepresentation.ts b/backend/keycloak/kc-client/models/ConfigPropertyRepresentation.ts deleted file mode 100644 index de8aacc..0000000 --- a/backend/keycloak/kc-client/models/ConfigPropertyRepresentation.ts +++ /dev/null @@ -1,113 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ConfigPropertyRepresentation - */ -export interface ConfigPropertyRepresentation { - /** - * - * @type {object} - * @memberof ConfigPropertyRepresentation - */ - defaultValue?: object; - /** - * - * @type {string} - * @memberof ConfigPropertyRepresentation - */ - helpText?: string; - /** - * - * @type {string} - * @memberof ConfigPropertyRepresentation - */ - label?: string; - /** - * - * @type {string} - * @memberof ConfigPropertyRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof ConfigPropertyRepresentation - */ - options?: Array; - /** - * - * @type {boolean} - * @memberof ConfigPropertyRepresentation - */ - readOnly?: boolean; - /** - * - * @type {boolean} - * @memberof ConfigPropertyRepresentation - */ - secret?: boolean; - /** - * - * @type {string} - * @memberof ConfigPropertyRepresentation - */ - type?: string; -} - -export function ConfigPropertyRepresentationFromJSON(json: any): ConfigPropertyRepresentation { - return ConfigPropertyRepresentationFromJSONTyped(json, false); -} - -export function ConfigPropertyRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ConfigPropertyRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'defaultValue': !exists(json, 'defaultValue') ? undefined : json['defaultValue'], - 'helpText': !exists(json, 'helpText') ? undefined : json['helpText'], - 'label': !exists(json, 'label') ? undefined : json['label'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'options': !exists(json, 'options') ? undefined : json['options'], - 'readOnly': !exists(json, 'readOnly') ? undefined : json['readOnly'], - 'secret': !exists(json, 'secret') ? undefined : json['secret'], - 'type': !exists(json, 'type') ? undefined : json['type'], - }; -} - -export function ConfigPropertyRepresentationToJSON(value?: ConfigPropertyRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'defaultValue': value.defaultValue, - 'helpText': value.helpText, - 'label': value.label, - 'name': value.name, - 'options': value.options, - 'readOnly': value.readOnly, - 'secret': value.secret, - 'type': value.type, - }; -} - - diff --git a/backend/keycloak/kc-client/models/CredentialRepresentation.ts b/backend/keycloak/kc-client/models/CredentialRepresentation.ts deleted file mode 100644 index ef2917f..0000000 --- a/backend/keycloak/kc-client/models/CredentialRepresentation.ts +++ /dev/null @@ -1,121 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface CredentialRepresentation - */ -export interface CredentialRepresentation { - /** - * - * @type {number} - * @memberof CredentialRepresentation - */ - createdDate?: number; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - credentialData?: string; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - id?: string; - /** - * - * @type {number} - * @memberof CredentialRepresentation - */ - priority?: number; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - secretData?: string; - /** - * - * @type {boolean} - * @memberof CredentialRepresentation - */ - temporary?: boolean; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - type?: string; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - userLabel?: string; - /** - * - * @type {string} - * @memberof CredentialRepresentation - */ - value?: string; -} - -export function CredentialRepresentationFromJSON(json: any): CredentialRepresentation { - return CredentialRepresentationFromJSONTyped(json, false); -} - -export function CredentialRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): CredentialRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'createdDate': !exists(json, 'createdDate') ? undefined : json['createdDate'], - 'credentialData': !exists(json, 'credentialData') ? undefined : json['credentialData'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'priority': !exists(json, 'priority') ? undefined : json['priority'], - 'secretData': !exists(json, 'secretData') ? undefined : json['secretData'], - 'temporary': !exists(json, 'temporary') ? undefined : json['temporary'], - 'type': !exists(json, 'type') ? undefined : json['type'], - 'userLabel': !exists(json, 'userLabel') ? undefined : json['userLabel'], - 'value': !exists(json, 'value') ? undefined : json['value'], - }; -} - -export function CredentialRepresentationToJSON(value?: CredentialRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'createdDate': value.createdDate, - 'credentialData': value.credentialData, - 'id': value.id, - 'priority': value.priority, - 'secretData': value.secretData, - 'temporary': value.temporary, - 'type': value.type, - 'userLabel': value.userLabel, - 'value': value.value, - }; -} - - diff --git a/backend/keycloak/kc-client/models/FederatedIdentityRepresentation.ts b/backend/keycloak/kc-client/models/FederatedIdentityRepresentation.ts deleted file mode 100644 index 95c1ed7..0000000 --- a/backend/keycloak/kc-client/models/FederatedIdentityRepresentation.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface FederatedIdentityRepresentation - */ -export interface FederatedIdentityRepresentation { - /** - * - * @type {string} - * @memberof FederatedIdentityRepresentation - */ - identityProvider?: string; - /** - * - * @type {string} - * @memberof FederatedIdentityRepresentation - */ - userId?: string; - /** - * - * @type {string} - * @memberof FederatedIdentityRepresentation - */ - userName?: string; -} - -export function FederatedIdentityRepresentationFromJSON(json: any): FederatedIdentityRepresentation { - return FederatedIdentityRepresentationFromJSONTyped(json, false); -} - -export function FederatedIdentityRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): FederatedIdentityRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'identityProvider': !exists(json, 'identityProvider') ? undefined : json['identityProvider'], - 'userId': !exists(json, 'userId') ? undefined : json['userId'], - 'userName': !exists(json, 'userName') ? undefined : json['userName'], - }; -} - -export function FederatedIdentityRepresentationToJSON(value?: FederatedIdentityRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'identityProvider': value.identityProvider, - 'userId': value.userId, - 'userName': value.userName, - }; -} - - diff --git a/backend/keycloak/kc-client/models/GlobalRequestResult.ts b/backend/keycloak/kc-client/models/GlobalRequestResult.ts deleted file mode 100644 index 48efb75..0000000 --- a/backend/keycloak/kc-client/models/GlobalRequestResult.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface GlobalRequestResult - */ -export interface GlobalRequestResult { - /** - * - * @type {Array} - * @memberof GlobalRequestResult - */ - failedRequests?: Array; - /** - * - * @type {Array} - * @memberof GlobalRequestResult - */ - successRequests?: Array; -} - -export function GlobalRequestResultFromJSON(json: any): GlobalRequestResult { - return GlobalRequestResultFromJSONTyped(json, false); -} - -export function GlobalRequestResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): GlobalRequestResult { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'failedRequests': !exists(json, 'failedRequests') ? undefined : json['failedRequests'], - 'successRequests': !exists(json, 'successRequests') ? undefined : json['successRequests'], - }; -} - -export function GlobalRequestResultToJSON(value?: GlobalRequestResult | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'failedRequests': value.failedRequests, - 'successRequests': value.successRequests, - }; -} - - diff --git a/backend/keycloak/kc-client/models/GroupRepresentation.ts b/backend/keycloak/kc-client/models/GroupRepresentation.ts deleted file mode 100644 index c53fdf0..0000000 --- a/backend/keycloak/kc-client/models/GroupRepresentation.ts +++ /dev/null @@ -1,113 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface GroupRepresentation - */ -export interface GroupRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof GroupRepresentation - */ - access?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof GroupRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof GroupRepresentation - */ - clientRoles?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof GroupRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof GroupRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof GroupRepresentation - */ - path?: string; - /** - * - * @type {Array} - * @memberof GroupRepresentation - */ - realmRoles?: Array; - /** - * - * @type {Array} - * @memberof GroupRepresentation - */ - subGroups?: Array; -} - -export function GroupRepresentationFromJSON(json: any): GroupRepresentation { - return GroupRepresentationFromJSONTyped(json, false); -} - -export function GroupRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): GroupRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'access': !exists(json, 'access') ? undefined : json['access'], - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'clientRoles': !exists(json, 'clientRoles') ? undefined : json['clientRoles'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'path': !exists(json, 'path') ? undefined : json['path'], - 'realmRoles': !exists(json, 'realmRoles') ? undefined : json['realmRoles'], - 'subGroups': !exists(json, 'subGroups') ? undefined : ((json['subGroups'] as Array).map(GroupRepresentationFromJSON)), - }; -} - -export function GroupRepresentationToJSON(value?: GroupRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'access': value.access, - 'attributes': value.attributes, - 'clientRoles': value.clientRoles, - 'id': value.id, - 'name': value.name, - 'path': value.path, - 'realmRoles': value.realmRoles, - 'subGroups': value.subGroups === undefined ? undefined : ((value.subGroups as Array).map(GroupRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/IDToken.ts b/backend/keycloak/kc-client/models/IDToken.ts deleted file mode 100644 index 65da9c0..0000000 --- a/backend/keycloak/kc-client/models/IDToken.ts +++ /dev/null @@ -1,374 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - AddressClaimSet, - AddressClaimSetFromJSON, - AddressClaimSetFromJSONTyped, - AddressClaimSetToJSON, -} from './'; - -/** - * - * @export - * @interface IDToken - */ -export interface IDToken { - /** - * - * @type {string} - * @memberof IDToken - */ - acr?: string; - /** - * - * @type {AddressClaimSet} - * @memberof IDToken - */ - address?: AddressClaimSet; - /** - * - * @type {string} - * @memberof IDToken - */ - atHash?: string; - /** - * - * @type {number} - * @memberof IDToken - */ - authTime?: number; - /** - * - * @type {string} - * @memberof IDToken - */ - azp?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - birthdate?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - cHash?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - category?: IDTokenCategoryEnum; - /** - * - * @type {string} - * @memberof IDToken - */ - claimsLocales?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - email?: string; - /** - * - * @type {boolean} - * @memberof IDToken - */ - emailVerified?: boolean; - /** - * - * @type {number} - * @memberof IDToken - */ - exp?: number; - /** - * - * @type {string} - * @memberof IDToken - */ - familyName?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - gender?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - givenName?: string; - /** - * - * @type {number} - * @memberof IDToken - */ - iat?: number; - /** - * - * @type {string} - * @memberof IDToken - */ - iss?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - jti?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - locale?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - middleName?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - name?: string; - /** - * - * @type {number} - * @memberof IDToken - */ - nbf?: number; - /** - * - * @type {string} - * @memberof IDToken - */ - nickname?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - nonce?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof IDToken - */ - otherClaims?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof IDToken - */ - phoneNumber?: string; - /** - * - * @type {boolean} - * @memberof IDToken - */ - phoneNumberVerified?: boolean; - /** - * - * @type {string} - * @memberof IDToken - */ - picture?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - preferredUsername?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - profile?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - sHash?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - sessionState?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - sid?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - sub?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - typ?: string; - /** - * - * @type {number} - * @memberof IDToken - */ - updatedAt?: number; - /** - * - * @type {string} - * @memberof IDToken - */ - website?: string; - /** - * - * @type {string} - * @memberof IDToken - */ - zoneinfo?: string; -} - -export function IDTokenFromJSON(json: any): IDToken { - return IDTokenFromJSONTyped(json, false); -} - -export function IDTokenFromJSONTyped(json: any, ignoreDiscriminator: boolean): IDToken { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'acr': !exists(json, 'acr') ? undefined : json['acr'], - 'address': !exists(json, 'address') ? undefined : AddressClaimSetFromJSON(json['address']), - 'atHash': !exists(json, 'at_hash') ? undefined : json['at_hash'], - 'authTime': !exists(json, 'auth_time') ? undefined : json['auth_time'], - 'azp': !exists(json, 'azp') ? undefined : json['azp'], - 'birthdate': !exists(json, 'birthdate') ? undefined : json['birthdate'], - 'cHash': !exists(json, 'c_hash') ? undefined : json['c_hash'], - 'category': !exists(json, 'category') ? undefined : json['category'], - 'claimsLocales': !exists(json, 'claims_locales') ? undefined : json['claims_locales'], - 'email': !exists(json, 'email') ? undefined : json['email'], - 'emailVerified': !exists(json, 'email_verified') ? undefined : json['email_verified'], - 'exp': !exists(json, 'exp') ? undefined : json['exp'], - 'familyName': !exists(json, 'family_name') ? undefined : json['family_name'], - 'gender': !exists(json, 'gender') ? undefined : json['gender'], - 'givenName': !exists(json, 'given_name') ? undefined : json['given_name'], - 'iat': !exists(json, 'iat') ? undefined : json['iat'], - 'iss': !exists(json, 'iss') ? undefined : json['iss'], - 'jti': !exists(json, 'jti') ? undefined : json['jti'], - 'locale': !exists(json, 'locale') ? undefined : json['locale'], - 'middleName': !exists(json, 'middle_name') ? undefined : json['middle_name'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'nbf': !exists(json, 'nbf') ? undefined : json['nbf'], - 'nickname': !exists(json, 'nickname') ? undefined : json['nickname'], - 'nonce': !exists(json, 'nonce') ? undefined : json['nonce'], - 'otherClaims': !exists(json, 'otherClaims') ? undefined : json['otherClaims'], - 'phoneNumber': !exists(json, 'phone_number') ? undefined : json['phone_number'], - 'phoneNumberVerified': !exists(json, 'phone_number_verified') ? undefined : json['phone_number_verified'], - 'picture': !exists(json, 'picture') ? undefined : json['picture'], - 'preferredUsername': !exists(json, 'preferred_username') ? undefined : json['preferred_username'], - 'profile': !exists(json, 'profile') ? undefined : json['profile'], - 'sHash': !exists(json, 's_hash') ? undefined : json['s_hash'], - 'sessionState': !exists(json, 'session_state') ? undefined : json['session_state'], - 'sid': !exists(json, 'sid') ? undefined : json['sid'], - 'sub': !exists(json, 'sub') ? undefined : json['sub'], - 'typ': !exists(json, 'typ') ? undefined : json['typ'], - 'updatedAt': !exists(json, 'updated_at') ? undefined : json['updated_at'], - 'website': !exists(json, 'website') ? undefined : json['website'], - 'zoneinfo': !exists(json, 'zoneinfo') ? undefined : json['zoneinfo'], - }; -} - -export function IDTokenToJSON(value?: IDToken | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'acr': value.acr, - 'address': AddressClaimSetToJSON(value.address), - 'at_hash': value.atHash, - 'auth_time': value.authTime, - 'azp': value.azp, - 'birthdate': value.birthdate, - 'c_hash': value.cHash, - 'category': value.category, - 'claims_locales': value.claimsLocales, - 'email': value.email, - 'email_verified': value.emailVerified, - 'exp': value.exp, - 'family_name': value.familyName, - 'gender': value.gender, - 'given_name': value.givenName, - 'iat': value.iat, - 'iss': value.iss, - 'jti': value.jti, - 'locale': value.locale, - 'middle_name': value.middleName, - 'name': value.name, - 'nbf': value.nbf, - 'nickname': value.nickname, - 'nonce': value.nonce, - 'otherClaims': value.otherClaims, - 'phone_number': value.phoneNumber, - 'phone_number_verified': value.phoneNumberVerified, - 'picture': value.picture, - 'preferred_username': value.preferredUsername, - 'profile': value.profile, - 's_hash': value.sHash, - 'session_state': value.sessionState, - 'sid': value.sid, - 'sub': value.sub, - 'typ': value.typ, - 'updated_at': value.updatedAt, - 'website': value.website, - 'zoneinfo': value.zoneinfo, - }; -} - -/** -* @export -* @enum {string} -*/ -export enum IDTokenCategoryEnum { - INTERNAL = 'INTERNAL', - ACCESS = 'ACCESS', - ID = 'ID', - ADMIN = 'ADMIN', - USERINFO = 'USERINFO', - LOGOUT = 'LOGOUT', - AUTHORIZATIONRESPONSE = 'AUTHORIZATION_RESPONSE' -} - - diff --git a/backend/keycloak/kc-client/models/IdentityProviderMapperRepresentation.ts b/backend/keycloak/kc-client/models/IdentityProviderMapperRepresentation.ts deleted file mode 100644 index a0570d0..0000000 --- a/backend/keycloak/kc-client/models/IdentityProviderMapperRepresentation.ts +++ /dev/null @@ -1,89 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface IdentityProviderMapperRepresentation - */ -export interface IdentityProviderMapperRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof IdentityProviderMapperRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof IdentityProviderMapperRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof IdentityProviderMapperRepresentation - */ - identityProviderAlias?: string; - /** - * - * @type {string} - * @memberof IdentityProviderMapperRepresentation - */ - identityProviderMapper?: string; - /** - * - * @type {string} - * @memberof IdentityProviderMapperRepresentation - */ - name?: string; -} - -export function IdentityProviderMapperRepresentationFromJSON(json: any): IdentityProviderMapperRepresentation { - return IdentityProviderMapperRepresentationFromJSONTyped(json, false); -} - -export function IdentityProviderMapperRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): IdentityProviderMapperRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : json['config'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'identityProviderAlias': !exists(json, 'identityProviderAlias') ? undefined : json['identityProviderAlias'], - 'identityProviderMapper': !exists(json, 'identityProviderMapper') ? undefined : json['identityProviderMapper'], - 'name': !exists(json, 'name') ? undefined : json['name'], - }; -} - -export function IdentityProviderMapperRepresentationToJSON(value?: IdentityProviderMapperRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': value.config, - 'id': value.id, - 'identityProviderAlias': value.identityProviderAlias, - 'identityProviderMapper': value.identityProviderMapper, - 'name': value.name, - }; -} - - diff --git a/backend/keycloak/kc-client/models/IdentityProviderRepresentation.ts b/backend/keycloak/kc-client/models/IdentityProviderRepresentation.ts deleted file mode 100644 index 341ca80..0000000 --- a/backend/keycloak/kc-client/models/IdentityProviderRepresentation.ts +++ /dev/null @@ -1,145 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface IdentityProviderRepresentation - */ -export interface IdentityProviderRepresentation { - /** - * - * @type {boolean} - * @memberof IdentityProviderRepresentation - */ - addReadTokenRoleOnCreate?: boolean; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - alias?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof IdentityProviderRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - displayName?: string; - /** - * - * @type {boolean} - * @memberof IdentityProviderRepresentation - */ - enabled?: boolean; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - firstBrokerLoginFlowAlias?: string; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - internalId?: string; - /** - * - * @type {boolean} - * @memberof IdentityProviderRepresentation - */ - linkOnly?: boolean; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - postBrokerLoginFlowAlias?: string; - /** - * - * @type {string} - * @memberof IdentityProviderRepresentation - */ - providerId?: string; - /** - * - * @type {boolean} - * @memberof IdentityProviderRepresentation - */ - storeToken?: boolean; - /** - * - * @type {boolean} - * @memberof IdentityProviderRepresentation - */ - trustEmail?: boolean; -} - -export function IdentityProviderRepresentationFromJSON(json: any): IdentityProviderRepresentation { - return IdentityProviderRepresentationFromJSONTyped(json, false); -} - -export function IdentityProviderRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): IdentityProviderRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'addReadTokenRoleOnCreate': !exists(json, 'addReadTokenRoleOnCreate') ? undefined : json['addReadTokenRoleOnCreate'], - 'alias': !exists(json, 'alias') ? undefined : json['alias'], - 'config': !exists(json, 'config') ? undefined : json['config'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'firstBrokerLoginFlowAlias': !exists(json, 'firstBrokerLoginFlowAlias') ? undefined : json['firstBrokerLoginFlowAlias'], - 'internalId': !exists(json, 'internalId') ? undefined : json['internalId'], - 'linkOnly': !exists(json, 'linkOnly') ? undefined : json['linkOnly'], - 'postBrokerLoginFlowAlias': !exists(json, 'postBrokerLoginFlowAlias') ? undefined : json['postBrokerLoginFlowAlias'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'storeToken': !exists(json, 'storeToken') ? undefined : json['storeToken'], - 'trustEmail': !exists(json, 'trustEmail') ? undefined : json['trustEmail'], - }; -} - -export function IdentityProviderRepresentationToJSON(value?: IdentityProviderRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'addReadTokenRoleOnCreate': value.addReadTokenRoleOnCreate, - 'alias': value.alias, - 'config': value.config, - 'displayName': value.displayName, - 'enabled': value.enabled, - 'firstBrokerLoginFlowAlias': value.firstBrokerLoginFlowAlias, - 'internalId': value.internalId, - 'linkOnly': value.linkOnly, - 'postBrokerLoginFlowAlias': value.postBrokerLoginFlowAlias, - 'providerId': value.providerId, - 'storeToken': value.storeToken, - 'trustEmail': value.trustEmail, - }; -} - - diff --git a/backend/keycloak/kc-client/models/JsonNode.ts b/backend/keycloak/kc-client/models/JsonNode.ts deleted file mode 100644 index a5894bf..0000000 --- a/backend/keycloak/kc-client/models/JsonNode.ts +++ /dev/null @@ -1,241 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface JsonNode - */ -export interface JsonNode { - /** - * - * @type {boolean} - * @memberof JsonNode - */ - array?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - bigDecimal?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - bigInteger?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - binary?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _boolean?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - containerNode?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _double?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - empty?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _float?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - floatingPointNumber?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _int?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - integralNumber?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _long?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - missingNode?: boolean; - /** - * - * @type {string} - * @memberof JsonNode - */ - nodeType?: JsonNodeNodeTypeEnum; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _null?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - number?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - object?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - pojo?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - _short?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - textual?: boolean; - /** - * - * @type {boolean} - * @memberof JsonNode - */ - valueNode?: boolean; -} - -export function JsonNodeFromJSON(json: any): JsonNode { - return JsonNodeFromJSONTyped(json, false); -} - -export function JsonNodeFromJSONTyped(json: any, ignoreDiscriminator: boolean): JsonNode { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'array': !exists(json, 'array') ? undefined : json['array'], - 'bigDecimal': !exists(json, 'bigDecimal') ? undefined : json['bigDecimal'], - 'bigInteger': !exists(json, 'bigInteger') ? undefined : json['bigInteger'], - 'binary': !exists(json, 'binary') ? undefined : json['binary'], - '_boolean': !exists(json, 'boolean') ? undefined : json['boolean'], - 'containerNode': !exists(json, 'containerNode') ? undefined : json['containerNode'], - '_double': !exists(json, 'double') ? undefined : json['double'], - 'empty': !exists(json, 'empty') ? undefined : json['empty'], - '_float': !exists(json, 'float') ? undefined : json['float'], - 'floatingPointNumber': !exists(json, 'floatingPointNumber') ? undefined : json['floatingPointNumber'], - '_int': !exists(json, 'int') ? undefined : json['int'], - 'integralNumber': !exists(json, 'integralNumber') ? undefined : json['integralNumber'], - '_long': !exists(json, 'long') ? undefined : json['long'], - 'missingNode': !exists(json, 'missingNode') ? undefined : json['missingNode'], - 'nodeType': !exists(json, 'nodeType') ? undefined : json['nodeType'], - '_null': !exists(json, 'null') ? undefined : json['null'], - 'number': !exists(json, 'number') ? undefined : json['number'], - 'object': !exists(json, 'object') ? undefined : json['object'], - 'pojo': !exists(json, 'pojo') ? undefined : json['pojo'], - '_short': !exists(json, 'short') ? undefined : json['short'], - 'textual': !exists(json, 'textual') ? undefined : json['textual'], - 'valueNode': !exists(json, 'valueNode') ? undefined : json['valueNode'], - }; -} - -export function JsonNodeToJSON(value?: JsonNode | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'array': value.array, - 'bigDecimal': value.bigDecimal, - 'bigInteger': value.bigInteger, - 'binary': value.binary, - 'boolean': value._boolean, - 'containerNode': value.containerNode, - 'double': value._double, - 'empty': value.empty, - 'float': value._float, - 'floatingPointNumber': value.floatingPointNumber, - 'int': value._int, - 'integralNumber': value.integralNumber, - 'long': value._long, - 'missingNode': value.missingNode, - 'nodeType': value.nodeType, - 'null': value._null, - 'number': value.number, - 'object': value.object, - 'pojo': value.pojo, - 'short': value._short, - 'textual': value.textual, - 'valueNode': value.valueNode, - }; -} - -/** -* @export -* @enum {string} -*/ -export enum JsonNodeNodeTypeEnum { - ARRAY = 'ARRAY', - BINARY = 'BINARY', - BOOLEAN = 'BOOLEAN', - MISSING = 'MISSING', - NULL = 'NULL', - NUMBER = 'NUMBER', - OBJECT = 'OBJECT', - POJO = 'POJO', - STRING = 'STRING' -} - - diff --git a/backend/keycloak/kc-client/models/KeyStoreConfig.ts b/backend/keycloak/kc-client/models/KeyStoreConfig.ts deleted file mode 100644 index c4c8dde..0000000 --- a/backend/keycloak/kc-client/models/KeyStoreConfig.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface KeyStoreConfig - */ -export interface KeyStoreConfig { - /** - * - * @type {string} - * @memberof KeyStoreConfig - */ - format?: string; - /** - * - * @type {string} - * @memberof KeyStoreConfig - */ - keyAlias?: string; - /** - * - * @type {string} - * @memberof KeyStoreConfig - */ - keyPassword?: string; - /** - * - * @type {string} - * @memberof KeyStoreConfig - */ - realmAlias?: string; - /** - * - * @type {boolean} - * @memberof KeyStoreConfig - */ - realmCertificate?: boolean; - /** - * - * @type {string} - * @memberof KeyStoreConfig - */ - storePassword?: string; -} - -export function KeyStoreConfigFromJSON(json: any): KeyStoreConfig { - return KeyStoreConfigFromJSONTyped(json, false); -} - -export function KeyStoreConfigFromJSONTyped(json: any, ignoreDiscriminator: boolean): KeyStoreConfig { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'format': !exists(json, 'format') ? undefined : json['format'], - 'keyAlias': !exists(json, 'keyAlias') ? undefined : json['keyAlias'], - 'keyPassword': !exists(json, 'keyPassword') ? undefined : json['keyPassword'], - 'realmAlias': !exists(json, 'realmAlias') ? undefined : json['realmAlias'], - 'realmCertificate': !exists(json, 'realmCertificate') ? undefined : json['realmCertificate'], - 'storePassword': !exists(json, 'storePassword') ? undefined : json['storePassword'], - }; -} - -export function KeyStoreConfigToJSON(value?: KeyStoreConfig | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'format': value.format, - 'keyAlias': value.keyAlias, - 'keyPassword': value.keyPassword, - 'realmAlias': value.realmAlias, - 'realmCertificate': value.realmCertificate, - 'storePassword': value.storePassword, - }; -} - - diff --git a/backend/keycloak/kc-client/models/KeysMetadataRepresentation.ts b/backend/keycloak/kc-client/models/KeysMetadataRepresentation.ts deleted file mode 100644 index 5621e1e..0000000 --- a/backend/keycloak/kc-client/models/KeysMetadataRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - KeysMetadataRepresentationKeyMetadataRepresentation, - KeysMetadataRepresentationKeyMetadataRepresentationFromJSON, - KeysMetadataRepresentationKeyMetadataRepresentationFromJSONTyped, - KeysMetadataRepresentationKeyMetadataRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface KeysMetadataRepresentation - */ -export interface KeysMetadataRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof KeysMetadataRepresentation - */ - active?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof KeysMetadataRepresentation - */ - keys?: Array; -} - -export function KeysMetadataRepresentationFromJSON(json: any): KeysMetadataRepresentation { - return KeysMetadataRepresentationFromJSONTyped(json, false); -} - -export function KeysMetadataRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): KeysMetadataRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'active': !exists(json, 'active') ? undefined : json['active'], - 'keys': !exists(json, 'keys') ? undefined : ((json['keys'] as Array).map(KeysMetadataRepresentationKeyMetadataRepresentationFromJSON)), - }; -} - -export function KeysMetadataRepresentationToJSON(value?: KeysMetadataRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'active': value.active, - 'keys': value.keys === undefined ? undefined : ((value.keys as Array).map(KeysMetadataRepresentationKeyMetadataRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/KeysMetadataRepresentationKeyMetadataRepresentation.ts b/backend/keycloak/kc-client/models/KeysMetadataRepresentationKeyMetadataRepresentation.ts deleted file mode 100644 index 2c18a7e..0000000 --- a/backend/keycloak/kc-client/models/KeysMetadataRepresentationKeyMetadataRepresentation.ts +++ /dev/null @@ -1,130 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface KeysMetadataRepresentationKeyMetadataRepresentation - */ -export interface KeysMetadataRepresentationKeyMetadataRepresentation { - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - algorithm?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - certificate?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - kid?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - providerId?: string; - /** - * - * @type {number} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - providerPriority?: number; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - publicKey?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - status?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - type?: string; - /** - * - * @type {string} - * @memberof KeysMetadataRepresentationKeyMetadataRepresentation - */ - use?: KeysMetadataRepresentationKeyMetadataRepresentationUseEnum; -} - -export function KeysMetadataRepresentationKeyMetadataRepresentationFromJSON(json: any): KeysMetadataRepresentationKeyMetadataRepresentation { - return KeysMetadataRepresentationKeyMetadataRepresentationFromJSONTyped(json, false); -} - -export function KeysMetadataRepresentationKeyMetadataRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): KeysMetadataRepresentationKeyMetadataRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'algorithm': !exists(json, 'algorithm') ? undefined : json['algorithm'], - 'certificate': !exists(json, 'certificate') ? undefined : json['certificate'], - 'kid': !exists(json, 'kid') ? undefined : json['kid'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - 'providerPriority': !exists(json, 'providerPriority') ? undefined : json['providerPriority'], - 'publicKey': !exists(json, 'publicKey') ? undefined : json['publicKey'], - 'status': !exists(json, 'status') ? undefined : json['status'], - 'type': !exists(json, 'type') ? undefined : json['type'], - 'use': !exists(json, 'use') ? undefined : json['use'], - }; -} - -export function KeysMetadataRepresentationKeyMetadataRepresentationToJSON(value?: KeysMetadataRepresentationKeyMetadataRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'algorithm': value.algorithm, - 'certificate': value.certificate, - 'kid': value.kid, - 'providerId': value.providerId, - 'providerPriority': value.providerPriority, - 'publicKey': value.publicKey, - 'status': value.status, - 'type': value.type, - 'use': value.use, - }; -} - -/** -* @export -* @enum {string} -*/ -export enum KeysMetadataRepresentationKeyMetadataRepresentationUseEnum { - SIG = 'SIG', - ENC = 'ENC' -} - - diff --git a/backend/keycloak/kc-client/models/ManagementPermissionReference.ts b/backend/keycloak/kc-client/models/ManagementPermissionReference.ts deleted file mode 100644 index 27f37d7..0000000 --- a/backend/keycloak/kc-client/models/ManagementPermissionReference.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ManagementPermissionReference - */ -export interface ManagementPermissionReference { - /** - * - * @type {boolean} - * @memberof ManagementPermissionReference - */ - enabled?: boolean; - /** - * - * @type {string} - * @memberof ManagementPermissionReference - */ - resource?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ManagementPermissionReference - */ - scopePermissions?: { [key: string]: object; }; -} - -export function ManagementPermissionReferenceFromJSON(json: any): ManagementPermissionReference { - return ManagementPermissionReferenceFromJSONTyped(json, false); -} - -export function ManagementPermissionReferenceFromJSONTyped(json: any, ignoreDiscriminator: boolean): ManagementPermissionReference { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'resource': !exists(json, 'resource') ? undefined : json['resource'], - 'scopePermissions': !exists(json, 'scopePermissions') ? undefined : json['scopePermissions'], - }; -} - -export function ManagementPermissionReferenceToJSON(value?: ManagementPermissionReference | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'enabled': value.enabled, - 'resource': value.resource, - 'scopePermissions': value.scopePermissions, - }; -} - - diff --git a/backend/keycloak/kc-client/models/MappingsRepresentation.ts b/backend/keycloak/kc-client/models/MappingsRepresentation.ts deleted file mode 100644 index c21800c..0000000 --- a/backend/keycloak/kc-client/models/MappingsRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationFromJSONTyped, - RoleRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface MappingsRepresentation - */ -export interface MappingsRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof MappingsRepresentation - */ - clientMappings?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof MappingsRepresentation - */ - realmMappings?: Array; -} - -export function MappingsRepresentationFromJSON(json: any): MappingsRepresentation { - return MappingsRepresentationFromJSONTyped(json, false); -} - -export function MappingsRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): MappingsRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'clientMappings': !exists(json, 'clientMappings') ? undefined : json['clientMappings'], - 'realmMappings': !exists(json, 'realmMappings') ? undefined : ((json['realmMappings'] as Array).map(RoleRepresentationFromJSON)), - }; -} - -export function MappingsRepresentationToJSON(value?: MappingsRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'clientMappings': value.clientMappings, - 'realmMappings': value.realmMappings === undefined ? undefined : ((value.realmMappings as Array).map(RoleRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/MemoryInfoRepresentation.ts b/backend/keycloak/kc-client/models/MemoryInfoRepresentation.ts deleted file mode 100644 index fbdf82c..0000000 --- a/backend/keycloak/kc-client/models/MemoryInfoRepresentation.ts +++ /dev/null @@ -1,105 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface MemoryInfoRepresentation - */ -export interface MemoryInfoRepresentation { - /** - * - * @type {number} - * @memberof MemoryInfoRepresentation - */ - free?: number; - /** - * - * @type {string} - * @memberof MemoryInfoRepresentation - */ - freeFormated?: string; - /** - * - * @type {number} - * @memberof MemoryInfoRepresentation - */ - freePercentage?: number; - /** - * - * @type {number} - * @memberof MemoryInfoRepresentation - */ - total?: number; - /** - * - * @type {string} - * @memberof MemoryInfoRepresentation - */ - totalFormated?: string; - /** - * - * @type {number} - * @memberof MemoryInfoRepresentation - */ - used?: number; - /** - * - * @type {string} - * @memberof MemoryInfoRepresentation - */ - usedFormated?: string; -} - -export function MemoryInfoRepresentationFromJSON(json: any): MemoryInfoRepresentation { - return MemoryInfoRepresentationFromJSONTyped(json, false); -} - -export function MemoryInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): MemoryInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'free': !exists(json, 'free') ? undefined : json['free'], - 'freeFormated': !exists(json, 'freeFormated') ? undefined : json['freeFormated'], - 'freePercentage': !exists(json, 'freePercentage') ? undefined : json['freePercentage'], - 'total': !exists(json, 'total') ? undefined : json['total'], - 'totalFormated': !exists(json, 'totalFormated') ? undefined : json['totalFormated'], - 'used': !exists(json, 'used') ? undefined : json['used'], - 'usedFormated': !exists(json, 'usedFormated') ? undefined : json['usedFormated'], - }; -} - -export function MemoryInfoRepresentationToJSON(value?: MemoryInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'free': value.free, - 'freeFormated': value.freeFormated, - 'freePercentage': value.freePercentage, - 'total': value.total, - 'totalFormated': value.totalFormated, - 'used': value.used, - 'usedFormated': value.usedFormated, - }; -} - - diff --git a/backend/keycloak/kc-client/models/MultivaluedHashMap.ts b/backend/keycloak/kc-client/models/MultivaluedHashMap.ts deleted file mode 100644 index 1de0b43..0000000 --- a/backend/keycloak/kc-client/models/MultivaluedHashMap.ts +++ /dev/null @@ -1,73 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface MultivaluedHashMap - */ -export interface MultivaluedHashMap { - /** - * - * @type {boolean} - * @memberof MultivaluedHashMap - */ - empty?: boolean; - /** - * - * @type {number} - * @memberof MultivaluedHashMap - */ - loadFactor?: number; - /** - * - * @type {number} - * @memberof MultivaluedHashMap - */ - threshold?: number; -} - -export function MultivaluedHashMapFromJSON(json: any): MultivaluedHashMap { - return MultivaluedHashMapFromJSONTyped(json, false); -} - -export function MultivaluedHashMapFromJSONTyped(json: any, ignoreDiscriminator: boolean): MultivaluedHashMap { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'empty': !exists(json, 'empty') ? undefined : json['empty'], - 'loadFactor': !exists(json, 'loadFactor') ? undefined : json['loadFactor'], - 'threshold': !exists(json, 'threshold') ? undefined : json['threshold'], - }; -} - -export function MultivaluedHashMapToJSON(value?: MultivaluedHashMap | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'empty': value.empty, - 'loadFactor': value.loadFactor, - 'threshold': value.threshold, - }; -} - - diff --git a/backend/keycloak/kc-client/models/PartialImportRepresentation.ts b/backend/keycloak/kc-client/models/PartialImportRepresentation.ts deleted file mode 100644 index f736c8c..0000000 --- a/backend/keycloak/kc-client/models/PartialImportRepresentation.ts +++ /dev/null @@ -1,138 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ClientRepresentation, - ClientRepresentationFromJSON, - ClientRepresentationFromJSONTyped, - ClientRepresentationToJSON, - GroupRepresentation, - GroupRepresentationFromJSON, - GroupRepresentationFromJSONTyped, - GroupRepresentationToJSON, - IdentityProviderRepresentation, - IdentityProviderRepresentationFromJSON, - IdentityProviderRepresentationFromJSONTyped, - IdentityProviderRepresentationToJSON, - RolesRepresentation, - RolesRepresentationFromJSON, - RolesRepresentationFromJSONTyped, - RolesRepresentationToJSON, - UserRepresentation, - UserRepresentationFromJSON, - UserRepresentationFromJSONTyped, - UserRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface PartialImportRepresentation - */ -export interface PartialImportRepresentation { - /** - * - * @type {Array} - * @memberof PartialImportRepresentation - */ - clients?: Array; - /** - * - * @type {Array} - * @memberof PartialImportRepresentation - */ - groups?: Array; - /** - * - * @type {Array} - * @memberof PartialImportRepresentation - */ - identityProviders?: Array; - /** - * - * @type {string} - * @memberof PartialImportRepresentation - */ - ifResourceExists?: string; - /** - * - * @type {string} - * @memberof PartialImportRepresentation - */ - policy?: PartialImportRepresentationPolicyEnum; - /** - * - * @type {RolesRepresentation} - * @memberof PartialImportRepresentation - */ - roles?: RolesRepresentation; - /** - * - * @type {Array} - * @memberof PartialImportRepresentation - */ - users?: Array; -} - -export function PartialImportRepresentationFromJSON(json: any): PartialImportRepresentation { - return PartialImportRepresentationFromJSONTyped(json, false); -} - -export function PartialImportRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PartialImportRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'clients': !exists(json, 'clients') ? undefined : ((json['clients'] as Array).map(ClientRepresentationFromJSON)), - 'groups': !exists(json, 'groups') ? undefined : ((json['groups'] as Array).map(GroupRepresentationFromJSON)), - 'identityProviders': !exists(json, 'identityProviders') ? undefined : ((json['identityProviders'] as Array).map(IdentityProviderRepresentationFromJSON)), - 'ifResourceExists': !exists(json, 'ifResourceExists') ? undefined : json['ifResourceExists'], - 'policy': !exists(json, 'policy') ? undefined : json['policy'], - 'roles': !exists(json, 'roles') ? undefined : RolesRepresentationFromJSON(json['roles']), - 'users': !exists(json, 'users') ? undefined : ((json['users'] as Array).map(UserRepresentationFromJSON)), - }; -} - -export function PartialImportRepresentationToJSON(value?: PartialImportRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'clients': value.clients === undefined ? undefined : ((value.clients as Array).map(ClientRepresentationToJSON)), - 'groups': value.groups === undefined ? undefined : ((value.groups as Array).map(GroupRepresentationToJSON)), - 'identityProviders': value.identityProviders === undefined ? undefined : ((value.identityProviders as Array).map(IdentityProviderRepresentationToJSON)), - 'ifResourceExists': value.ifResourceExists, - 'policy': value.policy, - 'roles': RolesRepresentationToJSON(value.roles), - 'users': value.users === undefined ? undefined : ((value.users as Array).map(UserRepresentationToJSON)), - }; -} - -/** -* @export -* @enum {string} -*/ -export enum PartialImportRepresentationPolicyEnum { - SKIP = 'SKIP', - OVERWRITE = 'OVERWRITE', - FAIL = 'FAIL' -} - - diff --git a/backend/keycloak/kc-client/models/PasswordPolicyTypeRepresentation.ts b/backend/keycloak/kc-client/models/PasswordPolicyTypeRepresentation.ts deleted file mode 100644 index 0ee21a3..0000000 --- a/backend/keycloak/kc-client/models/PasswordPolicyTypeRepresentation.ts +++ /dev/null @@ -1,89 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface PasswordPolicyTypeRepresentation - */ -export interface PasswordPolicyTypeRepresentation { - /** - * - * @type {string} - * @memberof PasswordPolicyTypeRepresentation - */ - configType?: string; - /** - * - * @type {string} - * @memberof PasswordPolicyTypeRepresentation - */ - defaultValue?: string; - /** - * - * @type {string} - * @memberof PasswordPolicyTypeRepresentation - */ - displayName?: string; - /** - * - * @type {string} - * @memberof PasswordPolicyTypeRepresentation - */ - id?: string; - /** - * - * @type {boolean} - * @memberof PasswordPolicyTypeRepresentation - */ - multipleSupported?: boolean; -} - -export function PasswordPolicyTypeRepresentationFromJSON(json: any): PasswordPolicyTypeRepresentation { - return PasswordPolicyTypeRepresentationFromJSONTyped(json, false); -} - -export function PasswordPolicyTypeRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PasswordPolicyTypeRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'configType': !exists(json, 'configType') ? undefined : json['configType'], - 'defaultValue': !exists(json, 'defaultValue') ? undefined : json['defaultValue'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'multipleSupported': !exists(json, 'multipleSupported') ? undefined : json['multipleSupported'], - }; -} - -export function PasswordPolicyTypeRepresentationToJSON(value?: PasswordPolicyTypeRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'configType': value.configType, - 'defaultValue': value.defaultValue, - 'displayName': value.displayName, - 'id': value.id, - 'multipleSupported': value.multipleSupported, - }; -} - - diff --git a/backend/keycloak/kc-client/models/Permission.ts b/backend/keycloak/kc-client/models/Permission.ts deleted file mode 100644 index 81fd8f9..0000000 --- a/backend/keycloak/kc-client/models/Permission.ts +++ /dev/null @@ -1,81 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface Permission - */ -export interface Permission { - /** - * - * @type {{ [key: string]: object; }} - * @memberof Permission - */ - claims?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof Permission - */ - rsid?: string; - /** - * - * @type {string} - * @memberof Permission - */ - rsname?: string; - /** - * - * @type {Array} - * @memberof Permission - */ - scopes?: Array; -} - -export function PermissionFromJSON(json: any): Permission { - return PermissionFromJSONTyped(json, false); -} - -export function PermissionFromJSONTyped(json: any, ignoreDiscriminator: boolean): Permission { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'claims': !exists(json, 'claims') ? undefined : json['claims'], - 'rsid': !exists(json, 'rsid') ? undefined : json['rsid'], - 'rsname': !exists(json, 'rsname') ? undefined : json['rsname'], - 'scopes': !exists(json, 'scopes') ? undefined : json['scopes'], - }; -} - -export function PermissionToJSON(value?: Permission | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'claims': value.claims, - 'rsid': value.rsid, - 'rsname': value.rsname, - 'scopes': value.scopes, - }; -} - - diff --git a/backend/keycloak/kc-client/models/PolicyRepresentation.ts b/backend/keycloak/kc-client/models/PolicyRepresentation.ts deleted file mode 100644 index 2bae042..0000000 --- a/backend/keycloak/kc-client/models/PolicyRepresentation.ts +++ /dev/null @@ -1,182 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ResourceRepresentation, - ResourceRepresentationFromJSON, - ResourceRepresentationFromJSONTyped, - ResourceRepresentationToJSON, - ScopeRepresentation, - ScopeRepresentationFromJSON, - ScopeRepresentationFromJSONTyped, - ScopeRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface PolicyRepresentation - */ -export interface PolicyRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof PolicyRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - decisionStrategy?: PolicyRepresentationDecisionStrategyEnum; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - description?: string; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - logic?: PolicyRepresentationLogicEnum; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - owner?: string; - /** - * - * @type {Array} - * @memberof PolicyRepresentation - */ - policies?: Array; - /** - * - * @type {Array} - * @memberof PolicyRepresentation - */ - resources?: Array; - /** - * - * @type {Array} - * @memberof PolicyRepresentation - */ - resourcesData?: Array; - /** - * - * @type {Array} - * @memberof PolicyRepresentation - */ - scopes?: Array; - /** - * - * @type {Array} - * @memberof PolicyRepresentation - */ - scopesData?: Array; - /** - * - * @type {string} - * @memberof PolicyRepresentation - */ - type?: string; -} - -export function PolicyRepresentationFromJSON(json: any): PolicyRepresentation { - return PolicyRepresentationFromJSONTyped(json, false); -} - -export function PolicyRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): PolicyRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : json['config'], - 'decisionStrategy': !exists(json, 'decisionStrategy') ? undefined : json['decisionStrategy'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'logic': !exists(json, 'logic') ? undefined : json['logic'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'owner': !exists(json, 'owner') ? undefined : json['owner'], - 'policies': !exists(json, 'policies') ? undefined : json['policies'], - 'resources': !exists(json, 'resources') ? undefined : json['resources'], - 'resourcesData': !exists(json, 'resourcesData') ? undefined : ((json['resourcesData'] as Array).map(ResourceRepresentationFromJSON)), - 'scopes': !exists(json, 'scopes') ? undefined : json['scopes'], - 'scopesData': !exists(json, 'scopesData') ? undefined : ((json['scopesData'] as Array).map(ScopeRepresentationFromJSON)), - 'type': !exists(json, 'type') ? undefined : json['type'], - }; -} - -export function PolicyRepresentationToJSON(value?: PolicyRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': value.config, - 'decisionStrategy': value.decisionStrategy, - 'description': value.description, - 'id': value.id, - 'logic': value.logic, - 'name': value.name, - 'owner': value.owner, - 'policies': value.policies, - 'resources': value.resources, - 'resourcesData': value.resourcesData === undefined ? undefined : ((value.resourcesData as Array).map(ResourceRepresentationToJSON)), - 'scopes': value.scopes, - 'scopesData': value.scopesData === undefined ? undefined : ((value.scopesData as Array).map(ScopeRepresentationToJSON)), - 'type': value.type, - }; -} - -/** -* @export -* @enum {string} -*/ -export enum PolicyRepresentationDecisionStrategyEnum { - AFFIRMATIVE = 'AFFIRMATIVE', - UNANIMOUS = 'UNANIMOUS', - CONSENSUS = 'CONSENSUS' -} -/** -* @export -* @enum {string} -*/ -export enum PolicyRepresentationLogicEnum { - POSITIVE = 'POSITIVE', - NEGATIVE = 'NEGATIVE' -} - - diff --git a/backend/keycloak/kc-client/models/ProfileInfoRepresentation.ts b/backend/keycloak/kc-client/models/ProfileInfoRepresentation.ts deleted file mode 100644 index 80a05ec..0000000 --- a/backend/keycloak/kc-client/models/ProfileInfoRepresentation.ts +++ /dev/null @@ -1,81 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ProfileInfoRepresentation - */ -export interface ProfileInfoRepresentation { - /** - * - * @type {Array} - * @memberof ProfileInfoRepresentation - */ - disabledFeatures?: Array; - /** - * - * @type {Array} - * @memberof ProfileInfoRepresentation - */ - experimentalFeatures?: Array; - /** - * - * @type {string} - * @memberof ProfileInfoRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof ProfileInfoRepresentation - */ - previewFeatures?: Array; -} - -export function ProfileInfoRepresentationFromJSON(json: any): ProfileInfoRepresentation { - return ProfileInfoRepresentationFromJSONTyped(json, false); -} - -export function ProfileInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProfileInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'disabledFeatures': !exists(json, 'disabledFeatures') ? undefined : json['disabledFeatures'], - 'experimentalFeatures': !exists(json, 'experimentalFeatures') ? undefined : json['experimentalFeatures'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'previewFeatures': !exists(json, 'previewFeatures') ? undefined : json['previewFeatures'], - }; -} - -export function ProfileInfoRepresentationToJSON(value?: ProfileInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'disabledFeatures': value.disabledFeatures, - 'experimentalFeatures': value.experimentalFeatures, - 'name': value.name, - 'previewFeatures': value.previewFeatures, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ProtocolMapperRepresentation.ts b/backend/keycloak/kc-client/models/ProtocolMapperRepresentation.ts deleted file mode 100644 index 79dc881..0000000 --- a/backend/keycloak/kc-client/models/ProtocolMapperRepresentation.ts +++ /dev/null @@ -1,89 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ProtocolMapperRepresentation - */ -export interface ProtocolMapperRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof ProtocolMapperRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof ProtocolMapperRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ProtocolMapperRepresentation - */ - name?: string; - /** - * - * @type {string} - * @memberof ProtocolMapperRepresentation - */ - protocol?: string; - /** - * - * @type {string} - * @memberof ProtocolMapperRepresentation - */ - protocolMapper?: string; -} - -export function ProtocolMapperRepresentationFromJSON(json: any): ProtocolMapperRepresentation { - return ProtocolMapperRepresentationFromJSONTyped(json, false); -} - -export function ProtocolMapperRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProtocolMapperRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : json['config'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'protocol': !exists(json, 'protocol') ? undefined : json['protocol'], - 'protocolMapper': !exists(json, 'protocolMapper') ? undefined : json['protocolMapper'], - }; -} - -export function ProtocolMapperRepresentationToJSON(value?: ProtocolMapperRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': value.config, - 'id': value.id, - 'name': value.name, - 'protocol': value.protocol, - 'protocolMapper': value.protocolMapper, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ProviderRepresentation.ts b/backend/keycloak/kc-client/models/ProviderRepresentation.ts deleted file mode 100644 index 00e6ff0..0000000 --- a/backend/keycloak/kc-client/models/ProviderRepresentation.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ProviderRepresentation - */ -export interface ProviderRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof ProviderRepresentation - */ - operationalInfo?: { [key: string]: object; }; - /** - * - * @type {number} - * @memberof ProviderRepresentation - */ - order?: number; -} - -export function ProviderRepresentationFromJSON(json: any): ProviderRepresentation { - return ProviderRepresentationFromJSONTyped(json, false); -} - -export function ProviderRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ProviderRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'operationalInfo': !exists(json, 'operationalInfo') ? undefined : json['operationalInfo'], - 'order': !exists(json, 'order') ? undefined : json['order'], - }; -} - -export function ProviderRepresentationToJSON(value?: ProviderRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'operationalInfo': value.operationalInfo, - 'order': value.order, - }; -} - - diff --git a/backend/keycloak/kc-client/models/RealmEventsConfigRepresentation.ts b/backend/keycloak/kc-client/models/RealmEventsConfigRepresentation.ts deleted file mode 100644 index 013e7a1..0000000 --- a/backend/keycloak/kc-client/models/RealmEventsConfigRepresentation.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface RealmEventsConfigRepresentation - */ -export interface RealmEventsConfigRepresentation { - /** - * - * @type {boolean} - * @memberof RealmEventsConfigRepresentation - */ - adminEventsDetailsEnabled?: boolean; - /** - * - * @type {boolean} - * @memberof RealmEventsConfigRepresentation - */ - adminEventsEnabled?: boolean; - /** - * - * @type {Array} - * @memberof RealmEventsConfigRepresentation - */ - enabledEventTypes?: Array; - /** - * - * @type {boolean} - * @memberof RealmEventsConfigRepresentation - */ - eventsEnabled?: boolean; - /** - * - * @type {number} - * @memberof RealmEventsConfigRepresentation - */ - eventsExpiration?: number; - /** - * - * @type {Array} - * @memberof RealmEventsConfigRepresentation - */ - eventsListeners?: Array; -} - -export function RealmEventsConfigRepresentationFromJSON(json: any): RealmEventsConfigRepresentation { - return RealmEventsConfigRepresentationFromJSONTyped(json, false); -} - -export function RealmEventsConfigRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RealmEventsConfigRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'adminEventsDetailsEnabled': !exists(json, 'adminEventsDetailsEnabled') ? undefined : json['adminEventsDetailsEnabled'], - 'adminEventsEnabled': !exists(json, 'adminEventsEnabled') ? undefined : json['adminEventsEnabled'], - 'enabledEventTypes': !exists(json, 'enabledEventTypes') ? undefined : json['enabledEventTypes'], - 'eventsEnabled': !exists(json, 'eventsEnabled') ? undefined : json['eventsEnabled'], - 'eventsExpiration': !exists(json, 'eventsExpiration') ? undefined : json['eventsExpiration'], - 'eventsListeners': !exists(json, 'eventsListeners') ? undefined : json['eventsListeners'], - }; -} - -export function RealmEventsConfigRepresentationToJSON(value?: RealmEventsConfigRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'adminEventsDetailsEnabled': value.adminEventsDetailsEnabled, - 'adminEventsEnabled': value.adminEventsEnabled, - 'enabledEventTypes': value.enabledEventTypes, - 'eventsEnabled': value.eventsEnabled, - 'eventsExpiration': value.eventsExpiration, - 'eventsListeners': value.eventsListeners, - }; -} - - diff --git a/backend/keycloak/kc-client/models/RealmRepresentation.ts b/backend/keycloak/kc-client/models/RealmRepresentation.ts deleted file mode 100644 index 4261f60..0000000 --- a/backend/keycloak/kc-client/models/RealmRepresentation.ts +++ /dev/null @@ -1,1104 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - AuthenticationFlowRepresentation, - AuthenticationFlowRepresentationFromJSON, - AuthenticationFlowRepresentationFromJSONTyped, - AuthenticationFlowRepresentationToJSON, - AuthenticatorConfigRepresentation, - AuthenticatorConfigRepresentationFromJSON, - AuthenticatorConfigRepresentationFromJSONTyped, - AuthenticatorConfigRepresentationToJSON, - ClientRepresentation, - ClientRepresentationFromJSON, - ClientRepresentationFromJSONTyped, - ClientRepresentationToJSON, - ClientScopeRepresentation, - ClientScopeRepresentationFromJSON, - ClientScopeRepresentationFromJSONTyped, - ClientScopeRepresentationToJSON, - GroupRepresentation, - GroupRepresentationFromJSON, - GroupRepresentationFromJSONTyped, - GroupRepresentationToJSON, - IdentityProviderMapperRepresentation, - IdentityProviderMapperRepresentationFromJSON, - IdentityProviderMapperRepresentationFromJSONTyped, - IdentityProviderMapperRepresentationToJSON, - IdentityProviderRepresentation, - IdentityProviderRepresentationFromJSON, - IdentityProviderRepresentationFromJSONTyped, - IdentityProviderRepresentationToJSON, - JsonNode, - JsonNodeFromJSON, - JsonNodeFromJSONTyped, - JsonNodeToJSON, - MultivaluedHashMap, - MultivaluedHashMapFromJSON, - MultivaluedHashMapFromJSONTyped, - MultivaluedHashMapToJSON, - ProtocolMapperRepresentation, - ProtocolMapperRepresentationFromJSON, - ProtocolMapperRepresentationFromJSONTyped, - ProtocolMapperRepresentationToJSON, - RequiredActionProviderRepresentation, - RequiredActionProviderRepresentationFromJSON, - RequiredActionProviderRepresentationFromJSONTyped, - RequiredActionProviderRepresentationToJSON, - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationFromJSONTyped, - RoleRepresentationToJSON, - RolesRepresentation, - RolesRepresentationFromJSON, - RolesRepresentationFromJSONTyped, - RolesRepresentationToJSON, - ScopeMappingRepresentation, - ScopeMappingRepresentationFromJSON, - ScopeMappingRepresentationFromJSONTyped, - ScopeMappingRepresentationToJSON, - UserFederationMapperRepresentation, - UserFederationMapperRepresentationFromJSON, - UserFederationMapperRepresentationFromJSONTyped, - UserFederationMapperRepresentationToJSON, - UserFederationProviderRepresentation, - UserFederationProviderRepresentationFromJSON, - UserFederationProviderRepresentationFromJSONTyped, - UserFederationProviderRepresentationToJSON, - UserRepresentation, - UserRepresentationFromJSON, - UserRepresentationFromJSONTyped, - UserRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface RealmRepresentation - */ -export interface RealmRepresentation { - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - accessCodeLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - accessCodeLifespanLogin?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - accessCodeLifespanUserAction?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - accessTokenLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - accessTokenLifespanForImplicitFlow?: number; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - accountTheme?: string; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - actionTokenGeneratedByAdminLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - actionTokenGeneratedByUserLifespan?: number; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - adminEventsDetailsEnabled?: boolean; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - adminEventsEnabled?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - adminTheme?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof RealmRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - authenticationFlows?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - authenticatorConfig?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - browserFlow?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof RealmRepresentation - */ - browserSecurityHeaders?: { [key: string]: object; }; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - bruteForceProtected?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - clientAuthenticationFlow?: string; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - clientOfflineSessionIdleTimeout?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - clientOfflineSessionMaxLifespan?: number; - /** - * - * @type {JsonNode} - * @memberof RealmRepresentation - */ - clientPolicies?: JsonNode; - /** - * - * @type {JsonNode} - * @memberof RealmRepresentation - */ - clientProfiles?: JsonNode; - /** - * - * @type {{ [key: string]: object; }} - * @memberof RealmRepresentation - */ - clientScopeMappings?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - clientScopes?: Array; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - clientSessionIdleTimeout?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - clientSessionMaxLifespan?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - clients?: Array; - /** - * - * @type {MultivaluedHashMap} - * @memberof RealmRepresentation - */ - components?: MultivaluedHashMap; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - defaultDefaultClientScopes?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - defaultGroups?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - defaultLocale?: string; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - defaultOptionalClientScopes?: Array; - /** - * - * @type {RoleRepresentation} - * @memberof RealmRepresentation - */ - defaultRole?: RoleRepresentation; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - defaultSignatureAlgorithm?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - directGrantFlow?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - displayName?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - displayNameHtml?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - dockerAuthenticationFlow?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - duplicateEmailsAllowed?: boolean; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - editUsernameAllowed?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - emailTheme?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - enabled?: boolean; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - enabledEventTypes?: Array; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - eventsEnabled?: boolean; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - eventsExpiration?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - eventsListeners?: Array; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - failureFactor?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - federatedUsers?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - groups?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - id?: string; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - identityProviderMappers?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - identityProviders?: Array; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - internationalizationEnabled?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - keycloakVersion?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - loginTheme?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - loginWithEmailAllowed?: boolean; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - maxDeltaTimeSeconds?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - maxFailureWaitSeconds?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - minimumQuickLoginWaitSeconds?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - notBefore?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - oAuth2DeviceCodeLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - oAuth2DevicePollingInterval?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - oauth2DeviceCodeLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - oauth2DevicePollingInterval?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - offlineSessionIdleTimeout?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - offlineSessionMaxLifespan?: number; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - offlineSessionMaxLifespanEnabled?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - otpPolicyAlgorithm?: string; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - otpPolicyDigits?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - otpPolicyInitialCounter?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - otpPolicyLookAheadWindow?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - otpPolicyPeriod?: number; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - otpPolicyType?: string; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - otpSupportedApplications?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - passwordPolicy?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - permanentLockout?: boolean; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - protocolMappers?: Array; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - quickLoginCheckMilliSeconds?: number; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - realm?: string; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - refreshTokenMaxReuse?: number; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - registrationAllowed?: boolean; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - registrationEmailAsUsername?: boolean; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - registrationFlow?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - rememberMe?: boolean; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - requiredActions?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - resetCredentialsFlow?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - resetPasswordAllowed?: boolean; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - revokeRefreshToken?: boolean; - /** - * - * @type {RolesRepresentation} - * @memberof RealmRepresentation - */ - roles?: RolesRepresentation; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - scopeMappings?: Array; - /** - * - * @type {{ [key: string]: object; }} - * @memberof RealmRepresentation - */ - smtpServer?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - sslRequired?: string; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - ssoSessionIdleTimeout?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - ssoSessionIdleTimeoutRememberMe?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - ssoSessionMaxLifespan?: number; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - ssoSessionMaxLifespanRememberMe?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - supportedLocales?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - userFederationMappers?: Array; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - userFederationProviders?: Array; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - userManagedAccessAllowed?: boolean; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - users?: Array; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - verifyEmail?: boolean; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - waitIncrementSeconds?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - webAuthnPolicyAcceptableAaguids?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyAttestationConveyancePreference?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyAuthenticatorAttachment?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - webAuthnPolicyAvoidSameAuthenticatorRegister?: boolean; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - webAuthnPolicyCreateTimeout?: number; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessAcceptableAaguids?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessAttestationConveyancePreference?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessAuthenticatorAttachment?: string; - /** - * - * @type {boolean} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister?: boolean; - /** - * - * @type {number} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessCreateTimeout?: number; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessRequireResidentKey?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessRpEntityName?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessRpId?: string; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessSignatureAlgorithms?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyPasswordlessUserVerificationRequirement?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyRequireResidentKey?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyRpEntityName?: string; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyRpId?: string; - /** - * - * @type {Array} - * @memberof RealmRepresentation - */ - webAuthnPolicySignatureAlgorithms?: Array; - /** - * - * @type {string} - * @memberof RealmRepresentation - */ - webAuthnPolicyUserVerificationRequirement?: string; -} - -export function RealmRepresentationFromJSON(json: any): RealmRepresentation { - return RealmRepresentationFromJSONTyped(json, false); -} - -export function RealmRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RealmRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'accessCodeLifespan': !exists(json, 'accessCodeLifespan') ? undefined : json['accessCodeLifespan'], - 'accessCodeLifespanLogin': !exists(json, 'accessCodeLifespanLogin') ? undefined : json['accessCodeLifespanLogin'], - 'accessCodeLifespanUserAction': !exists(json, 'accessCodeLifespanUserAction') ? undefined : json['accessCodeLifespanUserAction'], - 'accessTokenLifespan': !exists(json, 'accessTokenLifespan') ? undefined : json['accessTokenLifespan'], - 'accessTokenLifespanForImplicitFlow': !exists(json, 'accessTokenLifespanForImplicitFlow') ? undefined : json['accessTokenLifespanForImplicitFlow'], - 'accountTheme': !exists(json, 'accountTheme') ? undefined : json['accountTheme'], - 'actionTokenGeneratedByAdminLifespan': !exists(json, 'actionTokenGeneratedByAdminLifespan') ? undefined : json['actionTokenGeneratedByAdminLifespan'], - 'actionTokenGeneratedByUserLifespan': !exists(json, 'actionTokenGeneratedByUserLifespan') ? undefined : json['actionTokenGeneratedByUserLifespan'], - 'adminEventsDetailsEnabled': !exists(json, 'adminEventsDetailsEnabled') ? undefined : json['adminEventsDetailsEnabled'], - 'adminEventsEnabled': !exists(json, 'adminEventsEnabled') ? undefined : json['adminEventsEnabled'], - 'adminTheme': !exists(json, 'adminTheme') ? undefined : json['adminTheme'], - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'authenticationFlows': !exists(json, 'authenticationFlows') ? undefined : ((json['authenticationFlows'] as Array).map(AuthenticationFlowRepresentationFromJSON)), - 'authenticatorConfig': !exists(json, 'authenticatorConfig') ? undefined : ((json['authenticatorConfig'] as Array).map(AuthenticatorConfigRepresentationFromJSON)), - 'browserFlow': !exists(json, 'browserFlow') ? undefined : json['browserFlow'], - 'browserSecurityHeaders': !exists(json, 'browserSecurityHeaders') ? undefined : json['browserSecurityHeaders'], - 'bruteForceProtected': !exists(json, 'bruteForceProtected') ? undefined : json['bruteForceProtected'], - 'clientAuthenticationFlow': !exists(json, 'clientAuthenticationFlow') ? undefined : json['clientAuthenticationFlow'], - 'clientOfflineSessionIdleTimeout': !exists(json, 'clientOfflineSessionIdleTimeout') ? undefined : json['clientOfflineSessionIdleTimeout'], - 'clientOfflineSessionMaxLifespan': !exists(json, 'clientOfflineSessionMaxLifespan') ? undefined : json['clientOfflineSessionMaxLifespan'], - 'clientPolicies': !exists(json, 'clientPolicies') ? undefined : JsonNodeFromJSON(json['clientPolicies']), - 'clientProfiles': !exists(json, 'clientProfiles') ? undefined : JsonNodeFromJSON(json['clientProfiles']), - 'clientScopeMappings': !exists(json, 'clientScopeMappings') ? undefined : json['clientScopeMappings'], - 'clientScopes': !exists(json, 'clientScopes') ? undefined : ((json['clientScopes'] as Array).map(ClientScopeRepresentationFromJSON)), - 'clientSessionIdleTimeout': !exists(json, 'clientSessionIdleTimeout') ? undefined : json['clientSessionIdleTimeout'], - 'clientSessionMaxLifespan': !exists(json, 'clientSessionMaxLifespan') ? undefined : json['clientSessionMaxLifespan'], - 'clients': !exists(json, 'clients') ? undefined : ((json['clients'] as Array).map(ClientRepresentationFromJSON)), - 'components': !exists(json, 'components') ? undefined : MultivaluedHashMapFromJSON(json['components']), - 'defaultDefaultClientScopes': !exists(json, 'defaultDefaultClientScopes') ? undefined : json['defaultDefaultClientScopes'], - 'defaultGroups': !exists(json, 'defaultGroups') ? undefined : json['defaultGroups'], - 'defaultLocale': !exists(json, 'defaultLocale') ? undefined : json['defaultLocale'], - 'defaultOptionalClientScopes': !exists(json, 'defaultOptionalClientScopes') ? undefined : json['defaultOptionalClientScopes'], - 'defaultRole': !exists(json, 'defaultRole') ? undefined : RoleRepresentationFromJSON(json['defaultRole']), - 'defaultSignatureAlgorithm': !exists(json, 'defaultSignatureAlgorithm') ? undefined : json['defaultSignatureAlgorithm'], - 'directGrantFlow': !exists(json, 'directGrantFlow') ? undefined : json['directGrantFlow'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'displayNameHtml': !exists(json, 'displayNameHtml') ? undefined : json['displayNameHtml'], - 'dockerAuthenticationFlow': !exists(json, 'dockerAuthenticationFlow') ? undefined : json['dockerAuthenticationFlow'], - 'duplicateEmailsAllowed': !exists(json, 'duplicateEmailsAllowed') ? undefined : json['duplicateEmailsAllowed'], - 'editUsernameAllowed': !exists(json, 'editUsernameAllowed') ? undefined : json['editUsernameAllowed'], - 'emailTheme': !exists(json, 'emailTheme') ? undefined : json['emailTheme'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'enabledEventTypes': !exists(json, 'enabledEventTypes') ? undefined : json['enabledEventTypes'], - 'eventsEnabled': !exists(json, 'eventsEnabled') ? undefined : json['eventsEnabled'], - 'eventsExpiration': !exists(json, 'eventsExpiration') ? undefined : json['eventsExpiration'], - 'eventsListeners': !exists(json, 'eventsListeners') ? undefined : json['eventsListeners'], - 'failureFactor': !exists(json, 'failureFactor') ? undefined : json['failureFactor'], - 'federatedUsers': !exists(json, 'federatedUsers') ? undefined : ((json['federatedUsers'] as Array).map(UserRepresentationFromJSON)), - 'groups': !exists(json, 'groups') ? undefined : ((json['groups'] as Array).map(GroupRepresentationFromJSON)), - 'id': !exists(json, 'id') ? undefined : json['id'], - 'identityProviderMappers': !exists(json, 'identityProviderMappers') ? undefined : ((json['identityProviderMappers'] as Array).map(IdentityProviderMapperRepresentationFromJSON)), - 'identityProviders': !exists(json, 'identityProviders') ? undefined : ((json['identityProviders'] as Array).map(IdentityProviderRepresentationFromJSON)), - 'internationalizationEnabled': !exists(json, 'internationalizationEnabled') ? undefined : json['internationalizationEnabled'], - 'keycloakVersion': !exists(json, 'keycloakVersion') ? undefined : json['keycloakVersion'], - 'loginTheme': !exists(json, 'loginTheme') ? undefined : json['loginTheme'], - 'loginWithEmailAllowed': !exists(json, 'loginWithEmailAllowed') ? undefined : json['loginWithEmailAllowed'], - 'maxDeltaTimeSeconds': !exists(json, 'maxDeltaTimeSeconds') ? undefined : json['maxDeltaTimeSeconds'], - 'maxFailureWaitSeconds': !exists(json, 'maxFailureWaitSeconds') ? undefined : json['maxFailureWaitSeconds'], - 'minimumQuickLoginWaitSeconds': !exists(json, 'minimumQuickLoginWaitSeconds') ? undefined : json['minimumQuickLoginWaitSeconds'], - 'notBefore': !exists(json, 'notBefore') ? undefined : json['notBefore'], - 'oAuth2DeviceCodeLifespan': !exists(json, 'oAuth2DeviceCodeLifespan') ? undefined : json['oAuth2DeviceCodeLifespan'], - 'oAuth2DevicePollingInterval': !exists(json, 'oAuth2DevicePollingInterval') ? undefined : json['oAuth2DevicePollingInterval'], - 'oauth2DeviceCodeLifespan': !exists(json, 'oauth2DeviceCodeLifespan') ? undefined : json['oauth2DeviceCodeLifespan'], - 'oauth2DevicePollingInterval': !exists(json, 'oauth2DevicePollingInterval') ? undefined : json['oauth2DevicePollingInterval'], - 'offlineSessionIdleTimeout': !exists(json, 'offlineSessionIdleTimeout') ? undefined : json['offlineSessionIdleTimeout'], - 'offlineSessionMaxLifespan': !exists(json, 'offlineSessionMaxLifespan') ? undefined : json['offlineSessionMaxLifespan'], - 'offlineSessionMaxLifespanEnabled': !exists(json, 'offlineSessionMaxLifespanEnabled') ? undefined : json['offlineSessionMaxLifespanEnabled'], - 'otpPolicyAlgorithm': !exists(json, 'otpPolicyAlgorithm') ? undefined : json['otpPolicyAlgorithm'], - 'otpPolicyDigits': !exists(json, 'otpPolicyDigits') ? undefined : json['otpPolicyDigits'], - 'otpPolicyInitialCounter': !exists(json, 'otpPolicyInitialCounter') ? undefined : json['otpPolicyInitialCounter'], - 'otpPolicyLookAheadWindow': !exists(json, 'otpPolicyLookAheadWindow') ? undefined : json['otpPolicyLookAheadWindow'], - 'otpPolicyPeriod': !exists(json, 'otpPolicyPeriod') ? undefined : json['otpPolicyPeriod'], - 'otpPolicyType': !exists(json, 'otpPolicyType') ? undefined : json['otpPolicyType'], - 'otpSupportedApplications': !exists(json, 'otpSupportedApplications') ? undefined : json['otpSupportedApplications'], - 'passwordPolicy': !exists(json, 'passwordPolicy') ? undefined : json['passwordPolicy'], - 'permanentLockout': !exists(json, 'permanentLockout') ? undefined : json['permanentLockout'], - 'protocolMappers': !exists(json, 'protocolMappers') ? undefined : ((json['protocolMappers'] as Array).map(ProtocolMapperRepresentationFromJSON)), - 'quickLoginCheckMilliSeconds': !exists(json, 'quickLoginCheckMilliSeconds') ? undefined : json['quickLoginCheckMilliSeconds'], - 'realm': !exists(json, 'realm') ? undefined : json['realm'], - 'refreshTokenMaxReuse': !exists(json, 'refreshTokenMaxReuse') ? undefined : json['refreshTokenMaxReuse'], - 'registrationAllowed': !exists(json, 'registrationAllowed') ? undefined : json['registrationAllowed'], - 'registrationEmailAsUsername': !exists(json, 'registrationEmailAsUsername') ? undefined : json['registrationEmailAsUsername'], - 'registrationFlow': !exists(json, 'registrationFlow') ? undefined : json['registrationFlow'], - 'rememberMe': !exists(json, 'rememberMe') ? undefined : json['rememberMe'], - 'requiredActions': !exists(json, 'requiredActions') ? undefined : ((json['requiredActions'] as Array).map(RequiredActionProviderRepresentationFromJSON)), - 'resetCredentialsFlow': !exists(json, 'resetCredentialsFlow') ? undefined : json['resetCredentialsFlow'], - 'resetPasswordAllowed': !exists(json, 'resetPasswordAllowed') ? undefined : json['resetPasswordAllowed'], - 'revokeRefreshToken': !exists(json, 'revokeRefreshToken') ? undefined : json['revokeRefreshToken'], - 'roles': !exists(json, 'roles') ? undefined : RolesRepresentationFromJSON(json['roles']), - 'scopeMappings': !exists(json, 'scopeMappings') ? undefined : ((json['scopeMappings'] as Array).map(ScopeMappingRepresentationFromJSON)), - 'smtpServer': !exists(json, 'smtpServer') ? undefined : json['smtpServer'], - 'sslRequired': !exists(json, 'sslRequired') ? undefined : json['sslRequired'], - 'ssoSessionIdleTimeout': !exists(json, 'ssoSessionIdleTimeout') ? undefined : json['ssoSessionIdleTimeout'], - 'ssoSessionIdleTimeoutRememberMe': !exists(json, 'ssoSessionIdleTimeoutRememberMe') ? undefined : json['ssoSessionIdleTimeoutRememberMe'], - 'ssoSessionMaxLifespan': !exists(json, 'ssoSessionMaxLifespan') ? undefined : json['ssoSessionMaxLifespan'], - 'ssoSessionMaxLifespanRememberMe': !exists(json, 'ssoSessionMaxLifespanRememberMe') ? undefined : json['ssoSessionMaxLifespanRememberMe'], - 'supportedLocales': !exists(json, 'supportedLocales') ? undefined : json['supportedLocales'], - 'userFederationMappers': !exists(json, 'userFederationMappers') ? undefined : ((json['userFederationMappers'] as Array).map(UserFederationMapperRepresentationFromJSON)), - 'userFederationProviders': !exists(json, 'userFederationProviders') ? undefined : ((json['userFederationProviders'] as Array).map(UserFederationProviderRepresentationFromJSON)), - 'userManagedAccessAllowed': !exists(json, 'userManagedAccessAllowed') ? undefined : json['userManagedAccessAllowed'], - 'users': !exists(json, 'users') ? undefined : ((json['users'] as Array).map(UserRepresentationFromJSON)), - 'verifyEmail': !exists(json, 'verifyEmail') ? undefined : json['verifyEmail'], - 'waitIncrementSeconds': !exists(json, 'waitIncrementSeconds') ? undefined : json['waitIncrementSeconds'], - 'webAuthnPolicyAcceptableAaguids': !exists(json, 'webAuthnPolicyAcceptableAaguids') ? undefined : json['webAuthnPolicyAcceptableAaguids'], - 'webAuthnPolicyAttestationConveyancePreference': !exists(json, 'webAuthnPolicyAttestationConveyancePreference') ? undefined : json['webAuthnPolicyAttestationConveyancePreference'], - 'webAuthnPolicyAuthenticatorAttachment': !exists(json, 'webAuthnPolicyAuthenticatorAttachment') ? undefined : json['webAuthnPolicyAuthenticatorAttachment'], - 'webAuthnPolicyAvoidSameAuthenticatorRegister': !exists(json, 'webAuthnPolicyAvoidSameAuthenticatorRegister') ? undefined : json['webAuthnPolicyAvoidSameAuthenticatorRegister'], - 'webAuthnPolicyCreateTimeout': !exists(json, 'webAuthnPolicyCreateTimeout') ? undefined : json['webAuthnPolicyCreateTimeout'], - 'webAuthnPolicyPasswordlessAcceptableAaguids': !exists(json, 'webAuthnPolicyPasswordlessAcceptableAaguids') ? undefined : json['webAuthnPolicyPasswordlessAcceptableAaguids'], - 'webAuthnPolicyPasswordlessAttestationConveyancePreference': !exists(json, 'webAuthnPolicyPasswordlessAttestationConveyancePreference') ? undefined : json['webAuthnPolicyPasswordlessAttestationConveyancePreference'], - 'webAuthnPolicyPasswordlessAuthenticatorAttachment': !exists(json, 'webAuthnPolicyPasswordlessAuthenticatorAttachment') ? undefined : json['webAuthnPolicyPasswordlessAuthenticatorAttachment'], - 'webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister': !exists(json, 'webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister') ? undefined : json['webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister'], - 'webAuthnPolicyPasswordlessCreateTimeout': !exists(json, 'webAuthnPolicyPasswordlessCreateTimeout') ? undefined : json['webAuthnPolicyPasswordlessCreateTimeout'], - 'webAuthnPolicyPasswordlessRequireResidentKey': !exists(json, 'webAuthnPolicyPasswordlessRequireResidentKey') ? undefined : json['webAuthnPolicyPasswordlessRequireResidentKey'], - 'webAuthnPolicyPasswordlessRpEntityName': !exists(json, 'webAuthnPolicyPasswordlessRpEntityName') ? undefined : json['webAuthnPolicyPasswordlessRpEntityName'], - 'webAuthnPolicyPasswordlessRpId': !exists(json, 'webAuthnPolicyPasswordlessRpId') ? undefined : json['webAuthnPolicyPasswordlessRpId'], - 'webAuthnPolicyPasswordlessSignatureAlgorithms': !exists(json, 'webAuthnPolicyPasswordlessSignatureAlgorithms') ? undefined : json['webAuthnPolicyPasswordlessSignatureAlgorithms'], - 'webAuthnPolicyPasswordlessUserVerificationRequirement': !exists(json, 'webAuthnPolicyPasswordlessUserVerificationRequirement') ? undefined : json['webAuthnPolicyPasswordlessUserVerificationRequirement'], - 'webAuthnPolicyRequireResidentKey': !exists(json, 'webAuthnPolicyRequireResidentKey') ? undefined : json['webAuthnPolicyRequireResidentKey'], - 'webAuthnPolicyRpEntityName': !exists(json, 'webAuthnPolicyRpEntityName') ? undefined : json['webAuthnPolicyRpEntityName'], - 'webAuthnPolicyRpId': !exists(json, 'webAuthnPolicyRpId') ? undefined : json['webAuthnPolicyRpId'], - 'webAuthnPolicySignatureAlgorithms': !exists(json, 'webAuthnPolicySignatureAlgorithms') ? undefined : json['webAuthnPolicySignatureAlgorithms'], - 'webAuthnPolicyUserVerificationRequirement': !exists(json, 'webAuthnPolicyUserVerificationRequirement') ? undefined : json['webAuthnPolicyUserVerificationRequirement'], - }; -} - -export function RealmRepresentationToJSON(value?: RealmRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'accessCodeLifespan': value.accessCodeLifespan, - 'accessCodeLifespanLogin': value.accessCodeLifespanLogin, - 'accessCodeLifespanUserAction': value.accessCodeLifespanUserAction, - 'accessTokenLifespan': value.accessTokenLifespan, - 'accessTokenLifespanForImplicitFlow': value.accessTokenLifespanForImplicitFlow, - 'accountTheme': value.accountTheme, - 'actionTokenGeneratedByAdminLifespan': value.actionTokenGeneratedByAdminLifespan, - 'actionTokenGeneratedByUserLifespan': value.actionTokenGeneratedByUserLifespan, - 'adminEventsDetailsEnabled': value.adminEventsDetailsEnabled, - 'adminEventsEnabled': value.adminEventsEnabled, - 'adminTheme': value.adminTheme, - 'attributes': value.attributes, - 'authenticationFlows': value.authenticationFlows === undefined ? undefined : ((value.authenticationFlows as Array).map(AuthenticationFlowRepresentationToJSON)), - 'authenticatorConfig': value.authenticatorConfig === undefined ? undefined : ((value.authenticatorConfig as Array).map(AuthenticatorConfigRepresentationToJSON)), - 'browserFlow': value.browserFlow, - 'browserSecurityHeaders': value.browserSecurityHeaders, - 'bruteForceProtected': value.bruteForceProtected, - 'clientAuthenticationFlow': value.clientAuthenticationFlow, - 'clientOfflineSessionIdleTimeout': value.clientOfflineSessionIdleTimeout, - 'clientOfflineSessionMaxLifespan': value.clientOfflineSessionMaxLifespan, - 'clientPolicies': JsonNodeToJSON(value.clientPolicies), - 'clientProfiles': JsonNodeToJSON(value.clientProfiles), - 'clientScopeMappings': value.clientScopeMappings, - 'clientScopes': value.clientScopes === undefined ? undefined : ((value.clientScopes as Array).map(ClientScopeRepresentationToJSON)), - 'clientSessionIdleTimeout': value.clientSessionIdleTimeout, - 'clientSessionMaxLifespan': value.clientSessionMaxLifespan, - 'clients': value.clients === undefined ? undefined : ((value.clients as Array).map(ClientRepresentationToJSON)), - 'components': MultivaluedHashMapToJSON(value.components), - 'defaultDefaultClientScopes': value.defaultDefaultClientScopes, - 'defaultGroups': value.defaultGroups, - 'defaultLocale': value.defaultLocale, - 'defaultOptionalClientScopes': value.defaultOptionalClientScopes, - 'defaultRole': RoleRepresentationToJSON(value.defaultRole), - 'defaultSignatureAlgorithm': value.defaultSignatureAlgorithm, - 'directGrantFlow': value.directGrantFlow, - 'displayName': value.displayName, - 'displayNameHtml': value.displayNameHtml, - 'dockerAuthenticationFlow': value.dockerAuthenticationFlow, - 'duplicateEmailsAllowed': value.duplicateEmailsAllowed, - 'editUsernameAllowed': value.editUsernameAllowed, - 'emailTheme': value.emailTheme, - 'enabled': value.enabled, - 'enabledEventTypes': value.enabledEventTypes, - 'eventsEnabled': value.eventsEnabled, - 'eventsExpiration': value.eventsExpiration, - 'eventsListeners': value.eventsListeners, - 'failureFactor': value.failureFactor, - 'federatedUsers': value.federatedUsers === undefined ? undefined : ((value.federatedUsers as Array).map(UserRepresentationToJSON)), - 'groups': value.groups === undefined ? undefined : ((value.groups as Array).map(GroupRepresentationToJSON)), - 'id': value.id, - 'identityProviderMappers': value.identityProviderMappers === undefined ? undefined : ((value.identityProviderMappers as Array).map(IdentityProviderMapperRepresentationToJSON)), - 'identityProviders': value.identityProviders === undefined ? undefined : ((value.identityProviders as Array).map(IdentityProviderRepresentationToJSON)), - 'internationalizationEnabled': value.internationalizationEnabled, - 'keycloakVersion': value.keycloakVersion, - 'loginTheme': value.loginTheme, - 'loginWithEmailAllowed': value.loginWithEmailAllowed, - 'maxDeltaTimeSeconds': value.maxDeltaTimeSeconds, - 'maxFailureWaitSeconds': value.maxFailureWaitSeconds, - 'minimumQuickLoginWaitSeconds': value.minimumQuickLoginWaitSeconds, - 'notBefore': value.notBefore, - 'oAuth2DeviceCodeLifespan': value.oAuth2DeviceCodeLifespan, - 'oAuth2DevicePollingInterval': value.oAuth2DevicePollingInterval, - 'oauth2DeviceCodeLifespan': value.oauth2DeviceCodeLifespan, - 'oauth2DevicePollingInterval': value.oauth2DevicePollingInterval, - 'offlineSessionIdleTimeout': value.offlineSessionIdleTimeout, - 'offlineSessionMaxLifespan': value.offlineSessionMaxLifespan, - 'offlineSessionMaxLifespanEnabled': value.offlineSessionMaxLifespanEnabled, - 'otpPolicyAlgorithm': value.otpPolicyAlgorithm, - 'otpPolicyDigits': value.otpPolicyDigits, - 'otpPolicyInitialCounter': value.otpPolicyInitialCounter, - 'otpPolicyLookAheadWindow': value.otpPolicyLookAheadWindow, - 'otpPolicyPeriod': value.otpPolicyPeriod, - 'otpPolicyType': value.otpPolicyType, - 'otpSupportedApplications': value.otpSupportedApplications, - 'passwordPolicy': value.passwordPolicy, - 'permanentLockout': value.permanentLockout, - 'protocolMappers': value.protocolMappers === undefined ? undefined : ((value.protocolMappers as Array).map(ProtocolMapperRepresentationToJSON)), - 'quickLoginCheckMilliSeconds': value.quickLoginCheckMilliSeconds, - 'realm': value.realm, - 'refreshTokenMaxReuse': value.refreshTokenMaxReuse, - 'registrationAllowed': value.registrationAllowed, - 'registrationEmailAsUsername': value.registrationEmailAsUsername, - 'registrationFlow': value.registrationFlow, - 'rememberMe': value.rememberMe, - 'requiredActions': value.requiredActions === undefined ? undefined : ((value.requiredActions as Array).map(RequiredActionProviderRepresentationToJSON)), - 'resetCredentialsFlow': value.resetCredentialsFlow, - 'resetPasswordAllowed': value.resetPasswordAllowed, - 'revokeRefreshToken': value.revokeRefreshToken, - 'roles': RolesRepresentationToJSON(value.roles), - 'scopeMappings': value.scopeMappings === undefined ? undefined : ((value.scopeMappings as Array).map(ScopeMappingRepresentationToJSON)), - 'smtpServer': value.smtpServer, - 'sslRequired': value.sslRequired, - 'ssoSessionIdleTimeout': value.ssoSessionIdleTimeout, - 'ssoSessionIdleTimeoutRememberMe': value.ssoSessionIdleTimeoutRememberMe, - 'ssoSessionMaxLifespan': value.ssoSessionMaxLifespan, - 'ssoSessionMaxLifespanRememberMe': value.ssoSessionMaxLifespanRememberMe, - 'supportedLocales': value.supportedLocales, - 'userFederationMappers': value.userFederationMappers === undefined ? undefined : ((value.userFederationMappers as Array).map(UserFederationMapperRepresentationToJSON)), - 'userFederationProviders': value.userFederationProviders === undefined ? undefined : ((value.userFederationProviders as Array).map(UserFederationProviderRepresentationToJSON)), - 'userManagedAccessAllowed': value.userManagedAccessAllowed, - 'users': value.users === undefined ? undefined : ((value.users as Array).map(UserRepresentationToJSON)), - 'verifyEmail': value.verifyEmail, - 'waitIncrementSeconds': value.waitIncrementSeconds, - 'webAuthnPolicyAcceptableAaguids': value.webAuthnPolicyAcceptableAaguids, - 'webAuthnPolicyAttestationConveyancePreference': value.webAuthnPolicyAttestationConveyancePreference, - 'webAuthnPolicyAuthenticatorAttachment': value.webAuthnPolicyAuthenticatorAttachment, - 'webAuthnPolicyAvoidSameAuthenticatorRegister': value.webAuthnPolicyAvoidSameAuthenticatorRegister, - 'webAuthnPolicyCreateTimeout': value.webAuthnPolicyCreateTimeout, - 'webAuthnPolicyPasswordlessAcceptableAaguids': value.webAuthnPolicyPasswordlessAcceptableAaguids, - 'webAuthnPolicyPasswordlessAttestationConveyancePreference': value.webAuthnPolicyPasswordlessAttestationConveyancePreference, - 'webAuthnPolicyPasswordlessAuthenticatorAttachment': value.webAuthnPolicyPasswordlessAuthenticatorAttachment, - 'webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister': value.webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister, - 'webAuthnPolicyPasswordlessCreateTimeout': value.webAuthnPolicyPasswordlessCreateTimeout, - 'webAuthnPolicyPasswordlessRequireResidentKey': value.webAuthnPolicyPasswordlessRequireResidentKey, - 'webAuthnPolicyPasswordlessRpEntityName': value.webAuthnPolicyPasswordlessRpEntityName, - 'webAuthnPolicyPasswordlessRpId': value.webAuthnPolicyPasswordlessRpId, - 'webAuthnPolicyPasswordlessSignatureAlgorithms': value.webAuthnPolicyPasswordlessSignatureAlgorithms, - 'webAuthnPolicyPasswordlessUserVerificationRequirement': value.webAuthnPolicyPasswordlessUserVerificationRequirement, - 'webAuthnPolicyRequireResidentKey': value.webAuthnPolicyRequireResidentKey, - 'webAuthnPolicyRpEntityName': value.webAuthnPolicyRpEntityName, - 'webAuthnPolicyRpId': value.webAuthnPolicyRpId, - 'webAuthnPolicySignatureAlgorithms': value.webAuthnPolicySignatureAlgorithms, - 'webAuthnPolicyUserVerificationRequirement': value.webAuthnPolicyUserVerificationRequirement, - }; -} - - diff --git a/backend/keycloak/kc-client/models/RequiredActionProviderRepresentation.ts b/backend/keycloak/kc-client/models/RequiredActionProviderRepresentation.ts deleted file mode 100644 index b87affb..0000000 --- a/backend/keycloak/kc-client/models/RequiredActionProviderRepresentation.ts +++ /dev/null @@ -1,105 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface RequiredActionProviderRepresentation - */ -export interface RequiredActionProviderRepresentation { - /** - * - * @type {string} - * @memberof RequiredActionProviderRepresentation - */ - alias?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof RequiredActionProviderRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {boolean} - * @memberof RequiredActionProviderRepresentation - */ - defaultAction?: boolean; - /** - * - * @type {boolean} - * @memberof RequiredActionProviderRepresentation - */ - enabled?: boolean; - /** - * - * @type {string} - * @memberof RequiredActionProviderRepresentation - */ - name?: string; - /** - * - * @type {number} - * @memberof RequiredActionProviderRepresentation - */ - priority?: number; - /** - * - * @type {string} - * @memberof RequiredActionProviderRepresentation - */ - providerId?: string; -} - -export function RequiredActionProviderRepresentationFromJSON(json: any): RequiredActionProviderRepresentation { - return RequiredActionProviderRepresentationFromJSONTyped(json, false); -} - -export function RequiredActionProviderRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RequiredActionProviderRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'alias': !exists(json, 'alias') ? undefined : json['alias'], - 'config': !exists(json, 'config') ? undefined : json['config'], - 'defaultAction': !exists(json, 'defaultAction') ? undefined : json['defaultAction'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'priority': !exists(json, 'priority') ? undefined : json['priority'], - 'providerId': !exists(json, 'providerId') ? undefined : json['providerId'], - }; -} - -export function RequiredActionProviderRepresentationToJSON(value?: RequiredActionProviderRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'alias': value.alias, - 'config': value.config, - 'defaultAction': value.defaultAction, - 'enabled': value.enabled, - 'name': value.name, - 'priority': value.priority, - 'providerId': value.providerId, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ResourceRepresentation.ts b/backend/keycloak/kc-client/models/ResourceRepresentation.ts deleted file mode 100644 index 8123501..0000000 --- a/backend/keycloak/kc-client/models/ResourceRepresentation.ts +++ /dev/null @@ -1,128 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - ScopeRepresentation, - ScopeRepresentationFromJSON, - ScopeRepresentationFromJSONTyped, - ScopeRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ResourceRepresentation - */ -export interface ResourceRepresentation { - /** - * - * @type {string} - * @memberof ResourceRepresentation - */ - id?: string; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ResourceRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof ResourceRepresentation - */ - displayName?: string; - /** - * - * @type {string} - * @memberof ResourceRepresentation - */ - iconUri?: string; - /** - * - * @type {string} - * @memberof ResourceRepresentation - */ - name?: string; - /** - * - * @type {boolean} - * @memberof ResourceRepresentation - */ - ownerManagedAccess?: boolean; - /** - * - * @type {Array} - * @memberof ResourceRepresentation - */ - scopes?: Array; - /** - * - * @type {string} - * @memberof ResourceRepresentation - */ - type?: string; - /** - * - * @type {Array} - * @memberof ResourceRepresentation - */ - uris?: Array; -} - -export function ResourceRepresentationFromJSON(json: any): ResourceRepresentation { - return ResourceRepresentationFromJSONTyped(json, false); -} - -export function ResourceRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ResourceRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'id': !exists(json, 'id') ? undefined : json['id'], - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'iconUri': !exists(json, 'icon_uri') ? undefined : json['icon_uri'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'ownerManagedAccess': !exists(json, 'ownerManagedAccess') ? undefined : json['ownerManagedAccess'], - 'scopes': !exists(json, 'scopes') ? undefined : ((json['scopes'] as Array).map(ScopeRepresentationFromJSON)), - 'type': !exists(json, 'type') ? undefined : json['type'], - 'uris': !exists(json, 'uris') ? undefined : json['uris'], - }; -} - -export function ResourceRepresentationToJSON(value?: ResourceRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'id': value.id, - 'attributes': value.attributes, - 'displayName': value.displayName, - 'icon_uri': value.iconUri, - 'name': value.name, - 'ownerManagedAccess': value.ownerManagedAccess, - 'scopes': value.scopes === undefined ? undefined : ((value.scopes as Array).map(ScopeRepresentationToJSON)), - 'type': value.type, - 'uris': value.uris, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ResourceServerRepresentation.ts b/backend/keycloak/kc-client/models/ResourceServerRepresentation.ts deleted file mode 100644 index 71b5ff7..0000000 --- a/backend/keycloak/kc-client/models/ResourceServerRepresentation.ts +++ /dev/null @@ -1,155 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - PolicyRepresentation, - PolicyRepresentationFromJSON, - PolicyRepresentationFromJSONTyped, - PolicyRepresentationToJSON, - ResourceRepresentation, - ResourceRepresentationFromJSON, - ResourceRepresentationFromJSONTyped, - ResourceRepresentationToJSON, - ScopeRepresentation, - ScopeRepresentationFromJSON, - ScopeRepresentationFromJSONTyped, - ScopeRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ResourceServerRepresentation - */ -export interface ResourceServerRepresentation { - /** - * - * @type {boolean} - * @memberof ResourceServerRepresentation - */ - allowRemoteResourceManagement?: boolean; - /** - * - * @type {string} - * @memberof ResourceServerRepresentation - */ - clientId?: string; - /** - * - * @type {string} - * @memberof ResourceServerRepresentation - */ - decisionStrategy?: ResourceServerRepresentationDecisionStrategyEnum; - /** - * - * @type {string} - * @memberof ResourceServerRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ResourceServerRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof ResourceServerRepresentation - */ - policies?: Array; - /** - * - * @type {string} - * @memberof ResourceServerRepresentation - */ - policyEnforcementMode?: ResourceServerRepresentationPolicyEnforcementModeEnum; - /** - * - * @type {Array} - * @memberof ResourceServerRepresentation - */ - resources?: Array; - /** - * - * @type {Array} - * @memberof ResourceServerRepresentation - */ - scopes?: Array; -} - -export function ResourceServerRepresentationFromJSON(json: any): ResourceServerRepresentation { - return ResourceServerRepresentationFromJSONTyped(json, false); -} - -export function ResourceServerRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ResourceServerRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'allowRemoteResourceManagement': !exists(json, 'allowRemoteResourceManagement') ? undefined : json['allowRemoteResourceManagement'], - 'clientId': !exists(json, 'clientId') ? undefined : json['clientId'], - 'decisionStrategy': !exists(json, 'decisionStrategy') ? undefined : json['decisionStrategy'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'policies': !exists(json, 'policies') ? undefined : ((json['policies'] as Array).map(PolicyRepresentationFromJSON)), - 'policyEnforcementMode': !exists(json, 'policyEnforcementMode') ? undefined : json['policyEnforcementMode'], - 'resources': !exists(json, 'resources') ? undefined : ((json['resources'] as Array).map(ResourceRepresentationFromJSON)), - 'scopes': !exists(json, 'scopes') ? undefined : ((json['scopes'] as Array).map(ScopeRepresentationFromJSON)), - }; -} - -export function ResourceServerRepresentationToJSON(value?: ResourceServerRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'allowRemoteResourceManagement': value.allowRemoteResourceManagement, - 'clientId': value.clientId, - 'decisionStrategy': value.decisionStrategy, - 'id': value.id, - 'name': value.name, - 'policies': value.policies === undefined ? undefined : ((value.policies as Array).map(PolicyRepresentationToJSON)), - 'policyEnforcementMode': value.policyEnforcementMode, - 'resources': value.resources === undefined ? undefined : ((value.resources as Array).map(ResourceRepresentationToJSON)), - 'scopes': value.scopes === undefined ? undefined : ((value.scopes as Array).map(ScopeRepresentationToJSON)), - }; -} - -/** -* @export -* @enum {string} -*/ -export enum ResourceServerRepresentationDecisionStrategyEnum { - AFFIRMATIVE = 'AFFIRMATIVE', - UNANIMOUS = 'UNANIMOUS', - CONSENSUS = 'CONSENSUS' -} -/** -* @export -* @enum {string} -*/ -export enum ResourceServerRepresentationPolicyEnforcementModeEnum { - ENFORCING = 'ENFORCING', - PERMISSIVE = 'PERMISSIVE', - DISABLED = 'DISABLED' -} - - diff --git a/backend/keycloak/kc-client/models/RoleRepresentation.ts b/backend/keycloak/kc-client/models/RoleRepresentation.ts deleted file mode 100644 index 167cd18..0000000 --- a/backend/keycloak/kc-client/models/RoleRepresentation.ts +++ /dev/null @@ -1,120 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - RoleRepresentationComposites, - RoleRepresentationCompositesFromJSON, - RoleRepresentationCompositesFromJSONTyped, - RoleRepresentationCompositesToJSON, -} from './'; - -/** - * - * @export - * @interface RoleRepresentation - */ -export interface RoleRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof RoleRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {boolean} - * @memberof RoleRepresentation - */ - clientRole?: boolean; - /** - * - * @type {boolean} - * @memberof RoleRepresentation - */ - composite?: boolean; - /** - * - * @type {RoleRepresentationComposites} - * @memberof RoleRepresentation - */ - composites?: RoleRepresentationComposites; - /** - * - * @type {string} - * @memberof RoleRepresentation - */ - containerId?: string; - /** - * - * @type {string} - * @memberof RoleRepresentation - */ - description?: string; - /** - * - * @type {string} - * @memberof RoleRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof RoleRepresentation - */ - name?: string; -} - -export function RoleRepresentationFromJSON(json: any): RoleRepresentation { - return RoleRepresentationFromJSONTyped(json, false); -} - -export function RoleRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RoleRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'clientRole': !exists(json, 'clientRole') ? undefined : json['clientRole'], - 'composite': !exists(json, 'composite') ? undefined : json['composite'], - 'composites': !exists(json, 'composites') ? undefined : RoleRepresentationCompositesFromJSON(json['composites']), - 'containerId': !exists(json, 'containerId') ? undefined : json['containerId'], - 'description': !exists(json, 'description') ? undefined : json['description'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - }; -} - -export function RoleRepresentationToJSON(value?: RoleRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'attributes': value.attributes, - 'clientRole': value.clientRole, - 'composite': value.composite, - 'composites': RoleRepresentationCompositesToJSON(value.composites), - 'containerId': value.containerId, - 'description': value.description, - 'id': value.id, - 'name': value.name, - }; -} - - diff --git a/backend/keycloak/kc-client/models/RoleRepresentationComposites.ts b/backend/keycloak/kc-client/models/RoleRepresentationComposites.ts deleted file mode 100644 index 93b025f..0000000 --- a/backend/keycloak/kc-client/models/RoleRepresentationComposites.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface RoleRepresentationComposites - */ -export interface RoleRepresentationComposites { - /** - * - * @type {{ [key: string]: object; }} - * @memberof RoleRepresentationComposites - */ - client?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof RoleRepresentationComposites - */ - realm?: Array; -} - -export function RoleRepresentationCompositesFromJSON(json: any): RoleRepresentationComposites { - return RoleRepresentationCompositesFromJSONTyped(json, false); -} - -export function RoleRepresentationCompositesFromJSONTyped(json: any, ignoreDiscriminator: boolean): RoleRepresentationComposites { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'client': !exists(json, 'client') ? undefined : json['client'], - 'realm': !exists(json, 'realm') ? undefined : json['realm'], - }; -} - -export function RoleRepresentationCompositesToJSON(value?: RoleRepresentationComposites | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'client': value.client, - 'realm': value.realm, - }; -} - - diff --git a/backend/keycloak/kc-client/models/RolesRepresentation.ts b/backend/keycloak/kc-client/models/RolesRepresentation.ts deleted file mode 100644 index 27a8b3c..0000000 --- a/backend/keycloak/kc-client/models/RolesRepresentation.ts +++ /dev/null @@ -1,72 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - RoleRepresentation, - RoleRepresentationFromJSON, - RoleRepresentationFromJSONTyped, - RoleRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface RolesRepresentation - */ -export interface RolesRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof RolesRepresentation - */ - client?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof RolesRepresentation - */ - realm?: Array; -} - -export function RolesRepresentationFromJSON(json: any): RolesRepresentation { - return RolesRepresentationFromJSONTyped(json, false); -} - -export function RolesRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): RolesRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'client': !exists(json, 'client') ? undefined : json['client'], - 'realm': !exists(json, 'realm') ? undefined : ((json['realm'] as Array).map(RoleRepresentationFromJSON)), - }; -} - -export function RolesRepresentationToJSON(value?: RolesRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'client': value.client, - 'realm': value.realm === undefined ? undefined : ((value.realm as Array).map(RoleRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ScopeMappingRepresentation.ts b/backend/keycloak/kc-client/models/ScopeMappingRepresentation.ts deleted file mode 100644 index c5ad459..0000000 --- a/backend/keycloak/kc-client/models/ScopeMappingRepresentation.ts +++ /dev/null @@ -1,81 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface ScopeMappingRepresentation - */ -export interface ScopeMappingRepresentation { - /** - * - * @type {string} - * @memberof ScopeMappingRepresentation - */ - client?: string; - /** - * - * @type {string} - * @memberof ScopeMappingRepresentation - */ - clientScope?: string; - /** - * - * @type {Array} - * @memberof ScopeMappingRepresentation - */ - roles?: Array; - /** - * - * @type {string} - * @memberof ScopeMappingRepresentation - */ - self?: string; -} - -export function ScopeMappingRepresentationFromJSON(json: any): ScopeMappingRepresentation { - return ScopeMappingRepresentationFromJSONTyped(json, false); -} - -export function ScopeMappingRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScopeMappingRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'client': !exists(json, 'client') ? undefined : json['client'], - 'clientScope': !exists(json, 'clientScope') ? undefined : json['clientScope'], - 'roles': !exists(json, 'roles') ? undefined : json['roles'], - 'self': !exists(json, 'self') ? undefined : json['self'], - }; -} - -export function ScopeMappingRepresentationToJSON(value?: ScopeMappingRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'client': value.client, - 'clientScope': value.clientScope, - 'roles': value.roles, - 'self': value.self, - }; -} - - diff --git a/backend/keycloak/kc-client/models/ScopeRepresentation.ts b/backend/keycloak/kc-client/models/ScopeRepresentation.ts deleted file mode 100644 index 79b2a88..0000000 --- a/backend/keycloak/kc-client/models/ScopeRepresentation.ts +++ /dev/null @@ -1,108 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - PolicyRepresentation, - PolicyRepresentationFromJSON, - PolicyRepresentationFromJSONTyped, - PolicyRepresentationToJSON, - ResourceRepresentation, - ResourceRepresentationFromJSON, - ResourceRepresentationFromJSONTyped, - ResourceRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ScopeRepresentation - */ -export interface ScopeRepresentation { - /** - * - * @type {string} - * @memberof ScopeRepresentation - */ - displayName?: string; - /** - * - * @type {string} - * @memberof ScopeRepresentation - */ - iconUri?: string; - /** - * - * @type {string} - * @memberof ScopeRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof ScopeRepresentation - */ - name?: string; - /** - * - * @type {Array} - * @memberof ScopeRepresentation - */ - policies?: Array; - /** - * - * @type {Array} - * @memberof ScopeRepresentation - */ - resources?: Array; -} - -export function ScopeRepresentationFromJSON(json: any): ScopeRepresentation { - return ScopeRepresentationFromJSONTyped(json, false); -} - -export function ScopeRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ScopeRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'iconUri': !exists(json, 'iconUri') ? undefined : json['iconUri'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - 'policies': !exists(json, 'policies') ? undefined : ((json['policies'] as Array).map(PolicyRepresentationFromJSON)), - 'resources': !exists(json, 'resources') ? undefined : ((json['resources'] as Array).map(ResourceRepresentationFromJSON)), - }; -} - -export function ScopeRepresentationToJSON(value?: ScopeRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'displayName': value.displayName, - 'iconUri': value.iconUri, - 'id': value.id, - 'name': value.name, - 'policies': value.policies === undefined ? undefined : ((value.policies as Array).map(PolicyRepresentationToJSON)), - 'resources': value.resources === undefined ? undefined : ((value.resources as Array).map(ResourceRepresentationToJSON)), - }; -} - - diff --git a/backend/keycloak/kc-client/models/ServerInfoRepresentation.ts b/backend/keycloak/kc-client/models/ServerInfoRepresentation.ts deleted file mode 100644 index 65ef56c..0000000 --- a/backend/keycloak/kc-client/models/ServerInfoRepresentation.ts +++ /dev/null @@ -1,180 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - MemoryInfoRepresentation, - MemoryInfoRepresentationFromJSON, - MemoryInfoRepresentationFromJSONTyped, - MemoryInfoRepresentationToJSON, - PasswordPolicyTypeRepresentation, - PasswordPolicyTypeRepresentationFromJSON, - PasswordPolicyTypeRepresentationFromJSONTyped, - PasswordPolicyTypeRepresentationToJSON, - ProfileInfoRepresentation, - ProfileInfoRepresentationFromJSON, - ProfileInfoRepresentationFromJSONTyped, - ProfileInfoRepresentationToJSON, - SystemInfoRepresentation, - SystemInfoRepresentationFromJSON, - SystemInfoRepresentationFromJSONTyped, - SystemInfoRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface ServerInfoRepresentation - */ -export interface ServerInfoRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - builtinProtocolMappers?: { [key: string]: object; }; - /** - * - * @type {Array<{ [key: string]: object; }>} - * @memberof ServerInfoRepresentation - */ - clientImporters?: Array<{ [key: string]: object; }>; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - clientInstallations?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - componentTypes?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - enums?: { [key: string]: object; }; - /** - * - * @type {Array<{ [key: string]: object; }>} - * @memberof ServerInfoRepresentation - */ - identityProviders?: Array<{ [key: string]: object; }>; - /** - * - * @type {MemoryInfoRepresentation} - * @memberof ServerInfoRepresentation - */ - memoryInfo?: MemoryInfoRepresentation; - /** - * - * @type {Array} - * @memberof ServerInfoRepresentation - */ - passwordPolicies?: Array; - /** - * - * @type {ProfileInfoRepresentation} - * @memberof ServerInfoRepresentation - */ - profileInfo?: ProfileInfoRepresentation; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - protocolMapperTypes?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - providers?: { [key: string]: object; }; - /** - * - * @type {Array<{ [key: string]: object; }>} - * @memberof ServerInfoRepresentation - */ - socialProviders?: Array<{ [key: string]: object; }>; - /** - * - * @type {SystemInfoRepresentation} - * @memberof ServerInfoRepresentation - */ - systemInfo?: SystemInfoRepresentation; - /** - * - * @type {{ [key: string]: object; }} - * @memberof ServerInfoRepresentation - */ - themes?: { [key: string]: object; }; -} - -export function ServerInfoRepresentationFromJSON(json: any): ServerInfoRepresentation { - return ServerInfoRepresentationFromJSONTyped(json, false); -} - -export function ServerInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): ServerInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'builtinProtocolMappers': !exists(json, 'builtinProtocolMappers') ? undefined : json['builtinProtocolMappers'], - 'clientImporters': !exists(json, 'clientImporters') ? undefined : json['clientImporters'], - 'clientInstallations': !exists(json, 'clientInstallations') ? undefined : json['clientInstallations'], - 'componentTypes': !exists(json, 'componentTypes') ? undefined : json['componentTypes'], - 'enums': !exists(json, 'enums') ? undefined : json['enums'], - 'identityProviders': !exists(json, 'identityProviders') ? undefined : json['identityProviders'], - 'memoryInfo': !exists(json, 'memoryInfo') ? undefined : MemoryInfoRepresentationFromJSON(json['memoryInfo']), - 'passwordPolicies': !exists(json, 'passwordPolicies') ? undefined : ((json['passwordPolicies'] as Array).map(PasswordPolicyTypeRepresentationFromJSON)), - 'profileInfo': !exists(json, 'profileInfo') ? undefined : ProfileInfoRepresentationFromJSON(json['profileInfo']), - 'protocolMapperTypes': !exists(json, 'protocolMapperTypes') ? undefined : json['protocolMapperTypes'], - 'providers': !exists(json, 'providers') ? undefined : json['providers'], - 'socialProviders': !exists(json, 'socialProviders') ? undefined : json['socialProviders'], - 'systemInfo': !exists(json, 'systemInfo') ? undefined : SystemInfoRepresentationFromJSON(json['systemInfo']), - 'themes': !exists(json, 'themes') ? undefined : json['themes'], - }; -} - -export function ServerInfoRepresentationToJSON(value?: ServerInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'builtinProtocolMappers': value.builtinProtocolMappers, - 'clientImporters': value.clientImporters, - 'clientInstallations': value.clientInstallations, - 'componentTypes': value.componentTypes, - 'enums': value.enums, - 'identityProviders': value.identityProviders, - 'memoryInfo': MemoryInfoRepresentationToJSON(value.memoryInfo), - 'passwordPolicies': value.passwordPolicies === undefined ? undefined : ((value.passwordPolicies as Array).map(PasswordPolicyTypeRepresentationToJSON)), - 'profileInfo': ProfileInfoRepresentationToJSON(value.profileInfo), - 'protocolMapperTypes': value.protocolMapperTypes, - 'providers': value.providers, - 'socialProviders': value.socialProviders, - 'systemInfo': SystemInfoRepresentationToJSON(value.systemInfo), - 'themes': value.themes, - }; -} - - diff --git a/backend/keycloak/kc-client/models/SpiInfoRepresentation.ts b/backend/keycloak/kc-client/models/SpiInfoRepresentation.ts deleted file mode 100644 index e3004a3..0000000 --- a/backend/keycloak/kc-client/models/SpiInfoRepresentation.ts +++ /dev/null @@ -1,65 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface SpiInfoRepresentation - */ -export interface SpiInfoRepresentation { - /** - * - * @type {boolean} - * @memberof SpiInfoRepresentation - */ - internal?: boolean; - /** - * - * @type {{ [key: string]: object; }} - * @memberof SpiInfoRepresentation - */ - providers?: { [key: string]: object; }; -} - -export function SpiInfoRepresentationFromJSON(json: any): SpiInfoRepresentation { - return SpiInfoRepresentationFromJSONTyped(json, false); -} - -export function SpiInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): SpiInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'internal': !exists(json, 'internal') ? undefined : json['internal'], - 'providers': !exists(json, 'providers') ? undefined : json['providers'], - }; -} - -export function SpiInfoRepresentationToJSON(value?: SpiInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'internal': value.internal, - 'providers': value.providers, - }; -} - - diff --git a/backend/keycloak/kc-client/models/SynchronizationResult.ts b/backend/keycloak/kc-client/models/SynchronizationResult.ts deleted file mode 100644 index f8dd61f..0000000 --- a/backend/keycloak/kc-client/models/SynchronizationResult.ts +++ /dev/null @@ -1,97 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface SynchronizationResult - */ -export interface SynchronizationResult { - /** - * - * @type {number} - * @memberof SynchronizationResult - */ - added?: number; - /** - * - * @type {number} - * @memberof SynchronizationResult - */ - failed?: number; - /** - * - * @type {boolean} - * @memberof SynchronizationResult - */ - ignored?: boolean; - /** - * - * @type {number} - * @memberof SynchronizationResult - */ - removed?: number; - /** - * - * @type {string} - * @memberof SynchronizationResult - */ - status?: string; - /** - * - * @type {number} - * @memberof SynchronizationResult - */ - updated?: number; -} - -export function SynchronizationResultFromJSON(json: any): SynchronizationResult { - return SynchronizationResultFromJSONTyped(json, false); -} - -export function SynchronizationResultFromJSONTyped(json: any, ignoreDiscriminator: boolean): SynchronizationResult { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'added': !exists(json, 'added') ? undefined : json['added'], - 'failed': !exists(json, 'failed') ? undefined : json['failed'], - 'ignored': !exists(json, 'ignored') ? undefined : json['ignored'], - 'removed': !exists(json, 'removed') ? undefined : json['removed'], - 'status': !exists(json, 'status') ? undefined : json['status'], - 'updated': !exists(json, 'updated') ? undefined : json['updated'], - }; -} - -export function SynchronizationResultToJSON(value?: SynchronizationResult | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'added': value.added, - 'failed': value.failed, - 'ignored': value.ignored, - 'removed': value.removed, - 'status': value.status, - 'updated': value.updated, - }; -} - - diff --git a/backend/keycloak/kc-client/models/SystemInfoRepresentation.ts b/backend/keycloak/kc-client/models/SystemInfoRepresentation.ts deleted file mode 100644 index fef9124..0000000 --- a/backend/keycloak/kc-client/models/SystemInfoRepresentation.ts +++ /dev/null @@ -1,193 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface SystemInfoRepresentation - */ -export interface SystemInfoRepresentation { - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - fileEncoding?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaHome?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaRuntime?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaVendor?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaVersion?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaVm?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - javaVmVersion?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - osArchitecture?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - osName?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - osVersion?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - serverTime?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - uptime?: string; - /** - * - * @type {number} - * @memberof SystemInfoRepresentation - */ - uptimeMillis?: number; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - userDir?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - userLocale?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - userName?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - userTimezone?: string; - /** - * - * @type {string} - * @memberof SystemInfoRepresentation - */ - version?: string; -} - -export function SystemInfoRepresentationFromJSON(json: any): SystemInfoRepresentation { - return SystemInfoRepresentationFromJSONTyped(json, false); -} - -export function SystemInfoRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): SystemInfoRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'fileEncoding': !exists(json, 'fileEncoding') ? undefined : json['fileEncoding'], - 'javaHome': !exists(json, 'javaHome') ? undefined : json['javaHome'], - 'javaRuntime': !exists(json, 'javaRuntime') ? undefined : json['javaRuntime'], - 'javaVendor': !exists(json, 'javaVendor') ? undefined : json['javaVendor'], - 'javaVersion': !exists(json, 'javaVersion') ? undefined : json['javaVersion'], - 'javaVm': !exists(json, 'javaVm') ? undefined : json['javaVm'], - 'javaVmVersion': !exists(json, 'javaVmVersion') ? undefined : json['javaVmVersion'], - 'osArchitecture': !exists(json, 'osArchitecture') ? undefined : json['osArchitecture'], - 'osName': !exists(json, 'osName') ? undefined : json['osName'], - 'osVersion': !exists(json, 'osVersion') ? undefined : json['osVersion'], - 'serverTime': !exists(json, 'serverTime') ? undefined : json['serverTime'], - 'uptime': !exists(json, 'uptime') ? undefined : json['uptime'], - 'uptimeMillis': !exists(json, 'uptimeMillis') ? undefined : json['uptimeMillis'], - 'userDir': !exists(json, 'userDir') ? undefined : json['userDir'], - 'userLocale': !exists(json, 'userLocale') ? undefined : json['userLocale'], - 'userName': !exists(json, 'userName') ? undefined : json['userName'], - 'userTimezone': !exists(json, 'userTimezone') ? undefined : json['userTimezone'], - 'version': !exists(json, 'version') ? undefined : json['version'], - }; -} - -export function SystemInfoRepresentationToJSON(value?: SystemInfoRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'fileEncoding': value.fileEncoding, - 'javaHome': value.javaHome, - 'javaRuntime': value.javaRuntime, - 'javaVendor': value.javaVendor, - 'javaVersion': value.javaVersion, - 'javaVm': value.javaVm, - 'javaVmVersion': value.javaVmVersion, - 'osArchitecture': value.osArchitecture, - 'osName': value.osName, - 'osVersion': value.osVersion, - 'serverTime': value.serverTime, - 'uptime': value.uptime, - 'uptimeMillis': value.uptimeMillis, - 'userDir': value.userDir, - 'userLocale': value.userLocale, - 'userName': value.userName, - 'userTimezone': value.userTimezone, - 'version': value.version, - }; -} - - diff --git a/backend/keycloak/kc-client/models/TestLdapConnectionRepresentation.ts b/backend/keycloak/kc-client/models/TestLdapConnectionRepresentation.ts deleted file mode 100644 index 7b3bf81..0000000 --- a/backend/keycloak/kc-client/models/TestLdapConnectionRepresentation.ts +++ /dev/null @@ -1,121 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface TestLdapConnectionRepresentation - */ -export interface TestLdapConnectionRepresentation { - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - action?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - authType?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - bindCredential?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - bindDn?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - componentId?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - connectionTimeout?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - connectionUrl?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - startTls?: string; - /** - * - * @type {string} - * @memberof TestLdapConnectionRepresentation - */ - useTruststoreSpi?: string; -} - -export function TestLdapConnectionRepresentationFromJSON(json: any): TestLdapConnectionRepresentation { - return TestLdapConnectionRepresentationFromJSONTyped(json, false); -} - -export function TestLdapConnectionRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): TestLdapConnectionRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'action': !exists(json, 'action') ? undefined : json['action'], - 'authType': !exists(json, 'authType') ? undefined : json['authType'], - 'bindCredential': !exists(json, 'bindCredential') ? undefined : json['bindCredential'], - 'bindDn': !exists(json, 'bindDn') ? undefined : json['bindDn'], - 'componentId': !exists(json, 'componentId') ? undefined : json['componentId'], - 'connectionTimeout': !exists(json, 'connectionTimeout') ? undefined : json['connectionTimeout'], - 'connectionUrl': !exists(json, 'connectionUrl') ? undefined : json['connectionUrl'], - 'startTls': !exists(json, 'startTls') ? undefined : json['startTls'], - 'useTruststoreSpi': !exists(json, 'useTruststoreSpi') ? undefined : json['useTruststoreSpi'], - }; -} - -export function TestLdapConnectionRepresentationToJSON(value?: TestLdapConnectionRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'action': value.action, - 'authType': value.authType, - 'bindCredential': value.bindCredential, - 'bindDn': value.bindDn, - 'componentId': value.componentId, - 'connectionTimeout': value.connectionTimeout, - 'connectionUrl': value.connectionUrl, - 'startTls': value.startTls, - 'useTruststoreSpi': value.useTruststoreSpi, - }; -} - - diff --git a/backend/keycloak/kc-client/models/UserConsentRepresentation.ts b/backend/keycloak/kc-client/models/UserConsentRepresentation.ts deleted file mode 100644 index 62bd661..0000000 --- a/backend/keycloak/kc-client/models/UserConsentRepresentation.ts +++ /dev/null @@ -1,81 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface UserConsentRepresentation - */ -export interface UserConsentRepresentation { - /** - * - * @type {string} - * @memberof UserConsentRepresentation - */ - clientId?: string; - /** - * - * @type {number} - * @memberof UserConsentRepresentation - */ - createdDate?: number; - /** - * - * @type {Array} - * @memberof UserConsentRepresentation - */ - grantedClientScopes?: Array; - /** - * - * @type {number} - * @memberof UserConsentRepresentation - */ - lastUpdatedDate?: number; -} - -export function UserConsentRepresentationFromJSON(json: any): UserConsentRepresentation { - return UserConsentRepresentationFromJSONTyped(json, false); -} - -export function UserConsentRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserConsentRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'clientId': !exists(json, 'clientId') ? undefined : json['clientId'], - 'createdDate': !exists(json, 'createdDate') ? undefined : json['createdDate'], - 'grantedClientScopes': !exists(json, 'grantedClientScopes') ? undefined : json['grantedClientScopes'], - 'lastUpdatedDate': !exists(json, 'lastUpdatedDate') ? undefined : json['lastUpdatedDate'], - }; -} - -export function UserConsentRepresentationToJSON(value?: UserConsentRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'clientId': value.clientId, - 'createdDate': value.createdDate, - 'grantedClientScopes': value.grantedClientScopes, - 'lastUpdatedDate': value.lastUpdatedDate, - }; -} - - diff --git a/backend/keycloak/kc-client/models/UserFederationMapperRepresentation.ts b/backend/keycloak/kc-client/models/UserFederationMapperRepresentation.ts deleted file mode 100644 index 146a939..0000000 --- a/backend/keycloak/kc-client/models/UserFederationMapperRepresentation.ts +++ /dev/null @@ -1,89 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface UserFederationMapperRepresentation - */ -export interface UserFederationMapperRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof UserFederationMapperRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof UserFederationMapperRepresentation - */ - federationMapperType?: string; - /** - * - * @type {string} - * @memberof UserFederationMapperRepresentation - */ - federationProviderDisplayName?: string; - /** - * - * @type {string} - * @memberof UserFederationMapperRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof UserFederationMapperRepresentation - */ - name?: string; -} - -export function UserFederationMapperRepresentationFromJSON(json: any): UserFederationMapperRepresentation { - return UserFederationMapperRepresentationFromJSONTyped(json, false); -} - -export function UserFederationMapperRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserFederationMapperRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'config': !exists(json, 'config') ? undefined : json['config'], - 'federationMapperType': !exists(json, 'federationMapperType') ? undefined : json['federationMapperType'], - 'federationProviderDisplayName': !exists(json, 'federationProviderDisplayName') ? undefined : json['federationProviderDisplayName'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'name': !exists(json, 'name') ? undefined : json['name'], - }; -} - -export function UserFederationMapperRepresentationToJSON(value?: UserFederationMapperRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'config': value.config, - 'federationMapperType': value.federationMapperType, - 'federationProviderDisplayName': value.federationProviderDisplayName, - 'id': value.id, - 'name': value.name, - }; -} - - diff --git a/backend/keycloak/kc-client/models/UserFederationProviderRepresentation.ts b/backend/keycloak/kc-client/models/UserFederationProviderRepresentation.ts deleted file mode 100644 index 201f7a3..0000000 --- a/backend/keycloak/kc-client/models/UserFederationProviderRepresentation.ts +++ /dev/null @@ -1,113 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -/** - * - * @export - * @interface UserFederationProviderRepresentation - */ -export interface UserFederationProviderRepresentation { - /** - * - * @type {number} - * @memberof UserFederationProviderRepresentation - */ - changedSyncPeriod?: number; - /** - * - * @type {{ [key: string]: object; }} - * @memberof UserFederationProviderRepresentation - */ - config?: { [key: string]: object; }; - /** - * - * @type {string} - * @memberof UserFederationProviderRepresentation - */ - displayName?: string; - /** - * - * @type {number} - * @memberof UserFederationProviderRepresentation - */ - fullSyncPeriod?: number; - /** - * - * @type {string} - * @memberof UserFederationProviderRepresentation - */ - id?: string; - /** - * - * @type {number} - * @memberof UserFederationProviderRepresentation - */ - lastSync?: number; - /** - * - * @type {number} - * @memberof UserFederationProviderRepresentation - */ - priority?: number; - /** - * - * @type {string} - * @memberof UserFederationProviderRepresentation - */ - providerName?: string; -} - -export function UserFederationProviderRepresentationFromJSON(json: any): UserFederationProviderRepresentation { - return UserFederationProviderRepresentationFromJSONTyped(json, false); -} - -export function UserFederationProviderRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserFederationProviderRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'changedSyncPeriod': !exists(json, 'changedSyncPeriod') ? undefined : json['changedSyncPeriod'], - 'config': !exists(json, 'config') ? undefined : json['config'], - 'displayName': !exists(json, 'displayName') ? undefined : json['displayName'], - 'fullSyncPeriod': !exists(json, 'fullSyncPeriod') ? undefined : json['fullSyncPeriod'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'lastSync': !exists(json, 'lastSync') ? undefined : json['lastSync'], - 'priority': !exists(json, 'priority') ? undefined : json['priority'], - 'providerName': !exists(json, 'providerName') ? undefined : json['providerName'], - }; -} - -export function UserFederationProviderRepresentationToJSON(value?: UserFederationProviderRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'changedSyncPeriod': value.changedSyncPeriod, - 'config': value.config, - 'displayName': value.displayName, - 'fullSyncPeriod': value.fullSyncPeriod, - 'id': value.id, - 'lastSync': value.lastSync, - 'priority': value.priority, - 'providerName': value.providerName, - }; -} - - diff --git a/backend/keycloak/kc-client/models/UserRepresentation.ts b/backend/keycloak/kc-client/models/UserRepresentation.ts deleted file mode 100644 index dcae299..0000000 --- a/backend/keycloak/kc-client/models/UserRepresentation.ts +++ /dev/null @@ -1,248 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - -import { exists, mapValues } from '../runtime'; -import { - CredentialRepresentation, - CredentialRepresentationFromJSON, - CredentialRepresentationFromJSONTyped, - CredentialRepresentationToJSON, - FederatedIdentityRepresentation, - FederatedIdentityRepresentationFromJSON, - FederatedIdentityRepresentationFromJSONTyped, - FederatedIdentityRepresentationToJSON, - UserConsentRepresentation, - UserConsentRepresentationFromJSON, - UserConsentRepresentationFromJSONTyped, - UserConsentRepresentationToJSON, -} from './'; - -/** - * - * @export - * @interface UserRepresentation - */ -export interface UserRepresentation { - /** - * - * @type {{ [key: string]: object; }} - * @memberof UserRepresentation - */ - access?: { [key: string]: object; }; - /** - * - * @type {{ [key: string]: object; }} - * @memberof UserRepresentation - */ - attributes?: { [key: string]: object; }; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - clientConsents?: Array; - /** - * - * @type {{ [key: string]: object; }} - * @memberof UserRepresentation - */ - clientRoles?: { [key: string]: object; }; - /** - * - * @type {number} - * @memberof UserRepresentation - */ - createdTimestamp?: number; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - credentials?: Array; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - disableableCredentialTypes?: Array; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - email?: string; - /** - * - * @type {boolean} - * @memberof UserRepresentation - */ - emailVerified?: boolean; - /** - * - * @type {boolean} - * @memberof UserRepresentation - */ - enabled?: boolean; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - federatedIdentities?: Array; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - federationLink?: string; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - firstName?: string; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - groups?: Array; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - id?: string; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - lastName?: string; - /** - * - * @type {number} - * @memberof UserRepresentation - */ - notBefore?: number; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - origin?: string; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - realmRoles?: Array; - /** - * - * @type {Array} - * @memberof UserRepresentation - */ - requiredActions?: Array; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - self?: string; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - serviceAccountClientId?: string; - /** - * - * @type {string} - * @memberof UserRepresentation - */ - username?: string; -} - -export function UserRepresentationFromJSON(json: any): UserRepresentation { - return UserRepresentationFromJSONTyped(json, false); -} - -export function UserRepresentationFromJSONTyped(json: any, ignoreDiscriminator: boolean): UserRepresentation { - if ((json === undefined) || (json === null)) { - return json; - } - return { - - 'access': !exists(json, 'access') ? undefined : json['access'], - 'attributes': !exists(json, 'attributes') ? undefined : json['attributes'], - 'clientConsents': !exists(json, 'clientConsents') ? undefined : ((json['clientConsents'] as Array).map(UserConsentRepresentationFromJSON)), - 'clientRoles': !exists(json, 'clientRoles') ? undefined : json['clientRoles'], - 'createdTimestamp': !exists(json, 'createdTimestamp') ? undefined : json['createdTimestamp'], - 'credentials': !exists(json, 'credentials') ? undefined : ((json['credentials'] as Array).map(CredentialRepresentationFromJSON)), - 'disableableCredentialTypes': !exists(json, 'disableableCredentialTypes') ? undefined : json['disableableCredentialTypes'], - 'email': !exists(json, 'email') ? undefined : json['email'], - 'emailVerified': !exists(json, 'emailVerified') ? undefined : json['emailVerified'], - 'enabled': !exists(json, 'enabled') ? undefined : json['enabled'], - 'federatedIdentities': !exists(json, 'federatedIdentities') ? undefined : ((json['federatedIdentities'] as Array).map(FederatedIdentityRepresentationFromJSON)), - 'federationLink': !exists(json, 'federationLink') ? undefined : json['federationLink'], - 'firstName': !exists(json, 'firstName') ? undefined : json['firstName'], - 'groups': !exists(json, 'groups') ? undefined : json['groups'], - 'id': !exists(json, 'id') ? undefined : json['id'], - 'lastName': !exists(json, 'lastName') ? undefined : json['lastName'], - 'notBefore': !exists(json, 'notBefore') ? undefined : json['notBefore'], - 'origin': !exists(json, 'origin') ? undefined : json['origin'], - 'realmRoles': !exists(json, 'realmRoles') ? undefined : json['realmRoles'], - 'requiredActions': !exists(json, 'requiredActions') ? undefined : json['requiredActions'], - 'self': !exists(json, 'self') ? undefined : json['self'], - 'serviceAccountClientId': !exists(json, 'serviceAccountClientId') ? undefined : json['serviceAccountClientId'], - 'username': !exists(json, 'username') ? undefined : json['username'], - }; -} - -export function UserRepresentationToJSON(value?: UserRepresentation | null): any { - if (value === undefined) { - return undefined; - } - if (value === null) { - return null; - } - return { - - 'access': value.access, - 'attributes': value.attributes, - 'clientConsents': value.clientConsents === undefined ? undefined : ((value.clientConsents as Array).map(UserConsentRepresentationToJSON)), - 'clientRoles': value.clientRoles, - 'createdTimestamp': value.createdTimestamp, - 'credentials': value.credentials === undefined ? undefined : ((value.credentials as Array).map(CredentialRepresentationToJSON)), - 'disableableCredentialTypes': value.disableableCredentialTypes, - 'email': value.email, - 'emailVerified': value.emailVerified, - 'enabled': value.enabled, - 'federatedIdentities': value.federatedIdentities === undefined ? undefined : ((value.federatedIdentities as Array).map(FederatedIdentityRepresentationToJSON)), - 'federationLink': value.federationLink, - 'firstName': value.firstName, - 'groups': value.groups, - 'id': value.id, - 'lastName': value.lastName, - 'notBefore': value.notBefore, - 'origin': value.origin, - 'realmRoles': value.realmRoles, - 'requiredActions': value.requiredActions, - 'self': value.self, - 'serviceAccountClientId': value.serviceAccountClientId, - 'username': value.username, - }; -} - - diff --git a/backend/keycloak/kc-client/models/index.ts b/backend/keycloak/kc-client/models/index.ts deleted file mode 100644 index f0ab862..0000000 --- a/backend/keycloak/kc-client/models/index.ts +++ /dev/null @@ -1,68 +0,0 @@ -export * from './AccessToken'; -export * from './AccessTokenAccess'; -export * from './AccessTokenAuthorization'; -export * from './AccessTokenCertConf'; -export * from './AddressClaimSet'; -export * from './AuthenticationExecutionExportRepresentation'; -export * from './AuthenticationExecutionInfoRepresentation'; -export * from './AuthenticationExecutionRepresentation'; -export * from './AuthenticationFlowRepresentation'; -export * from './AuthenticatorConfigInfoRepresentation'; -export * from './AuthenticatorConfigRepresentation'; -export * from './CertificateRepresentation'; -export * from './ClientInitialAccessCreatePresentation'; -export * from './ClientInitialAccessPresentation'; -export * from './ClientMappingsRepresentation'; -export * from './ClientPoliciesRepresentation'; -export * from './ClientPolicyConditionRepresentation'; -export * from './ClientPolicyExecutorRepresentation'; -export * from './ClientPolicyRepresentation'; -export * from './ClientProfileRepresentation'; -export * from './ClientProfilesRepresentation'; -export * from './ClientRepresentation'; -export * from './ClientScopeEvaluateResourceProtocolMapperEvaluationRepresentation'; -export * from './ClientScopeRepresentation'; -export * from './ComponentExportRepresentation'; -export * from './ComponentRepresentation'; -export * from './ConfigPropertyRepresentation'; -export * from './CredentialRepresentation'; -export * from './FederatedIdentityRepresentation'; -export * from './GlobalRequestResult'; -export * from './GroupRepresentation'; -export * from './IDToken'; -export * from './IdentityProviderMapperRepresentation'; -export * from './IdentityProviderRepresentation'; -export * from './JsonNode'; -export * from './KeyStoreConfig'; -export * from './KeysMetadataRepresentation'; -export * from './KeysMetadataRepresentationKeyMetadataRepresentation'; -export * from './ManagementPermissionReference'; -export * from './MappingsRepresentation'; -export * from './MemoryInfoRepresentation'; -export * from './MultivaluedHashMap'; -export * from './PartialImportRepresentation'; -export * from './PasswordPolicyTypeRepresentation'; -export * from './Permission'; -export * from './PolicyRepresentation'; -export * from './ProfileInfoRepresentation'; -export * from './ProtocolMapperRepresentation'; -export * from './ProviderRepresentation'; -export * from './RealmEventsConfigRepresentation'; -export * from './RealmRepresentation'; -export * from './RequiredActionProviderRepresentation'; -export * from './ResourceRepresentation'; -export * from './ResourceServerRepresentation'; -export * from './RoleRepresentation'; -export * from './RoleRepresentationComposites'; -export * from './RolesRepresentation'; -export * from './ScopeMappingRepresentation'; -export * from './ScopeRepresentation'; -export * from './ServerInfoRepresentation'; -export * from './SpiInfoRepresentation'; -export * from './SynchronizationResult'; -export * from './SystemInfoRepresentation'; -export * from './TestLdapConnectionRepresentation'; -export * from './UserConsentRepresentation'; -export * from './UserFederationMapperRepresentation'; -export * from './UserFederationProviderRepresentation'; -export * from './UserRepresentation'; diff --git a/backend/keycloak/kc-client/runtime.ts b/backend/keycloak/kc-client/runtime.ts deleted file mode 100644 index 3e7c8ce..0000000 --- a/backend/keycloak/kc-client/runtime.ts +++ /dev/null @@ -1,316 +0,0 @@ -/* tslint:disable */ -/* eslint-disable */ -/** - * Keycloak Admin REST API - * This is a REST API reference for the Keycloak Admin - * - * The version of the OpenAPI document: 1 - * - * - * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). - * https://openapi-generator.tech - * Do not edit the class manually. - */ - - -export const BASE_PATH = "http://localhost".replace(/\/+$/, ""); - -const isBlob = (value: any) => typeof Blob !== 'undefined' && value instanceof Blob; - -/** - * This is the base class for all generated API classes. - */ -export class BaseAPI { - - private middleware: Middleware[]; - - constructor(protected configuration = new Configuration()) { - this.middleware = configuration.middleware; - } - - withMiddleware(this: T, ...middlewares: Middleware[]) { - const next = this.clone(); - next.middleware = next.middleware.concat(...middlewares); - return next; - } - - withPreMiddleware(this: T, ...preMiddlewares: Array) { - const middlewares = preMiddlewares.map((pre) => ({ pre })); - return this.withMiddleware(...middlewares); - } - - withPostMiddleware(this: T, ...postMiddlewares: Array) { - const middlewares = postMiddlewares.map((post) => ({ post })); - return this.withMiddleware(...middlewares); - } - - protected async request(context: RequestOpts): Promise { - const { url, init } = this.createFetchParams(context); - const response = await this.fetchApi(url, init); - if (response.status >= 200 && response.status < 300) { - return response; - } - throw response; - } - - private createFetchParams(context: RequestOpts) { - let url = this.configuration.basePath + context.path; - if (context.query !== undefined && Object.keys(context.query).length !== 0) { - // only add the querystring to the URL if there are query parameters. - // this is done to avoid urls ending with a "?" character which buggy webservers - // do not handle correctly sometimes. - url += '?' + this.configuration.queryParamsStringify(context.query); - } - const body = ((typeof FormData !== "undefined" && context.body instanceof FormData) || context.body instanceof URLSearchParams || isBlob(context.body)) - ? context.body - : JSON.stringify(context.body); - - const headers = Object.assign({}, this.configuration.headers, context.headers); - const init = { - method: context.method, - headers: headers, - body, - credentials: this.configuration.credentials - }; - return { url, init }; - } - - private fetchApi = async (url: string, init: RequestInit) => { - let fetchParams = { url, init }; - for (const middleware of this.middleware) { - if (middleware.pre) { - fetchParams = await middleware.pre({ - fetch: this.fetchApi, - ...fetchParams, - }) || fetchParams; - } - } - let response = await this.configuration.fetchApi(fetchParams.url, fetchParams.init); - for (const middleware of this.middleware) { - if (middleware.post) { - response = await middleware.post({ - fetch: this.fetchApi, - url, - init, - response: response.clone(), - }) || response; - } - } - return response; - } - - /** - * Create a shallow clone of `this` by constructing a new instance - * and then shallow cloning data members. - */ - private clone(this: T): T { - const constructor = this.constructor as any; - const next = new constructor(this.configuration); - next.middleware = this.middleware.slice(); - return next; - } -}; - -export class RequiredError extends Error { - name: "RequiredError" = "RequiredError"; - constructor(public field: string, msg?: string) { - super(msg); - } -} - -export const COLLECTION_FORMATS = { - csv: ",", - ssv: " ", - tsv: "\t", - pipes: "|", -}; - -export type FetchAPI = GlobalFetch['fetch']; - -export interface ConfigurationParameters { - basePath?: string; // override base path - fetchApi?: FetchAPI; // override for fetch implementation - middleware?: Middleware[]; // middleware to apply before/after fetch requests - queryParamsStringify?: (params: HTTPQuery) => string; // stringify function for query strings - username?: string; // parameter for basic security - password?: string; // parameter for basic security - apiKey?: string | ((name: string) => string); // parameter for apiKey security - accessToken?: string | ((name?: string, scopes?: string[]) => string); // parameter for oauth2 security - headers?: HTTPHeaders; //header params we want to use on every request - credentials?: RequestCredentials; //value for the credentials param we want to use on each request -} - -export class Configuration { - constructor(private configuration: ConfigurationParameters = {}) {} - - get basePath(): string { - return this.configuration.basePath != null ? this.configuration.basePath : BASE_PATH; - } - - get fetchApi(): FetchAPI { - return this.configuration.fetchApi || window.fetch.bind(window); - } - - get middleware(): Middleware[] { - return this.configuration.middleware || []; - } - - get queryParamsStringify(): (params: HTTPQuery) => string { - return this.configuration.queryParamsStringify || querystring; - } - - get username(): string | undefined { - return this.configuration.username; - } - - get password(): string | undefined { - return this.configuration.password; - } - - get apiKey(): ((name: string) => string) | undefined { - const apiKey = this.configuration.apiKey; - if (apiKey) { - return typeof apiKey === 'function' ? apiKey : () => apiKey; - } - return undefined; - } - - get accessToken(): ((name: string, scopes?: string[]) => string) | undefined { - const accessToken = this.configuration.accessToken; - if (accessToken) { - return typeof accessToken === 'function' ? accessToken : () => accessToken; - } - return undefined; - } - - get headers(): HTTPHeaders | undefined { - return this.configuration.headers; - } - - get credentials(): RequestCredentials | undefined { - return this.configuration.credentials; - } -} - -export type Json = any; -export type HTTPMethod = 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'OPTIONS' | 'HEAD'; -export type HTTPHeaders = { [key: string]: string }; -export type HTTPQuery = { [key: string]: string | number | null | boolean | Array | HTTPQuery }; -export type HTTPBody = Json | FormData | URLSearchParams; -export type ModelPropertyNaming = 'camelCase' | 'snake_case' | 'PascalCase' | 'original'; - -export interface FetchParams { - url: string; - init: RequestInit; -} - -export interface RequestOpts { - path: string; - method: HTTPMethod; - headers: HTTPHeaders; - query?: HTTPQuery; - body?: HTTPBody; -} - -export function exists(json: any, key: string) { - const value = json[key]; - return value !== null && value !== undefined; -} - -export function querystring(params: HTTPQuery, prefix: string = ''): string { - return Object.keys(params) - .map((key) => { - const fullKey = prefix + (prefix.length ? `[${key}]` : key); - const value = params[key]; - if (value instanceof Array) { - const multiValue = value.map(singleValue => encodeURIComponent(String(singleValue))) - .join(`&${encodeURIComponent(fullKey)}=`); - return `${encodeURIComponent(fullKey)}=${multiValue}`; - } - if (value instanceof Object) { - return querystring(value as HTTPQuery, fullKey); - } - return `${encodeURIComponent(fullKey)}=${encodeURIComponent(String(value))}`; - }) - .filter(part => part.length > 0) - .join('&'); -} - -export function mapValues(data: any, fn: (item: any) => any) { - return Object.keys(data).reduce( - (acc, key) => ({ ...acc, [key]: fn(data[key]) }), - {} - ); -} - -export function canConsumeForm(consumes: Consume[]): boolean { - for (const consume of consumes) { - if ('multipart/form-data' === consume.contentType) { - return true; - } - } - return false; -} - -export interface Consume { - contentType: string -} - -export interface RequestContext { - fetch: FetchAPI; - url: string; - init: RequestInit; -} - -export interface ResponseContext { - fetch: FetchAPI; - url: string; - init: RequestInit; - response: Response; -} - -export interface Middleware { - pre?(context: RequestContext): Promise; - post?(context: ResponseContext): Promise; -} - -export interface ApiResponse { - raw: Response; - value(): Promise; -} - -export interface ResponseTransformer { - (json: any): T; -} - -export class JSONApiResponse { - constructor(public raw: Response, private transformer: ResponseTransformer = (jsonValue: any) => jsonValue) {} - - async value(): Promise { - return this.transformer(await this.raw.json()); - } -} - -export class VoidApiResponse { - constructor(public raw: Response) {} - - async value(): Promise { - return undefined; - } -} - -export class BlobApiResponse { - constructor(public raw: Response) {} - - async value(): Promise { - return await this.raw.blob(); - }; -} - -export class TextApiResponse { - constructor(public raw: Response) {} - - async value(): Promise { - return await this.raw.text(); - }; -} diff --git a/backend/keycloak/openapi.specs.yml b/backend/keycloak/openapi.specs.yml new file mode 100644 index 0000000..3767f0a --- /dev/null +++ b/backend/keycloak/openapi.specs.yml @@ -0,0 +1,9368 @@ +--- +openapi: 3.0.2 +info: + title: Keycloak Admin REST API + description: This is a REST API reference for the Keycloak Admin + version: '1' +paths: +# Login Manualisht + # "/auth/realms/{realm}": + # get: + # tags: + # - Login + # summary: Login + # responses: + # 2XX: + # description: success + # content: + # application/json: + # schema: + # "$ref": "#/components/schemas/LoginResponse" + # post: + # tags: + # - Login to Realm + # summary: Login with Username/Email and password + # requestBody: + # description: JSON representation of the realm + # content: + # application/json: + # schema: + # "$ref": "#/components/schemas/RealmRepresentation" + # required: true + # responses: + # 2XX: + # description: success +#end Login + "/": + get: + tags: + - Root + summary: Get themes, social providers, auth providers, and event listeners available + on this server + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ServerInfoRepresentation" + post: + tags: + - Realms Admin + summary: Import a realm Imports a realm from a full representation of that + realm. + requestBody: + description: JSON representation of the realm + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmRepresentation" + required: true + responses: + 2XX: + description: success + "/{id}/name": + get: + tags: + - User Storage Provider + summary: Need this for admin console to display simple name of provider when + displaying client detail KEYCLOAK-4328 + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}": + get: + tags: + - Realms Admin + summary: Get the top-level representation of the realm It will not include + nested information like User and Client representations. + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmRepresentation" + put: + tags: + - Realms Admin + summary: Update the top-level information of the realm Any user, roles or + client information in the representation will be ignored. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + summary: Delete the realm + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/admin-events": + get: + tags: + - Realms Admin + summary: Get admin events Returns all admin events, or filters events based + on URL query parameters listed here + parameters: + - in: query + name: authClient + schema: + type: string + style: form + - in: query + name: authIpAddress + schema: + type: string + style: form + - in: query + name: authRealm + schema: + type: string + style: form + - in: query + name: authUser + description: user id + schema: + type: string + style: form + - in: query + name: dateFrom + schema: + type: string + style: form + - in: query + name: dateTo + schema: + type: string + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: operationTypes + schema: + type: array + items: + type: string + style: form + - in: query + name: resourcePath + schema: + type: string + style: form + - in: query + name: resourceTypes + schema: + type: array + items: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + delete: + tags: + - Realms Admin + summary: Delete all admin events + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/attack-detection/brute-force/users": + delete: + tags: + - Attack Detection + summary: Clear any user login failures for all users This can release temporary + disabled users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/attack-detection/brute-force/users/{userId}": + get: + tags: + - Attack Detection + summary: Get status of a username in brute force detection + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + delete: + tags: + - Attack Detection + summary: Clear any user login failures for the user This can release temporary + disabled user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: userId + required: true + schema: + type: string + style: simple + "/{realm}/authentication/authenticator-providers": + get: + tags: + - Authentication Management + summary: Get authenticator providers Returns a stream of authenticator providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/client-authenticator-providers": + get: + tags: + - Authentication Management + summary: Get client authenticator providers Returns a stream of client authenticator + providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/config-description/{providerId}": + get: + tags: + - Authentication Management + summary: Get authenticator provider’s configuration description + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticatorConfigInfoRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: providerId + required: true + schema: + type: string + style: simple + "/{realm}/authentication/config/{id}": + get: + tags: + - Authentication Management + summary: Get authenticator configuration + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticatorConfigRepresentation" + put: + tags: + - Authentication Management + summary: Update authenticator configuration + requestBody: + description: JSON describing new state of authenticator configuration + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticatorConfigRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete authenticator configuration + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Configuration id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/executions": + post: + tags: + - Authentication Management + summary: Add new authentication execution + requestBody: + description: JSON model describing authentication execution + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticationExecutionRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/executions/{executionId}": + get: + tags: + - Authentication Management + summary: Get Single Execution + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete execution + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/executions/{executionId}/config": + post: + tags: + - Authentication Management + summary: Update execution with new configuration + requestBody: + description: JSON with new configuration + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticatorConfigRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/executions/{executionId}/lower-priority": + post: + tags: + - Authentication Management + summary: Lower execution’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/executions/{executionId}/raise-priority": + post: + tags: + - Authentication Management + summary: Raise execution’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows": + get: + tags: + - Authentication Management + summary: Get authentication flows Returns a stream of authentication flows. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Authentication Management + summary: Create a new authentication flow + requestBody: + description: Authentication flow representation + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticationFlowRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows/{flowAlias}/copy": + post: + tags: + - Authentication Management + summary: Copy existing authentication flow under a new name The new name is + given as 'newName' attribute of the passed JSON object + requestBody: + description: JSON containing 'newName' attribute + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Name of the existing authentication flow + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows/{flowAlias}/executions": + get: + tags: + - Authentication Management + summary: Get authentication executions for a flow + responses: + 2XX: + description: success + put: + tags: + - Authentication Management + summary: Update authentication executions of a Flow + requestBody: + description: AuthenticationExecutionInfoRepresentation + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticationExecutionInfoRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Flow alias + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows/{flowAlias}/executions/execution": + post: + tags: + - Authentication Management + summary: Add new authentication execution to a flow + requestBody: + description: New execution JSON data containing 'provider' attribute + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Alias of parent flow + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows/{flowAlias}/executions/flow": + post: + tags: + - Authentication Management + summary: Add new flow with new execution to existing flow + requestBody: + description: New authentication flow / execution JSON data containing 'alias', + 'type', 'provider', and 'description' attributes + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Alias of parent authentication flow + required: true + schema: + type: string + style: simple + "/{realm}/authentication/flows/{id}": + get: + tags: + - Authentication Management + summary: Get authentication flow for id + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticationFlowRepresentation" + put: + tags: + - Authentication Management + summary: Update an authentication flow + requestBody: + description: Authentication flow representation + content: + application/json: + schema: + "$ref": "#/components/schemas/AuthenticationFlowRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete an authentication flow + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Flow id + required: true + schema: + type: string + style: simple + "/{realm}/authentication/form-action-providers": + get: + tags: + - Authentication Management + summary: Get form action providers Returns a stream of form action providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/form-providers": + get: + tags: + - Authentication Management + summary: Get form providers Returns a stream of form providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/per-client-config-description": + get: + tags: + - Authentication Management + summary: Get configuration descriptions for all clients + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/register-required-action": + post: + tags: + - Authentication Management + summary: Register a new required actions + requestBody: + description: JSON containing 'providerId', and 'name' attributes. + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/required-actions": + get: + tags: + - Authentication Management + summary: Get required actions Returns a stream of required actions. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/authentication/required-actions/{alias}": + get: + tags: + - Authentication Management + summary: Get required action for alias + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RequiredActionProviderRepresentation" + put: + tags: + - Authentication Management + summary: Update required action + requestBody: + description: JSON describing new state of required action + content: + application/json: + schema: + "$ref": "#/components/schemas/RequiredActionProviderRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete required action + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + "/{realm}/authentication/required-actions/{alias}/lower-priority": + post: + tags: + - Authentication Management + summary: Lower required action’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + "/{realm}/authentication/required-actions/{alias}/raise-priority": + post: + tags: + - Authentication Management + summary: Raise required action’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + "/{realm}/authentication/unregistered-required-actions": + get: + tags: + - Authentication Management + summary: Get unregistered required actions Returns a stream of unregistered + required actions. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clear-keys-cache": + post: + tags: + - Realms Admin + summary: Clear cache of external public keys (Public keys of clients or Identity + providers) + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clear-realm-cache": + post: + tags: + - Realms Admin + summary: Clear realm cache + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clear-user-cache": + post: + tags: + - Realms Admin + summary: Clear user cache + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-description-converter": + post: + tags: + - Realms Admin + summary: Base path for importing clients under this realm. + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-policies/policies": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientPoliciesRepresentation" + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientPoliciesRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-policies/profiles": + get: + tags: + - Realms Admin + parameters: + - in: query + name: include-global-profiles + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientProfilesRepresentation" + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientProfilesRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-registration-policy/providers": + get: + tags: + - Client Registration Policy + summary: Base path for retrieve providers with the configProperties properly + filled + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes": + get: + tags: + - Client Scopes + summary: Get client scopes belonging to the realm Returns a list of client + scopes belonging to the realm + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Scopes + summary: Create a new client scope Client Scope’s name must be unique! + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientScopeRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id1}/protocol-mappers/models/{id2}": + get: + tags: + - Protocol Mappers + summary: Get mapper by id + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + put: + tags: + - Protocol Mappers + summary: Update the mapper + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Protocol Mappers + summary: Delete the mapper + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id1 + required: true + schema: + type: string + style: simple + - in: path + name: id2 + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}": + get: + tags: + - Client Scopes + summary: Get representation of the client scope + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientScopeRepresentation" + put: + tags: + - Client Scopes + summary: Update the client scope + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientScopeRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Scopes + summary: Delete the client scope + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/protocol-mappers/add-models": + post: + tags: + - Protocol Mappers + summary: Create multiple mappers + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/protocol-mappers/models": + get: + tags: + - Protocol Mappers + summary: Get mappers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Protocol Mappers + summary: Create a mapper + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/protocol-mappers/protocol/{protocol}": + get: + tags: + - Protocol Mappers + summary: Get mappers by name for a specific protocol + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: protocol + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/clients/{client}": + get: + tags: + - Scope Mappings + summary: Get the roles associated with a client’s scope Returns roles for + the client. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add client-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove client-level roles from the client’s scope. + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/clients/{client}/available": + get: + tags: + - Scope Mappings + summary: The available client-level roles Returns the roles for the client + that can be associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/clients/{client}/composite": + get: + tags: + - Scope Mappings + summary: Get effective client roles Returns the roles for the client that + are associated with the client’s scope. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/realm": + get: + tags: + - Scope Mappings + summary: Get realm-level roles associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add a set of realm-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove a set of realm-level roles from the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/realm/available": + get: + tags: + - Scope Mappings + summary: Get realm-level roles that are available to attach to this client’s + scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-scopes/{id}/scope-mappings/realm/composite": + get: + tags: + - Scope Mappings + summary: Get effective realm-level roles associated with the client’s scope What + this does is recurse any composite roles associated with the client’s scope + and adds the roles to this lists. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + "/{realm}/client-session-stats": + get: + tags: + - Realms Admin + summary: Get client session stats Returns a JSON map. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients": + get: + tags: + - Clients + summary: Get clients belonging to the realm. + parameters: + - in: query + name: clientId + description: filter by clientId + schema: + type: string + style: form + - in: query + name: first + description: the first result + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: the max results to return + schema: + type: integer + format: int32 + style: form + - in: query + name: q + schema: + type: string + style: form + - in: query + name: search + description: whether this is a search query or a getClientById query + schema: + type: boolean + style: form + - in: query + name: viewableOnly + description: filter clients that cannot be viewed in full by admin + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Clients + summary: Create a new client Client’s client_id must be unique! + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients-initial-access": + get: + tags: + - Client Initial Access + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Initial Access + summary: Create a new initial access token. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientInitialAccessCreatePresentation" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientInitialAccessPresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients-initial-access/{id}": + delete: + tags: + - Client Initial Access + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id1}/protocol-mappers/models/{id2}": + get: + tags: + - Protocol Mappers + summary: Get mapper by id + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + put: + tags: + - Protocol Mappers + summary: Update the mapper + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Protocol Mappers + summary: Delete the mapper + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id1 + required: true + schema: + type: string + style: simple + - in: path + name: id2 + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}": + get: + tags: + - Clients + summary: Get representation of the client + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientRepresentation" + put: + tags: + - Clients + summary: Update the client + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Clients + summary: Delete the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}": + get: + tags: + - Client Attribute Certificate + summary: Get key info + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CertificateRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}/download": + post: + tags: + - Client Attribute Certificate + summary: Get a keystore file for the client, containing private key and public + certificate + requestBody: + description: Keystore configuration as JSON + content: + application/json: + schema: + "$ref": "#/components/schemas/KeyStoreConfig" + required: true + responses: + 2XX: + description: success + content: + application/octet-stream: + schema: + type: string + format: byte + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}/generate": + post: + tags: + - Client Attribute Certificate + summary: Generate a new certificate with new key pair + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CertificateRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}/generate-and-download": + post: + tags: + - Client Attribute Certificate + summary: Generate a new keypair and certificate, and get the private key file Generates + a keypair and certificate and serves the private key in a specified keystore + format. + requestBody: + description: Keystore configuration as JSON + content: + application/json: + schema: + "$ref": "#/components/schemas/KeyStoreConfig" + required: true + responses: + 2XX: + description: success + content: + application/octet-stream: + schema: + type: string + format: byte + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}/upload": + post: + tags: + - Client Attribute Certificate + summary: Upload certificate and eventually private key + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CertificateRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/certificates/{attr}/upload-certificate": + post: + tags: + - Client Attribute Certificate + summary: Upload only certificate, not private key + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CertificateRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/client-secret": + get: + tags: + - Clients + summary: Get the client secret + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CredentialRepresentation" + post: + tags: + - Clients + summary: Generate a new secret for the client + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CredentialRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/client-secret/rotated": + get: + tags: + - Clients + summary: Get the rotated client secret + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/CredentialRepresentation" + delete: + tags: + - Clients + summary: Invalidate the rotated secret for the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/default-client-scopes": + get: + tags: + - Clients + summary: Get default client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/default-client-scopes/{clientScopeId}": + put: + tags: + - Clients + responses: + 2XX: + description: success + delete: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/generate-example-access-token": + get: + tags: + - Clients + summary: Create JSON with payload of example access token + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/AccessToken" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/generate-example-id-token": + get: + tags: + - Clients + summary: Create JSON with payload of example id token + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/IDToken" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/generate-example-userinfo": + get: + tags: + - Clients + summary: Create JSON with payload of example user info + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/protocol-mappers": + get: + tags: + - Clients + summary: Return list of all protocol mappers, which will be used when generating + tokens issued for particular client. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/granted": + get: + tags: + - Clients + summary: Get effective scope mapping of all roles of particular role container, + which this client is defacto allowed to have in the accessToken issued for + him. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: roleContainerId + description: either realm name OR client UUID + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/not-granted": + get: + tags: + - Clients + summary: Get roles, which this client doesn’t have scope for and can’t have + them in the accessToken issued for him. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: roleContainerId + description: either realm name OR client UUID + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/installation/providers/{providerId}": + get: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: providerId + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/management/permissions": + get: + tags: + - Clients + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Clients + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/nodes": + post: + tags: + - Clients + summary: Register a cluster node with the client Manually register cluster + node to this client - usually it’s not needed to call this directly as adapter + should handle by sending registration request to Keycloak + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/nodes/{node}": + delete: + tags: + - Clients + summary: Unregister a cluster node from the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: node + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/offline-session-count": + get: + tags: + - Clients + summary: 'Get application offline session count Returns a number of offline + user sessions associated with this client { "count": number }' + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/offline-sessions": + get: + tags: + - Clients + summary: Get offline sessions for client Returns a list of offline user sessions + associated with this client + parameters: + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/optional-client-scopes": + get: + tags: + - Clients + summary: Get optional client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/optional-client-scopes/{clientScopeId}": + put: + tags: + - Clients + responses: + 2XX: + description: success + delete: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/protocol-mappers/add-models": + post: + tags: + - Protocol Mappers + summary: Create multiple mappers + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/protocol-mappers/models": + get: + tags: + - Protocol Mappers + summary: Get mappers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Protocol Mappers + summary: Create a mapper + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/protocol-mappers/protocol/{protocol}": + get: + tags: + - Protocol Mappers + summary: Get mappers by name for a specific protocol + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: protocol + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/push-revocation": + post: + tags: + - Clients + summary: Push the client’s revocation policy to its admin URL If the client + has an admin URL, push revocation policy to it. + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/GlobalRequestResult" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/registration-access-token": + post: + tags: + - Clients + summary: Generate a new registration access token for the client + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ClientRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles": + get: + tags: + - Roles + summary: Get all roles for the realm or client + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Create a new role for the realm or client + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}": + get: + tags: + - Roles + summary: Get a role by name + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + put: + tags: + - Roles + summary: Update a role by name + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Delete a role by name + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/composites": + get: + tags: + - Roles + summary: Get composites of the role + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Add a composite to the role + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Remove roles from the role’s composite + requestBody: + description: roles to remove + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/composites/clients/{clientUuid}": + get: + tags: + - Roles + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/composites/realm": + get: + tags: + - Roles + summary: Get realm-level roles of the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/groups": + get: + tags: + - Roles + summary: Returns a stream of groups that have the specified role name + parameters: + - in: query + name: briefRepresentation + description: if false, return a full representation of the {@code GroupRepresentation} + objects. + schema: + type: boolean + style: form + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or {@code + null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/management/permissions": + get: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/roles/{role-name}/users": + get: + tags: + - Roles + summary: Returns a stream of users that have the specified role name. + parameters: + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or {@code + null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/clients/{client}": + get: + tags: + - Scope Mappings + summary: Get the roles associated with a client’s scope Returns roles for + the client. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add client-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove client-level roles from the client’s scope. + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/clients/{client}/available": + get: + tags: + - Scope Mappings + summary: The available client-level roles Returns the roles for the client + that can be associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/clients/{client}/composite": + get: + tags: + - Scope Mappings + summary: Get effective client roles Returns the roles for the client that + are associated with the client’s scope. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/realm": + get: + tags: + - Scope Mappings + summary: Get realm-level roles associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add a set of realm-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove a set of realm-level roles from the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/realm/available": + get: + tags: + - Scope Mappings + summary: Get realm-level roles that are available to attach to this client’s + scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/scope-mappings/realm/composite": + get: + tags: + - Scope Mappings + summary: Get effective realm-level roles associated with the client’s scope What + this does is recurse any composite roles associated with the client’s scope + and adds the roles to this lists. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/service-account-user": + get: + tags: + - Clients + summary: Get a user dedicated to the service account + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/UserRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/session-count": + get: + tags: + - Clients + summary: 'Get application session count Returns a number of user sessions + associated with this client { "count": number }' + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/test-nodes-available": + get: + tags: + - Clients + summary: Test if registered cluster nodes are available Tests availability + by sending 'ping' request to all cluster nodes. + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/GlobalRequestResult" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/clients/{id}/user-sessions": + get: + tags: + - Clients + summary: Get user sessions for client Returns a list of user sessions associated + with this client + parameters: + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + "/{realm}/components": + get: + tags: + - Component + parameters: + - in: query + name: name + schema: + type: string + style: form + - in: query + name: parent + schema: + type: string + style: form + - in: query + name: type + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Component + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ComponentRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/components/{id}": + get: + tags: + - Component + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ComponentRepresentation" + put: + tags: + - Component + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ComponentRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Component + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/components/{id}/sub-component-types": + get: + tags: + - Component + summary: List of subcomponent types that are available to configure for a particular + parent component. + parameters: + - in: query + name: type + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/credential-registrators": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/default-default-client-scopes": + get: + tags: + - Realms Admin + summary: Get realm default client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/default-default-client-scopes/{clientScopeId}": + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + "/{realm}/default-groups": + get: + tags: + - Realms Admin + summary: Get group hierarchy. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/default-groups/{groupId}": + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: groupId + required: true + schema: + type: string + style: simple + "/{realm}/default-optional-client-scopes": + get: + tags: + - Realms Admin + summary: Get realm optional client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/default-optional-client-scopes/{clientScopeId}": + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + "/{realm}/events": + get: + tags: + - Realms Admin + summary: Get events Returns all events, or filters them based on URL query + parameters listed here + parameters: + - in: query + name: client + description: App or oauth client name + schema: + type: string + style: form + - in: query + name: dateFrom + description: From date + schema: + type: string + style: form + - in: query + name: dateTo + description: To date + schema: + type: string + style: form + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: ipAddress + description: IP address + schema: + type: string + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: type + description: The types of events to return + schema: + type: array + items: + type: string + style: form + - in: query + name: user + description: User id + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + delete: + tags: + - Realms Admin + summary: Delete all events + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/events/config": + get: + tags: + - Realms Admin + summary: Get the events provider configuration Returns JSON object with events + provider configuration + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmEventsConfigRepresentation" + put: + tags: + - Realms Admin + summary: Update the events provider Change the events provider and/or its + configuration + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmEventsConfigRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/group-by-path/{path}": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/GroupRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: path + required: true + schema: + type: string + style: simple + "/{realm}/groups": + get: + tags: + - Groups + summary: Get group hierarchy. + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Groups + summary: create or add a top level realm groupSet or create child. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/GroupRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/groups/count": + get: + tags: + - Groups + summary: Returns the groups counts. + parameters: + - in: query + name: search + schema: + type: string + style: form + - in: query + name: top + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}": + get: + tags: + - Groups + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/GroupRepresentation" + put: + tags: + - Groups + summary: Update group, ignores subgroups. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/GroupRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Groups + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/children": + post: + tags: + - Groups + summary: Set or create child. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/GroupRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/management/permissions": + get: + tags: + - Groups + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Groups + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/members": + get: + tags: + - Groups + summary: Get users Returns a stream of users, filtered according to query + parameters + parameters: + - in: query + name: briefRepresentation + description: |- + Only return basic information (only guaranteed to return id, username, created, first and last name, + email, enabled state, email verification state, federation link, and access. + Note that it means that namely user attributes, required actions, and not before are not returned.) + schema: + type: boolean + style: form + - in: query + name: first + description: Pagination offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings": + get: + tags: + - Role Mapper + summary: Get role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/MappingsRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/clients/{client}": + get: + tags: + - Client Role Mappings + summary: Get client-level role mappings for the user, and the app + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Role Mappings + summary: Add client-level roles to the user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Role Mappings + summary: Delete client-level roles from user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/clients/{client}/available": + get: + tags: + - Client Role Mappings + summary: Get available client-level roles that can be mapped to the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/clients/{client}/composite": + get: + tags: + - Client Role Mappings + summary: Get effective client-level role mappings This recurses any composite + roles + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/realm": + get: + tags: + - Role Mapper + summary: Get realm-level role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Role Mapper + summary: Add realm-level role mappings to the user + requestBody: + description: Roles to add + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Role Mapper + summary: Delete realm-level role mappings + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/realm/available": + get: + tags: + - Role Mapper + summary: Get realm-level roles that can be mapped + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/groups/{id}/role-mappings/realm/composite": + get: + tags: + - Role Mapper + summary: Get effective realm-level role mappings This will recurse all composite + roles to get the result. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/import-config": + post: + tags: + - Identity Providers + summary: Import identity provider from uploaded JSON file + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances": + get: + tags: + - Identity Providers + summary: Get identity providers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Identity Providers + summary: Create a new identity provider + requestBody: + description: JSON body + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}": + get: + tags: + - Identity Providers + summary: Get the identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderRepresentation" + put: + tags: + - Identity Providers + summary: Update the identity provider + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Identity Providers + summary: Delete the identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}/export": + get: + tags: + - Identity Providers + summary: Export public broker configuration for identity provider + parameters: + - in: query + name: format + description: Format to use + schema: + type: string + style: form + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}/management/permissions": + get: + tags: + - Identity Providers + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Identity Providers + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}/mapper-types": + get: + tags: + - Identity Providers + summary: Get mapper types for identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}/mappers": + get: + tags: + - Identity Providers + summary: Get mappers for identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Identity Providers + summary: Add a mapper to identity provider + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderMapperRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/instances/{alias}/mappers/{id}": + get: + tags: + - Identity Providers + summary: Get mapper by id for the identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderMapperRepresentation" + put: + tags: + - Identity Providers + summary: Update a mapper for the identity provider + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/IdentityProviderMapperRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Identity Providers + summary: Delete a mapper for the identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Mapper id + required: true + schema: + type: string + style: simple + "/{realm}/identity-provider/providers/{provider_id}": + get: + tags: + - Identity Providers + summary: Get identity providers + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: provider_id + description: Provider id + required: true + schema: + type: string + style: simple + "/{realm}/keys": + get: + tags: + - Key + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/KeysMetadataRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/ldap-server-capabilities": + post: + tags: + - Realms Admin + summary: Get LDAP supported extensions. + requestBody: + description: LDAP configuration + content: + application/json: + schema: + "$ref": "#/components/schemas/TestLdapConnectionRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/localization": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/localization/{locale}": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + post: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: locale + required: true + schema: + type: string + style: simple + "/{realm}/localization/{locale}/{key}": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + text/plain: + schema: + type: string + put: + tags: + - Realms Admin + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: locale + required: true + schema: + type: string + style: simple + - in: path + name: key + required: true + schema: + type: string + style: simple + "/{realm}/logout-all": + post: + tags: + - Realms Admin + summary: Removes all user sessions. + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/GlobalRequestResult" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/partial-export": + post: + tags: + - Realms Admin + summary: Partial export of existing realm into a JSON file. + parameters: + - in: query + name: exportClients + schema: + type: boolean + style: form + - in: query + name: exportGroupsAndRoles + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RealmRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/partialImport": + post: + tags: + - Realms Admin + summary: Partial import from a JSON file to an existing realm. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/PartialImportRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/push-revocation": + post: + tags: + - Realms Admin + summary: Push the realm’s revocation policy to any client that has an admin + url associated with it. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/roles": + get: + tags: + - Roles + summary: Get all roles for the realm or client + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Create a new role for the realm or client + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/roles-by-id/{role-id}": + get: + tags: + - Roles (by ID) + summary: Get a specific role’s representation + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + put: + tags: + - Roles (by ID) + summary: Update the role + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles (by ID) + summary: Delete the role + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + description: id of role + required: true + schema: + type: string + style: simple + "/{realm}/roles-by-id/{role-id}/composites": + get: + tags: + - Roles (by ID) + summary: Get role’s children Returns a set of role’s children provided the + role is a composite. + parameters: + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles (by ID) + summary: Make the role a composite role by associating some child roles + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles (by ID) + summary: Remove a set of roles from the role’s composite + requestBody: + description: A set of roles to be removed + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + description: Role id + required: true + schema: + type: string + style: simple + "/{realm}/roles-by-id/{role-id}/composites/clients/{clientUuid}": + get: + tags: + - Roles (by ID) + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + "/{realm}/roles-by-id/{role-id}/composites/realm": + get: + tags: + - Roles (by ID) + summary: Get realm-level roles that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + "/{realm}/roles-by-id/{role-id}/management/permissions": + get: + tags: + - Roles (by ID) + summary: Return object stating whether role Authoirzation permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Roles (by ID) + summary: Return object stating whether role Authoirzation permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}": + get: + tags: + - Roles + summary: Get a role by name + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + put: + tags: + - Roles + summary: Update a role by name + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Delete a role by name + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/composites": + get: + tags: + - Roles + summary: Get composites of the role + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Add a composite to the role + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Remove roles from the role’s composite + requestBody: + description: roles to remove + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/composites/clients/{clientUuid}": + get: + tags: + - Roles + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/composites/realm": + get: + tags: + - Roles + summary: Get realm-level roles of the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/groups": + get: + tags: + - Roles + summary: Returns a stream of groups that have the specified role name + parameters: + - in: query + name: briefRepresentation + description: if false, return a full representation of the {@code GroupRepresentation} + objects. + schema: + type: boolean + style: form + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or {@code + null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/management/permissions": + get: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + required: true + schema: + type: string + style: simple + "/{realm}/roles/{role-name}/users": + get: + tags: + - Roles + summary: Returns a stream of users that have the specified role name. + parameters: + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or {@code + null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + "/{realm}/sessions/{session}": + delete: + tags: + - Realms Admin + summary: Remove a specific user session. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: session + required: true + schema: + type: string + style: simple + "/{realm}/testLDAPConnection": + post: + tags: + - Realms Admin + summary: Test LDAP connection + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/TestLdapConnectionRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/testSMTPConnection": + post: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/user-storage/{id}/name": + get: + tags: + - User Storage Provider + summary: Need this for admin console to display simple name of provider when + displaying user detail KEYCLOAK-4328 + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/user-storage/{id}/remove-imported-users": + post: + tags: + - User Storage Provider + summary: Remove imported users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/user-storage/{id}/sync": + post: + tags: + - User Storage Provider + summary: Trigger sync of users Action can be "triggerFullSync" or "triggerChangedUsersSync" + parameters: + - in: query + name: action + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/SynchronizationResult" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/user-storage/{id}/unlink-users": + post: + tags: + - User Storage Provider + summary: Unlink imported users from a storage provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/user-storage/{parentId}/mappers/{id}/sync": + post: + tags: + - User Storage Provider + summary: Trigger sync of mapper data related to ldap mapper (roles, groups, + …​) direction is "fedToKeycloak" or "keycloakToFed" + parameters: + - in: query + name: direction + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/SynchronizationResult" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: parentId + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + "/{realm}/users": + get: + tags: + - Users + summary: Get users Returns a stream of users, filtered according to query + parameters. + parameters: + - in: query + name: briefRepresentation + description: 'Boolean which defines whether brief representations are returned + (default: false)' + schema: + type: boolean + style: form + - in: query + name: email + description: A String contained in email, or the complete email, if param + "exact" is true + schema: + type: string + style: form + - in: query + name: emailVerified + description: whether the email has been verified + schema: + type: boolean + style: form + - in: query + name: enabled + description: Boolean representing if user is enabled or not + schema: + type: boolean + style: form + - in: query + name: exact + description: Boolean which defines whether the params "last", "first", "email" + and "username" must match exactly + schema: + type: boolean + style: form + - in: query + name: first + description: Pagination offset + schema: + type: integer + format: int32 + style: form + - in: query + name: firstName + description: A String contained in firstName, or the complete firstName, if + param "exact" is true + schema: + type: string + style: form + - in: query + name: idpAlias + description: The alias of an Identity Provider linked to the user + schema: + type: string + style: form + - in: query + name: idpUserId + description: The userId at an Identity Provider linked to the user + schema: + type: string + style: form + - in: query + name: lastName + description: A String contained in lastName, or the complete lastName, if + param "exact" is true + schema: + type: string + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: q + description: A query to search for custom attributes, in the format 'key1:value2 + key2:value2' + schema: + type: string + style: form + - in: query + name: search + description: A String contained in username, first or last name, or email + schema: + type: string + style: form + - in: query + name: username + description: A String contained in username, or the complete username, if + param "exact" is true + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Users + summary: Create a new user Username must be unique. + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/UserRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/users-management-permissions": + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/ManagementPermissionReference" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/users/count": + get: + tags: + - Users + summary: Returns the number of users that match the given criteria. + parameters: + - in: query + name: email + description: email filter + schema: + type: string + style: form + - in: query + name: emailVerified + schema: + type: boolean + style: form + - in: query + name: enabled + description: Boolean representing if user is enabled or not + schema: + type: boolean + style: form + - in: query + name: firstName + description: first name filter + schema: + type: string + style: form + - in: query + name: lastName + description: last name filter + schema: + type: string + style: form + - in: query + name: search + description: arbitrary search string for all the fields below + schema: + type: string + style: form + - in: query + name: username + description: username filter + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: integer + format: int32 + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/users/profile": + get: + tags: + - Users + responses: + 2XX: + description: success + content: + application/json: + schema: + type: string + put: + tags: + - Users + requestBody: + content: + application/json: + schema: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}": + get: + tags: + - Users + summary: Get representation of the user + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/UserRepresentation" + put: + tags: + - Users + summary: Update the user + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/UserRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Users + summary: Delete the user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/configured-user-storage-credential-types": + get: + tags: + - Users + summary: Return credential types, which are provided by the user storage where + user is stored. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/consents": + get: + tags: + - Users + summary: Get consents granted by the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/consents/{client}": + delete: + tags: + - Users + summary: Revoke consent and offline tokens for particular client from user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + description: Client id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/credentials": + get: + tags: + - Users + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/credentials/{credentialId}": + delete: + tags: + - Users + summary: Remove a credential for a user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/credentials/{credentialId}/moveAfter/{newPreviousCredentialId}": + post: + tags: + - Users + summary: Move a credential to a position behind another credential + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + description: The credential to move + required: true + schema: + type: string + style: simple + - in: path + name: newPreviousCredentialId + description: The credential that will be the previous element in the list. If + set to null, the moved credential will be the first element in the list. + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/credentials/{credentialId}/moveToFirst": + post: + tags: + - Users + summary: Move a credential to a first position in the credentials list of the + user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + description: The credential to move + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/credentials/{credentialId}/userLabel": + put: + tags: + - Users + summary: Update a credential label for a user + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/disable-credential-types": + put: + tags: + - Users + summary: Disable all credentials for a user of a specific type + requestBody: + content: + application/json: + schema: + type: array + items: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/execute-actions-email": + put: + tags: + - Users + summary: Send a update account email to the user An email contains a link + the user can click to perform a set of required actions. + parameters: + - in: query + name: client_id + description: Client id + schema: + type: string + style: form + - in: query + name: lifespan + description: Number of seconds after which the generated token expires + schema: + type: integer + format: int32 + style: form + - in: query + name: redirect_uri + description: Redirect uri + schema: + type: string + style: form + requestBody: + description: required actions the user needs to complete + content: + application/json: + schema: + type: array + items: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/federated-identity": + get: + tags: + - Users + summary: Get social logins associated with the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/federated-identity/{provider}": + post: + tags: + - Users + summary: Add a social login provider to the user + requestBody: + content: + application/json: + schema: + "$ref": "#/components/schemas/FederatedIdentityRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Users + summary: Remove a social login provider from user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: provider + description: Social login provider id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/groups": + get: + tags: + - Users + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/groups/count": + get: + tags: + - Users + parameters: + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/groups/{groupId}": + put: + tags: + - Users + responses: + 2XX: + description: success + delete: + tags: + - Users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: groupId + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/impersonation": + post: + tags: + - Users + summary: Impersonate the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/logout": + post: + tags: + - Users + summary: Remove all user sessions associated with the user Also send notification + to all clients that have an admin URL to invalidate the sessions for the particular + user. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/offline-sessions/{clientUuid}": + get: + tags: + - Users + summary: Get offline sessions associated with the user and client + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/reset-password": + put: + tags: + - Users + summary: Set up a new password for the user. + requestBody: + description: The representation must contain a rawPassword with the plain-text + password + content: + application/json: + schema: + "$ref": "#/components/schemas/CredentialRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings": + get: + tags: + - Role Mapper + summary: Get role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + "$ref": "#/components/schemas/MappingsRepresentation" + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/clients/{client}": + get: + tags: + - Client Role Mappings + summary: Get client-level role mappings for the user, and the app + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Role Mappings + summary: Add client-level roles to the user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Role Mappings + summary: Delete client-level roles from user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/clients/{client}/available": + get: + tags: + - Client Role Mappings + summary: Get available client-level roles that can be mapped to the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/clients/{client}/composite": + get: + tags: + - Client Role Mappings + summary: Get effective client-level role mappings This recurses any composite + roles + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/realm": + get: + tags: + - Role Mapper + summary: Get realm-level role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Role Mapper + summary: Add realm-level role mappings to the user + requestBody: + description: Roles to add + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + delete: + tags: + - Role Mapper + summary: Delete realm-level role mappings + requestBody: + content: + application/json: + schema: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/realm/available": + get: + tags: + - Role Mapper + summary: Get realm-level roles that can be mapped + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/role-mappings/realm/composite": + get: + tags: + - Role Mapper + summary: Get effective realm-level role mappings This will recurse all composite + roles to get the result. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/send-verify-email": + put: + tags: + - Users + summary: Send an email-verification email to the user An email contains a + link the user can click to verify their email address. + parameters: + - in: query + name: client_id + description: Client id + schema: + type: string + style: form + - in: query + name: redirect_uri + description: Redirect uri + schema: + type: string + style: form + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + "/{realm}/users/{id}/sessions": + get: + tags: + - Users + summary: Get sessions associated with the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple +components: + securitySchemes: + access_token: + type: http + scheme: bearer + bearerFormat: + schemas: + #LoginResponse Manual + # LoginResponse: + # type: object + # properties: + # access_token: + # type: string + # expires_in: + # type: integer + # format: int32 + # refresh_token: + # type: string + # refresh_expires_in: + # type: integer + # format: int32 + # token_type: + # type: string + # not-before-policy: + # type: integer + # format: int32 + # session_state: + # type: string + # token_type: + # scope: string + #EndLoginResponse + AccessToken: + type: object + properties: + acr: + type: string + address: + "$ref": "#/components/schemas/AddressClaimSet" + allowed-origins: + type: array + items: + type: string + at_hash: + type: string + auth_time: + type: integer + format: int64 + authorization: + "$ref": "#/components/schemas/AccessToken-Authorization" + azp: + type: string + birthdate: + type: string + c_hash: + type: string + category: + type: string + enum: + - INTERNAL + - ACCESS + - ID + - ADMIN + - USERINFO + - LOGOUT + - AUTHORIZATION_RESPONSE + claims_locales: + type: string + cnf: + "$ref": "#/components/schemas/AccessToken-CertConf" + email: + type: string + email_verified: + type: boolean + exp: + type: integer + format: int64 + family_name: + type: string + gender: + type: string + given_name: + type: string + iat: + type: integer + format: int64 + iss: + type: string + jti: + type: string + locale: + type: string + middle_name: + type: string + name: + type: string + nbf: + type: integer + format: int64 + nickname: + type: string + nonce: + type: string + otherClaims: + type: object + additionalProperties: true + phone_number: + type: string + phone_number_verified: + type: boolean + picture: + type: string + preferred_username: + type: string + profile: + type: string + realm_access: + "$ref": "#/components/schemas/AccessToken-Access" + s_hash: + type: string + scope: + type: string + session_state: + type: string + sid: + type: string + sub: + type: string + trusted-certs: + type: array + items: + type: string + typ: + type: string + updated_at: + type: integer + format: int64 + website: + type: string + zoneinfo: + type: string + AccessToken-Access: + type: object + properties: + roles: + type: array + items: + type: string + verify_caller: + type: boolean + AccessToken-Authorization: + type: object + properties: + permissions: + type: array + items: + "$ref": "#/components/schemas/Permission" + AccessToken-CertConf: + type: object + properties: + x5t#S256: + type: string + AddressClaimSet: + type: object + properties: + country: + type: string + formatted: + type: string + locality: + type: string + postal_code: + type: string + region: + type: string + street_address: + type: string + AuthenticationExecutionExportRepresentation: + type: object + properties: + authenticator: + type: string + authenticatorConfig: + type: string + authenticatorFlow: + type: boolean + flowAlias: + type: string + priority: + type: integer + format: int32 + requirement: + type: string + userSetupAllowed: + type: boolean + AuthenticationExecutionInfoRepresentation: + type: object + properties: + alias: + type: string + authenticationConfig: + type: string + authenticationFlow: + type: boolean + configurable: + type: boolean + description: + type: string + displayName: + type: string + flowId: + type: string + id: + type: string + index: + type: integer + format: int32 + level: + type: integer + format: int32 + providerId: + type: string + requirement: + type: string + requirementChoices: + type: array + items: + type: string + AuthenticationExecutionRepresentation: + type: object + properties: + authenticator: + type: string + authenticatorConfig: + type: string + authenticatorFlow: + type: boolean + flowId: + type: string + id: + type: string + parentFlow: + type: string + priority: + type: integer + format: int32 + requirement: + type: string + AuthenticationFlowRepresentation: + type: object + properties: + alias: + type: string + authenticationExecutions: + type: array + items: + "$ref": "#/components/schemas/AuthenticationExecutionExportRepresentation" + builtIn: + type: boolean + description: + type: string + id: + type: string + providerId: + type: string + topLevel: + type: boolean + AuthenticatorConfigInfoRepresentation: + type: object + properties: + helpText: + type: string + name: + type: string + properties: + type: array + items: + "$ref": "#/components/schemas/ConfigPropertyRepresentation" + providerId: + type: string + AuthenticatorConfigRepresentation: + type: object + properties: + alias: + type: string + config: + type: object + additionalProperties: true + id: + type: string + CertificateRepresentation: + type: object + properties: + certificate: + type: string + kid: + type: string + privateKey: + type: string + publicKey: + type: string + ClientInitialAccessCreatePresentation: + type: object + properties: + count: + type: integer + format: int32 + expiration: + type: integer + format: int32 + ClientInitialAccessPresentation: + type: object + properties: + count: + type: integer + format: int32 + expiration: + type: integer + format: int32 + id: + type: string + remainingCount: + type: integer + format: int32 + timestamp: + type: integer + format: int32 + token: + type: string + ClientMappingsRepresentation: + type: object + properties: + client: + type: string + id: + type: string + mappings: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + ClientPoliciesRepresentation: + type: object + properties: + policies: + type: array + items: + "$ref": "#/components/schemas/ClientPolicyRepresentation" + ClientPolicyConditionRepresentation: + type: object + properties: + condition: + type: string + configuration: + "$ref": "#/components/schemas/JsonNode" + ClientPolicyExecutorRepresentation: + type: object + properties: + configuration: + "$ref": "#/components/schemas/JsonNode" + executor: + type: string + ClientPolicyRepresentation: + type: object + properties: + conditions: + type: array + items: + "$ref": "#/components/schemas/ClientPolicyConditionRepresentation" + description: + type: string + enabled: + type: boolean + name: + type: string + profiles: + type: array + items: + type: string + ClientProfileRepresentation: + type: object + properties: + description: + type: string + executors: + type: array + items: + "$ref": "#/components/schemas/ClientPolicyExecutorRepresentation" + name: + type: string + ClientProfilesRepresentation: + type: object + properties: + globalProfiles: + type: array + items: + "$ref": "#/components/schemas/ClientProfileRepresentation" + profiles: + type: array + items: + "$ref": "#/components/schemas/ClientProfileRepresentation" + ClientRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + adminUrl: + type: string + alwaysDisplayInConsole: + type: boolean + attributes: + type: object + additionalProperties: true + authenticationFlowBindingOverrides: + type: object + additionalProperties: true + authorizationServicesEnabled: + type: boolean + authorizationSettings: + "$ref": "#/components/schemas/ResourceServerRepresentation" + baseUrl: + type: string + bearerOnly: + type: boolean + clientAuthenticatorType: + type: string + clientId: + type: string + consentRequired: + type: boolean + defaultClientScopes: + type: array + items: + type: string + description: + type: string + directAccessGrantsEnabled: + type: boolean + enabled: + type: boolean + frontchannelLogout: + type: boolean + fullScopeAllowed: + type: boolean + id: + type: string + implicitFlowEnabled: + type: boolean + name: + type: string + nodeReRegistrationTimeout: + type: integer + format: int32 + notBefore: + type: integer + format: int32 + oauth2DeviceAuthorizationGrantEnabled: + type: boolean + optionalClientScopes: + type: array + items: + type: string + origin: + type: string + protocol: + type: string + protocolMappers: + type: array + items: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + publicClient: + type: boolean + redirectUris: + type: array + items: + type: string + registeredNodes: + type: object + additionalProperties: true + registrationAccessToken: + type: string + rootUrl: + type: string + secret: + type: string + serviceAccountsEnabled: + type: boolean + standardFlowEnabled: + type: boolean + surrogateAuthRequired: + type: boolean + webOrigins: + type: array + items: + type: string + ClientScopeEvaluateResource-ProtocolMapperEvaluationRepresentation: + type: object + properties: + containerId: + type: string + containerName: + type: string + containerType: + type: string + mapperId: + type: string + mapperName: + type: string + protocolMapper: + type: string + ClientScopeRepresentation: + type: object + properties: + attributes: + type: object + additionalProperties: true + description: + type: string + id: + type: string + name: + type: string + protocol: + type: string + protocolMappers: + type: array + items: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + ComponentExportRepresentation: + type: object + properties: + config: + "$ref": "#/components/schemas/MultivaluedHashMap" + id: + type: string + name: + type: string + providerId: + type: string + subComponents: + "$ref": "#/components/schemas/MultivaluedHashMap" + subType: + type: string + ComponentRepresentation: + type: object + properties: + config: + "$ref": "#/components/schemas/MultivaluedHashMap" + id: + type: string + name: + type: string + parentId: + type: string + providerId: + type: string + providerType: + type: string + subType: + type: string + ConfigPropertyRepresentation: + type: object + properties: + defaultValue: + type: object + helpText: + type: string + label: + type: string + name: + type: string + options: + type: array + items: + type: string + readOnly: + type: boolean + secret: + type: boolean + type: + type: string + CredentialRepresentation: + type: object + properties: + createdDate: + type: integer + format: int64 + credentialData: + type: string + id: + type: string + priority: + type: integer + format: int32 + secretData: + type: string + temporary: + type: boolean + type: + type: string + userLabel: + type: string + value: + type: string + FederatedIdentityRepresentation: + type: object + properties: + identityProvider: + type: string + userId: + type: string + userName: + type: string + GlobalRequestResult: + type: object + properties: + failedRequests: + type: array + items: + type: string + successRequests: + type: array + items: + type: string + GroupRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + attributes: + type: object + additionalProperties: true + clientRoles: + type: object + additionalProperties: true + id: + type: string + name: + type: string + path: + type: string + realmRoles: + type: array + items: + type: string + subGroups: + type: array + items: + "$ref": "#/components/schemas/GroupRepresentation" + IDToken: + type: object + properties: + acr: + type: string + address: + "$ref": "#/components/schemas/AddressClaimSet" + at_hash: + type: string + auth_time: + type: integer + format: int64 + azp: + type: string + birthdate: + type: string + c_hash: + type: string + category: + type: string + enum: + - INTERNAL + - ACCESS + - ID + - ADMIN + - USERINFO + - LOGOUT + - AUTHORIZATION_RESPONSE + claims_locales: + type: string + email: + type: string + email_verified: + type: boolean + exp: + type: integer + format: int64 + family_name: + type: string + gender: + type: string + given_name: + type: string + iat: + type: integer + format: int64 + iss: + type: string + jti: + type: string + locale: + type: string + middle_name: + type: string + name: + type: string + nbf: + type: integer + format: int64 + nickname: + type: string + nonce: + type: string + otherClaims: + type: object + additionalProperties: true + phone_number: + type: string + phone_number_verified: + type: boolean + picture: + type: string + preferred_username: + type: string + profile: + type: string + s_hash: + type: string + session_state: + type: string + sid: + type: string + sub: + type: string + typ: + type: string + updated_at: + type: integer + format: int64 + website: + type: string + zoneinfo: + type: string + IdentityProviderMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + id: + type: string + identityProviderAlias: + type: string + identityProviderMapper: + type: string + name: + type: string + IdentityProviderRepresentation: + type: object + properties: + addReadTokenRoleOnCreate: + type: boolean + alias: + type: string + config: + type: object + additionalProperties: true + displayName: + type: string + enabled: + type: boolean + firstBrokerLoginFlowAlias: + type: string + internalId: + type: string + linkOnly: + type: boolean + postBrokerLoginFlowAlias: + type: string + providerId: + type: string + storeToken: + type: boolean + trustEmail: + type: boolean + JsonNode: + type: object + properties: + array: + type: boolean + bigDecimal: + type: boolean + bigInteger: + type: boolean + binary: + type: boolean + boolean: + type: boolean + containerNode: + type: boolean + double: + type: boolean + empty: + type: boolean + float: + type: boolean + floatingPointNumber: + type: boolean + int: + type: boolean + integralNumber: + type: boolean + long: + type: boolean + missingNode: + type: boolean + nodeType: + type: string + enum: + - ARRAY + - BINARY + - BOOLEAN + - MISSING + - 'NULL' + - NUMBER + - OBJECT + - POJO + - STRING + 'null': + type: boolean + number: + type: boolean + object: + type: boolean + pojo: + type: boolean + short: + type: boolean + textual: + type: boolean + valueNode: + type: boolean + KeyStoreConfig: + type: object + properties: + format: + type: string + keyAlias: + type: string + keyPassword: + type: string + realmAlias: + type: string + realmCertificate: + type: boolean + storePassword: + type: string + KeysMetadataRepresentation: + type: object + properties: + active: + type: object + additionalProperties: true + keys: + type: array + items: + "$ref": "#/components/schemas/KeysMetadataRepresentation-KeyMetadataRepresentation" + KeysMetadataRepresentation-KeyMetadataRepresentation: + type: object + properties: + algorithm: + type: string + certificate: + type: string + kid: + type: string + providerId: + type: string + providerPriority: + type: integer + format: int64 + publicKey: + type: string + status: + type: string + type: + type: string + use: + type: string + enum: + - SIG + - ENC + ManagementPermissionReference: + type: object + properties: + enabled: + type: boolean + resource: + type: string + scopePermissions: + type: object + additionalProperties: true + MappingsRepresentation: + type: object + properties: + clientMappings: + type: object + additionalProperties: true + realmMappings: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + MemoryInfoRepresentation: + type: object + properties: + free: + type: integer + format: int64 + freeFormated: + type: string + freePercentage: + type: integer + format: int64 + total: + type: integer + format: int64 + totalFormated: + type: string + used: + type: integer + format: int64 + usedFormated: + type: string + MultivaluedHashMap: + type: object + properties: + empty: + type: boolean + loadFactor: + type: number + format: float + threshold: + type: integer + format: int32 + PartialImportRepresentation: + type: object + properties: + clients: + type: array + items: + "$ref": "#/components/schemas/ClientRepresentation" + groups: + type: array + items: + "$ref": "#/components/schemas/GroupRepresentation" + identityProviders: + type: array + items: + "$ref": "#/components/schemas/IdentityProviderRepresentation" + ifResourceExists: + type: string + policy: + type: string + enum: + - SKIP + - OVERWRITE + - FAIL + roles: + "$ref": "#/components/schemas/RolesRepresentation" + users: + type: array + items: + "$ref": "#/components/schemas/UserRepresentation" + PasswordPolicyTypeRepresentation: + type: object + properties: + configType: + type: string + defaultValue: + type: string + displayName: + type: string + id: + type: string + multipleSupported: + type: boolean + Permission: + type: object + properties: + claims: + type: object + additionalProperties: true + rsid: + type: string + rsname: + type: string + scopes: + type: array + items: + type: string + PolicyRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + decisionStrategy: + type: string + enum: + - AFFIRMATIVE + - UNANIMOUS + - CONSENSUS + description: + type: string + id: + type: string + logic: + type: string + enum: + - POSITIVE + - NEGATIVE + name: + type: string + owner: + type: string + policies: + type: array + items: + type: string + resources: + type: array + items: + type: string + resourcesData: + type: array + items: + "$ref": "#/components/schemas/ResourceRepresentation" + scopes: + type: array + items: + type: string + scopesData: + type: array + items: + "$ref": "#/components/schemas/ScopeRepresentation" + type: + type: string + ProfileInfoRepresentation: + type: object + properties: + disabledFeatures: + type: array + items: + type: string + experimentalFeatures: + type: array + items: + type: string + name: + type: string + previewFeatures: + type: array + items: + type: string + ProtocolMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + id: + type: string + name: + type: string + protocol: + type: string + protocolMapper: + type: string + ProviderRepresentation: + type: object + properties: + operationalInfo: + type: object + additionalProperties: true + order: + type: integer + format: int32 + RealmEventsConfigRepresentation: + type: object + properties: + adminEventsDetailsEnabled: + type: boolean + adminEventsEnabled: + type: boolean + enabledEventTypes: + type: array + items: + type: string + eventsEnabled: + type: boolean + eventsExpiration: + type: integer + format: int64 + eventsListeners: + type: array + items: + type: string + RealmRepresentation: + type: object + properties: + accessCodeLifespan: + type: integer + format: int32 + accessCodeLifespanLogin: + type: integer + format: int32 + accessCodeLifespanUserAction: + type: integer + format: int32 + accessTokenLifespan: + type: integer + format: int32 + accessTokenLifespanForImplicitFlow: + type: integer + format: int32 + accountTheme: + type: string + actionTokenGeneratedByAdminLifespan: + type: integer + format: int32 + actionTokenGeneratedByUserLifespan: + type: integer + format: int32 + adminEventsDetailsEnabled: + type: boolean + adminEventsEnabled: + type: boolean + adminTheme: + type: string + attributes: + type: object + additionalProperties: true + authenticationFlows: + type: array + items: + "$ref": "#/components/schemas/AuthenticationFlowRepresentation" + authenticatorConfig: + type: array + items: + "$ref": "#/components/schemas/AuthenticatorConfigRepresentation" + browserFlow: + type: string + browserSecurityHeaders: + type: object + additionalProperties: true + bruteForceProtected: + type: boolean + clientAuthenticationFlow: + type: string + clientOfflineSessionIdleTimeout: + type: integer + format: int32 + clientOfflineSessionMaxLifespan: + type: integer + format: int32 + clientPolicies: + "$ref": "#/components/schemas/JsonNode" + clientProfiles: + "$ref": "#/components/schemas/JsonNode" + clientScopeMappings: + type: object + additionalProperties: true + clientScopes: + type: array + items: + "$ref": "#/components/schemas/ClientScopeRepresentation" + clientSessionIdleTimeout: + type: integer + format: int32 + clientSessionMaxLifespan: + type: integer + format: int32 + clients: + type: array + items: + "$ref": "#/components/schemas/ClientRepresentation" + components: + "$ref": "#/components/schemas/MultivaluedHashMap" + defaultDefaultClientScopes: + type: array + items: + type: string + defaultGroups: + type: array + items: + type: string + defaultLocale: + type: string + defaultOptionalClientScopes: + type: array + items: + type: string + defaultRole: + "$ref": "#/components/schemas/RoleRepresentation" + defaultSignatureAlgorithm: + type: string + directGrantFlow: + type: string + displayName: + type: string + displayNameHtml: + type: string + dockerAuthenticationFlow: + type: string + duplicateEmailsAllowed: + type: boolean + editUsernameAllowed: + type: boolean + emailTheme: + type: string + enabled: + type: boolean + enabledEventTypes: + type: array + items: + type: string + eventsEnabled: + type: boolean + eventsExpiration: + type: integer + format: int64 + eventsListeners: + type: array + items: + type: string + failureFactor: + type: integer + format: int32 + federatedUsers: + type: array + items: + "$ref": "#/components/schemas/UserRepresentation" + groups: + type: array + items: + "$ref": "#/components/schemas/GroupRepresentation" + id: + type: string + identityProviderMappers: + type: array + items: + "$ref": "#/components/schemas/IdentityProviderMapperRepresentation" + identityProviders: + type: array + items: + "$ref": "#/components/schemas/IdentityProviderRepresentation" + internationalizationEnabled: + type: boolean + keycloakVersion: + type: string + loginTheme: + type: string + loginWithEmailAllowed: + type: boolean + maxDeltaTimeSeconds: + type: integer + format: int32 + maxFailureWaitSeconds: + type: integer + format: int32 + minimumQuickLoginWaitSeconds: + type: integer + format: int32 + notBefore: + type: integer + format: int32 + oAuth2DeviceCodeLifespan: + type: integer + format: int32 + oAuth2DevicePollingInterval: + type: integer + format: int32 + oauth2DeviceCodeLifespan: + type: integer + format: int32 + oauth2DevicePollingInterval: + type: integer + format: int32 + offlineSessionIdleTimeout: + type: integer + format: int32 + offlineSessionMaxLifespan: + type: integer + format: int32 + offlineSessionMaxLifespanEnabled: + type: boolean + otpPolicyAlgorithm: + type: string + otpPolicyDigits: + type: integer + format: int32 + otpPolicyInitialCounter: + type: integer + format: int32 + otpPolicyLookAheadWindow: + type: integer + format: int32 + otpPolicyPeriod: + type: integer + format: int32 + otpPolicyType: + type: string + otpSupportedApplications: + type: array + items: + type: string + passwordPolicy: + type: string + permanentLockout: + type: boolean + protocolMappers: + type: array + items: + "$ref": "#/components/schemas/ProtocolMapperRepresentation" + quickLoginCheckMilliSeconds: + type: integer + format: int64 + realm: + type: string + refreshTokenMaxReuse: + type: integer + format: int32 + registrationAllowed: + type: boolean + registrationEmailAsUsername: + type: boolean + registrationFlow: + type: string + rememberMe: + type: boolean + requiredActions: + type: array + items: + "$ref": "#/components/schemas/RequiredActionProviderRepresentation" + resetCredentialsFlow: + type: string + resetPasswordAllowed: + type: boolean + revokeRefreshToken: + type: boolean + roles: + "$ref": "#/components/schemas/RolesRepresentation" + scopeMappings: + type: array + items: + "$ref": "#/components/schemas/ScopeMappingRepresentation" + smtpServer: + type: object + additionalProperties: true + sslRequired: + type: string + ssoSessionIdleTimeout: + type: integer + format: int32 + ssoSessionIdleTimeoutRememberMe: + type: integer + format: int32 + ssoSessionMaxLifespan: + type: integer + format: int32 + ssoSessionMaxLifespanRememberMe: + type: integer + format: int32 + supportedLocales: + type: array + items: + type: string + userFederationMappers: + type: array + items: + "$ref": "#/components/schemas/UserFederationMapperRepresentation" + userFederationProviders: + type: array + items: + "$ref": "#/components/schemas/UserFederationProviderRepresentation" + userManagedAccessAllowed: + type: boolean + users: + type: array + items: + "$ref": "#/components/schemas/UserRepresentation" + verifyEmail: + type: boolean + waitIncrementSeconds: + type: integer + format: int32 + webAuthnPolicyAcceptableAaguids: + type: array + items: + type: string + webAuthnPolicyAttestationConveyancePreference: + type: string + webAuthnPolicyAuthenticatorAttachment: + type: string + webAuthnPolicyAvoidSameAuthenticatorRegister: + type: boolean + webAuthnPolicyCreateTimeout: + type: integer + format: int32 + webAuthnPolicyPasswordlessAcceptableAaguids: + type: array + items: + type: string + webAuthnPolicyPasswordlessAttestationConveyancePreference: + type: string + webAuthnPolicyPasswordlessAuthenticatorAttachment: + type: string + webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister: + type: boolean + webAuthnPolicyPasswordlessCreateTimeout: + type: integer + format: int32 + webAuthnPolicyPasswordlessRequireResidentKey: + type: string + webAuthnPolicyPasswordlessRpEntityName: + type: string + webAuthnPolicyPasswordlessRpId: + type: string + webAuthnPolicyPasswordlessSignatureAlgorithms: + type: array + items: + type: string + webAuthnPolicyPasswordlessUserVerificationRequirement: + type: string + webAuthnPolicyRequireResidentKey: + type: string + webAuthnPolicyRpEntityName: + type: string + webAuthnPolicyRpId: + type: string + webAuthnPolicySignatureAlgorithms: + type: array + items: + type: string + webAuthnPolicyUserVerificationRequirement: + type: string + RequiredActionProviderRepresentation: + type: object + properties: + alias: + type: string + config: + type: object + additionalProperties: true + defaultAction: + type: boolean + enabled: + type: boolean + name: + type: string + priority: + type: integer + format: int32 + providerId: + type: string + ResourceRepresentation: + type: object + properties: + id: + type: string + attributes: + type: object + additionalProperties: true + displayName: + type: string + icon_uri: + type: string + name: + type: string + ownerManagedAccess: + type: boolean + scopes: + type: array + items: + "$ref": "#/components/schemas/ScopeRepresentation" + type: + type: string + uris: + type: array + items: + type: string + ResourceServerRepresentation: + type: object + properties: + allowRemoteResourceManagement: + type: boolean + clientId: + type: string + decisionStrategy: + type: string + enum: + - AFFIRMATIVE + - UNANIMOUS + - CONSENSUS + id: + type: string + name: + type: string + policies: + type: array + items: + "$ref": "#/components/schemas/PolicyRepresentation" + policyEnforcementMode: + type: string + enum: + - ENFORCING + - PERMISSIVE + - DISABLED + resources: + type: array + items: + "$ref": "#/components/schemas/ResourceRepresentation" + scopes: + type: array + items: + "$ref": "#/components/schemas/ScopeRepresentation" + RoleRepresentation: + type: object + properties: + attributes: + type: object + additionalProperties: true + clientRole: + type: boolean + composite: + type: boolean + composites: + "$ref": "#/components/schemas/RoleRepresentation-Composites" + containerId: + type: string + description: + type: string + id: + type: string + name: + type: string + RoleRepresentation-Composites: + type: object + properties: + client: + type: object + additionalProperties: true + realm: + type: array + items: + type: string + RolesRepresentation: + type: object + properties: + client: + type: object + additionalProperties: true + realm: + type: array + items: + "$ref": "#/components/schemas/RoleRepresentation" + ScopeMappingRepresentation: + type: object + properties: + client: + type: string + clientScope: + type: string + roles: + type: array + items: + type: string + self: + type: string + ScopeRepresentation: + type: object + properties: + displayName: + type: string + iconUri: + type: string + id: + type: string + name: + type: string + policies: + type: array + items: + "$ref": "#/components/schemas/PolicyRepresentation" + resources: + type: array + items: + "$ref": "#/components/schemas/ResourceRepresentation" + ServerInfoRepresentation: + type: object + properties: + builtinProtocolMappers: + type: object + additionalProperties: true + clientImporters: + type: array + items: + type: object + additionalProperties: true + clientInstallations: + type: object + additionalProperties: true + componentTypes: + type: object + additionalProperties: true + enums: + type: object + additionalProperties: true + identityProviders: + type: array + items: + type: object + additionalProperties: true + memoryInfo: + "$ref": "#/components/schemas/MemoryInfoRepresentation" + passwordPolicies: + type: array + items: + "$ref": "#/components/schemas/PasswordPolicyTypeRepresentation" + profileInfo: + "$ref": "#/components/schemas/ProfileInfoRepresentation" + protocolMapperTypes: + type: object + additionalProperties: true + providers: + type: object + additionalProperties: true + socialProviders: + type: array + items: + type: object + additionalProperties: true + systemInfo: + "$ref": "#/components/schemas/SystemInfoRepresentation" + themes: + type: object + additionalProperties: true + SpiInfoRepresentation: + type: object + properties: + internal: + type: boolean + providers: + type: object + additionalProperties: true + SynchronizationResult: + type: object + properties: + added: + type: integer + format: int32 + failed: + type: integer + format: int32 + ignored: + type: boolean + removed: + type: integer + format: int32 + status: + type: string + updated: + type: integer + format: int32 + SystemInfoRepresentation: + type: object + properties: + fileEncoding: + type: string + javaHome: + type: string + javaRuntime: + type: string + javaVendor: + type: string + javaVersion: + type: string + javaVm: + type: string + javaVmVersion: + type: string + osArchitecture: + type: string + osName: + type: string + osVersion: + type: string + serverTime: + type: string + uptime: + type: string + uptimeMillis: + type: integer + format: int64 + userDir: + type: string + userLocale: + type: string + userName: + type: string + userTimezone: + type: string + version: + type: string + TestLdapConnectionRepresentation: + type: object + properties: + action: + type: string + authType: + type: string + bindCredential: + type: string + bindDn: + type: string + componentId: + type: string + connectionTimeout: + type: string + connectionUrl: + type: string + startTls: + type: string + useTruststoreSpi: + type: string + UserConsentRepresentation: + type: object + properties: + clientId: + type: string + createdDate: + type: integer + format: int64 + grantedClientScopes: + type: array + items: + type: string + lastUpdatedDate: + type: integer + format: int64 + UserFederationMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + federationMapperType: + type: string + federationProviderDisplayName: + type: string + id: + type: string + name: + type: string + UserFederationProviderRepresentation: + type: object + properties: + changedSyncPeriod: + type: integer + format: int32 + config: + type: object + additionalProperties: true + displayName: + type: string + fullSyncPeriod: + type: integer + format: int32 + id: + type: string + lastSync: + type: integer + format: int32 + priority: + type: integer + format: int32 + providerName: + type: string + UserRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + attributes: + type: object + additionalProperties: true + clientConsents: + type: array + items: + "$ref": "#/components/schemas/UserConsentRepresentation" + clientRoles: + type: object + additionalProperties: true + createdTimestamp: + type: integer + format: int64 + credentials: + type: array + items: + "$ref": "#/components/schemas/CredentialRepresentation" + disableableCredentialTypes: + type: array + items: + type: string + email: + type: string + emailVerified: + type: boolean + enabled: + type: boolean + federatedIdentities: + type: array + items: + "$ref": "#/components/schemas/FederatedIdentityRepresentation" + federationLink: + type: string + firstName: + type: string + groups: + type: array + items: + type: string + id: + type: string + lastName: + type: string + notBefore: + type: integer + format: int32 + origin: + type: string + realmRoles: + type: array + items: + type: string + requiredActions: + type: array + items: + type: string + self: + type: string + serviceAccountClientId: + type: string + username: + type: string +security: +- access_token: [] +externalDocs: + description: Schema source code + url: https://github.com/keycloak/keycloak/tree/6.0.1/core/src/main/java/org/keycloak/representations diff --git a/backend/keycloak/openapi.yaml b/backend/keycloak/openapi.yaml new file mode 100644 index 0000000..d414bf5 --- /dev/null +++ b/backend/keycloak/openapi.yaml @@ -0,0 +1,9318 @@ +openapi: 3.0.2 +info: + version: 1.0.0 + title: Keycloak Admin REST API + license: + name: MIT + +paths: + /: + get: + tags: + - Root + summary: Get themes, social providers, auth providers, and event listeners available + on this server + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ServerInfoRepresentation' + post: + tags: + - Realms Admin + summary: Import a realm Imports a realm from a full representation of that + realm. + requestBody: + description: JSON representation of the realm + content: + application/json: + schema: + $ref: '#/components/schemas/RealmRepresentation' + required: true + responses: + 2XX: + description: success + /{id}/name: + get: + tags: + - User Storage Provider + summary: Need this for admin console to display simple name of provider when + displaying client detail KEYCLOAK-4328 + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}: + get: + tags: + - Realms Admin + summary: Get the top-level representation of the realm It will not include + nested information like User and Client representations. + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RealmRepresentation' + put: + tags: + - Realms Admin + summary: Update the top-level information of the realm Any user, roles or + client information in the representation will be ignored. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RealmRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + summary: Delete the realm + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/admin-events: + get: + tags: + - Realms Admin + summary: Get admin events Returns all admin events, or filters events based + on URL query parameters listed here + parameters: + - in: query + name: authClient + schema: + type: string + style: form + - in: query + name: authIpAddress + schema: + type: string + style: form + - in: query + name: authRealm + schema: + type: string + style: form + - in: query + name: authUser + description: user id + schema: + type: string + style: form + - in: query + name: dateFrom + schema: + type: string + style: form + - in: query + name: dateTo + schema: + type: string + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: operationTypes + schema: + type: array + items: + type: string + style: form + - in: query + name: resourcePath + schema: + type: string + style: form + - in: query + name: resourceTypes + schema: + type: array + items: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + delete: + tags: + - Realms Admin + summary: Delete all admin events + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/attack-detection/brute-force/users: + delete: + tags: + - Attack Detection + summary: Clear any user login failures for all users This can release temporary + disabled users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/attack-detection/brute-force/users/{userId}: + get: + tags: + - Attack Detection + summary: Get status of a username in brute force detection + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + delete: + tags: + - Attack Detection + summary: Clear any user login failures for the user This can release temporary + disabled user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: userId + required: true + schema: + type: string + style: simple + /{realm}/authentication/authenticator-providers: + get: + tags: + - Authentication Management + summary: Get authenticator providers Returns a stream of authenticator providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/client-authenticator-providers: + get: + tags: + - Authentication Management + summary: Get client authenticator providers Returns a stream of client authenticator + providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/config-description/{providerId}: + get: + tags: + - Authentication Management + summary: Get authenticator provider’s configuration description + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorConfigInfoRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: providerId + required: true + schema: + type: string + style: simple + /{realm}/authentication/config/{id}: + get: + tags: + - Authentication Management + summary: Get authenticator configuration + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorConfigRepresentation' + put: + tags: + - Authentication Management + summary: Update authenticator configuration + requestBody: + description: JSON describing new state of authenticator configuration + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorConfigRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete authenticator configuration + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Configuration id + required: true + schema: + type: string + style: simple + /{realm}/authentication/executions: + post: + tags: + - Authentication Management + summary: Add new authentication execution + requestBody: + description: JSON model describing authentication execution + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticationExecutionRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/executions/{executionId}: + get: + tags: + - Authentication Management + summary: Get Single Execution + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete execution + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + /{realm}/authentication/executions/{executionId}/config: + post: + tags: + - Authentication Management + summary: Update execution with new configuration + requestBody: + description: JSON with new configuration + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticatorConfigRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + /{realm}/authentication/executions/{executionId}/lower-priority: + post: + tags: + - Authentication Management + summary: Lower execution’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + /{realm}/authentication/executions/{executionId}/raise-priority: + post: + tags: + - Authentication Management + summary: Raise execution’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: executionId + description: Execution id + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows: + get: + tags: + - Authentication Management + summary: Get authentication flows Returns a stream of authentication flows. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Authentication Management + summary: Create a new authentication flow + requestBody: + description: Authentication flow representation + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticationFlowRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows/{flowAlias}/copy: + post: + tags: + - Authentication Management + summary: Copy existing authentication flow under a new name The new name is + given as 'newName' attribute of the passed JSON object + requestBody: + description: JSON containing 'newName' attribute + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Name of the existing authentication flow + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows/{flowAlias}/executions: + get: + tags: + - Authentication Management + summary: Get authentication executions for a flow + responses: + 2XX: + description: success + put: + tags: + - Authentication Management + summary: Update authentication executions of a Flow + requestBody: + description: AuthenticationExecutionInfoRepresentation + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticationExecutionInfoRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Flow alias + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows/{flowAlias}/executions/execution: + post: + tags: + - Authentication Management + summary: Add new authentication execution to a flow + requestBody: + description: New execution JSON data containing 'provider' attribute + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Alias of parent flow + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows/{flowAlias}/executions/flow: + post: + tags: + - Authentication Management + summary: Add new flow with new execution to existing flow + requestBody: + description: New authentication flow / execution JSON data containing 'alias', + 'type', 'provider', and 'description' attributes + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: flowAlias + description: Alias of parent authentication flow + required: true + schema: + type: string + style: simple + /{realm}/authentication/flows/{id}: + get: + tags: + - Authentication Management + summary: Get authentication flow for id + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticationFlowRepresentation' + put: + tags: + - Authentication Management + summary: Update an authentication flow + requestBody: + description: Authentication flow representation + content: + application/json: + schema: + $ref: '#/components/schemas/AuthenticationFlowRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete an authentication flow + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Flow id + required: true + schema: + type: string + style: simple + /{realm}/authentication/form-action-providers: + get: + tags: + - Authentication Management + summary: Get form action providers Returns a stream of form action providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/form-providers: + get: + tags: + - Authentication Management + summary: Get form providers Returns a stream of form providers. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/per-client-config-description: + get: + tags: + - Authentication Management + summary: Get configuration descriptions for all clients + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/register-required-action: + post: + tags: + - Authentication Management + summary: Register a new required actions + requestBody: + description: JSON containing 'providerId', and 'name' attributes. + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/required-actions: + get: + tags: + - Authentication Management + summary: Get required actions Returns a stream of required actions. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/authentication/required-actions/{alias}: + get: + tags: + - Authentication Management + summary: Get required action for alias + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RequiredActionProviderRepresentation' + put: + tags: + - Authentication Management + summary: Update required action + requestBody: + description: JSON describing new state of required action + content: + application/json: + schema: + $ref: '#/components/schemas/RequiredActionProviderRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Authentication Management + summary: Delete required action + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + /{realm}/authentication/required-actions/{alias}/lower-priority: + post: + tags: + - Authentication Management + summary: Lower required action’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + /{realm}/authentication/required-actions/{alias}/raise-priority: + post: + tags: + - Authentication Management + summary: Raise required action’s priority + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + description: Alias of required action + required: true + schema: + type: string + style: simple + /{realm}/authentication/unregistered-required-actions: + get: + tags: + - Authentication Management + summary: Get unregistered required actions Returns a stream of unregistered + required actions. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clear-keys-cache: + post: + tags: + - Realms Admin + summary: Clear cache of external public keys (Public keys of clients or Identity + providers) + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clear-realm-cache: + post: + tags: + - Realms Admin + summary: Clear realm cache + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clear-user-cache: + post: + tags: + - Realms Admin + summary: Clear user cache + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-description-converter: + post: + tags: + - Realms Admin + summary: Base path for importing clients under this realm. + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-policies/policies: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientPoliciesRepresentation' + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientPoliciesRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-policies/profiles: + get: + tags: + - Realms Admin + parameters: + - in: query + name: include-global-profiles + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientProfilesRepresentation' + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientProfilesRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-registration-policy/providers: + get: + tags: + - Client Registration Policy + summary: Base path for retrieve providers with the configProperties properly + filled + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes: + get: + tags: + - Client Scopes + summary: Get client scopes belonging to the realm Returns a list of client + scopes belonging to the realm + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Scopes + summary: Create a new client scope Client Scope’s name must be unique! + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientScopeRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id1}/protocol-mappers/models/{id2}: + get: + tags: + - Protocol Mappers + summary: Get mapper by id + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + put: + tags: + - Protocol Mappers + summary: Update the mapper + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Protocol Mappers + summary: Delete the mapper + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id1 + required: true + schema: + type: string + style: simple + - in: path + name: id2 + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}: + get: + tags: + - Client Scopes + summary: Get representation of the client scope + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientScopeRepresentation' + put: + tags: + - Client Scopes + summary: Update the client scope + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientScopeRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Scopes + summary: Delete the client scope + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/protocol-mappers/add-models: + post: + tags: + - Protocol Mappers + summary: Create multiple mappers + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/protocol-mappers/models: + get: + tags: + - Protocol Mappers + summary: Get mappers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Protocol Mappers + summary: Create a mapper + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/protocol-mappers/protocol/{protocol}: + get: + tags: + - Protocol Mappers + summary: Get mappers by name for a specific protocol + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: protocol + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/clients/{client}: + get: + tags: + - Scope Mappings + summary: Get the roles associated with a client’s scope Returns roles for + the client. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add client-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove client-level roles from the client’s scope. + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/clients/{client}/available: + get: + tags: + - Scope Mappings + summary: The available client-level roles Returns the roles for the client + that can be associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/clients/{client}/composite: + get: + tags: + - Scope Mappings + summary: Get effective client roles Returns the roles for the client that + are associated with the client’s scope. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/realm: + get: + tags: + - Scope Mappings + summary: Get realm-level roles associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add a set of realm-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove a set of realm-level roles from the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/realm/available: + get: + tags: + - Scope Mappings + summary: Get realm-level roles that are available to attach to this client’s + scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-scopes/{id}/scope-mappings/realm/composite: + get: + tags: + - Scope Mappings + summary: Get effective realm-level roles associated with the client’s scope What + this does is recurse any composite roles associated with the client’s scope + and adds the roles to this lists. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client scope (not name) + required: true + schema: + type: string + style: simple + /{realm}/client-session-stats: + get: + tags: + - Realms Admin + summary: Get client session stats Returns a JSON map. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients: + get: + tags: + - Clients + summary: Get clients belonging to the realm. + parameters: + - in: query + name: clientId + description: filter by clientId + schema: + type: string + style: form + - in: query + name: first + description: the first result + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: the max results to return + schema: + type: integer + format: int32 + style: form + - in: query + name: q + schema: + type: string + style: form + - in: query + name: search + description: whether this is a search query or a getClientById query + schema: + type: boolean + style: form + - in: query + name: viewableOnly + description: filter clients that cannot be viewed in full by admin + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Clients + summary: Create a new client Client’s client_id must be unique! + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients-initial-access: + get: + tags: + - Client Initial Access + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Initial Access + summary: Create a new initial access token. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientInitialAccessCreatePresentation' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientInitialAccessPresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients-initial-access/{id}: + delete: + tags: + - Client Initial Access + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/clients/{id1}/protocol-mappers/models/{id2}: + get: + tags: + - Protocol Mappers + summary: Get mapper by id + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + put: + tags: + - Protocol Mappers + summary: Update the mapper + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Protocol Mappers + summary: Delete the mapper + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id1 + required: true + schema: + type: string + style: simple + - in: path + name: id2 + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}: + get: + tags: + - Clients + summary: Get representation of the client + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientRepresentation' + put: + tags: + - Clients + summary: Update the client + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ClientRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Clients + summary: Delete the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}: + get: + tags: + - Client Attribute Certificate + summary: Get key info + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}/download: + post: + tags: + - Client Attribute Certificate + summary: Get a keystore file for the client, containing private key and public + certificate + requestBody: + description: Keystore configuration as JSON + content: + application/json: + schema: + $ref: '#/components/schemas/KeyStoreConfig' + required: true + responses: + 2XX: + description: success + content: + application/octet-stream: + schema: + type: string + format: byte + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}/generate: + post: + tags: + - Client Attribute Certificate + summary: Generate a new certificate with new key pair + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}/generate-and-download: + post: + tags: + - Client Attribute Certificate + summary: Generate a new keypair and certificate, and get the private key file Generates + a keypair and certificate and serves the private key in a specified keystore + format. + requestBody: + description: Keystore configuration as JSON + content: + application/json: + schema: + $ref: '#/components/schemas/KeyStoreConfig' + required: true + responses: + 2XX: + description: success + content: + application/octet-stream: + schema: + type: string + format: byte + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}/upload: + post: + tags: + - Client Attribute Certificate + summary: Upload certificate and eventually private key + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/certificates/{attr}/upload-certificate: + post: + tags: + - Client Attribute Certificate + summary: Upload only certificate, not private key + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CertificateRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: attr + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/client-secret: + get: + tags: + - Clients + summary: Get the client secret + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CredentialRepresentation' + post: + tags: + - Clients + summary: Generate a new secret for the client + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CredentialRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/client-secret/rotated: + get: + tags: + - Clients + summary: Get the rotated client secret + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/CredentialRepresentation' + delete: + tags: + - Clients + summary: Invalidate the rotated secret for the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/default-client-scopes: + get: + tags: + - Clients + summary: Get default client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/default-client-scopes/{clientScopeId}: + put: + tags: + - Clients + responses: + 2XX: + description: success + delete: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/generate-example-access-token: + get: + tags: + - Clients + summary: Create JSON with payload of example access token + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/AccessToken' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/generate-example-id-token: + get: + tags: + - Clients + summary: Create JSON with payload of example id token + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/IDToken' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/generate-example-userinfo: + get: + tags: + - Clients + summary: Create JSON with payload of example user info + parameters: + - in: query + name: scope + schema: + type: string + style: form + - in: query + name: userId + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/protocol-mappers: + get: + tags: + - Clients + summary: Return list of all protocol mappers, which will be used when generating + tokens issued for particular client. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/granted: + get: + tags: + - Clients + summary: Get effective scope mapping of all roles of particular role container, + which this client is defacto allowed to have in the accessToken issued for + him. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: roleContainerId + description: either realm name OR client UUID + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/evaluate-scopes/scope-mappings/{roleContainerId}/not-granted: + get: + tags: + - Clients + summary: Get roles, which this client doesn’t have scope for and can’t have + them in the accessToken issued for him. + parameters: + - in: query + name: scope + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: roleContainerId + description: either realm name OR client UUID + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/installation/providers/{providerId}: + get: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: providerId + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/management/permissions: + get: + tags: + - Clients + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Clients + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/nodes: + post: + tags: + - Clients + summary: Register a cluster node with the client Manually register cluster + node to this client - usually it’s not needed to call this directly as adapter + should handle by sending registration request to Keycloak + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/nodes/{node}: + delete: + tags: + - Clients + summary: Unregister a cluster node from the client + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: node + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/offline-session-count: + get: + tags: + - Clients + summary: 'Get application offline session count Returns a number of offline + user sessions associated with this client { "count": number }' + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/offline-sessions: + get: + tags: + - Clients + summary: Get offline sessions for client Returns a list of offline user sessions + associated with this client + parameters: + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/optional-client-scopes: + get: + tags: + - Clients + summary: Get optional client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/optional-client-scopes/{clientScopeId}: + put: + tags: + - Clients + responses: + 2XX: + description: success + delete: + tags: + - Clients + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/protocol-mappers/add-models: + post: + tags: + - Protocol Mappers + summary: Create multiple mappers + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/protocol-mappers/models: + get: + tags: + - Protocol Mappers + summary: Get mappers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Protocol Mappers + summary: Create a mapper + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/protocol-mappers/protocol/{protocol}: + get: + tags: + - Protocol Mappers + summary: Get mappers by name for a specific protocol + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: protocol + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/push-revocation: + post: + tags: + - Clients + summary: Push the client’s revocation policy to its admin URL If the client + has an admin URL, push revocation policy to it. + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/GlobalRequestResult' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/registration-access-token: + post: + tags: + - Clients + summary: Generate a new registration access token for the client + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ClientRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles: + get: + tags: + - Roles + summary: Get all roles for the realm or client + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Create a new role for the realm or client + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}: + get: + tags: + - Roles + summary: Get a role by name + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + put: + tags: + - Roles + summary: Update a role by name + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Delete a role by name + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/composites: + get: + tags: + - Roles + summary: Get composites of the role + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Add a composite to the role + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Remove roles from the role’s composite + requestBody: + description: roles to remove + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/composites/clients/{clientUuid}: + get: + tags: + - Roles + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/composites/realm: + get: + tags: + - Roles + summary: Get realm-level roles of the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/groups: + get: + tags: + - Roles + summary: Returns a stream of groups that have the specified role name + parameters: + - in: query + name: briefRepresentation + description: if false, return a full representation of the {@code GroupRepresentation} + objects. + schema: + type: boolean + style: form + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or + {@code null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/management/permissions: + get: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/roles/{role-name}/users: + get: + tags: + - Roles + summary: Returns a stream of users that have the specified role name. + parameters: + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or + {@code null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/clients/{client}: + get: + tags: + - Scope Mappings + summary: Get the roles associated with a client’s scope Returns roles for + the client. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add client-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove client-level roles from the client’s scope. + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/clients/{client}/available: + get: + tags: + - Scope Mappings + summary: The available client-level roles Returns the roles for the client + that can be associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/clients/{client}/composite: + get: + tags: + - Scope Mappings + summary: Get effective client roles Returns the roles for the client that + are associated with the client’s scope. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/realm: + get: + tags: + - Scope Mappings + summary: Get realm-level roles associated with the client’s scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Scope Mappings + summary: Add a set of realm-level roles to the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Scope Mappings + summary: Remove a set of realm-level roles from the client’s scope + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/realm/available: + get: + tags: + - Scope Mappings + summary: Get realm-level roles that are available to attach to this client’s + scope + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/scope-mappings/realm/composite: + get: + tags: + - Scope Mappings + summary: Get effective realm-level roles associated with the client’s scope What + this does is recurse any composite roles associated with the client’s scope + and adds the roles to this lists. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/service-account-user: + get: + tags: + - Clients + summary: Get a user dedicated to the service account + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/UserRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/session-count: + get: + tags: + - Clients + summary: 'Get application session count Returns a number of user sessions + associated with this client { "count": number }' + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/test-nodes-available: + get: + tags: + - Clients + summary: Test if registered cluster nodes are available Tests availability + by sending 'ping' request to all cluster nodes. + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/GlobalRequestResult' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/clients/{id}/user-sessions: + get: + tags: + - Clients + summary: Get user sessions for client Returns a list of user sessions associated + with this client + parameters: + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: id of client (not client-id) + required: true + schema: + type: string + style: simple + /{realm}/components: + get: + tags: + - Component + parameters: + - in: query + name: name + schema: + type: string + style: form + - in: query + name: parent + schema: + type: string + style: form + - in: query + name: type + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Component + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ComponentRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/components/{id}: + get: + tags: + - Component + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ComponentRepresentation' + put: + tags: + - Component + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ComponentRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Component + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/components/{id}/sub-component-types: + get: + tags: + - Component + summary: List of subcomponent types that are available to configure for a particular + parent component. + parameters: + - in: query + name: type + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/credential-registrators: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/default-default-client-scopes: + get: + tags: + - Realms Admin + summary: Get realm default client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/default-default-client-scopes/{clientScopeId}: + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + /{realm}/default-groups: + get: + tags: + - Realms Admin + summary: Get group hierarchy. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/default-groups/{groupId}: + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: groupId + required: true + schema: + type: string + style: simple + /{realm}/default-optional-client-scopes: + get: + tags: + - Realms Admin + summary: Get realm optional client scopes. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/default-optional-client-scopes/{clientScopeId}: + put: + tags: + - Realms Admin + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientScopeId + required: true + schema: + type: string + style: simple + /{realm}/events: + get: + tags: + - Realms Admin + summary: Get events Returns all events, or filters them based on URL query + parameters listed here + parameters: + - in: query + name: client + description: App or oauth client name + schema: + type: string + style: form + - in: query + name: dateFrom + description: From date + schema: + type: string + style: form + - in: query + name: dateTo + description: To date + schema: + type: string + style: form + - in: query + name: first + description: Paging offset + schema: + type: integer + format: int32 + style: form + - in: query + name: ipAddress + description: IP address + schema: + type: string + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: type + description: The types of events to return + schema: + type: array + items: + type: string + style: form + - in: query + name: user + description: User id + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + delete: + tags: + - Realms Admin + summary: Delete all events + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/events/config: + get: + tags: + - Realms Admin + summary: Get the events provider configuration Returns JSON object with events + provider configuration + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RealmEventsConfigRepresentation' + put: + tags: + - Realms Admin + summary: Update the events provider Change the events provider and/or its + configuration + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RealmEventsConfigRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/group-by-path/{path}: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: path + required: true + schema: + type: string + style: simple + /{realm}/groups: + get: + tags: + - Groups + summary: Get group hierarchy. + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Groups + summary: create or add a top level realm groupSet or create child. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/groups/count: + get: + tags: + - Groups + summary: Returns the groups counts. + parameters: + - in: query + name: search + schema: + type: string + style: form + - in: query + name: top + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}: + get: + tags: + - Groups + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRepresentation' + put: + tags: + - Groups + summary: Update group, ignores subgroups. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Groups + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/children: + post: + tags: + - Groups + summary: Set or create child. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/GroupRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/management/permissions: + get: + tags: + - Groups + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Groups + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/members: + get: + tags: + - Groups + summary: Get users Returns a stream of users, filtered according to query + parameters + parameters: + - in: query + name: briefRepresentation + description: "Only return basic information (only guaranteed to return id,\ + \ username, created, first and last name,\n email, enabled state, email\ + \ verification state, federation link, and access.\n Note that it means\ + \ that namely user attributes, required actions, and not before are not\ + \ returned.)" + schema: + type: boolean + style: form + - in: query + name: first + description: Pagination offset + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings: + get: + tags: + - Role Mapper + summary: Get role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/MappingsRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/clients/{client}: + get: + tags: + - Client Role Mappings + summary: Get client-level role mappings for the user, and the app + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Role Mappings + summary: Add client-level roles to the user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Role Mappings + summary: Delete client-level roles from user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/clients/{client}/available: + get: + tags: + - Client Role Mappings + summary: Get available client-level roles that can be mapped to the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/clients/{client}/composite: + get: + tags: + - Client Role Mappings + summary: Get effective client-level role mappings This recurses any composite + roles + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/realm: + get: + tags: + - Role Mapper + summary: Get realm-level role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Role Mapper + summary: Add realm-level role mappings to the user + requestBody: + description: Roles to add + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Role Mapper + summary: Delete realm-level role mappings + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/realm/available: + get: + tags: + - Role Mapper + summary: Get realm-level roles that can be mapped + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/groups/{id}/role-mappings/realm/composite: + get: + tags: + - Role Mapper + summary: Get effective realm-level role mappings This will recurse all composite + roles to get the result. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/import-config: + post: + tags: + - Identity Providers + summary: Import identity provider from uploaded JSON file + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances: + get: + tags: + - Identity Providers + summary: Get identity providers + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Identity Providers + summary: Create a new identity provider + requestBody: + description: JSON body + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}: + get: + tags: + - Identity Providers + summary: Get the identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderRepresentation' + put: + tags: + - Identity Providers + summary: Update the identity provider + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Identity Providers + summary: Delete the identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}/export: + get: + tags: + - Identity Providers + summary: Export public broker configuration for identity provider + parameters: + - in: query + name: format + description: Format to use + schema: + type: string + style: form + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}/management/permissions: + get: + tags: + - Identity Providers + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Identity Providers + summary: Return object stating whether client Authorization permissions have + been initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}/mapper-types: + get: + tags: + - Identity Providers + summary: Get mapper types for identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}/mappers: + get: + tags: + - Identity Providers + summary: Get mappers for identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Identity Providers + summary: Add a mapper to identity provider + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderMapperRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/instances/{alias}/mappers/{id}: + get: + tags: + - Identity Providers + summary: Get mapper by id for the identity provider + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderMapperRepresentation' + put: + tags: + - Identity Providers + summary: Update a mapper for the identity provider + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/IdentityProviderMapperRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Identity Providers + summary: Delete a mapper for the identity provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: alias + required: true + schema: + type: string + style: simple + - in: path + name: id + description: Mapper id + required: true + schema: + type: string + style: simple + /{realm}/identity-provider/providers/{provider_id}: + get: + tags: + - Identity Providers + summary: Get identity providers + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: provider_id + description: Provider id + required: true + schema: + type: string + style: simple + /{realm}/keys: + get: + tags: + - Key + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/KeysMetadataRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/ldap-server-capabilities: + post: + tags: + - Realms Admin + summary: Get LDAP supported extensions. + requestBody: + description: LDAP configuration + content: + application/json: + schema: + $ref: '#/components/schemas/TestLdapConnectionRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/localization: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/localization/{locale}: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + post: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: locale + required: true + schema: + type: string + style: simple + /{realm}/localization/{locale}/{key}: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + text/plain: + schema: + type: string + put: + tags: + - Realms Admin + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + delete: + tags: + - Realms Admin + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: locale + required: true + schema: + type: string + style: simple + - in: path + name: key + required: true + schema: + type: string + style: simple + /{realm}/logout-all: + post: + tags: + - Realms Admin + summary: Removes all user sessions. + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/GlobalRequestResult' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/partial-export: + post: + tags: + - Realms Admin + summary: Partial export of existing realm into a JSON file. + parameters: + - in: query + name: exportClients + schema: + type: boolean + style: form + - in: query + name: exportGroupsAndRoles + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RealmRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/partialImport: + post: + tags: + - Realms Admin + summary: Partial import from a JSON file to an existing realm. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/PartialImportRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/push-revocation: + post: + tags: + - Realms Admin + summary: Push the realm’s revocation policy to any client that has an admin + url associated with it. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/roles: + get: + tags: + - Roles + summary: Get all roles for the realm or client + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Create a new role for the realm or client + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/roles-by-id/{role-id}: + get: + tags: + - Roles (by ID) + summary: Get a specific role’s representation + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + put: + tags: + - Roles (by ID) + summary: Update the role + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles (by ID) + summary: Delete the role + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + description: id of role + required: true + schema: + type: string + style: simple + /{realm}/roles-by-id/{role-id}/composites: + get: + tags: + - Roles (by ID) + summary: Get role’s children Returns a set of role’s children provided the + role is a composite. + parameters: + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles (by ID) + summary: Make the role a composite role by associating some child roles + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles (by ID) + summary: Remove a set of roles from the role’s composite + requestBody: + description: A set of roles to be removed + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + description: Role id + required: true + schema: + type: string + style: simple + /{realm}/roles-by-id/{role-id}/composites/clients/{clientUuid}: + get: + tags: + - Roles (by ID) + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + /{realm}/roles-by-id/{role-id}/composites/realm: + get: + tags: + - Roles (by ID) + summary: Get realm-level roles that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + /{realm}/roles-by-id/{role-id}/management/permissions: + get: + tags: + - Roles (by ID) + summary: Return object stating whether role Authoirzation permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Roles (by ID) + summary: Return object stating whether role Authoirzation permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-id + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}: + get: + tags: + - Roles + summary: Get a role by name + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + put: + tags: + - Roles + summary: Update a role by name + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Delete a role by name + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/composites: + get: + tags: + - Roles + summary: Get composites of the role + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Roles + summary: Add a composite to the role + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Roles + summary: Remove roles from the role’s composite + requestBody: + description: roles to remove + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/composites/clients/{clientUuid}: + get: + tags: + - Roles + summary: Get client-level roles for the client that are in the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/composites/realm: + get: + tags: + - Roles + summary: Get realm-level roles of the role’s composite + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: role’s name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/groups: + get: + tags: + - Roles + summary: Returns a stream of groups that have the specified role name + parameters: + - in: query + name: briefRepresentation + description: if false, return a full representation of the {@code GroupRepresentation} + objects. + schema: + type: boolean + style: form + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or + {@code null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/management/permissions: + get: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Roles + summary: Return object stating whether role Authorization permissions have been + initialized or not and a reference + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + required: true + schema: + type: string + style: simple + /{realm}/roles/{role-name}/users: + get: + tags: + - Roles + summary: Returns a stream of users that have the specified role name. + parameters: + - in: query + name: first + description: first result to return. Ignored if negative or {@code null}. + schema: + type: integer + format: int32 + style: form + - in: query + name: max + description: maximum number of results to return. Ignored if negative or + {@code null}. + schema: + type: integer + format: int32 + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: role-name + description: the role name. + required: true + schema: + type: string + style: simple + /{realm}/sessions/{session}: + delete: + tags: + - Realms Admin + summary: Remove a specific user session. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: session + required: true + schema: + type: string + style: simple + /{realm}/testLDAPConnection: + post: + tags: + - Realms Admin + summary: Test LDAP connection + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/TestLdapConnectionRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/testSMTPConnection: + post: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + type: object + additionalProperties: true + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/user-storage/{id}/name: + get: + tags: + - User Storage Provider + summary: Need this for admin console to display simple name of provider when + displaying user detail KEYCLOAK-4328 + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/user-storage/{id}/remove-imported-users: + post: + tags: + - User Storage Provider + summary: Remove imported users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/user-storage/{id}/sync: + post: + tags: + - User Storage Provider + summary: Trigger sync of users Action can be "triggerFullSync" or "triggerChangedUsersSync" + parameters: + - in: query + name: action + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/SynchronizationResult' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/user-storage/{id}/unlink-users: + post: + tags: + - User Storage Provider + summary: Unlink imported users from a storage provider + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/user-storage/{parentId}/mappers/{id}/sync: + post: + tags: + - User Storage Provider + summary: Trigger sync of mapper data related to ldap mapper (roles, groups, + …​) direction is "fedToKeycloak" or "keycloakToFed" + parameters: + - in: query + name: direction + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/SynchronizationResult' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: parentId + required: true + schema: + type: string + style: simple + - in: path + name: id + required: true + schema: + type: string + style: simple + /{realm}/users: + get: + tags: + - Users + summary: Get users Returns a stream of users, filtered according to query + parameters. + parameters: + - in: query + name: briefRepresentation + description: 'Boolean which defines whether brief representations are returned + (default: false)' + schema: + type: boolean + style: form + - in: query + name: email + description: A String contained in email, or the complete email, if param + "exact" is true + schema: + type: string + style: form + - in: query + name: emailVerified + description: whether the email has been verified + schema: + type: boolean + style: form + - in: query + name: enabled + description: Boolean representing if user is enabled or not + schema: + type: boolean + style: form + - in: query + name: exact + description: Boolean which defines whether the params "last", "first", "email" + and "username" must match exactly + schema: + type: boolean + style: form + - in: query + name: first + description: Pagination offset + schema: + type: integer + format: int32 + style: form + - in: query + name: firstName + description: A String contained in firstName, or the complete firstName, + if param "exact" is true + schema: + type: string + style: form + - in: query + name: idpAlias + description: The alias of an Identity Provider linked to the user + schema: + type: string + style: form + - in: query + name: idpUserId + description: The userId at an Identity Provider linked to the user + schema: + type: string + style: form + - in: query + name: lastName + description: A String contained in lastName, or the complete lastName, if + param "exact" is true + schema: + type: string + style: form + - in: query + name: max + description: Maximum results size (defaults to 100) + schema: + type: integer + format: int32 + style: form + - in: query + name: q + description: A query to search for custom attributes, in the format 'key1:value2 + key2:value2' + schema: + type: string + style: form + - in: query + name: search + description: A String contained in username, first or last name, or email + schema: + type: string + style: form + - in: query + name: username + description: A String contained in username, or the complete username, if + param "exact" is true + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Users + summary: Create a new user Username must be unique. + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/users-management-permissions: + get: + tags: + - Realms Admin + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + put: + tags: + - Realms Admin + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + required: true + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/ManagementPermissionReference' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/users/count: + get: + tags: + - Users + summary: Returns the number of users that match the given criteria. + parameters: + - in: query + name: email + description: email filter + schema: + type: string + style: form + - in: query + name: emailVerified + schema: + type: boolean + style: form + - in: query + name: enabled + description: Boolean representing if user is enabled or not + schema: + type: boolean + style: form + - in: query + name: firstName + description: first name filter + schema: + type: string + style: form + - in: query + name: lastName + description: last name filter + schema: + type: string + style: form + - in: query + name: search + description: arbitrary search string for all the fields below + schema: + type: string + style: form + - in: query + name: username + description: username filter + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: integer + format: int32 + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/users/profile: + get: + tags: + - Users + responses: + 2XX: + description: success + content: + application/json: + schema: + type: string + put: + tags: + - Users + requestBody: + content: + application/json: + schema: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + /{realm}/users/{id}: + get: + tags: + - Users + summary: Get representation of the user + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/UserRepresentation' + put: + tags: + - Users + summary: Update the user + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/UserRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Users + summary: Delete the user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/configured-user-storage-credential-types: + get: + tags: + - Users + summary: Return credential types, which are provided by the user storage where + user is stored. + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/consents: + get: + tags: + - Users + summary: Get consents granted by the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/consents/{client}: + delete: + tags: + - Users + summary: Revoke consent and offline tokens for particular client from user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + description: Client id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/credentials: + get: + tags: + - Users + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/credentials/{credentialId}: + delete: + tags: + - Users + summary: Remove a credential for a user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/credentials/{credentialId}/moveAfter/{newPreviousCredentialId}: + post: + tags: + - Users + summary: Move a credential to a position behind another credential + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + description: The credential to move + required: true + schema: + type: string + style: simple + - in: path + name: newPreviousCredentialId + description: The credential that will be the previous element in the list. + If set to null, the moved credential will be the first element in the list. + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/credentials/{credentialId}/moveToFirst: + post: + tags: + - Users + summary: Move a credential to a first position in the credentials list of the + user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + description: The credential to move + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/credentials/{credentialId}/userLabel: + put: + tags: + - Users + summary: Update a credential label for a user + requestBody: + content: + text/plain: + schema: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: credentialId + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/disable-credential-types: + put: + tags: + - Users + summary: Disable all credentials for a user of a specific type + requestBody: + content: + application/json: + schema: + type: array + items: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/execute-actions-email: + put: + tags: + - Users + summary: Send a update account email to the user An email contains a link + the user can click to perform a set of required actions. + parameters: + - in: query + name: client_id + description: Client id + schema: + type: string + style: form + - in: query + name: lifespan + description: Number of seconds after which the generated token expires + schema: + type: integer + format: int32 + style: form + - in: query + name: redirect_uri + description: Redirect uri + schema: + type: string + style: form + requestBody: + description: required actions the user needs to complete + content: + application/json: + schema: + type: array + items: + type: string + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/federated-identity: + get: + tags: + - Users + summary: Get social logins associated with the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/federated-identity/{provider}: + post: + tags: + - Users + summary: Add a social login provider to the user + requestBody: + content: + application/json: + schema: + $ref: '#/components/schemas/FederatedIdentityRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Users + summary: Remove a social login provider from user + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: provider + description: Social login provider id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/groups: + get: + tags: + - Users + parameters: + - in: query + name: briefRepresentation + schema: + type: boolean + style: form + - in: query + name: first + schema: + type: integer + format: int32 + style: form + - in: query + name: max + schema: + type: integer + format: int32 + style: form + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/groups/count: + get: + tags: + - Users + parameters: + - in: query + name: search + schema: + type: string + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/groups/{groupId}: + put: + tags: + - Users + responses: + 2XX: + description: success + delete: + tags: + - Users + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: groupId + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/impersonation: + post: + tags: + - Users + summary: Impersonate the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/logout: + post: + tags: + - Users + summary: Remove all user sessions associated with the user Also send notification + to all clients that have an admin URL to invalidate the sessions for the particular + user. + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/offline-sessions/{clientUuid}: + get: + tags: + - Users + summary: Get offline sessions associated with the user and client + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: clientUuid + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/reset-password: + put: + tags: + - Users + summary: Set up a new password for the user. + requestBody: + description: The representation must contain a rawPassword with the plain-text + password + content: + application/json: + schema: + $ref: '#/components/schemas/CredentialRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings: + get: + tags: + - Role Mapper + summary: Get role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + $ref: '#/components/schemas/MappingsRepresentation' + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/clients/{client}: + get: + tags: + - Client Role Mappings + summary: Get client-level role mappings for the user, and the app + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Client Role Mappings + summary: Add client-level roles to the user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Client Role Mappings + summary: Delete client-level roles from user role mapping + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/clients/{client}/available: + get: + tags: + - Client Role Mappings + summary: Get available client-level roles that can be mapped to the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/clients/{client}/composite: + get: + tags: + - Client Role Mappings + summary: Get effective client-level role mappings This recurses any composite + roles + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + - in: path + name: client + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/realm: + get: + tags: + - Role Mapper + summary: Get realm-level role mappings + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + post: + tags: + - Role Mapper + summary: Add realm-level role mappings to the user + requestBody: + description: Roles to add + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + delete: + tags: + - Role Mapper + summary: Delete realm-level role mappings + requestBody: + content: + application/json: + schema: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + required: true + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/realm/available: + get: + tags: + - Role Mapper + summary: Get realm-level roles that can be mapped + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/role-mappings/realm/composite: + get: + tags: + - Role Mapper + summary: Get effective realm-level role mappings This will recurse all composite + roles to get the result. + parameters: + - in: query + name: briefRepresentation + description: if false, return roles with their attributes + schema: + type: boolean + style: form + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/send-verify-email: + put: + tags: + - Users + summary: Send an email-verification email to the user An email contains a + link the user can click to verify their email address. + parameters: + - in: query + name: client_id + description: Client id + schema: + type: string + style: form + - in: query + name: redirect_uri + description: Redirect uri + schema: + type: string + style: form + responses: + 2XX: + description: success + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple + /{realm}/users/{id}/sessions: + get: + tags: + - Users + summary: Get sessions associated with the user + responses: + 2XX: + description: success + content: + application/json: + schema: + type: array + items: + type: object + additionalProperties: true + parameters: + - in: path + name: realm + description: realm name (not id!) + required: true + schema: + type: string + style: simple + - in: path + name: id + description: User id + required: true + schema: + type: string + style: simple +components: + securitySchemes: + access_token: + type: http + scheme: bearer + bearerFormat: string + schemas: + AccessToken: + type: object + properties: + acr: + type: string + address: + $ref: '#/components/schemas/AddressClaimSet' + allowed-origins: + type: array + items: + type: string + at_hash: + type: string + auth_time: + type: integer + format: int64 + authorization: + $ref: '#/components/schemas/AccessToken-Authorization' + azp: + type: string + birthdate: + type: string + c_hash: + type: string + category: + type: string + enum: + - INTERNAL + - ACCESS + - ID + - ADMIN + - USERINFO + - LOGOUT + - AUTHORIZATION_RESPONSE + claims_locales: + type: string + cnf: + $ref: '#/components/schemas/AccessToken-CertConf' + email: + type: string + email_verified: + type: boolean + exp: + type: integer + format: int64 + family_name: + type: string + gender: + type: string + given_name: + type: string + iat: + type: integer + format: int64 + iss: + type: string + jti: + type: string + locale: + type: string + middle_name: + type: string + name: + type: string + nbf: + type: integer + format: int64 + nickname: + type: string + nonce: + type: string + otherClaims: + type: object + additionalProperties: true + phone_number: + type: string + phone_number_verified: + type: boolean + picture: + type: string + preferred_username: + type: string + profile: + type: string + realm_access: + $ref: '#/components/schemas/AccessToken-Access' + s_hash: + type: string + scope: + type: string + session_state: + type: string + sid: + type: string + sub: + type: string + trusted-certs: + type: array + items: + type: string + typ: + type: string + updated_at: + type: integer + format: int64 + website: + type: string + zoneinfo: + type: string + AccessToken-Access: + type: object + properties: + roles: + type: array + items: + type: string + verify_caller: + type: boolean + AccessToken-Authorization: + type: object + properties: + permissions: + type: array + items: + $ref: '#/components/schemas/Permission' + AccessToken-CertConf: + type: object + properties: + x5t#S256: + type: string + AddressClaimSet: + type: object + properties: + country: + type: string + formatted: + type: string + locality: + type: string + postal_code: + type: string + region: + type: string + street_address: + type: string + AuthenticationExecutionExportRepresentation: + type: object + properties: + authenticator: + type: string + authenticatorConfig: + type: string + authenticatorFlow: + type: boolean + flowAlias: + type: string + priority: + type: integer + format: int32 + requirement: + type: string + userSetupAllowed: + type: boolean + AuthenticationExecutionInfoRepresentation: + type: object + properties: + alias: + type: string + authenticationConfig: + type: string + authenticationFlow: + type: boolean + configurable: + type: boolean + description: + type: string + displayName: + type: string + flowId: + type: string + id: + type: string + index: + type: integer + format: int32 + level: + type: integer + format: int32 + providerId: + type: string + requirement: + type: string + requirementChoices: + type: array + items: + type: string + AuthenticationExecutionRepresentation: + type: object + properties: + authenticator: + type: string + authenticatorConfig: + type: string + authenticatorFlow: + type: boolean + flowId: + type: string + id: + type: string + parentFlow: + type: string + priority: + type: integer + format: int32 + requirement: + type: string + AuthenticationFlowRepresentation: + type: object + properties: + alias: + type: string + authenticationExecutions: + type: array + items: + $ref: '#/components/schemas/AuthenticationExecutionExportRepresentation' + builtIn: + type: boolean + description: + type: string + id: + type: string + providerId: + type: string + topLevel: + type: boolean + AuthenticatorConfigInfoRepresentation: + type: object + properties: + helpText: + type: string + name: + type: string + properties: + type: array + items: + $ref: '#/components/schemas/ConfigPropertyRepresentation' + providerId: + type: string + AuthenticatorConfigRepresentation: + type: object + properties: + alias: + type: string + config: + type: object + additionalProperties: true + id: + type: string + CertificateRepresentation: + type: object + properties: + certificate: + type: string + kid: + type: string + privateKey: + type: string + publicKey: + type: string + ClientInitialAccessCreatePresentation: + type: object + properties: + count: + type: integer + format: int32 + expiration: + type: integer + format: int32 + ClientInitialAccessPresentation: + type: object + properties: + count: + type: integer + format: int32 + expiration: + type: integer + format: int32 + id: + type: string + remainingCount: + type: integer + format: int32 + timestamp: + type: integer + format: int32 + token: + type: string + ClientMappingsRepresentation: + type: object + properties: + client: + type: string + id: + type: string + mappings: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + ClientPoliciesRepresentation: + type: object + properties: + policies: + type: array + items: + $ref: '#/components/schemas/ClientPolicyRepresentation' + ClientPolicyConditionRepresentation: + type: object + properties: + condition: + type: string + configuration: + $ref: '#/components/schemas/JsonNode' + ClientPolicyExecutorRepresentation: + type: object + properties: + configuration: + $ref: '#/components/schemas/JsonNode' + executor: + type: string + ClientPolicyRepresentation: + type: object + properties: + conditions: + type: array + items: + $ref: '#/components/schemas/ClientPolicyConditionRepresentation' + description: + type: string + enabled: + type: boolean + name: + type: string + profiles: + type: array + items: + type: string + ClientProfileRepresentation: + type: object + properties: + description: + type: string + executors: + type: array + items: + $ref: '#/components/schemas/ClientPolicyExecutorRepresentation' + name: + type: string + ClientProfilesRepresentation: + type: object + properties: + globalProfiles: + type: array + items: + $ref: '#/components/schemas/ClientProfileRepresentation' + profiles: + type: array + items: + $ref: '#/components/schemas/ClientProfileRepresentation' + ClientRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + adminUrl: + type: string + alwaysDisplayInConsole: + type: boolean + attributes: + type: object + additionalProperties: true + authenticationFlowBindingOverrides: + type: object + additionalProperties: true + authorizationServicesEnabled: + type: boolean + authorizationSettings: + $ref: '#/components/schemas/ResourceServerRepresentation' + baseUrl: + type: string + bearerOnly: + type: boolean + clientAuthenticatorType: + type: string + clientId: + type: string + consentRequired: + type: boolean + defaultClientScopes: + type: array + items: + type: string + description: + type: string + directAccessGrantsEnabled: + type: boolean + enabled: + type: boolean + frontchannelLogout: + type: boolean + fullScopeAllowed: + type: boolean + id: + type: string + implicitFlowEnabled: + type: boolean + name: + type: string + nodeReRegistrationTimeout: + type: integer + format: int32 + notBefore: + type: integer + format: int32 + oauth2DeviceAuthorizationGrantEnabled: + type: boolean + optionalClientScopes: + type: array + items: + type: string + origin: + type: string + protocol: + type: string + protocolMappers: + type: array + items: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + publicClient: + type: boolean + redirectUris: + type: array + items: + type: string + registeredNodes: + type: object + additionalProperties: true + registrationAccessToken: + type: string + rootUrl: + type: string + secret: + type: string + serviceAccountsEnabled: + type: boolean + standardFlowEnabled: + type: boolean + surrogateAuthRequired: + type: boolean + webOrigins: + type: array + items: + type: string + ClientScopeEvaluateResource-ProtocolMapperEvaluationRepresentation: + type: object + properties: + containerId: + type: string + containerName: + type: string + containerType: + type: string + mapperId: + type: string + mapperName: + type: string + protocolMapper: + type: string + ClientScopeRepresentation: + type: object + properties: + attributes: + type: object + additionalProperties: true + description: + type: string + id: + type: string + name: + type: string + protocol: + type: string + protocolMappers: + type: array + items: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + ComponentExportRepresentation: + type: object + properties: + config: + $ref: '#/components/schemas/MultivaluedHashMap' + id: + type: string + name: + type: string + providerId: + type: string + subComponents: + $ref: '#/components/schemas/MultivaluedHashMap' + subType: + type: string + ComponentRepresentation: + type: object + properties: + config: + $ref: '#/components/schemas/MultivaluedHashMap' + id: + type: string + name: + type: string + parentId: + type: string + providerId: + type: string + providerType: + type: string + subType: + type: string + ConfigPropertyRepresentation: + type: object + properties: + defaultValue: + type: object + helpText: + type: string + label: + type: string + name: + type: string + options: + type: array + items: + type: string + readOnly: + type: boolean + secret: + type: boolean + type: + type: string + CredentialRepresentation: + type: object + properties: + createdDate: + type: integer + format: int64 + credentialData: + type: string + id: + type: string + priority: + type: integer + format: int32 + secretData: + type: string + temporary: + type: boolean + type: + type: string + userLabel: + type: string + value: + type: string + FederatedIdentityRepresentation: + type: object + properties: + identityProvider: + type: string + userId: + type: string + userName: + type: string + GlobalRequestResult: + type: object + properties: + failedRequests: + type: array + items: + type: string + successRequests: + type: array + items: + type: string + GroupRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + attributes: + type: object + additionalProperties: true + clientRoles: + type: object + additionalProperties: true + id: + type: string + name: + type: string + path: + type: string + realmRoles: + type: array + items: + type: string + subGroups: + type: array + items: + $ref: '#/components/schemas/GroupRepresentation' + IDToken: + type: object + properties: + acr: + type: string + address: + $ref: '#/components/schemas/AddressClaimSet' + at_hash: + type: string + auth_time: + type: integer + format: int64 + azp: + type: string + birthdate: + type: string + c_hash: + type: string + category: + type: string + enum: + - INTERNAL + - ACCESS + - ID + - ADMIN + - USERINFO + - LOGOUT + - AUTHORIZATION_RESPONSE + claims_locales: + type: string + email: + type: string + email_verified: + type: boolean + exp: + type: integer + format: int64 + family_name: + type: string + gender: + type: string + given_name: + type: string + iat: + type: integer + format: int64 + iss: + type: string + jti: + type: string + locale: + type: string + middle_name: + type: string + name: + type: string + nbf: + type: integer + format: int64 + nickname: + type: string + nonce: + type: string + otherClaims: + type: object + additionalProperties: true + phone_number: + type: string + phone_number_verified: + type: boolean + picture: + type: string + preferred_username: + type: string + profile: + type: string + s_hash: + type: string + session_state: + type: string + sid: + type: string + sub: + type: string + typ: + type: string + updated_at: + type: integer + format: int64 + website: + type: string + zoneinfo: + type: string + IdentityProviderMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + id: + type: string + identityProviderAlias: + type: string + identityProviderMapper: + type: string + name: + type: string + IdentityProviderRepresentation: + type: object + properties: + addReadTokenRoleOnCreate: + type: boolean + alias: + type: string + config: + type: object + additionalProperties: true + displayName: + type: string + enabled: + type: boolean + firstBrokerLoginFlowAlias: + type: string + internalId: + type: string + linkOnly: + type: boolean + postBrokerLoginFlowAlias: + type: string + providerId: + type: string + storeToken: + type: boolean + trustEmail: + type: boolean + JsonNode: + type: object + properties: + array: + type: boolean + bigDecimal: + type: boolean + bigInteger: + type: boolean + binary: + type: boolean + boolean: + type: boolean + containerNode: + type: boolean + double: + type: boolean + empty: + type: boolean + float: + type: boolean + floatingPointNumber: + type: boolean + int: + type: boolean + integralNumber: + type: boolean + long: + type: boolean + missingNode: + type: boolean + nodeType: + type: string + enum: + - ARRAY + - BINARY + - BOOLEAN + - MISSING + - 'NULL' + - NUMBER + - OBJECT + - POJO + - STRING + 'null': + type: boolean + number: + type: boolean + object: + type: boolean + pojo: + type: boolean + short: + type: boolean + textual: + type: boolean + valueNode: + type: boolean + KeyStoreConfig: + type: object + properties: + format: + type: string + keyAlias: + type: string + keyPassword: + type: string + realmAlias: + type: string + realmCertificate: + type: boolean + storePassword: + type: string + KeysMetadataRepresentation: + type: object + properties: + active: + type: object + additionalProperties: true + keys: + type: array + items: + $ref: '#/components/schemas/KeysMetadataRepresentation-KeyMetadataRepresentation' + KeysMetadataRepresentation-KeyMetadataRepresentation: + type: object + properties: + algorithm: + type: string + certificate: + type: string + kid: + type: string + providerId: + type: string + providerPriority: + type: integer + format: int64 + publicKey: + type: string + status: + type: string + type: + type: string + use: + type: string + enum: + - SIG + - ENC + ManagementPermissionReference: + type: object + properties: + enabled: + type: boolean + resource: + type: string + scopePermissions: + type: object + additionalProperties: true + MappingsRepresentation: + type: object + properties: + clientMappings: + type: object + additionalProperties: true + realmMappings: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + MemoryInfoRepresentation: + type: object + properties: + free: + type: integer + format: int64 + freeFormated: + type: string + freePercentage: + type: integer + format: int64 + total: + type: integer + format: int64 + totalFormated: + type: string + used: + type: integer + format: int64 + usedFormated: + type: string + MultivaluedHashMap: + type: object + properties: + empty: + type: boolean + loadFactor: + type: number + format: float + threshold: + type: integer + format: int32 + PartialImportRepresentation: + type: object + properties: + clients: + type: array + items: + $ref: '#/components/schemas/ClientRepresentation' + groups: + type: array + items: + $ref: '#/components/schemas/GroupRepresentation' + identityProviders: + type: array + items: + $ref: '#/components/schemas/IdentityProviderRepresentation' + ifResourceExists: + type: string + policy: + type: string + enum: + - SKIP + - OVERWRITE + - FAIL + roles: + $ref: '#/components/schemas/RolesRepresentation' + users: + type: array + items: + $ref: '#/components/schemas/UserRepresentation' + PasswordPolicyTypeRepresentation: + type: object + properties: + configType: + type: string + defaultValue: + type: string + displayName: + type: string + id: + type: string + multipleSupported: + type: boolean + Permission: + type: object + properties: + claims: + type: object + additionalProperties: true + rsid: + type: string + rsname: + type: string + scopes: + type: array + items: + type: string + PolicyRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + decisionStrategy: + type: string + enum: + - AFFIRMATIVE + - UNANIMOUS + - CONSENSUS + description: + type: string + id: + type: string + logic: + type: string + enum: + - POSITIVE + - NEGATIVE + name: + type: string + owner: + type: string + policies: + type: array + items: + type: string + resources: + type: array + items: + type: string + resourcesData: + type: array + items: + $ref: '#/components/schemas/ResourceRepresentation' + scopes: + type: array + items: + type: string + scopesData: + type: array + items: + $ref: '#/components/schemas/ScopeRepresentation' + type: + type: string + ProfileInfoRepresentation: + type: object + properties: + disabledFeatures: + type: array + items: + type: string + experimentalFeatures: + type: array + items: + type: string + name: + type: string + previewFeatures: + type: array + items: + type: string + ProtocolMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + id: + type: string + name: + type: string + protocol: + type: string + protocolMapper: + type: string + ProviderRepresentation: + type: object + properties: + operationalInfo: + type: object + additionalProperties: true + order: + type: integer + format: int32 + RealmEventsConfigRepresentation: + type: object + properties: + adminEventsDetailsEnabled: + type: boolean + adminEventsEnabled: + type: boolean + enabledEventTypes: + type: array + items: + type: string + eventsEnabled: + type: boolean + eventsExpiration: + type: integer + format: int64 + eventsListeners: + type: array + items: + type: string + RealmRepresentation: + type: object + properties: + accessCodeLifespan: + type: integer + format: int32 + accessCodeLifespanLogin: + type: integer + format: int32 + accessCodeLifespanUserAction: + type: integer + format: int32 + accessTokenLifespan: + type: integer + format: int32 + accessTokenLifespanForImplicitFlow: + type: integer + format: int32 + accountTheme: + type: string + actionTokenGeneratedByAdminLifespan: + type: integer + format: int32 + actionTokenGeneratedByUserLifespan: + type: integer + format: int32 + adminEventsDetailsEnabled: + type: boolean + adminEventsEnabled: + type: boolean + adminTheme: + type: string + attributes: + type: object + additionalProperties: true + authenticationFlows: + type: array + items: + $ref: '#/components/schemas/AuthenticationFlowRepresentation' + authenticatorConfig: + type: array + items: + $ref: '#/components/schemas/AuthenticatorConfigRepresentation' + browserFlow: + type: string + browserSecurityHeaders: + type: object + additionalProperties: true + bruteForceProtected: + type: boolean + clientAuthenticationFlow: + type: string + clientOfflineSessionIdleTimeout: + type: integer + format: int32 + clientOfflineSessionMaxLifespan: + type: integer + format: int32 + clientPolicies: + $ref: '#/components/schemas/JsonNode' + clientProfiles: + $ref: '#/components/schemas/JsonNode' + clientScopeMappings: + type: object + additionalProperties: true + clientScopes: + type: array + items: + $ref: '#/components/schemas/ClientScopeRepresentation' + clientSessionIdleTimeout: + type: integer + format: int32 + clientSessionMaxLifespan: + type: integer + format: int32 + clients: + type: array + items: + $ref: '#/components/schemas/ClientRepresentation' + components: + $ref: '#/components/schemas/MultivaluedHashMap' + defaultDefaultClientScopes: + type: array + items: + type: string + defaultGroups: + type: array + items: + type: string + defaultLocale: + type: string + defaultOptionalClientScopes: + type: array + items: + type: string + defaultRole: + $ref: '#/components/schemas/RoleRepresentation' + defaultSignatureAlgorithm: + type: string + directGrantFlow: + type: string + displayName: + type: string + displayNameHtml: + type: string + dockerAuthenticationFlow: + type: string + duplicateEmailsAllowed: + type: boolean + editUsernameAllowed: + type: boolean + emailTheme: + type: string + enabled: + type: boolean + enabledEventTypes: + type: array + items: + type: string + eventsEnabled: + type: boolean + eventsExpiration: + type: integer + format: int64 + eventsListeners: + type: array + items: + type: string + failureFactor: + type: integer + format: int32 + federatedUsers: + type: array + items: + $ref: '#/components/schemas/UserRepresentation' + groups: + type: array + items: + $ref: '#/components/schemas/GroupRepresentation' + id: + type: string + identityProviderMappers: + type: array + items: + $ref: '#/components/schemas/IdentityProviderMapperRepresentation' + identityProviders: + type: array + items: + $ref: '#/components/schemas/IdentityProviderRepresentation' + internationalizationEnabled: + type: boolean + keycloakVersion: + type: string + loginTheme: + type: string + loginWithEmailAllowed: + type: boolean + maxDeltaTimeSeconds: + type: integer + format: int32 + maxFailureWaitSeconds: + type: integer + format: int32 + minimumQuickLoginWaitSeconds: + type: integer + format: int32 + notBefore: + type: integer + format: int32 + oAuth2DeviceCodeLifespan: + type: integer + format: int32 + oAuth2DevicePollingInterval: + type: integer + format: int32 + oauth2DeviceCodeLifespan: + type: integer + format: int32 + oauth2DevicePollingInterval: + type: integer + format: int32 + offlineSessionIdleTimeout: + type: integer + format: int32 + offlineSessionMaxLifespan: + type: integer + format: int32 + offlineSessionMaxLifespanEnabled: + type: boolean + otpPolicyAlgorithm: + type: string + otpPolicyDigits: + type: integer + format: int32 + otpPolicyInitialCounter: + type: integer + format: int32 + otpPolicyLookAheadWindow: + type: integer + format: int32 + otpPolicyPeriod: + type: integer + format: int32 + otpPolicyType: + type: string + otpSupportedApplications: + type: array + items: + type: string + passwordPolicy: + type: string + permanentLockout: + type: boolean + protocolMappers: + type: array + items: + $ref: '#/components/schemas/ProtocolMapperRepresentation' + quickLoginCheckMilliSeconds: + type: integer + format: int64 + realm: + type: string + refreshTokenMaxReuse: + type: integer + format: int32 + registrationAllowed: + type: boolean + registrationEmailAsUsername: + type: boolean + registrationFlow: + type: string + rememberMe: + type: boolean + requiredActions: + type: array + items: + $ref: '#/components/schemas/RequiredActionProviderRepresentation' + resetCredentialsFlow: + type: string + resetPasswordAllowed: + type: boolean + revokeRefreshToken: + type: boolean + roles: + $ref: '#/components/schemas/RolesRepresentation' + scopeMappings: + type: array + items: + $ref: '#/components/schemas/ScopeMappingRepresentation' + smtpServer: + type: object + additionalProperties: true + sslRequired: + type: string + ssoSessionIdleTimeout: + type: integer + format: int32 + ssoSessionIdleTimeoutRememberMe: + type: integer + format: int32 + ssoSessionMaxLifespan: + type: integer + format: int32 + ssoSessionMaxLifespanRememberMe: + type: integer + format: int32 + supportedLocales: + type: array + items: + type: string + userFederationMappers: + type: array + items: + $ref: '#/components/schemas/UserFederationMapperRepresentation' + userFederationProviders: + type: array + items: + $ref: '#/components/schemas/UserFederationProviderRepresentation' + userManagedAccessAllowed: + type: boolean + users: + type: array + items: + $ref: '#/components/schemas/UserRepresentation' + verifyEmail: + type: boolean + waitIncrementSeconds: + type: integer + format: int32 + webAuthnPolicyAcceptableAaguids: + type: array + items: + type: string + webAuthnPolicyAttestationConveyancePreference: + type: string + webAuthnPolicyAuthenticatorAttachment: + type: string + webAuthnPolicyAvoidSameAuthenticatorRegister: + type: boolean + webAuthnPolicyCreateTimeout: + type: integer + format: int32 + webAuthnPolicyPasswordlessAcceptableAaguids: + type: array + items: + type: string + webAuthnPolicyPasswordlessAttestationConveyancePreference: + type: string + webAuthnPolicyPasswordlessAuthenticatorAttachment: + type: string + webAuthnPolicyPasswordlessAvoidSameAuthenticatorRegister: + type: boolean + webAuthnPolicyPasswordlessCreateTimeout: + type: integer + format: int32 + webAuthnPolicyPasswordlessRequireResidentKey: + type: string + webAuthnPolicyPasswordlessRpEntityName: + type: string + webAuthnPolicyPasswordlessRpId: + type: string + webAuthnPolicyPasswordlessSignatureAlgorithms: + type: array + items: + type: string + webAuthnPolicyPasswordlessUserVerificationRequirement: + type: string + webAuthnPolicyRequireResidentKey: + type: string + webAuthnPolicyRpEntityName: + type: string + webAuthnPolicyRpId: + type: string + webAuthnPolicySignatureAlgorithms: + type: array + items: + type: string + webAuthnPolicyUserVerificationRequirement: + type: string + RequiredActionProviderRepresentation: + type: object + properties: + alias: + type: string + config: + type: object + additionalProperties: true + defaultAction: + type: boolean + enabled: + type: boolean + name: + type: string + priority: + type: integer + format: int32 + providerId: + type: string + ResourceRepresentation: + type: object + properties: + id: + type: string + attributes: + type: object + additionalProperties: true + displayName: + type: string + icon_uri: + type: string + name: + type: string + ownerManagedAccess: + type: boolean + scopes: + type: array + items: + $ref: '#/components/schemas/ScopeRepresentation' + type: + type: string + uris: + type: array + items: + type: string + ResourceServerRepresentation: + type: object + properties: + allowRemoteResourceManagement: + type: boolean + clientId: + type: string + decisionStrategy: + type: string + enum: + - AFFIRMATIVE + - UNANIMOUS + - CONSENSUS + id: + type: string + name: + type: string + policies: + type: array + items: + $ref: '#/components/schemas/PolicyRepresentation' + policyEnforcementMode: + type: string + enum: + - ENFORCING + - PERMISSIVE + - DISABLED + resources: + type: array + items: + $ref: '#/components/schemas/ResourceRepresentation' + scopes: + type: array + items: + $ref: '#/components/schemas/ScopeRepresentation' + RoleRepresentation: + type: object + properties: + attributes: + type: object + additionalProperties: true + clientRole: + type: boolean + composite: + type: boolean + composites: + $ref: '#/components/schemas/RoleRepresentation-Composites' + containerId: + type: string + description: + type: string + id: + type: string + name: + type: string + RoleRepresentation-Composites: + type: object + properties: + client: + type: object + additionalProperties: true + realm: + type: array + items: + type: string + RolesRepresentation: + type: object + properties: + client: + type: object + additionalProperties: true + realm: + type: array + items: + $ref: '#/components/schemas/RoleRepresentation' + ScopeMappingRepresentation: + type: object + properties: + client: + type: string + clientScope: + type: string + roles: + type: array + items: + type: string + self: + type: string + ScopeRepresentation: + type: object + properties: + displayName: + type: string + iconUri: + type: string + id: + type: string + name: + type: string + policies: + type: array + items: + $ref: '#/components/schemas/PolicyRepresentation' + resources: + type: array + items: + $ref: '#/components/schemas/ResourceRepresentation' + ServerInfoRepresentation: + type: object + properties: + builtinProtocolMappers: + type: object + additionalProperties: true + clientImporters: + type: array + items: + type: object + additionalProperties: true + clientInstallations: + type: object + additionalProperties: true + componentTypes: + type: object + additionalProperties: true + enums: + type: object + additionalProperties: true + identityProviders: + type: array + items: + type: object + additionalProperties: true + memoryInfo: + $ref: '#/components/schemas/MemoryInfoRepresentation' + passwordPolicies: + type: array + items: + $ref: '#/components/schemas/PasswordPolicyTypeRepresentation' + profileInfo: + $ref: '#/components/schemas/ProfileInfoRepresentation' + protocolMapperTypes: + type: object + additionalProperties: true + providers: + type: object + additionalProperties: true + socialProviders: + type: array + items: + type: object + additionalProperties: true + systemInfo: + $ref: '#/components/schemas/SystemInfoRepresentation' + themes: + type: object + additionalProperties: true + SpiInfoRepresentation: + type: object + properties: + internal: + type: boolean + providers: + type: object + additionalProperties: true + SynchronizationResult: + type: object + properties: + added: + type: integer + format: int32 + failed: + type: integer + format: int32 + ignored: + type: boolean + removed: + type: integer + format: int32 + status: + type: string + updated: + type: integer + format: int32 + SystemInfoRepresentation: + type: object + properties: + fileEncoding: + type: string + javaHome: + type: string + javaRuntime: + type: string + javaVendor: + type: string + javaVersion: + type: string + javaVm: + type: string + javaVmVersion: + type: string + osArchitecture: + type: string + osName: + type: string + osVersion: + type: string + serverTime: + type: string + uptime: + type: string + uptimeMillis: + type: integer + format: int64 + userDir: + type: string + userLocale: + type: string + userName: + type: string + userTimezone: + type: string + version: + type: string + TestLdapConnectionRepresentation: + type: object + properties: + action: + type: string + authType: + type: string + bindCredential: + type: string + bindDn: + type: string + componentId: + type: string + connectionTimeout: + type: string + connectionUrl: + type: string + startTls: + type: string + useTruststoreSpi: + type: string + UserConsentRepresentation: + type: object + properties: + clientId: + type: string + createdDate: + type: integer + format: int64 + grantedClientScopes: + type: array + items: + type: string + lastUpdatedDate: + type: integer + format: int64 + UserFederationMapperRepresentation: + type: object + properties: + config: + type: object + additionalProperties: true + federationMapperType: + type: string + federationProviderDisplayName: + type: string + id: + type: string + name: + type: string + UserFederationProviderRepresentation: + type: object + properties: + changedSyncPeriod: + type: integer + format: int32 + config: + type: object + additionalProperties: true + displayName: + type: string + fullSyncPeriod: + type: integer + format: int32 + id: + type: string + lastSync: + type: integer + format: int32 + priority: + type: integer + format: int32 + providerName: + type: string + UserRepresentation: + type: object + properties: + access: + type: object + additionalProperties: true + attributes: + type: object + additionalProperties: true + clientConsents: + type: array + items: + $ref: '#/components/schemas/UserConsentRepresentation' + clientRoles: + type: object + additionalProperties: true + createdTimestamp: + type: integer + format: int64 + credentials: + type: array + items: + $ref: '#/components/schemas/CredentialRepresentation' + disableableCredentialTypes: + type: array + items: + type: string + email: + type: string + emailVerified: + type: boolean + enabled: + type: boolean + federatedIdentities: + type: array + items: + $ref: '#/components/schemas/FederatedIdentityRepresentation' + federationLink: + type: string + firstName: + type: string + groups: + type: array + items: + type: string + id: + type: string + lastName: + type: string + notBefore: + type: integer + format: int32 + origin: + type: string + realmRoles: + type: array + items: + type: string + requiredActions: + type: array + items: + type: string + self: + type: string + serviceAccountClientId: + type: string + username: + type: string +security: + - access_token: [] +externalDocs: + description: Schema source code + url: https://github.com/keycloak/keycloak/tree/6.0.1/core/src/main/java/org/keycloak/representations \ No newline at end of file diff --git a/backend/package.json b/backend/package.json index a03eb18..d73c4df 100644 --- a/backend/package.json +++ b/backend/package.json @@ -30,6 +30,7 @@ "axios": "^0.27.2", "openid-client": "^5.1.9", "reflect-metadata": "^0.1.13", + "request": "^2.88.2", "rimraf": "^3.0.2", "rxjs": "^7.2.0" }, @@ -41,6 +42,7 @@ "@types/jest": "28.1.8", "@types/node": "^16.0.0", "@types/supertest": "^2.0.11", + "isomorphic-fetch": "^3.0.0", "jest": "28.1.3", "prettier": "^2.3.2", "source-map-support": "^0.5.20", diff --git a/backend/src/auth/register/register.controller.ts b/backend/src/auth/register/register.controller.ts index 2d37aba..1589a8c 100644 --- a/backend/src/auth/register/register.controller.ts +++ b/backend/src/auth/register/register.controller.ts @@ -1,4 +1,13 @@ -import { Controller, Get, Post, Body, Patch, Param, Delete } from '@nestjs/common'; +import { + Controller, + Get, + Post, + Body, + Patch, + Param, + Delete, + Headers, +} from '@nestjs/common'; import { RegisterService } from './register.service'; import { CreateUserDto } from './dto/create-user.dto'; import { UpdateUserDto } from './dto/update-user.dto'; @@ -8,13 +17,16 @@ export class RegisterController { constructor(private readonly registerService: RegisterService) {} @Post() - create(@Body() createUserDto: CreateUserDto) { - return this.registerService.create(createUserDto); + create( + @Headers('Authorization') accessToken: string, + @Body() createUserDto: CreateUserDto, + ) { + return this.registerService.create(accessToken, createUserDto); } @Get() - findAll() { - return this.registerService.findAll(); + findAll(@Headers('Authorization') accessToken: string) { + return this.registerService.findAll(accessToken); } @Get(':id') diff --git a/backend/src/auth/register/register.service.ts b/backend/src/auth/register/register.service.ts index a827e14..c8456b2 100644 --- a/backend/src/auth/register/register.service.ts +++ b/backend/src/auth/register/register.service.ts @@ -1,7 +1,7 @@ -import { Injectable } from '@nestjs/common'; +import { Body, Injectable } from '@nestjs/common'; import { Configuration, - RealmUsersPostRequest, + CredentialRepresentation, UserRepresentation, UsersApi, } from '../../../keycloak/kc-client'; @@ -9,28 +9,81 @@ import { UpdateUserDto } from './dto/update-user.dto'; @Injectable() export class RegisterService { - async create(userRepresentation: UserRepresentation) { - const accessToken = - 'eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICItQjJOQnpxUmhMTjBqNlJyUWFGRHpMaTNIQUhaMFU0VDZQUFN5Y3cyc0RrIn0.eyJleHAiOjE2NjIzODQ0NjAsImlhdCI6MTY2MjM4NDE2MCwianRpIjoiNTNkMDA2NTYtYWE2ZS00YjY1LTgyMTEtNWY4ODJmODVlNTIxIiwiaXNzIjoiaHR0cHM6Ly9vYXV0aC5hcHBzLmFydHNlcnZpcy5hbC9hdXRoL3JlYWxtcy9GbHV4ZW0tREVWIiwiYXVkIjpbInJlYWxtLW1hbmFnZW1lbnQiLCJhY2NvdW50Il0sInN1YiI6IjIzYjM5MTk0LTlhMmQtNDk3Yi1hYjM5LWIwM2YwYTJjMzM5YiIsInR5cCI6IkJlYXJlciIsImF6cCI6IndlYmFwcC1kZXYiLCJzZXNzaW9uX3N0YXRlIjoiYTg1YjZhMWUtMGQzNy00OWQ0LTk5YjUtMmZhOTU5MGZkYzhlIiwiYWNyIjoiMSIsImFsbG93ZWQtb3JpZ2lucyI6WyJodHRwczovL2hhc3VyYS5hcHBzLmFydHNlcnZpcy5hbCIsImh0dHA6Ly9sb2NhbGhvc3Q6MzAwMCJdLCJyZWFsbV9hY2Nlc3MiOnsicm9sZXMiOlsib2ZmbGluZV9hY2Nlc3MiLCJ1bWFfYXV0aG9yaXphdGlvbiIsImRlZmF1bHQtcm9sZXMtZmx1eGVtLWRldiJdfSwicmVzb3VyY2VfYWNjZXNzIjp7InJlYWxtLW1hbmFnZW1lbnQiOnsicm9sZXMiOlsibWFuYWdlLXVzZXJzIl19LCJ3ZWJhcHAtZGV2Ijp7InJvbGVzIjpbImFkbWluIiwidXNlciJdfSwiYWNjb3VudCI6eyJyb2xlcyI6WyJtYW5hZ2UtYWNjb3VudCIsIm1hbmFnZS1hY2NvdW50LWxpbmtzIiwidmlldy1wcm9maWxlIl19fSwic2NvcGUiOiJlbWFpbCBoYXNzdXJhIHByb2ZpbGUiLCJzaWQiOiJhODViNmExZS0wZDM3LTQ5ZDQtOTliNS0yZmE5NTkwZmRjOGUiLCJlbWFpbF92ZXJpZmllZCI6dHJ1ZSwiaHR0cHM6Ly9oYXN1cmEuaW8vand0L2NsYWltcyI6eyJ4LWhhc3VyYS1kZWZhdWx0LXJvbGUiOiJ1c2VyIiwieC1oYXN1cmEtdXNlci1pZCI6IjIzYjM5MTk0LTlhMmQtNDk3Yi1hYjM5LWIwM2YwYTJjMzM5YiIsIngtaGFzdXJhLWFsbG93ZWQtcm9sZXMiOlsiYWRtaW4iLCJ1c2VyIl19LCJuYW1lIjoiQWRtaW4gVGVzdCIsInByZWZlcnJlZF91c2VybmFtZSI6ImFkbWluIiwiZ2l2ZW5fbmFtZSI6IkFkbWluIiwiZmFtaWx5X25hbWUiOiJUZXN0In0.ov4yxi19x7QNHa3Jz_pNSLVwtZukYhfh-cbfHUOrIKlIuaZDO_QAohmO6Vgv7uiKRFMHp4ntJntJiaH-lxtPAUo7ai4c6hbjnZPYI-yzSwsohfuEh7eG7sgowV2j4DZ8nxJp4WS1ipukilAQhdITKuKGjUuA9vpy5NNh-kzIakJDp8Jh0OYcIncV-WrDSmnvDQPP4grq09kXcg34e6YNWr4LCJgQDkUQ4XAZOLfqNs7cqqJL57kdEN7oEDzczMCYY9baRvflEtxDWMKNSjYW6-9L6mF3aKG1sR0JHogf24CmwuVNohgda2dCqmp57Djsyr7tqdll0fnhEiUBi-h3xQ'; + async create(accessToken: string, userRepresentation: UserRepresentation) { + accessToken = accessToken.replace('Bearer ', ''); const basePath = `${process.env.KC_BASE_URL}/auth/admin/realms`; - const config = new Configuration({ basePath, accessToken }); - const usersApi = new UsersApi(config); - - const requestParams: RealmUsersPostRequest = { - realm: process.env.KC_REALM, - userRepresentation, - }; - + const usersApi = new UsersApi({ basePath, accessToken }); try { - const registereredUser = await usersApi.realmUsersPost(requestParams); - return registereredUser; + const registereredUser = await usersApi.realmUsersPost( + process.env.KC_REALM, + userRepresentation, + ); + // console.log(registereredUser); + + try { + const newUserRegistered = await usersApi.realmUsersGet( + process.env.KC_REALM, + true, + userRepresentation.email, + ); + if (newUserRegistered.data.length > 0) { + const userFound: UserRepresentation = newUserRegistered.data[0]; + console.log(userFound.id); + + try { + const credentialRepresentation: CredentialRepresentation = {temporary: false, value: "1234"} + const setUserPassword = await usersApi.realmUsersIdResetPasswordPut(process.env.KC_REALM, userFound.id, credentialRepresentation) + } catch (error) { + + } + + try { + // Ska nevoje te nsim email. + const sendMailToCreatedUser = + await usersApi.realmUsersIdSendVerifyEmailPut( + process.env.KC_REALM, + userFound.id, + process.env.KC_CLIENT_ID, + 'http://localhost:3000', + { + headers: { + 'Content-Type': 'application/json', + }, + }, + ); + console.log(sendMailToCreatedUser); + } catch (error) { + console.log(error); + } + } + } catch (error) { + // console.log(error); + return error.data; + } + + return registereredUser.data; + // try { + // const sendMail = await usersApi.realmUsersIdSendVerifyEmailPut(process.env.KC_REALM, registereredUser.data.id) + // } catch (error) { + + // } } catch (error) { - return error; + console.log(error); + return error.response.data; } } - async findAll() { - return 'Find all Users'; + async findAll(accessToken: string) { + accessToken = accessToken.replace('Bearer ', ''); + + const basePath = `${process.env.KC_BASE_URL}/auth/admin/realms`; + const usersApi = new UsersApi({ basePath, accessToken }); + try { + const users = await usersApi.realmUsersGet(process.env.KC_REALM); + return users.data; + } catch (error) { + return error.data; + } } findOne(id: number) { diff --git a/backend/yarn.lock b/backend/yarn.lock index 0636022..8621f98 100644 --- a/backend/yarn.lock +++ b/backend/yarn.lock @@ -1171,7 +1171,7 @@ ajv@8.11.0, ajv@^8.0.0: require-from-string "^2.0.2" uri-js "^4.2.2" -ajv@^6.12.5: +ajv@^6.12.3, ajv@^6.12.5: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -1257,11 +1257,33 @@ asap@^2.0.0: resolved "https://registry.yarnpkg.com/asap/-/asap-2.0.6.tgz#e50347611d7e690943208bbdafebcbc2fb866d46" integrity sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA== +asn1@~0.2.3: + version "0.2.6" + resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.6.tgz#0d3a7bb6e64e02a90c0303b31f292868ea09a08d" + integrity sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ== + dependencies: + safer-buffer "~2.1.0" + +assert-plus@1.0.0, assert-plus@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" + integrity sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw== + asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== +aws-sign2@~0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" + integrity sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA== + +aws4@^1.8.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.11.0.tgz#d61f46d83b2519250e2784daf5b09479a8b41c59" + integrity sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA== + axios@0.27.2, axios@^0.27.2: version "0.27.2" resolved "https://registry.yarnpkg.com/axios/-/axios-0.27.2.tgz#207658cc8621606e586c85db4b41a750e756d972" @@ -1340,6 +1362,13 @@ base64-js@^1.3.1: resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== +bcrypt-pbkdf@^1.0.0: + version "1.0.2" + resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" + integrity sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w== + dependencies: + tweetnacl "^0.14.3" + binary-extensions@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" @@ -1464,6 +1493,11 @@ caniuse-lite@^1.0.30001370: resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001390.tgz#158a43011e7068ef7fc73590e9fd91a7cece5e7f" integrity sha512-sS4CaUM+/+vqQUlCvCJ2WtDlV81aWtHhqeEVkLokVJJa3ViN4zDxAGfq9R8i1m90uGHxo99cy10Od+lvn3hf0g== +caseless@~0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" + integrity sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw== + chalk@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/chalk/-/chalk-3.0.0.tgz#3f73c2bf526591f574cc492c51e2456349f844e4" @@ -1603,7 +1637,7 @@ color-name@~1.1.4: resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -combined-stream@^1.0.8: +combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: version "1.0.8" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== @@ -1679,6 +1713,11 @@ cookiejar@^2.1.3: resolved "https://registry.yarnpkg.com/cookiejar/-/cookiejar-2.1.3.tgz#fc7a6216e408e74414b90230050842dacda75acc" integrity sha512-JxbCBUdrfr6AQjOXrxoTvAMJO4HBTUIlBzslcJPAz+/KT8yk53fXun51u+RenNYvad/+Vc2DIz5o9UxlCDymFQ== +core-util-is@1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" + integrity sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ== + core-util-is@~1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" @@ -1717,6 +1756,13 @@ cross-spawn@^7.0.0, cross-spawn@^7.0.3: shebang-command "^2.0.0" which "^2.0.1" +dashdash@^1.12.0: + version "1.14.1" + resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" + integrity sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g== + dependencies: + assert-plus "^1.0.0" + debug@2.6.9: version "2.6.9" resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" @@ -1796,6 +1842,14 @@ dotenv@16.0.1: resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.0.1.tgz#8f8f9d94876c35dac989876a5d3a82a267fdce1d" integrity sha512-1K6hR6wtk2FviQ4kEiSjFiH5rpzEVi8WW0x96aztHVMhEspNpc4DVOUTEHtEva5VThQ8IaBX1Pe4gSzpVVUsKQ== +ecc-jsbn@~0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" + integrity sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw== + dependencies: + jsbn "~0.1.0" + safer-buffer "^2.1.0" + ee-first@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/ee-first/-/ee-first-1.1.1.tgz#590c61156b0ae2f4f0255732a158b266bc56b21d" @@ -1991,6 +2045,11 @@ express@4.18.1: utils-merge "1.0.1" vary "~1.1.2" +extend@~3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" + integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== + external-editor@^3.0.3: version "3.1.0" resolved "https://registry.yarnpkg.com/external-editor/-/external-editor-3.1.0.tgz#cb03f740befae03ea4d283caed2741a83f335495" @@ -2000,6 +2059,16 @@ external-editor@^3.0.3: iconv-lite "^0.4.24" tmp "^0.0.33" +extsprintf@1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" + integrity sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g== + +extsprintf@^1.2.0: + version "1.4.1" + resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.1.tgz#8d172c064867f235c0c84a596806d279bf4bcc07" + integrity sha512-Wrk35e8ydCKDj/ArClo1VrPVmN8zph5V4AtHwIuHhvMXsKf73UT3BOD+azBIW+3wOJ4FhEH7zyaJCFvChjYvMA== + fast-deep-equal@^3.1.1: version "3.1.3" resolved "https://registry.yarnpkg.com/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz#3a7d56b559d6cbc3eb512325244e619a65c6c525" @@ -2062,6 +2131,11 @@ follow-redirects@^1.14.9: resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.15.1.tgz#0ca6a452306c9b276e4d3127483e29575e207ad5" integrity sha512-yLAMQs+k0b2m7cVxpS1VKJVvoz7SS9Td1zss3XRwXj+ZDH00RJgnuLx7E44wx02kQLrdM3aOOy+FpzS7+8OizA== +forever-agent@~0.6.1: + version "0.6.1" + resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" + integrity sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw== + fork-ts-checker-webpack-plugin@7.2.13: version "7.2.13" resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-7.2.13.tgz#51ffd6a2f96f03ab64b92f8aedf305dbf3dee0f1" @@ -2089,6 +2163,15 @@ form-data@^4.0.0: combined-stream "^1.0.8" mime-types "^2.1.12" +form-data@~2.3.2: + version "2.3.3" + resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" + integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== + dependencies: + asynckit "^0.4.0" + combined-stream "^1.0.6" + mime-types "^2.1.12" + formidable@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/formidable/-/formidable-2.0.1.tgz#4310bc7965d185536f9565184dee74fbb75557ff" @@ -2174,6 +2257,13 @@ get-stream@^6.0.0: resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== +getpass@^0.1.1: + version "0.1.7" + resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" + integrity sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng== + dependencies: + assert-plus "^1.0.0" + glob-parent@~5.1.2: version "5.1.2" resolved "https://registry.yarnpkg.com/glob-parent/-/glob-parent-5.1.2.tgz#869832c58034fe68a4093c17dc15e8340d8401c4" @@ -2208,6 +2298,19 @@ graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.4, resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c" integrity sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA== +har-schema@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" + integrity sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q== + +har-validator@~5.1.3: + version "5.1.5" + resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.5.tgz#1f0803b9f8cb20c0fa13822df1ecddb36bde1efd" + integrity sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w== + dependencies: + ajv "^6.12.3" + har-schema "^2.0.0" + has-flag@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" @@ -2251,6 +2354,15 @@ http-errors@2.0.0: statuses "2.0.1" toidentifier "1.0.1" +http-signature@~1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" + integrity sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ== + dependencies: + assert-plus "^1.0.0" + jsprim "^1.2.2" + sshpk "^1.7.0" + human-signals@^1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-1.1.1.tgz#c5b1cd14f50aeae09ab6c59fe63ba3395fe4dfa3" @@ -2413,6 +2525,11 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-typedarray@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" + integrity sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA== + is-unicode-supported@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz#3f26c76a809593b52bfa2ecb5710ed2779b522a7" @@ -2428,6 +2545,19 @@ isexe@^2.0.0: resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10" integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== +isomorphic-fetch@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/isomorphic-fetch/-/isomorphic-fetch-3.0.0.tgz#0267b005049046d2421207215d45d6a262b8b8b4" + integrity sha512-qvUtwJ3j6qwsF3jLxkZ72qCgjMysPzDfeV240JHiGZsANBYd+EEuu35v7dfrJ9Up0Ak07D7GGSkGhCHTqg/5wA== + dependencies: + node-fetch "^2.6.1" + whatwg-fetch "^3.4.1" + +isstream@~0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" + integrity sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g== + istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: version "3.2.0" resolved "https://registry.yarnpkg.com/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz#189e7909d0a39fa5a3dfad5b03f71947770191d3" @@ -2867,6 +2997,11 @@ js-yaml@^3.13.1: argparse "^1.0.7" esprima "^4.0.0" +jsbn@~0.1.0: + version "0.1.1" + resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" + integrity sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg== + jsesc@^2.5.1: version "2.5.2" resolved "https://registry.yarnpkg.com/jsesc/-/jsesc-2.5.2.tgz#80564d2e483dacf6e8ef209650a67df3f0c283a4" @@ -2887,6 +3022,16 @@ json-schema-traverse@^1.0.0: resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== +json-schema@0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.4.0.tgz#f7de4cf6efab838ebaeb3236474cbba5a1930ab5" + integrity sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA== + +json-stringify-safe@~5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" + integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== + json5@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.1.tgz#655d50ed1e6f95ad1a3caababd2b0efda10b395c" @@ -2911,6 +3056,16 @@ jsonfile@^6.0.1: optionalDependencies: graceful-fs "^4.1.6" +jsprim@^1.2.2: + version "1.4.2" + resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.2.tgz#712c65533a15c878ba59e9ed5f0e26d5b77c5feb" + integrity sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw== + dependencies: + assert-plus "1.0.0" + extsprintf "1.3.0" + json-schema "0.4.0" + verror "1.10.0" + kleur@^3.0.3: version "3.0.3" resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" @@ -3034,7 +3189,7 @@ mime-db@1.52.0: resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== -mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.24, mime-types@~2.1.34: +mime-types@^2.1.12, mime-types@^2.1.27, mime-types@~2.1.19, mime-types@~2.1.24, mime-types@~2.1.34: version "2.1.35" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== @@ -3164,6 +3319,11 @@ npm-run-path@^4.0.0, npm-run-path@^4.0.1: dependencies: path-key "^3.0.0" +oauth-sign@~0.9.0: + version "0.9.0" + resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" + integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== + object-assign@^4, object-assign@^4.1.1: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" @@ -3331,6 +3491,11 @@ path-type@^4.0.0: resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== +performance-now@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" + integrity sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow== + picocolors@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" @@ -3394,6 +3559,11 @@ proxy-addr@~2.0.7: forwarded "0.2.0" ipaddr.js "1.9.1" +psl@^1.1.28: + version "1.9.0" + resolved "https://registry.yarnpkg.com/psl/-/psl-1.9.0.tgz#d0df2a137f00794565fcaf3b2c00cd09f8d5a5a7" + integrity sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag== + pump@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/pump/-/pump-3.0.0.tgz#b4a2116815bde2f4e1ea602354e8c75565107a64" @@ -3402,7 +3572,7 @@ pump@^3.0.0: end-of-stream "^1.1.0" once "^1.3.1" -punycode@^2.1.0: +punycode@^2.1.0, punycode@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" integrity sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A== @@ -3426,6 +3596,11 @@ qs@^6.10.3: dependencies: side-channel "^1.0.4" +qs@~6.5.2: + version "6.5.3" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.3.tgz#3aeeffc91967ef6e35c0e488ef46fb296ab76aad" + integrity sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA== + randombytes@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" @@ -3494,6 +3669,32 @@ reflect-metadata@^0.1.13: resolved "https://registry.yarnpkg.com/reflect-metadata/-/reflect-metadata-0.1.13.tgz#67ae3ca57c972a2aa1642b10fe363fe32d49dc08" integrity sha512-Ts1Y/anZELhSsjMcU605fU9RE4Oi3p5ORujwbIKXfWa+0Zxs510Qrmrce5/Jowq3cHSZSJqBjypxmHarc+vEWg== +request@^2.88.2: + version "2.88.2" + resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" + integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== + dependencies: + aws-sign2 "~0.7.0" + aws4 "^1.8.0" + caseless "~0.12.0" + combined-stream "~1.0.6" + extend "~3.0.2" + forever-agent "~0.6.1" + form-data "~2.3.2" + har-validator "~5.1.3" + http-signature "~1.2.0" + is-typedarray "~1.0.0" + isstream "~0.1.2" + json-stringify-safe "~5.0.1" + mime-types "~2.1.19" + oauth-sign "~0.9.0" + performance-now "^2.1.0" + qs "~6.5.2" + safe-buffer "^5.1.2" + tough-cookie "~2.5.0" + tunnel-agent "^0.6.0" + uuid "^3.3.2" + require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" @@ -3569,7 +3770,7 @@ rxjs@^7.2.0, rxjs@^7.5.5: dependencies: tslib "^2.1.0" -safe-buffer@5.2.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: +safe-buffer@5.2.1, safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@^5.1.2, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== @@ -3579,7 +3780,7 @@ safe-buffer@~5.1.0, safe-buffer@~5.1.1: resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== -"safer-buffer@>= 2.1.2 < 3": +"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== @@ -3727,6 +3928,21 @@ sprintf-js@~1.0.2: resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== +sshpk@^1.7.0: + version "1.17.0" + resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.17.0.tgz#578082d92d4fe612b13007496e543fa0fbcbe4c5" + integrity sha512-/9HIEs1ZXGhSPE8X6Ccm7Nam1z8KcoCqPdI7ecm1N33EzAetWahvQWVqLZtaZQ+IDKX4IyA2o0gBzqIMkAagHQ== + dependencies: + asn1 "~0.2.3" + assert-plus "^1.0.0" + bcrypt-pbkdf "^1.0.0" + dashdash "^1.12.0" + ecc-jsbn "~0.1.1" + getpass "^0.1.1" + jsbn "~0.1.0" + safer-buffer "^2.0.2" + tweetnacl "~0.14.0" + stack-utils@^2.0.3: version "2.0.5" resolved "https://registry.yarnpkg.com/stack-utils/-/stack-utils-2.0.5.tgz#d25265fca995154659dbbfba3b49254778d2fdd5" @@ -3948,6 +4164,14 @@ toidentifier@1.0.1: resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== +tough-cookie@~2.5.0: + version "2.5.0" + resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" + integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== + dependencies: + psl "^1.1.28" + punycode "^2.1.1" + tr46@~0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" @@ -4029,6 +4253,18 @@ tslib@^1.9.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== +tunnel-agent@^0.6.0: + version "0.6.0" + resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" + integrity sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w== + dependencies: + safe-buffer "^5.0.1" + +tweetnacl@^0.14.3, tweetnacl@~0.14.0: + version "0.14.5" + resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" + integrity sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA== + type-detect@4.0.8: version "4.0.8" resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" @@ -4097,6 +4333,11 @@ uuid@8.3.2: resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== +uuid@^3.3.2: + version "3.4.0" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" + integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== + v8-compile-cache-lib@^3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz#6336e8d71965cb3d35a1bbb7868445a7c05264bf" @@ -4116,6 +4357,15 @@ vary@^1, vary@~1.1.2: resolved "https://registry.yarnpkg.com/vary/-/vary-1.1.2.tgz#2299f02c6ded30d4a5961b0b9f74524a18f634fc" integrity sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg== +verror@1.10.0: + version "1.10.0" + resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" + integrity sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw== + dependencies: + assert-plus "^1.0.0" + core-util-is "1.0.2" + extsprintf "^1.2.0" + walker@^1.0.8: version "1.0.8" resolved "https://registry.yarnpkg.com/walker/-/walker-1.0.8.tgz#bd498db477afe573dc04185f011d3ab8a8d7653f" @@ -4183,6 +4433,11 @@ webpack@5.73.0: watchpack "^2.3.1" webpack-sources "^3.2.3" +whatwg-fetch@^3.4.1: + version "3.6.2" + resolved "https://registry.yarnpkg.com/whatwg-fetch/-/whatwg-fetch-3.6.2.tgz#dced24f37f2624ed0281725d51d0e2e3fe677f8c" + integrity sha512-bJlen0FcuU/0EMLrdbJ7zOnW6ITZLrZMIarMUVmdKtsGvZna8vxKYaexICWPfZ8qwf9fzNq+UEIZrnSaApt6RA== + whatwg-url@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d"