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

# Remove group members

> <Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>

Removes members from a custom group, up to 200 per request.

Each affected member's role is worked out again from their other groups. A member left in no group becomes a viewer, or gets the workspace's SSO default role when SSO is set up.

Removing someone who isn't in the group changes nothing, so retrying is safe. A group whose `source` is `idp` gets its name and members from your identity provider, so they can't be changed here. You can't make a change that removes your own admin access. Removing members works on any plan, so you can take groups apart after a downgrade.

This is limited to 60 requests per minute, shared with the other endpoints that change groups or their members. A signed-in session has its own limit, and every personal access token for the workspace shares one. Some workspaces have a different limit.

<Note>Call this as an owner or admin of the workspace, with a personal access token for that workspace sent as a Bearer token, or from a signed-in session. A read-only token is refused, and workspace API keys aren't accepted.</Note>



## OpenAPI

````yaml /developers/references/app-management/app-management-openapi.json post /api/workspace/groups/{group_id}/members/remove
openapi: 3.1.0
info:
  title: Base44 App Management API
  version: 1.0.0
servers:
  - url: https://app.base44.com
security:
  - PersonalAccessTokenAuth: []
paths:
  /api/workspace/groups/{group_id}/members/remove:
    post:
      summary: Remove group members
      description: >-
        <Info>This API is in beta. Endpoints, fields, and behavior may still
        change, so avoid depending on it in production.</Info>


        Removes members from a custom group, up to 200 per request.


        Each affected member's role is worked out again from their other groups.
        A member left in no group becomes a viewer, or gets the workspace's SSO
        default role when SSO is set up.


        Removing someone who isn't in the group changes nothing, so retrying is
        safe. A group whose `source` is `idp` gets its name and members from
        your identity provider, so they can't be changed here. You can't make a
        change that removes your own admin access. Removing members works on any
        plan, so you can take groups apart after a downgrade.


        This is limited to 60 requests per minute, shared with the other
        endpoints that change groups or their members. A signed-in session has
        its own limit, and every personal access token for the workspace shares
        one. Some workspaces have a different limit.


        <Note>Call this as an owner or admin of the workspace, with a personal
        access token for that workspace sent as a Bearer token, or from a
        signed-in session. A read-only token is refused, and workspace API keys
        aren't accepted.</Note>
      operationId: remove_group_members_api_workspace_groups__group_id__members_remove_post
      parameters:
        - name: group_id
          in: path
          required: true
          schema:
            type: string
            description: >-
              ID of the group to remove members from. Get it from `id` in [List
              workspace groups](/api-reference/list-workspace-groups).
            title: Group Id
          description: >-
            ID of the group to remove members from. Get it from `id` in [List
            workspace groups](/api-reference/list-workspace-groups).
          example: 68b4e1d2c9a7f3001e2d4b61
        - name: workspaceId
          in: query
          required: true
          schema:
            type: string
            minLength: 1
            description: >-
              ID of the workspace. With a personal access token, use the token's
              workspace. Get it from `organization_id` in [Get
              app](/api-reference/get-app).
            title: Workspaceid
          description: >-
            ID of the workspace. With a personal access token, use the token's
            workspace. Get it from `organization_id` in [Get
            app](/api-reference/get-app).
          example: 67e0b12c4d8a3f005b21c9e4
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GroupMembersModifyRequest'
      responses:
        '200':
          description: The members are no longer in the group.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GroupChangeResult'
              example:
                status: success
                message: Members removed from group.
        '400':
          description: >-
            The group's members come from your identity provider, or the change
            would remove your own admin access.
        '401':
          description: Missing or invalid credentials.
        '403':
          description: >-
            You aren't an owner or admin of the workspace, your token is for a
            different workspace or is read-only, or your credential can't be
            used on this endpoint.
        '404':
          description: Group not found in this workspace.
        '409':
          description: Your workspace requires an unlocked SSO session.
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '429':
          description: Rate limit exceeded.
components:
  schemas:
    GroupMembersModifyRequest:
      properties:
        emails:
          items:
            type: string
          type: array
          maxItems: 200
          minItems: 1
          title: Emails
          description: Emails of the members, 1 to 200.
          example:
            - dana@acme.com
            - sam@acme.com
      type: object
      required:
        - emails
      title: GroupMembersModifyRequest
    GroupChangeResult:
      properties:
        status:
          type: string
          const: success
          title: Status
          description: Always `success`.
          example: success
        message:
          type: string
          title: Message
          description: Short confirmation. Its wording can change, so don't parse it.
          example: Members added to group.
      type: object
      required:
        - status
        - message
      title: GroupChangeResult
      description: Confirms the change.
    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:
    PersonalAccessTokenAuth:
      type: http
      scheme: bearer
      description: 'Personal access token, sent as `Authorization: Bearer <token>`.'

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.