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

# Delete mutation

> Delete a mutation.



## OpenAPI

````yaml /api-reference/v1/mutations-v1.yaml delete /agents/{agent_id}/mutations/{mutation_id}
openapi: 3.0.3
info:
  title: Coval Agent Mutations API
  version: 1.0.0
  description: >
    Manage configuration variants (mutations) for AI agents.


    Mutations enable A/B testing of agent configurations by storing only the

    delta changes (config_overrides) that get deep-merged with the parent agent

    at run time. This allows testing multiple configuration variants within a

    single simulation run.


    ## Key Concepts


    - **Mutation**: A named configuration variant of an agent

    - **config_overrides**: Delta configuration merged with parent agent at
    runtime

    - **parameter_values**: Flattened key-value display metadata (auto-derived
    if not provided)


    ## Multi-Mutation Runs


    Launch runs with multiple mutations using the Runs API:

    - `mutation_id`: Single mutation (runs base agent + mutation)

    - `mutation_ids`: Multiple mutations (runs base agent + all mutations)

    - Base agent always runs alongside mutations
  contact:
    name: Coval API Support
    email: support@coval.dev
    url: https://docs.coval.ai
  license:
    name: Proprietary
    url: https://coval.dev/terms
servers:
  - url: https://api.coval.dev/v1
    description: Production API
security:
  - ApiKeyAuth: []
tags:
  - name: Mutations
    description: CRUD operations for agent configuration mutations
paths:
  /agents/{agent_id}/mutations/{mutation_id}:
    delete:
      tags:
        - Mutations
      summary: Delete mutation
      description: Delete a mutation.
      operationId: deleteMutation
      parameters:
        - name: agent_id
          in: path
          required: true
          schema:
            type: string
            pattern: ^[A-Za-z0-9]{22}$
          description: Parent agent ID (22-character ShortUUID)
          example: gk3jK9mPq2xRt5vW8yZaBc
        - name: mutation_id
          in: path
          required: true
          schema:
            type: string
            pattern: ^[A-Za-z0-9]{26}$
          description: Mutation ID (26-character ULID)
          example: 01ARZ3NDEKTSV4RRFFQ69G5FAV
      responses:
        '204':
          description: Mutation deleted successfully (or already deleted)
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          description: Agent or mutation not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              examples:
                notFound:
                  $ref: '#/components/examples/MutationNotFoundError'
        '500':
          $ref: '#/components/responses/InternalError'
      security:
        - ApiKeyAuth: []
components:
  responses:
    Unauthorized:
      description: Authentication failed
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error:
              code: UNAUTHENTICATED
              message: Authentication failed
              details:
                - field: X-API-Key
                  description: Invalid or missing API key
    InternalError:
      description: Internal server error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error:
              code: INTERNAL
              message: Internal server error
              details:
                - description: An unexpected error occurred
  schemas:
    ErrorResponse:
      type: object
      description: Standard error response
      required:
        - error
      properties:
        error:
          type: object
          required:
            - code
            - message
            - details
          properties:
            code:
              type: string
              description: Machine-readable error code
              enum:
                - INVALID_ARGUMENT
                - UNAUTHENTICATED
                - NOT_FOUND
                - ALREADY_EXISTS
                - INTERNAL
              example: INVALID_ARGUMENT
            message:
              type: string
              description: Human-readable error message
              example: Invalid request parameter
            details:
              type: array
              description: Detailed error information
              items:
                type: object
                properties:
                  field:
                    type: string
                    nullable: true
                    description: Field name that caused the error
                    example: config_overrides
                  description:
                    type: string
                    description: Detailed error description
                    example: Override key 'invalid_key' does not exist on parent agent
  examples:
    MutationNotFoundError:
      summary: Mutation not found
      value:
        error:
          code: NOT_FOUND
          message: Mutation not found
          details:
            - field: mutation_id
              description: >-
                Mutation '01ARZ3NDEKTSV4RRFFQ69G5FAV' does not exist or is not
                accessible
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: API key for authentication

````