---
title: "Batch Create Runs"
method: POST
path: "/api/v1/runs/batch"
tags: ["runs"]
---

# Batch Create Runs

`POST /api/v1/runs/batch`

## Request

- Base URL: `https://api.badgeia.com`
- URL: `https://api.badgeia.com/api/v1/runs/batch`
- Auth: none declared

Submit multiple runs at once for an agent across different tasks.
Returns list of created runs.

WP-I (ROAD-002 §WP-I, 2026-07-02): this endpoint is an AUTHENTICATED write.
It resolves the caller via ``require_user_or_api_key("write")`` — the same
canonical dependency ``POST /agents`` uses — so a session/JWT user OR an
API key carrying ``write`` scope authenticates as its owner, and an
anonymous request gets a 401. Previously the handler used
``get_current_user_optional``, which does not accept API-key auth: the Badge
MCP server and SDK callers (who authenticate with ``X-API-Key`` /
``Authorization: Bearer <key>``) fell through to ``user is None`` and ran
UNMETERED — no ``monthly_run_count`` attribution and the wrong rate-limit
category on a prod site with live billing. Requiring auth here means every
batch reserves against the owner's monthly run quota, exactly like the
single-run path. (There is no per-tier cost cap: that feature was removed
2026-07-27 because Badge bills a flat subscription and meters no customer
LLM spend.)

## Request body

- BatchRunCreate
  - `agent_id` string, uuid, required
  - `suite_id` string, uuid, nullable
  - `entry_point` 'suite_detail' | 'marketplace_card' | 'screen_deep_link' | 'screen_selector', nullable
  - `task_ids` string[], nullable
  - `repeats` integer
  - `trigger_source` 'staleness_chip', nullable

## Response `202`

Successful Response

- RunRead[]
  - `id` string, uuid, required
  - `agent_id` string, uuid, required
  - `agent_display_name` string, nullable
  - `agent_identity_state` 'active' | 'deactivated' | 'unavailable', nullable
  - `task_id` string, uuid, required
  - `status` 'pending' | 'running' | 'completed' | 'failed' | 'timeout', required
  - `started_at` string, date-time, nullable, required
  - `completed_at` string, date-time, nullable, required
  - `latency_ms` integer, nullable, required
  - `success` boolean, nullable, required
  - `output` string, nullable, required
  - `output_withheld` boolean
  - `error_message` string, nullable, required
  - `input_tokens` integer, nullable, required
  - `output_tokens` integer, nullable, required
  - `total_cost_usd` number, nullable, required
  - `evidence_cost_usd` number, nullable
  - `evidence_cost_source` string
  - `evidence_cost_partial` boolean
  - `evidence_priced_call_count` integer
  - `evidence_unpriced_call_count` integer
  - `evidence_total_call_count` integer
  - `retry_count` integer, required
  - `created_at` string, date-time, required
  - `answer_exposed` boolean
  - `provider_cost_authority` string, nullable
  - `screening_session_id` string, uuid, nullable
  - `repeat_index` integer, nullable
  - `repeat_total` integer, nullable
  - `architecture_hash` string, nullable
  - `previous_architecture_hash` string, nullable
  - `architecture_changed` boolean, nullable
  - `architecture_comparable` boolean
  - `architecture_change_summary` object, nullable
  - `architecture_span_count` integer
  - `certification_id` string, uuid, nullable
  - `certification_sequence` integer, nullable
  - `requested_model` string, nullable
  - `returned_model` string, nullable
  - `llm_provider` string, nullable
  - `usage_source` string, nullable
  - `model_pricing_id` string, uuid, nullable
  - `pricing_input_cost_per_million` number, nullable
  - `pricing_output_cost_per_million` number, nullable
  - `pricing_effective_date` string, date, nullable
  - `error_class` string, nullable
  - `response_status` integer, nullable
  - `error_body_excerpt` string, nullable
  - `execution_mode` string, nullable
  - `verification_hash` string, nullable
  - `signed_at` string, date-time, nullable
  - `key_id` string, nullable
  - `public_certificate_state` 'verified' | 'simulated' | 'unsigned' | 'invalid'
  - `suite_id` string, nullable
  - `suite_version` integer, nullable
  - `model` string, nullable
  - `cost_provenance` string, nullable
  - `cost_basis` 'metered' | 'traced' | 'traced_partial' | 'self_reported' | 'unavailable', nullable
  - `scored_cost_usd` number, nullable
  - `provenance_level` string, nullable
  - `manifest_hash` string, nullable
  - `provenance_flags` string[], required

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/badgeia/apis/badge.md) · [All operations](https://skmtc.dev/badgeia/apis/badge/llms.txt) · [OpenAPI document](https://skmtc.dev/badgeia/apis/badge/revisions/7e7f7fee8b77?raw)
