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

# Remove Seats

> Remove extra seat add-ons from the existing subscription.

Reduces the seat add-on quantity by ``seats_to_remove``. Cannot go below
zero extra seats. If the quantity reaches zero the add-on line item is
removed from the subscription entirely.

When the reduction would put the workspace over the new seat limit, the
caller must supply ``member_ids_to_evict`` — exactly as many IDs as the
overflow count.  If they are not supplied, the endpoint returns 409 with
``type="member_eviction_required"`` and the full list of evictable members
(non-owners, sorted newest-first) so the frontend can render a picker.

The Stripe item modification and the member removals are committed together
so the workspace is never left in a partially-updated state.



## OpenAPI

````yaml /openapi.json delete /api/v1/workspaces/{workspace_id}/billing/seats
openapi: 3.1.0
info:
  description: Change Impact Engine for multi-repo systems
  title: Riftmap
  version: 1.12.3
servers: []
security: []
paths:
  /api/v1/workspaces/{workspace_id}/billing/seats:
    delete:
      tags:
        - billing
      summary: Remove Seats
      description: >-
        Remove extra seat add-ons from the existing subscription.


        Reduces the seat add-on quantity by ``seats_to_remove``. Cannot go below

        zero extra seats. If the quantity reaches zero the add-on line item is

        removed from the subscription entirely.


        When the reduction would put the workspace over the new seat limit, the

        caller must supply ``member_ids_to_evict`` — exactly as many IDs as the

        overflow count.  If they are not supplied, the endpoint returns 409 with

        ``type="member_eviction_required"`` and the full list of evictable
        members

        (non-owners, sorted newest-first) so the frontend can render a picker.


        The Stripe item modification and the member removals are committed
        together

        so the workspace is never left in a partially-updated state.
      operationId: remove_seats_api_v1_workspaces__workspace_id__billing_seats_delete
      parameters:
        - in: path
          name: workspace_id
          required: true
          schema:
            format: uuid
            title: Workspace Id
            type: string
        - in: header
          name: X-Workspace-Id
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: X-Workspace-Id
        - in: cookie
          name: riftmap_access
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: Riftmap Access
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/RemoveSeatsRequest'
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RemoveSeatsResponse'
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
      security:
        - APIKeyHeader: []
        - HTTPBearer: []
components:
  schemas:
    RemoveSeatsRequest:
      properties:
        member_ids_to_evict:
          anyOf:
            - items:
                format: uuid
                type: string
              type: array
            - type: 'null'
          title: Member Ids To Evict
        seats_to_remove:
          title: Seats To Remove
          type: integer
      required:
        - seats_to_remove
      title: RemoveSeatsRequest
      type: object
    RemoveSeatsResponse:
      properties:
        extra_seats:
          title: Extra Seats
          type: integer
        seat_limit:
          title: Seat Limit
          type: integer
      required:
        - extra_seats
        - seat_limit
      title: RemoveSeatsResponse
      type: object
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    APIKeyHeader:
      in: header
      name: X-API-Key
      type: apiKey
    HTTPBearer:
      description: API key as Bearer token (rfm_live_... prefix)
      scheme: bearer
      type: http

````