---
title: "Preview which injected secrets a 'snapshot and delete' would remove"
method: GET
path: "/api/v0beta1/rig-snapshots/scrub-preview"
tags: ["SandboxSnapshots"]
---

# Preview which injected secrets a 'snapshot and delete' would remove

`GET /api/v0beta1/rig-snapshots/scrub-preview`

## Request

- Base URL: `https://app.amika.dev` (the document declares no server; this is the origin it was published from)
- URL: `https://app.amika.dev/api/v0beta1/rig-snapshots/scrub-preview`
- Auth: one of:
  - HTTP bearer
  - API key in cookie `wos-session`

## Query parameters

- `sandbox` string: The sandbox whose injected secrets would be scrubbed.
- `by` 'name' | 'id' | 'ref' | 'name_or_id': How to interpret `sandbox`: name (default), id, or ref/name_or_id (matches either; rejects ambiguity).
- `sandbox_id` string: Deprecated: use `sandbox` with `by=id` instead.

## Response `200`

Secrets that would be scrubbed and files reset to a baseline (paths + names only).

- SandboxScrubPreviewResponse
  - `files` string[], required
  - `restored_files` string[], required
  - `env_vars` string[], required

## Other responses

- `400`: Error
- `401`: Error
- `403`: Error
- `404`: Error
- `409`: Error
- `502`: Error

## Changes

- **2026-09-16** `25ba06b40ead`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/amika/apis/amika-api/changes/api/v0beta1/rig-snapshots/scrub-preview/get.md)

---

[API](https://skmtc.dev/amika/apis/amika-api.md) - [All operations](https://skmtc.dev/amika/apis/amika-api/llms.txt) - [OpenAPI document](https://skmtc.dev/amika/apis/amika-api/revisions/86f031a957c1?raw)
