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

# Delete an API key

> Revokes a key immediately; anything using it stops working. You can delete your own keys, and owners and admins can delete anyone's. Someone else's key you can't manage returns 404.




## OpenAPI

````yaml /openapi/workspace.yaml delete /workspaces/{workspaceId}/api-keys/{keyId}
openapi: 3.1.0
info:
  title: Connie Workspace API
  version: 1.0.0
  description: >
    Endpoints the Connie web app uses for workspace settings, members and API
    keys. They authenticate with your signed-in browser session — see
    https://docs.connie.ai/api-reference/authentication. These are the app's own
    endpoints and can change when the app changes.
servers:
  - url: https://connie.ai/api
security:
  - sessionCookie: []
tags:
  - name: Settings
    description: The workspace name, logo and memory switch. Owners and admins only.
  - name: Members
    description: People in the workspace and their roles.
  - name: Invitations
    description: Email invitations and the workspace invite link.
  - name: Join requests
    description: People who asked to join the workspace.
  - name: API keys
    description: >
      Workspace API keys for MCP clients and agents. Keys work only with the
      Connie MCP server; these web app endpoints don't accept them.
paths:
  /workspaces/{workspaceId}/api-keys/{keyId}:
    delete:
      tags:
        - API keys
      summary: Delete an API key
      description: >
        Revokes a key immediately; anything using it stops working. You can
        delete your own keys, and owners and admins can delete anyone's. Someone
        else's key you can't manage returns 404.
      operationId: deleteApiKey
      parameters:
        - $ref: '#/components/parameters/workspaceId'
        - name: keyId
          in: path
          required: true
          description: The key's `id` from List API keys.
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: Revoked.
          content:
            application/json:
              schema:
                type: object
                properties:
                  revoked:
                    type: string
                    format: uuid
                    description: The id of the revoked key.
        '400':
          description: '`keyId` is not a valid id.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          description: Not a member, or a guest.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          $ref: '#/components/responses/NotFound'
        '503':
          $ref: '#/components/responses/Unavailable'
components:
  parameters:
    workspaceId:
      name: workspaceId
      in: path
      required: true
      description: The workspace id, as in the app URL `connie.ai/<workspaceId>/...`.
      schema:
        type: string
        format: uuid
  schemas:
    Error:
      type: object
      properties:
        error:
          type: string
          description: A readable message.
        code:
          type: string
          description: >-
            A machine-readable code such as `VALIDATION_ERROR`, `FORBIDDEN` or
            `CONFLICT`, when the route sets one.
  responses:
    Unauthorized:
      description: No valid session, or the session has expired (`SESSION_EXPIRED`).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Not found in this workspace.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unavailable:
      description: API keys are temporarily unavailable. Try again.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    sessionCookie:
      type: apiKey
      in: header
      name: Cookie
      description: >-
        The full Cookie header copied from a signed-in connie.ai browser
        request. See the Authentication page.

````

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