Skip to main content
POST
/
ai
/
run_circuits_on_qpu_or_simulator
Run Circuits On Qpu Or Simulator
curl --request POST \
  --url 'https://api.example.com/ai/run_circuits_on_qpu_or_simulator?HAIQU_API_KEY=' \
  --header 'Content-Type: application/json' \
  --data '
{
  "experiment_id": "<string>",
  "circuit_ids": [],
  "parameters": [
    "<unknown>"
  ],
  "shots": 1024,
  "observables": [
    [
      [
        [
          "<string>"
        ],
        [
          123
        ]
      ]
    ]
  ],
  "device_id": "",
  "options": {},
  "use_mitigation": false,
  "name": "",
  "description": "",
  "dry_run": false,
  "run_type": "Run",
  "circuits_qasm": [
    "<string>"
  ]
}
'
{
  "context": "<string>"
}

Authorizations

HAIQU_API_KEY
string
query
required

Body

application/json

Define run submission payload for MCP execution endpoint.

This model extends :class:haiqu.sdk.schemas.RunSubmitModel with optional inline QASM input so agents can submit and run circuits in one operation.

Attributes: experiment_id: Parent experiment identifier for the run job. circuit_ids: Existing stored circuit IDs to run. Use either this field or circuits_qasm. circuits_qasm: Inline QASM circuits to persist and run in one step. device_id: Backend identifier returned by list_qpus_and_simulators. run_type: Execution mode. Use Run for sampled execution or StatevectorRun for exact simulation. options: Backend-specific runtime options forwarded to the execution provider. parameters: Optional parameter bindings for parameterized circuits. observables: Optional observables used to compute expectation values. use_mitigation: Whether backend mitigation features should be enabled when supported. name: Optional job name. description: Optional plain-text job description. dry_run: Whether to request dry-run cost or planning information instead of a real execution when supported by the backend.

experiment_id
string
required
circuit_ids
any[] | null
parameters
any[] | null

Optional parameter bindings for parameterized circuits. Shape is backend-compatible and typically [circuit][parameter_set][value].

shots
integer
default:1024

Number of measurement shots (must be >= 1)

Required range: x >= 1
observables
tuple[][] | null

Optional observables per circuit, where each observable is (pauli_strings, coefficients); used to compute expectation values instead of bitstring counts.

device_id
string | null
default:""
options
Options · object

Backend-specific runtime options. For example: {'resilience_level': 1, 'optimization_level': 2}.

use_mitigation
boolean | null
default:false
name
string | null
default:""
description
string | null
default:""
dry_run
boolean | null
default:false
run_type
enum<string>
default:Run

Execution mode: Run for device/simulator shots, or StatevectorRun for exact simulation.

Available options:
Run,
StatevectorRun
circuits_qasm
string[] | null

List of quantum circuits in QASM 2.0 or 3.0 format. Use either this field or circuit_ids field to specify the existing circuits IDs to run.

Response

Successful Response

Represent lightweight run-job context returned by MCP execution tool.

Attributes: context: Submission summary text including the job ID and next polling step. This response model does not expose structured job_id or result fields outside the text payload.

context
string
required