diff --git a/docsfera.json b/docsfera.json index 04ae33d..75a5699 100644 --- a/docsfera.json +++ b/docsfera.json @@ -6231,221 +6231,6 @@ ] } }, - "/health": { - "get": { - "operationId": "HealthController_check", - "parameters": [], - "responses": { - "200": { - "description": "" - } - }, - "tags": [ - "Health" - ] - } - }, - "/identity-providers": { - "post": { - "operationId": "IdentityProviderController_addIdentityProvider", - "parameters": [], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateIdentityProvider" - } - } - } - }, - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IdentityProviderResponse" - } - } - } - } - }, - "security": [ - { - "access-token": [] - }, - { - "access-token": [] - }, - { - "access-token": [] - } - ] - }, - "get": { - "operationId": "IdentityProviderController_getProviders", - "parameters": [], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/IdentityProviderListResponse" - } - } - } - } - }, - "security": [ - { - "access-token": [] - }, - { - "access-token": [] - }, - { - "access-token": [] - } - ] - } - }, - "/identity-providers/{id}": { - "delete": { - "operationId": "IdentityProviderController_deleteIdentityProvider", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { - "type": "string" - } - } - ], - "responses": { - "204": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - } - }, - "security": [ - { - "access-token": [] - }, - { - "access-token": [] - } - ] - }, - "put": { - "operationId": "IdentityProviderController_updateIdentityProviders", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { - "type": "string" - } - } - ], - "requestBody": { - "required": true, - "content": { - "application/json": { - "schema": { - "$ref": "#/components/schemas/CreateIdentityProvider" - } - } - } - }, - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - } - }, - "security": [ - { - "access-token": [] - }, - { - "access-token": [] - }, - { - "access-token": [] - } - ] - }, - "get": { - "operationId": "IdentityProviderController_loginIdp", - "parameters": [ - { - "name": "id", - "required": true, - "in": "path", - "schema": { - "type": "string" - } - } - ], - "responses": { - "200": { - "description": "" - } - } - } - }, - "/identity-providers/callback": { - "post": { - "operationId": "IdentityProviderController_callbackIdp", - "parameters": [], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - } - } - } - }, - "/identity-providers/links": { - "get": { - "operationId": "IdentityProviderController_providerLinks", - "parameters": [], - "responses": { - "200": { - "description": "", - "content": { - "application/json": { - "schema": { - "type": "object" - } - } - } - } - } - } - }, "/network-policy": { "get": { "operationId": "NetworkPolicyController_getNetworks", @@ -6754,6 +6539,207 @@ ] } }, + "/identity-providers": { + "post": { + "operationId": "IdentityProviderController_addIdentityProvider", + "parameters": [], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateIdentityProvider" + } + } + } + }, + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/IdentityProviderResponse" + } + } + } + } + }, + "security": [ + { + "access-token": [] + }, + { + "access-token": [] + }, + { + "access-token": [] + } + ] + }, + "get": { + "operationId": "IdentityProviderController_getProviders", + "parameters": [], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/IdentityProviderListResponse" + } + } + } + } + }, + "security": [ + { + "access-token": [] + }, + { + "access-token": [] + }, + { + "access-token": [] + } + ] + } + }, + "/identity-providers/{id}": { + "delete": { + "operationId": "IdentityProviderController_deleteIdentityProvider", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "schema": { + "type": "string" + } + } + ], + "responses": { + "204": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "object" + } + } + } + } + }, + "security": [ + { + "access-token": [] + }, + { + "access-token": [] + } + ] + }, + "put": { + "operationId": "IdentityProviderController_updateIdentityProviders", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "schema": { + "type": "string" + } + } + ], + "requestBody": { + "required": true, + "content": { + "application/json": { + "schema": { + "$ref": "#/components/schemas/CreateIdentityProvider" + } + } + } + }, + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "object" + } + } + } + } + }, + "security": [ + { + "access-token": [] + }, + { + "access-token": [] + }, + { + "access-token": [] + } + ] + }, + "get": { + "operationId": "IdentityProviderController_loginIdp", + "parameters": [ + { + "name": "id", + "required": true, + "in": "path", + "schema": { + "type": "string" + } + } + ], + "responses": { + "200": { + "description": "" + } + } + } + }, + "/identity-providers/callback": { + "post": { + "operationId": "IdentityProviderController_callbackIdp", + "parameters": [], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "object" + } + } + } + } + } + } + }, + "/identity-providers/links": { + "get": { + "operationId": "IdentityProviderController_providerLinks", + "parameters": [], + "responses": { + "200": { + "description": "", + "content": { + "application/json": { + "schema": { + "type": "object" + } + } + } + } + } + } + }, "/health": { "get": { "operationId": "HealthController_check", @@ -9668,80 +9654,6 @@ "theme" ] }, - "CreateIdentityProvider": { - "type": "object", - "properties": { - "name": { - "type": "string" - }, - "clientId": { - "type": "string" - }, - "clientSecret": { - "type": "string" - }, - "issuerUrl": { - "type": "string" - }, - "permissions": { - "type": "array", - "items": { - "type": "number" - } - } - }, - "required": [ - "name", - "clientId", - "clientSecret", - "issuerUrl", - "permissions" - ] - }, - "IdentityProviderResponse": { - "type": "object", - "properties": { - "id": { - "type": "string" - }, - "name": { - "type": "string" - }, - "clientId": { - "type": "string" - }, - "issueUrl": { - "type": "string" - }, - "permissions": { - "type": "array", - "items": { - "type": "string" - } - } - }, - "required": [ - "id", - "name", - "clientId", - "issueUrl", - "permissions" - ] - }, - "IdentityProviderListResponse": { - "type": "object", - "properties": { - "providers": { - "type": "array", - "items": { - "$ref": "#/components/schemas/IdentityProviderResponse" - } - } - }, - "required": [ - "providers" - ] - }, "NetworkPoliciesDTO": { "type": "object", "properties": { @@ -9849,6 +9761,80 @@ "created_at", "created_by" ] + }, + "CreateIdentityProvider": { + "type": "object", + "properties": { + "name": { + "type": "string" + }, + "clientId": { + "type": "string" + }, + "clientSecret": { + "type": "string" + }, + "issuerUrl": { + "type": "string" + }, + "permissions": { + "type": "array", + "items": { + "type": "number" + } + } + }, + "required": [ + "name", + "clientId", + "clientSecret", + "issuerUrl", + "permissions" + ] + }, + "IdentityProviderResponse": { + "type": "object", + "properties": { + "id": { + "type": "string" + }, + "name": { + "type": "string" + }, + "clientId": { + "type": "string" + }, + "issueUrl": { + "type": "string" + }, + "permissions": { + "type": "array", + "items": { + "type": "string" + } + } + }, + "required": [ + "id", + "name", + "clientId", + "issueUrl", + "permissions" + ] + }, + "IdentityProviderListResponse": { + "type": "object", + "properties": { + "providers": { + "type": "array", + "items": { + "$ref": "#/components/schemas/IdentityProviderResponse" + } + } + }, + "required": [ + "providers" + ] } } } diff --git a/src/modules/identity-provider/identity-provider.controller.ts b/src/modules/identity-provider/identity-provider.controller.ts index 813d925..5bdfd16 100644 --- a/src/modules/identity-provider/identity-provider.controller.ts +++ b/src/modules/identity-provider/identity-provider.controller.ts @@ -18,7 +18,7 @@ import { IdentityProviderService } from './identity-provider.service'; import { RequestUser, User } from 'src/decorators/user.decorator'; import { Language } from 'src/decorators/language.decorator'; import { LanguageEnum } from 'src/utils/languages.enum'; -import { PackTheMetadata } from 'src/utils/ PackTheMetadata'; +import { PackTheMetadata } from 'src/utils/PackTheMetadata'; import { ApiOkResponse } from '@nestjs/swagger'; import { CreateIdentityProvider,