> ## Documentation Index
> Fetch the complete documentation index at: https://aspect.inc/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Remove User From Workspace

> Remove a user from a workspace.

This works for both full users and stub users. Removing a user from the workspace
also removes all their project-level permissions within this workspace.



## OpenAPI

````yaml /api-reference/openapi.json delete /workspaces/{workspace_id}/users/{user_id}
openapi: 3.1.0
info:
  title: Aspect Platform API
  description: A FastAPI application for Aspect Platform functionality
  version: 0.0.0
servers:
  - url: https://api.aspect.inc
security:
  - BearerAuth: []
  - ApiKeyAuth: []
paths:
  /workspaces/{workspace_id}/users/{user_id}:
    delete:
      tags:
        - Workspaces
      summary: Remove User From Workspace
      description: >-
        Remove a user from a workspace.


        This works for both full users and stub users. Removing a user from the
        workspace

        also removes all their project-level permissions within this workspace.
      operationId: delete_Workspaces_workspaces_workspace_id_users_user_id
      parameters:
        - name: workspace_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Workspace Id
        - name: user_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: User Id
      responses:
        '204':
          description: Successful Response
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT in Authorization header. 'Bearer ' prefix optional.
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
      description: Aspect API key (sk_...) in Authorization header. 'Bearer ' optional.

````