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

# Delete Agent Legacy

> Delete agent from local database.

**Use DELETE /{agent_id} instead - it provides more comprehensive cleanup.**

This legacy endpoint:
- Delete agent from local database
- Delete all associated data (sessions, knowledge base, etc.)



## OpenAPI

````yaml https://api.mrassistant.ai/openapi.json delete /agents/{agent_id}/legacy
openapi: 3.1.0
info:
  title: Backend - Multilingual Voice Agent System
  description: FastAPI backend for multilingual voice agents with tool use
  version: 1.0.0
servers: []
security: []
paths:
  /agents/{agent_id}/legacy:
    delete:
      tags:
        - agents
      summary: Delete Agent Legacy
      description: >-
        Delete agent from local database.


        **Use DELETE /{agent_id} instead - it provides more comprehensive
        cleanup.**


        This legacy endpoint:

        - Delete agent from local database

        - Delete all associated data (sessions, knowledge base, etc.)
      operationId: delete_agent_legacy
      parameters:
        - name: agent_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Agent Id
      responses:
        '204':
          description: Successful Response
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      deprecated: true
      security:
        - HTTPBearer: []
components:
  schemas:
    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
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````