Update existing endpoints in API reference to support Identities, update Identities docs

This commit is contained in:
Tuan Dang
2023-12-11 20:01:32 +07:00
parent f3e8ef1537
commit 5f29562fad
40 changed files with 924 additions and 333 deletions

View File

@@ -16,6 +16,54 @@
}
],
"paths": {
"/api/v1/identities/": {
"post": {
"description": "",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/identities/{identityId}": {
"patch": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
},
"delete": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/secret/{secretId}/secret-versions": {
"get": {
"summary": "Return secret versions",
@@ -176,7 +224,25 @@
"schema": {
"type": "string"
},
"description": "ID of project"
"description": "ID of project where to get secret snapshots for"
},
{
"name": "environment",
"description": "Slug of environment where to get secret snapshots for",
"required": true,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "directory",
"description": "Path where to get secret snapshots for like / or /foo/bar. Default is /",
"required": false,
"in": "query",
"schema": {
"type": "string"
}
},
{
"name": "offset",
@@ -220,7 +286,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
]
}
@@ -257,7 +324,7 @@
"schema": {
"type": "string"
},
"description": "ID of project"
"description": "ID of project where to roll back"
}
],
"responses": {
@@ -283,7 +350,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
],
"requestBody": {
@@ -293,6 +361,14 @@
"schema": {
"type": "object",
"properties": {
"environment": {
"type": "string",
"description": "Slug of environment where to roll back"
},
"directory": {
"type": "string",
"description": "Path where to roll back for like / or /foo/bar. Default is /"
},
"version": {
"type": "integer",
"description": "Version of secret snapshot to roll back to"
@@ -978,80 +1054,6 @@
}
}
},
"/api/v3/service-token/me/key": {
"get": {
"description": "",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v3/service-token/me/token": {
"post": {
"description": "",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v3/service-token/": {
"post": {
"description": "",
"responses": {
"200": {
"description": "OK"
},
"400": {
"description": "Bad Request"
}
}
}
},
"/api/v3/service-token/{serviceTokenDataId}": {
"patch": {
"description": "",
"parameters": [
{
"name": "serviceTokenDataId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
},
"400": {
"description": "Bad Request"
}
}
},
"delete": {
"description": "",
"parameters": [
{
"name": "serviceTokenDataId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/secret-rotation-providers/{workspaceId}": {
"get": {
"description": "",
@@ -1218,6 +1220,163 @@
}
}
},
"/api/v1/auth/token/renew": {
"post": {
"description": "",
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/auth/universal-auth/login": {
"post": {
"description": "",
"parameters": [
{
"name": "user-agent",
"in": "header",
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/auth/universal-auth/identities/{identityId}": {
"post": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
},
"400": {
"description": "Bad Request"
}
}
},
"patch": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
},
"400": {
"description": "Bad Request"
}
}
},
"get": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/auth/universal-auth/identities/{identityId}/client-secrets": {
"post": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
},
"get": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/auth/universal-auth/identities/{identityId}/client-secrets/{clientSecretId}/revoke": {
"post": {
"description": "",
"parameters": [
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "clientSecretId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v1/admin/config": {
"get": {
"description": "",
@@ -1807,6 +1966,9 @@
"responses": {
"200": {
"description": "OK"
},
"400": {
"description": "Bad Request"
}
}
}
@@ -4130,8 +4292,8 @@
},
"/api/v2/organizations/{organizationId}/memberships": {
"get": {
"summary": "Return organization memberships",
"description": "Return organization memberships",
"summary": "Return organization user memberships",
"description": "Return organization user memberships",
"parameters": [
{
"name": "organizationId",
@@ -4166,15 +4328,16 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
]
}
},
"/api/v2/organizations/{organizationId}/memberships/{membershipId}": {
"patch": {
"summary": "Update organization membership",
"description": "Update organization membership",
"summary": "Update organization user membership",
"description": "Update organization user membership",
"parameters": [
{
"name": "organizationId",
@@ -4211,11 +4374,15 @@
}
}
}
},
"400": {
"description": "Bad Request"
}
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
],
"requestBody": {
@@ -4236,8 +4403,8 @@
}
},
"delete": {
"summary": "Delete organization membership",
"description": "Delete organization membership",
"summary": "Delete organization user membership",
"description": "Delete organization user membership",
"parameters": [
{
"name": "organizationId",
@@ -4278,7 +4445,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
]
}
@@ -4356,6 +4524,26 @@
}
}
},
"/api/v2/organizations/{organizationId}/identity-memberships": {
"get": {
"description": "",
"parameters": [
{
"name": "organizationId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v2/workspace/{workspaceId}/memberships": {
"post": {
"description": "",
@@ -4376,8 +4564,8 @@
}
},
"get": {
"summary": "Return project memberships",
"description": "Return project memberships",
"summary": "Return project user memberships",
"description": "Return project user memberships",
"parameters": [
{
"name": "workspaceId",
@@ -4412,7 +4600,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
]
}
@@ -4878,8 +5067,8 @@
},
"/api/v2/workspace/{workspaceId}/memberships/{membershipId}": {
"patch": {
"summary": "Update project membership",
"description": "Update project membership",
"summary": "Update project user membership",
"description": "Update project user membership",
"parameters": [
{
"name": "workspaceId",
@@ -4920,7 +5109,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
],
"requestBody": {
@@ -4941,8 +5131,8 @@
}
},
"delete": {
"summary": "Delete project membership",
"description": "Delete project membership",
"summary": "Delete project user membership",
"description": "Delete project user membership",
"parameters": [
{
"name": "workspaceId",
@@ -4983,7 +5173,8 @@
},
"security": [
{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}
]
}
@@ -5008,6 +5199,106 @@
}
}
},
"/api/v2/workspace/{workspaceId}/identity-memberships/{identityId}": {
"post": {
"description": "",
"parameters": [
{
"name": "workspaceId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
},
"patch": {
"description": "",
"parameters": [
{
"name": "workspaceId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
},
"delete": {
"description": "",
"parameters": [
{
"name": "workspaceId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "identityId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v2/workspace/{workspaceId}/identity-memberships": {
"get": {
"description": "",
"parameters": [
{
"name": "workspaceId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v2/secret/batch-create/workspace/{workspaceId}/environment/{environment}": {
"post": {
"description": "",
@@ -6171,26 +6462,6 @@
}
}
},
"/api/v3/workspaces/{workspaceId}/service-token": {
"get": {
"description": "",
"parameters": [
{
"name": "workspaceId",
"in": "path",
"required": true,
"schema": {
"type": "string"
}
}
],
"responses": {
"200": {
"description": "OK"
}
}
}
},
"/api/v3/signup/complete-account/signup": {
"post": {
"description": "",
@@ -6990,7 +7261,7 @@
"type": "http",
"scheme": "bearer",
"bearerFormat": "JWT",
"description": "A service token in Infisical"
"description": "An access token in Infisical"
},
"apiKeyAuth": {
"type": "apiKey",

View File

@@ -33,11 +33,12 @@ import { ForbiddenError } from "@casl/ability";
*/
export const getOrganizationMemberships = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Return organization memberships'
#swagger.description = 'Return organization memberships'
#swagger.summary = 'Return organization user memberships'
#swagger.description = 'Return organization user memberships'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['organizationId'] = {
@@ -94,11 +95,12 @@ export const getOrganizationMemberships = async (req: Request, res: Response) =>
*/
export const updateOrganizationMembership = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Update organization membership'
#swagger.description = 'Update organization membership'
#swagger.summary = 'Update organization user membership'
#swagger.description = 'Update organization user membership'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['organizationId'] = {
@@ -214,11 +216,12 @@ export const updateOrganizationMembership = async (req: Request, res: Response)
*/
export const deleteOrganizationMembership = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Delete organization membership'
#swagger.description = 'Delete organization membership'
#swagger.summary = 'Delete organization user membership'
#swagger.description = 'Delete organization user membership'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['organizationId'] = {

View File

@@ -249,11 +249,12 @@ export const getWorkspaceServiceTokenData = async (req: Request, res: Response)
*/
export const getWorkspaceMemberships = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Return project memberships'
#swagger.description = 'Return project memberships'
#swagger.summary = 'Return project user memberships'
#swagger.description = 'Return project user memberships'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['workspaceId'] = {
@@ -312,11 +313,12 @@ export const getWorkspaceMemberships = async (req: Request, res: Response) => {
*/
export const updateWorkspaceMembership = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Update project membership'
#swagger.description = 'Update project membership'
#swagger.summary = 'Update project user membership'
#swagger.description = 'Update project user membership'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['workspaceId'] = {
@@ -402,11 +404,12 @@ export const updateWorkspaceMembership = async (req: Request, res: Response) =>
*/
export const deleteWorkspaceMembership = async (req: Request, res: Response) => {
/*
#swagger.summary = 'Delete project membership'
#swagger.description = 'Delete project membership'
#swagger.summary = 'Delete project user membership'
#swagger.description = 'Delete project user membership'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['workspaceId'] = {

View File

@@ -62,15 +62,30 @@ export const getWorkspaceSecretSnapshots = async (req: Request, res: Response) =
#swagger.description = 'Return project secret snapshots ids'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['workspaceId'] = {
"description": "ID of project",
"description": "ID of project where to get secret snapshots for",
"required": true,
"type": "string"
}
#swagger.parameters['environment'] = {
"description": "Slug of environment where to get secret snapshots for",
"required": true,
"type": "string",
"in": "query"
}
#swagger.parameters['directory'] = {
"description": "Path where to get secret snapshots for like / or /foo/bar. Default is /",
"required": false,
"type": "string",
"in": "query"
}
#swagger.parameters['offset'] = {
"description": "Number of secret snapshots to skip",
"required": false,
@@ -195,11 +210,12 @@ export const rollbackWorkspaceSecretSnapshot = async (req: Request, res: Respons
#swagger.description = 'Roll back project secrets to those captured in a secret snapshot version.'
#swagger.security = [{
"apiKeyAuth": []
"apiKeyAuth": [],
"bearerAuth": []
}]
#swagger.parameters['workspaceId'] = {
"description": "ID of project",
"description": "ID of project where to roll back",
"required": true,
"type": "string"
}
@@ -211,6 +227,14 @@ export const rollbackWorkspaceSecretSnapshot = async (req: Request, res: Respons
"schema": {
"type": "object",
"properties": {
"environment": {
"type": "string",
"description": "Slug of environment where to roll back"
},
"directory": {
"type": "string",
"description": "Path where to roll back for like / or /foo/bar. Default is /"
},
"version": {
"type": "integer",
"description": "Version of secret snapshot to roll back to",

View File

@@ -7,7 +7,7 @@ import { workspaceController } from "../../controllers/v1";
router.get(
"/:workspaceId/secret-snapshots",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.getWorkspaceSecretSnapshots
);
@@ -23,7 +23,7 @@ router.get(
router.post(
"/:workspaceId/secret-snapshots/rollback",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.rollbackWorkspaceSecretSnapshot
);
@@ -31,7 +31,7 @@ router.post(
router.get(
"/:workspaceId/audit-logs",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.getWorkspaceAuditLogs
);

View File

@@ -7,7 +7,7 @@ import { AuthMode } from "../../variables";
router.post(
"/",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
secretImpsController.createSecretImp
);
@@ -15,7 +15,7 @@ router.post(
router.put(
"/:id",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
secretImpsController.updateSecretImport
);
@@ -23,7 +23,7 @@ router.put(
router.delete(
"/:id",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
secretImpsController.deleteSecretImport
);
@@ -31,7 +31,7 @@ router.delete(
router.get(
"/",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
secretImpsController.getSecretImports
);

View File

@@ -12,7 +12,7 @@ import { AuthMode } from "../../variables";
router.post(
"/",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
createFolder
);
@@ -20,7 +20,7 @@ router.post(
router.patch(
"/:folderName",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
updateFolderById
);
@@ -28,7 +28,7 @@ router.patch(
router.delete(
"/:folderName",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
deleteFolder
);
@@ -36,7 +36,7 @@ router.delete(
router.get(
"/",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.SERVICE_TOKEN, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
getFolders
);

View File

@@ -7,7 +7,7 @@ import { AuthMode } from "../../variables";
router.post(
"/:workspaceId/environments",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
environmentController.createWorkspaceEnvironment
);
@@ -15,7 +15,7 @@ router.post(
router.put(
"/:workspaceId/environments",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
environmentController.renameWorkspaceEnvironment
);
@@ -23,7 +23,7 @@ router.put(
router.patch(
"/:workspaceId/environments",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
environmentController.reorderWorkspaceEnvironments
);
@@ -31,7 +31,7 @@ router.patch(
router.delete(
"/:workspaceId/environments",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
environmentController.deleteWorkspaceEnvironment
);

View File

@@ -9,7 +9,7 @@ import { organizationsController } from "../../controllers/v2";
router.get(
"/:organizationId/memberships",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
organizationsController.getOrganizationMemberships
);
@@ -17,7 +17,7 @@ router.get(
router.patch(
"/:organizationId/memberships/:membershipId",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
organizationsController.updateOrganizationMembership
);
@@ -25,7 +25,7 @@ router.patch(
router.delete(
"/:organizationId/memberships/:membershipId",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
organizationsController.deleteOrganizationMembership
);
@@ -33,7 +33,7 @@ router.delete(
router.get(
"/:organizationId/workspaces",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
organizationsController.getOrganizationWorkspaces
);

View File

@@ -62,7 +62,7 @@ router.get(
// new - TODO: rewire dashboard to this route
"/:workspaceId/memberships",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.getWorkspaceMemberships
);
@@ -71,7 +71,7 @@ router.patch(
// TODO - rewire dashboard to this route
"/:workspaceId/memberships/:membershipId",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.updateWorkspaceMembership
);
@@ -80,7 +80,7 @@ router.delete(
// TODO - rewire dashboard to this route
"/:workspaceId/memberships/:membershipId",
requireAuth({
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY]
acceptedAuthModes: [AuthMode.JWT, AuthMode.API_KEY, AuthMode.IDENTITY_ACCESS_TOKEN]
}),
workspaceController.deleteWorkspaceMembership
);

View File

@@ -30,7 +30,7 @@ const generateOpenAPISpec = async () => {
type: "http",
scheme: "bearer",
bearerFormat: "JWT",
description: "A service token in Infisical"
description: "An access token in Infisical"
},
apiKeyAuth: {
type: "apiKey",