openapi: 3.2.0 info: title: Aembit Cloud User API version: v1 servers: - url: https://{tenant}.aembit.io variables: tenant: default: tenant description: Aembit Tenant ID security: - {} tags: - name: User paths: /api/v1/users: get: tags: - User summary: Get a page of Users description: Get a page of Users. operationId: get-users parameters: - name: page in: query schema: type: integer format: int32 default: 1 - name: per-page in: query schema: type: integer format: int32 default: 100 - name: filter in: query schema: type: string default: '' - name: order in: query schema: type: string default: '' - name: group-by in: query schema: type: string default: '' responses: '200': description: Page of Users content: application/json: schema: $ref: '#/components/schemas/UserListDTO' '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' post: tags: - User summary: Create a User description: Create a User. operationId: post-user requestBody: description: UserDTO content: application/json: schema: $ref: '#/components/schemas/UserDTO' responses: '201': description: Created User content: application/json: schema: $ref: '#/components/schemas/UserDTO' '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' /api/v1/users/{id}: patch: tags: - User summary: Patch a User description: Patch a User identified by its ID. operationId: patch-user parameters: - name: id in: path description: ID of User required: true schema: type: string format: uuid requestBody: description: UserPatchDTO content: application/json: schema: $ref: '#/components/schemas/UserPatchDTO' responses: '200': description: Patched User content: application/json: schema: $ref: '#/components/schemas/UserDTO' '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' get: tags: - User summary: Get a User description: Get a User identified by its ID. operationId: get-user parameters: - name: id in: path description: ID of User required: true schema: type: string format: uuid responses: '201': description: User content: application/json: schema: $ref: '#/components/schemas/UserDTO' '204': description: User Not Found '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' put: tags: - User summary: Update a User description: Update a User. operationId: put-user parameters: - name: id in: path required: true schema: type: string requestBody: description: UserDTO content: application/json: schema: $ref: '#/components/schemas/UserDTO' responses: '200': description: User content: application/json: schema: $ref: '#/components/schemas/UserDTO' '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' delete: tags: - User summary: Delete a User description: Delete a User identified by its ID. operationId: delete-user parameters: - name: id in: path description: ID of User required: true schema: type: string format: uuid responses: '204': description: Successfully deleted User '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' /api/v1/users/{id}/unlock: post: tags: - User summary: Unlock a User description: Unlock a User identified by its ID. operationId: post-user-unlock parameters: - name: id in: path description: ID of User required: true schema: type: string format: uuid responses: '200': description: Successfully unlocked User content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' '400': description: Bad Request '401': description: Not Authenticated '500': description: Internal Server Error content: application/json: schema: description: DTO for a Generic API Response $ref: '#/components/schemas/GenericResponseDTO' components: schemas: ResourceSetDTO: required: - isActive - name type: object properties: externalId: type: string format: uuid name: maxLength: 128 minLength: 1 type: string description: Name of the Entity description: type: - 'null' - string description: Description of the Entity isActive: type: boolean description: True/False value that determines if this entity is Active or Disabled format: boolean tags: type: - 'null' - array items: description: Aembit Entity Tag Details $ref: '#/components/schemas/TagDTO' createdAt: type: string format: date-time modifiedAt: type: - 'null' - string format: date-time createdBy: type: - 'null' - string modifiedBy: type: - 'null' - string serverWorkloadCount: type: - 'null' - integer description: Server Workloads associated with this Resource Set format: int32 clientWorkloadCount: type: - 'null' - integer description: Client Workloads associated with this Resource Set format: int32 accessPolicyCount: type: - 'null' - integer description: Access Policies associated with this Resource Set format: int32 trustProviderCount: type: - 'null' - integer description: Trust Providers associated with this Resource Set format: int32 accessConditionCount: type: - 'null' - integer description: Access Conditions associated with this Resource Set format: int32 credentialProviderCount: type: - 'null' - integer description: Credential Providers associated with this Resource Set format: int32 roles: type: - 'null' - array items: type: string format: uuid description: Roles associated with this Resource Set rolesDetails: type: - 'null' - array items: description: Individual Role $ref: '#/components/schemas/RoleDTO' description: Details of the Roles associated with this Resource Set users: type: - 'null' - array items: type: string description: Users associated with this Resource Set standaloneCertificateAuthority: type: - 'null' - string description: Standalone Certificate Authority associated with this Resource Set format: uuid additionalProperties: false description: Individual Resource Set TagDTO: required: - key - value type: object properties: key: minLength: 1 type: string description: Tag Key value: minLength: 1 type: string description: Tag Key Value additionalProperties: false description: Aembit Entity Tag Details UserTokensDTO: type: object properties: id: type: string format: uuid name: type: - 'null' - string verified: type: boolean createdAt: type: string format: date-time additionalProperties: false PermissionDTO: type: object properties: name: type: - 'null' - string description: Name of the Permission Target read: type: boolean description: True if this permission allows access to Read the Permission Target, False otherwise write: type: boolean description: True if this permission allows access to Write the Permission Target, False otherwise isWritable: type: boolean description: True if this permission allows access to Write the Permission Target, False otherwise isReadable: type: boolean description: True if this permission allows access to Read the Permission Target, False otherwise accessLevel: type: - 'null' - string description: Description of the Permission level readOnly: true additionalProperties: false description: Individual Permission details RoleDTO: required: - isActive - name type: object properties: externalId: type: string format: uuid name: maxLength: 128 minLength: 1 type: string description: Name of the Entity description: type: - 'null' - string description: Description of the Entity isActive: type: boolean description: True/False value that determines if this entity is Active or Disabled format: boolean tags: type: - 'null' - array items: description: Aembit Entity Tag Details $ref: '#/components/schemas/TagDTO' createdAt: type: string format: date-time modifiedAt: type: - 'null' - string format: date-time createdBy: type: - 'null' - string modifiedBy: type: - 'null' - string usersCount: type: integer description: Number of Users associated with this Role format: int32 credentialProvidersCount: type: integer description: Number of Credential Providers associated with this Role format: int32 isSystem: type: boolean description: True if this is a system included Role (e.g. SuperAdmin or Auditor) permissions: type: - 'null' - array items: description: Individual Permission details $ref: '#/components/schemas/PermissionDTO' description: Permissions assigned to this Role resourceSets: type: - 'null' - array items: description: Individual Resource Set $ref: '#/components/schemas/ResourceSetDTO' description: Resource Sets assigned to this Role additionalProperties: false description: Individual Role GenericResponseDTO: type: object properties: success: type: boolean description: True if the API call was successful, False otherwise message: type: - 'null' - string description: Message to indicate why the API call failed id: type: integer description: Unique identifier of the API response format: int32 additionalProperties: false description: DTO for a Generic API Response UserListDTO: type: object properties: page: type: integer description: Page of entities format: int32 perPage: type: integer description: Number of entities requested for the current page format: int32 order: type: - 'null' - string description: Ordering criteria used for the current page statusCode: type: integer format: int32 recordsTotal: type: integer format: int32 users: type: - 'null' - array items: $ref: '#/components/schemas/UserDTO' additionalProperties: false UserDTO: required: - email - firstName - lastName type: object properties: email: minLength: 1 type: string format: email externalId: type: string format: uuid roles: type: - 'null' - array items: type: string format: uuid rolesDetails: type: - 'null' - array items: description: Individual Role $ref: '#/components/schemas/RoleDTO' firstName: maxLength: 64 minLength: 2 type: string lastName: maxLength: 64 minLength: 2 type: string phoneNumber: type: - 'null' - string createdAt: type: string format: date-time isActive: type: boolean twoFactorEnabled: type: boolean isLocked: type: boolean tags: type: - 'null' - array items: description: Aembit Entity Tag Details $ref: '#/components/schemas/TagDTO' userTokens: type: - 'null' - array items: $ref: '#/components/schemas/UserTokensDTO' additionalProperties: false UserPatchDTO: type: object properties: email: type: - 'null' - string firstName: type: - 'null' - string lastName: type: - 'null' - string phoneNumber: type: - 'null' - string isActive: type: - 'null' - boolean additionalProperties: false securitySchemes: bearerAuth: type: http description: Authorization header using the Bearer scheme. scheme: bearer bearerFormat: Reference