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

# Delete your account

> Deletes the caller's own user identity. There is no `id` parameter — the account to delete is resolved from the `sub` claim of the bearer token itself, so a caller can only ever delete their own account.

Requires a **user token** (the user access token from [Exchange a verification code](/auth/exchange-verification-code) or [Refresh a token](/auth/refresh-token)) — the service token from [Obtain a service token](/auth/obtain-token) is rejected with 403.

Idempotent: deleting an account that's already deleted, or doesn't exist, still returns 200.



## OpenAPI

````yaml /openapi.json delete /iam/users/me
openapi: 3.1.0
info:
  title: OpenLoop API
  version: 0.1.0
  description: >-
    Unified reference for the OpenLoop Patient (clinical) and Payments & Revenue
    APIs.
servers:
  - url: https://api.openloophealth.com/v0.1
    description: Production partner edge
  - url: https://api-staging.openloophealth.com/v0.1
    description: Staging partner edge (sandbox credentials)
security: []
paths:
  /iam/users/me:
    delete:
      tags:
        - Users
      summary: Delete your account
      description: >-
        Deletes the caller's own user identity. There is no `id` parameter — the
        account to delete is resolved from the `sub` claim of the bearer token
        itself, so a caller can only ever delete their own account.


        Requires a **user token** (the user access token from [Exchange a
        verification code](/auth/exchange-verification-code) or [Refresh a
        token](/auth/refresh-token)) — the service token from [Obtain a service
        token](/auth/obtain-token) is rejected with 403.


        Idempotent: deleting an account that's already deleted, or doesn't
        exist, still returns 200.
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      status:
                        type: string
                        enum:
                          - deleted
                    required:
                      - status
                  request_id:
                    type: string
                required:
                  - data
                  - request_id
        '401':
          description: Missing or invalid bearer token
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Bearer token belongs to a service/app client, not a user
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - userToken: []
components:
  schemas:
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            message:
              type: string
            error_code:
              type: string
          required:
            - message
            - error_code
        request_id:
          type: string
      required:
        - error
        - request_id
  securitySchemes:
    userToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        User access token issued by POST /auth/token via the verification-code
        grant (after Verify a one-time code) or the refresh_token grant.

````

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