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

# Cancel Evaluation

> Cancel a running evaluation (Kubernetes Job cancellation + workflow status update).

Cancels an evaluation that is in progress (CREATED, STARTING, or RUNNING status).
This will:
- Delete the Kubernetes Job (which cancels the running pod)
- Update workflow status to CANCELLED
- Optionally clean up partial S3 data (request file is kept for audit)

Args:
    evaluation_id: UUID of the evaluation to cancel
    claims: JWT claims with user and team info
    diamond_domain: Diamond domain orchestrator
    storage: Evaluation storage adapter

Returns:
    Status dict with "cancelled" status

Raises:
    HTTPException: 404 if evaluation not found, 400 if evaluation is already completed/cancelled



## OpenAPI

````yaml /openapi/api.json post /v1/evaluations/{evaluation_id}/cancel
openapi: 3.1.0
info:
  title: Vijil Console API (Combined)
  description: Combined OpenAPI specification for all vijil-console microservices.
  version: 0.1.0
servers: []
security: []
tags:
  - name: Teams
    description: Authentication, users, and team management
  - name: Agent Environment
    description: Agent, persona, policy, and harness management
  - name: Diamond
    description: Evaluation management and report retrieval
  - name: Dome
    description: Protection, guardrails, and telemetry
  - name: Red Team
    description: Red team campaigns
paths:
  /v1/evaluations/{evaluation_id}/cancel:
    post:
      tags:
        - Diamond
        - evaluations
      summary: Cancel Evaluation
      description: >-
        Cancel a running evaluation (Kubernetes Job cancellation + workflow
        status update).


        Cancels an evaluation that is in progress (CREATED, STARTING, or RUNNING
        status).

        This will:

        - Delete the Kubernetes Job (which cancels the running pod)

        - Update workflow status to CANCELLED

        - Optionally clean up partial S3 data (request file is kept for audit)


        Args:
            evaluation_id: UUID of the evaluation to cancel
            claims: JWT claims with user and team info
            diamond_domain: Diamond domain orchestrator
            storage: Evaluation storage adapter

        Returns:
            Status dict with "cancelled" status

        Raises:
            HTTPException: 404 if evaluation not found, 400 if evaluation is already completed/cancelled
      operationId: cancel_evaluation_v1_evaluations__evaluation_id__cancel_post
      parameters:
        - name: evaluation_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Evaluation Id
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: object
                additionalProperties:
                  type: string
                title: >-
                  Response Cancel Evaluation V1 Evaluations  Evaluation Id 
                  Cancel Post
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
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
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````