pydo.genai.patch_cancel_simulation_run()

Generated on 1 Oct 2026 from pydo version v0.43.0

Usage

client.genai.patch_cancel_simulation_run(
    run_uuid="\"123e4567-e89b-12d3-a456-426614174000\"",
    body={
        "run_uuid": "123e4567-e89b-12d3-a456-426614174000",
    },
)
Returns JSONRaises HttpResponseError

Description

To cancel an in-progress simulation run, send a PATCH request to /v2/gen-ai/simulation_runs/{run_uuid}/cancel.

Parameters

run_uuid string required

UUID of the simulation run to cancel. Returned by CreateSimulationRun
and listed via ListSimulationRuns. The run must be in a non-terminal
status; already-terminal runs return an error.

run_uuid string optional

Example: 123e4567-e89b-12d3-a456-426614174000

UUID of the run to cancel.

Request Sample

Show Request Sample
import os
from pydo import Client

client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN"))

req = {
  "run_uuid": "123e4567-e89b-12d3-a456-426614174000"
}

resp = client.genai.patch_cancel_simulation_run(run_uuid="\"123e4567-e89b-12d3-a456-426614174000\"", body=req)

Response Example

Show Response Example
{
  "simulation_run": {
    "agent_config": {
      "agent_deployment_uuid": "123e4567-e89b-12d3-a456-426614174000",
      "agent_uuid": "123e4567-e89b-12d3-a456-426614174000",
      "name": "example name"
    },
    "created_at": "2023-01-01T00:00:00Z",
    "created_by_user_email": "[email protected]",
    "created_by_user_id": "12345",
    "deleted_at": "2023-01-01T00:00:00Z",
    "evaluation_run_uuid": "123e4567-e89b-12d3-a456-426614174000",
    "exploration_budget": 123,
    "failure_reason": "example string",
    "journeys_finished": 123,
    "judge_model_name": "example name",
    "judge_model_uuid": "123e4567-e89b-12d3-a456-426614174000",
    "max_turns": 123,
    "name": "example name",
    "result_summary": {
      "total_duration_sec": "12345"
    },
    "run_uuid": "123e4567-e89b-12d3-a456-426614174000",
    "scenario_count": 123,
    "scenario_set_uuid": "123e4567-e89b-12d3-a456-426614174000",
    "status": "SIMULATION_RUN_STATUS_UNSPECIFIED",
    "total_journeys": 123,
    "updated_at": "2023-01-01T00:00:00Z",
    "user_simulator_model_name": "example name",
    "user_simulator_model_uuid": "123e4567-e89b-12d3-a456-426614174000",
    "workflow_uuid": "123e4567-e89b-12d3-a456-426614174000"
  }
}

More Information

See /v2/gen-ai/simulation_runs/{run_uuid}/cancel in the API reference for additional detail on responses, headers, parameters, and more.

We can't find any results for your search.

Try using different keywords or simplifying your search terms.