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

# POST Start a twin reset

> Start or recover a durable asynchronous reset using an idempotency key

```text theme={null}
POST /twin-runs/{run_id}/resets
```

Restore the run's captured baseline without restarting its VM. The run must be `ready` and support asynchronous resets. Authenticate with an [Arga API key](https://docs.argalabs.com/api-reference/auth.md) that owns the run.

## Request

| Parameter | Location | Type | Required | Description |
| - | - | - | - | - |
| `run_id` | Path | UUID | Yes | Twin Run to reset. |
| `Idempotency-Key` | Header | string | Yes | Nonblank key, 1–200 characters. Reuse it when retrying this reset; use a new key for the next reset. |

No request body is required.

```bash theme={null}
curl --request POST \
  "https://api.argalabs.com/twin-runs/$RUN_ID/resets" \
  --header "Authorization: Bearer $ARGA_API_KEY" \
  --header "Idempotency-Key: evaluation-17-reset-1"
```

## Response

HTTP `202` returns a [reset operation](https://docs.argalabs.com/api-reference/get-get-twin-reset-operation.md#response). Save its `operation_id` and `status_url`.

| Header | Value |
| - | - |
| `Location` | Relative operation URL: `/twin-runs/{run_id}/resets/{operation_id}`. |
| `Retry-After` | `2` seconds. |
| `Cache-Control` | `no-store`. |

The same key on the same run returns the same operation, including after completion. If the initial response is lost, retry with that key. Do not switch keys to recover a request timeout.

While a reset is active, the run is `resetting` and provider requests are blocked. A reset does not extend the run's TTL. Teardown and expiry take precedence.

## Errors

| HTTP status | Meaning |
| - | - |
| `400` | The run type does not support reset. |
| `401` / `403` | Authentication or access is denied. |
| `404` | The run was not found for the authenticated owner. |
| `409` | The run is not ready, another reset is active under a different key, its worker is too old, or the environment is unavailable or due for cleanup. |
| `422` | A path parameter is not a UUID, or the required idempotency key is missing or invalid. |

A worker compatibility error says `Async reset requires an updated worker. Reprovision after the worker rollout.` Provision a new run to use asynchronous reset.

For a complete start-and-poll example, see [Reset Twin Runs](https://docs.argalabs.com/features/twin-resets.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.