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

# Set Workspace Third-Party Disabling Policy

> Set the workspace-wide Third-Party Disabling policy. When set, it forces, for every API key in the workspace, whether the holder of a key (potentially a third party who found it) may disable it via the self-disable endpoint or when it leaks publicly - overriding each key's own setting. Pass `true` to allow it for all keys, `false` to forbid it for all keys, or `null` to clear the override so per-key values and the plan default apply again. Workspace admins only.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/workspaces/api-keys/third-party-disabling
openapi: 3.1.0
info:
  title: Threetone API Documentation
  description: >-
    This is the documentation for the Threetone API. You can use this API to use
    our service programmatically with API keys sent in the x-api-key header. You
    can create and manage API keys in the dashboard at
    https://threetone.in/app/developers/api-keys.
  version: '1.0'
servers:
  - url: https://api.threetone.in
    description: Production
security: []
paths:
  /v1/workspaces/api-keys/third-party-disabling:
    post:
      tags:
        - workspace
        - api-key
      summary: Set Workspace Third-Party Disabling Policy
      description: >-
        Set the workspace-wide Third-Party Disabling policy. When set, it
        forces, for every API key in the workspace, whether the holder of a key
        (potentially a third party who found it) may disable it via the
        self-disable endpoint or when it leaks publicly - overriding each key's
        own setting. Pass `true` to allow it for all keys, `false` to forbid it
        for all keys, or `null` to clear the override so per-key values and the
        plan default apply again. Workspace admins only.
      operationId: set_third_party_disabling_policy
      parameters:
        - name: x-api-key
          in: header
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            description: >-
              Your API key for programmatic access. Send it in the x-api-key
              header; you can create and manage keys from the Developers page.
            title: X-Api-Key
          description: >-
            Your API key for programmatic access. Send it in the x-api-key
            header; you can create and manage keys from the Developers page.
      requestBody:
        content:
          application/json:
            schema:
              $ref: >-
                #/components/schemas/Body_Set_workspace_Third_Party_Disabling_policy_v1_workspaces_api_keys_third_party_disabling_post
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema: {}
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    Body_Set_workspace_Third_Party_Disabling_policy_v1_workspaces_api_keys_third_party_disabling_post:
      properties:
        third_party_disable_allowed:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Third Party Disable Allowed
          description: >-
            `true` forces every key in the workspace to be disable-able by its
            holder; `false` forbids it for every key; `null` clears the override
            (per-key values and the plan default apply).
      type: object
      title: >-
        Body_Set_workspace_Third_Party_Disabling_policy_v1_workspaces_api_keys_third_party_disabling_post
    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

````