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

# Delete Memory Record

> Soft-delete a memory record (sets is_active = False).

The row is retained, matching the sessions/projects soft-delete
convention; browse and retrieval exclude inactive records. Returns
404 (never 403) when the record does not exist, belongs to another
user, or the id is unparseable, so cross-tenant existence is not
leaked. get_db_for_principal applies set_rls_user before the write,
matching the ingest path.

# IDOR AUDIT PASS - MemoryRecord.user_id == authenticated user_id is
# enforced in the WHERE clause on both the lookup and the write.



## OpenAPI

````yaml delete /api/v1/memory/records/{record_id}
openapi: 3.1.0
info:
  title: EDN Memory Engine
  version: 0.1.0
servers:
  - description: EDN evaluation endpoint
    url: https://api.tensorpro.ai
security:
  - EDNApiKey: []
paths:
  /api/v1/memory/records/{record_id}:
    delete:
      summary: Delete Memory Record
      description: |-
        Soft-delete a memory record (sets is_active = False).

        The row is retained, matching the sessions/projects soft-delete
        convention; browse and retrieval exclude inactive records. Returns
        404 (never 403) when the record does not exist, belongs to another
        user, or the id is unparseable, so cross-tenant existence is not
        leaked. get_db_for_principal applies set_rls_user before the write,
        matching the ingest path.

        # IDOR AUDIT PASS - MemoryRecord.user_id == authenticated user_id is
        # enforced in the WHERE clause on both the lookup and the write.
      operationId: delete_memory_record_api_v1_memory_records__record_id__delete
      parameters:
        - in: path
          name: record_id
          required: true
          schema:
            title: Record Id
            type: string
      responses:
        '204':
          description: Successful Response
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
          description: Validation Error
components:
  schemas:
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          title: Detail
          type: array
      title: HTTPValidationError
      type: object
    ValidationError:
      properties:
        ctx:
          title: Context
          type: object
        input:
          title: Input
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          title: Location
          type: array
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
      required:
        - loc
        - msg
        - type
      title: ValidationError
      type: object
  securitySchemes:
    EDNApiKey:
      description: >-
        EDN API key presented as 'Bearer <key>' in the Authorization header.
        Create and manage keys from the Console.
      in: header
      name: Authorization
      type: apiKey

````