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

# Delete an identity

> Permanently deletes an identity from your workspace and cleans up associated budget configurations. This action cannot be undone.



## OpenAPI

````yaml delete /v2/identities/{id}
openapi: 3.1.0
info:
  title: orq.ai API
  version: '2.0'
  description: orq.ai API documentation
servers:
  - url: https://api.orq.ai
security:
  - ApiKey: []
tags:
  - name: Guardrail Rules
  - name: Policies
  - name: Routing Rules
  - name: Files
    description: File upload and retrieval operations.
  - name: FilesService
  - name: Projects
    description: Projects organize resources within a workspace
  - name: ProjectsService
  - name: Skills
    description: >-
      Skills are modular instructions you can use to codify processes and
      conventions
  - name: SkillsService
  - name: Responses
  - description: >-
      Run agents on a cadence — cron, interval, or one-off. Minimum firing
      interval is 1 hour.
    name: Agent Schedules
  - name: Reporting
    description: >-
      GenAI reporting API over canonical analytics rollups. Accepts a metric
      name, time range, grain, group-by, and filters; returns a typed time
      series and optional totals.
  - name: ReportingService
    description: |-
      ReportingService exposes a single QueryReport RPC that maps allowlisted
       analytics payloads onto safe rollup queries. Callers never send SQL;
       the backend picks the rollup family and grain from the metric
       catalogue, the requested range, and the requested grouping.
externalDocs:
  url: https://docs.orq.ai
  description: orq.ai Documentation
paths:
  /v2/identities/{id}:
    delete:
      tags:
        - Identities
      summary: Delete an identity
      description: >-
        Permanently deletes an identity from your workspace and cleans up
        associated budget configurations. This action cannot be undone.
      operationId: DeleteIdentity
      parameters:
        - schema:
            type: string
            description: Identity ID or External ID
          required: true
          description: Identity ID or External ID
          name: id
          in: path
      responses:
        '204':
          description: Identity successfully deleted
        '404':
          description: Identity not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    description: Error message
                required:
                  - error
              example:
                error: Identity not found
      x-code-samples:
        - lang: typescript
          label: Node.js
          source: |-
            import { Orq } from "@orq-ai/node";

            const orq = new Orq({
              apiKey: process.env["ORQ_API_KEY"]
            });

            // Delete by identity ID
            await orq.identities.delete("identity_01ARZ3NDEKTSV4RRFFQ69G5FAV");

            // Or delete by external ID
            await orq.identities.delete("user_12345");

            console.log("Identity deleted successfully");
        - lang: python
          label: Python
          source: |-
            from orq_ai_sdk import Orq
            import os

            orq = Orq(api_key=os.getenv("ORQ_API_KEY"))

            # Delete by identity ID
            orq.identities.delete("identity_01ARZ3NDEKTSV4RRFFQ69G5FAV")

            # Or delete by external ID
            orq.identities.delete("user_12345")

            print("Identity deleted successfully")
components:
  securitySchemes:
    ApiKey:
      type: http
      scheme: bearer
      bearerFormat: JWT

````