Skip to main content

Snapshot API

Point-in-time backups of epilot configuration with restore.

Quick Startโ€‹

# List available operations
epilot snapshot

# Call an operation
epilot snapshot listSnapshots

Common Flagsโ€‹

FlagDescription
-p key=valueSet a named parameter
-d '{...}'Request body JSON
-H 'Key: Value'Custom header
-t, --token <token>Bearer token for authentication
--profile <name>Use a named profile
-s, --server <url>Override server base URL
-i, --includeInclude response headers in output
--jsonOutput raw JSON (no formatting)
-v, --verboseVerbose output (show request details)
--jsonata <expr>JSONata expression to transform response
--definition <file>Override OpenAPI spec file/URL
--guidedPrompt for all parameters interactively
--no-interactiveDisable interactive prompts

Operationsโ€‹

Snapshots

  • listSnapshots โ€” List snapshots for the caller's organization, newest first.
  • createSnapshot โ€” Create a new snapshot of the given resources. Async โ€” returns immediately
  • captureOrgSnapshot โ€” Snapshot the caller's whole organization now. Creates a scope: "org"
  • getSnapshot โ€” Fetch a snapshot's metadata. Poll this endpoint to track create/restore progress.
  • deleteSnapshot โ€” Delete a snapshot's metadata and S3 manifest.
  • restoreSnapshot โ€” Restore a snapshot to the org. Async โ€” returns immediately; client polls
  • listSnapshotResources โ€” List the resources captured in this snapshot. Returns lightweight
  • getSnapshotResource โ€” Fetch one captured resource with its full payload. For UI views
  • listDependencies โ€” Walk the dependency tree for a set of resources and return the full

ScheduledSnapshots

listSnapshotsโ€‹

List snapshots for the caller's organization, newest first.

GET /v1/snapshots

Parameters

NameInTypeRequiredDescription
cursorquerystringNo
sizequerynumberNo
resourcequerystring[]NoFilter to snapshots containing one or more resources. Format

<type>:<id>. Split on the first colon โ€” the <id> half may contain colons (e.g., role acl ids like role:acl:internal:foo). Repeat the | | trigger | query | "manual" | "sync" | "blueprint_install" | "scheduled" | No | Filter to snapshots with a specific trigger. Uses the byTrigger GSI for an efficient indexed query โ€” no table scan. Only snapshots created after the GSI was added carry this index entry; pre-existin |

Sample Call

epilot snapshot listSnapshots

With JSONata filter:

epilot snapshot listSnapshots --jsonata 'results[0]'
Sample Response
{
"page_size": 0,
"cursor": "string",
"results": [
{
"id": "string",
"org_id": "string",
"name": "string",
"description": "string",
"trigger": "manual",
"blueprint_instance_id": "string",
"resource_counts": {},
"create": {
"type": "create",
"started_at": "1970-01-01T00:00:00.000Z",
"completed_at": "1970-01-01T00:00:00.000Z",
"status": "in_progress",
"error": "string",
"triggered_by": {
"name": "string",
"user_id": "string",
"token_id": "string"
}
},
"restores": [
{
"type": "create",
"started_at": "1970-01-01T00:00:00.000Z",
"completed_at": "1970-01-01T00:00:00.000Z",
"status": "in_progress",
"error": "string",
"triggered_by": {
"name": "string",
"user_id": "string",
"token_id": "string"
}
}
],
"matched_count": 0,
"scope": "selection",
"expires_at": "1970-01-01T00:00:00.000Z",
"capture_summary": {
"total": 0,
"captured": 0,
"skipped": 0,
"failed": 0
}
}
]
}

createSnapshotโ€‹

Create a new snapshot of the given resources. Async โ€” returns immediately

POST /v1/snapshots

Request Body (required)

Sample Call

epilot snapshot createSnapshot

With request body:

epilot snapshot createSnapshot \
-d '{
"name": "string",
"description": "string",
"trigger": "manual",
"blueprint_instance_id": "string",
"resources": [
{
"type": "string",
"id": "string"
}
]
}'

Using stdin pipe:

cat body.json | epilot snapshot createSnapshot

With JSONata filter:

epilot snapshot createSnapshot --jsonata '$'

captureOrgSnapshotโ€‹

Snapshot the caller's whole organization now. Creates a scope: "org"

POST /v1/snapshots:capture-org

Request Body

Sample Call

epilot snapshot captureOrgSnapshot \
-d '{"name":"string","retention":{"value":1,"unit":"days"},"excluded_types":["string"]}'

Using stdin pipe:

cat body.json | epilot snapshot captureOrgSnapshot

With JSONata filter:

epilot snapshot captureOrgSnapshot --jsonata '$'

getSnapshotโ€‹

Fetch a snapshot's metadata. Poll this endpoint to track create/restore progress.

GET /v1/snapshots/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYes

Sample Call

epilot snapshot getSnapshot \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot snapshot getSnapshot 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot snapshot getSnapshot -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'id'
Sample Response
{
"id": "string",
"org_id": "string",
"name": "string",
"description": "string",
"trigger": "manual",
"blueprint_instance_id": "string",
"resource_counts": {},
"create": {
"type": "create",
"started_at": "1970-01-01T00:00:00.000Z",
"completed_at": "1970-01-01T00:00:00.000Z",
"status": "in_progress",
"error": "string",
"triggered_by": {
"name": "string",
"user_id": "string",
"token_id": "string"
}
},
"restores": [
{
"type": "create",
"started_at": "1970-01-01T00:00:00.000Z",
"completed_at": "1970-01-01T00:00:00.000Z",
"status": "in_progress",
"error": "string",
"triggered_by": {
"name": "string",
"user_id": "string",
"token_id": "string"
}
}
],
"matched_count": 0,
"scope": "selection",
"expires_at": "1970-01-01T00:00:00.000Z",
"capture_summary": {
"total": 0,
"captured": 0,
"skipped": 0,
"failed": 0
}
}

deleteSnapshotโ€‹

Delete a snapshot's metadata and S3 manifest.

DELETE /v1/snapshots/{id}

Parameters

NameInTypeRequiredDescription
idpathstringYes

Sample Call

epilot snapshot deleteSnapshot \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot snapshot deleteSnapshot 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot snapshot deleteSnapshot -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata '$'

restoreSnapshotโ€‹

Restore a snapshot to the org. Async โ€” returns immediately; client polls

POST /v1/snapshots/{id}:restore

Parameters

NameInTypeRequiredDescription
idpathstringYes

Request Body

Sample Call

epilot snapshot restoreSnapshot \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-d '{"exclude_target_ids":["string"]}'

Using positional args for path parameters:

epilot snapshot restoreSnapshot 123e4567-e89b-12d3-a456-426614174000

Using stdin pipe:

cat body.json | epilot snapshot restoreSnapshot -p id=123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot snapshot restoreSnapshot -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata '$'

listSnapshotResourcesโ€‹

List the resources captured in this snapshot. Returns lightweight

GET /v1/snapshots/{id}/resources

Parameters

NameInTypeRequiredDescription
idpathstringYes

Sample Call

epilot snapshot listSnapshotResources \
-p id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot snapshot listSnapshotResources 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot snapshot listSnapshotResources -p id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'resources'
Sample Response
{
"resources": [
{
"lineage_id": "string",
"target_id": "string",
"type": "string",
"name": "string"
}
]
}

getSnapshotResourceโ€‹

Fetch one captured resource with its full payload. For UI views

GET /v1/snapshots/{id}/resources/{lineage_id}

Parameters

NameInTypeRequiredDescription
idpathstringYes
lineage_idpathstringYes

Sample Call

epilot snapshot getSnapshotResource \
-p id=123e4567-e89b-12d3-a456-426614174000 \
-p lineage_id=123e4567-e89b-12d3-a456-426614174000

Using positional args for path parameters:

epilot snapshot getSnapshotResource 123e4567-e89b-12d3-a456-426614174000 123e4567-e89b-12d3-a456-426614174000

With JSONata filter:

epilot snapshot getSnapshotResource -p id=123e4567-e89b-12d3-a456-426614174000 -p lineage_id=123e4567-e89b-12d3-a456-426614174000 --jsonata 'lineage_id'
Sample Response
{
"lineage_id": "string",
"target_id": "string",
"type": "string",
"name": "string",
"captured": {}
}

getOrgSnapshotScheduleโ€‹

Return the scheduled-snapshot enrollment config for the caller's org.

GET /v1/org-snapshot-schedule

Sample Call

epilot snapshot getOrgSnapshotSchedule

With JSONata filter:

epilot snapshot getOrgSnapshotSchedule --jsonata 'org_id'
Sample Response
{
"org_id": "string",
"enabled": true,
"cron_expression": "cron(0 2 * * ? *)",
"timezone": "string",
"retention": {
"value": 1,
"unit": "days"
},
"excluded_types": ["string"],
"schedule_name": "string",
"last_started_at": "1970-01-01T00:00:00.000Z",
"last_completed_at": "1970-01-01T00:00:00.000Z",
"last_status": "completed",
"created_by": "string",
"created_at": "1970-01-01T00:00:00.000Z",
"updated_at": "1970-01-01T00:00:00.000Z"
}

putOrgSnapshotScheduleโ€‹

Create or update the scheduled-snapshot enrollment config for the

PUT /v1/org-snapshot-schedule

Request Body

Sample Call

epilot snapshot putOrgSnapshotSchedule

With request body:

epilot snapshot putOrgSnapshotSchedule \
-d '{
"enabled": true,
"cron_expression": "cron(0 2 * * ? *)",
"timezone": "Europe/Berlin",
"retention": {
"value": 1,
"unit": "days"
},
"excluded_types": ["string"]
}'

Using stdin pipe:

cat body.json | epilot snapshot putOrgSnapshotSchedule

With JSONata filter:

epilot snapshot putOrgSnapshotSchedule --jsonata 'org_id'
Sample Response
{
"org_id": "string",
"enabled": true,
"cron_expression": "cron(0 2 * * ? *)",
"timezone": "string",
"retention": {
"value": 1,
"unit": "days"
},
"excluded_types": ["string"],
"schedule_name": "string",
"last_started_at": "1970-01-01T00:00:00.000Z",
"last_completed_at": "1970-01-01T00:00:00.000Z",
"last_status": "completed",
"created_by": "string",
"created_at": "1970-01-01T00:00:00.000Z",
"updated_at": "1970-01-01T00:00:00.000Z"
}

deleteOrgSnapshotScheduleโ€‹

Remove the scheduled-snapshot enrollment for the caller's org.

DELETE /v1/org-snapshot-schedule

Sample Call

epilot snapshot deleteOrgSnapshotSchedule

With JSONata filter:

epilot snapshot deleteOrgSnapshotSchedule --jsonata '$'

listDependenciesโ€‹

Walk the dependency tree for a set of resources and return the full

POST /v1/snapshots:list-dependencies

Request Body (required)

Sample Call

epilot snapshot listDependencies \
-d '{"resources":[{"type":"string","id":"string"}]}'

Using stdin pipe:

cat body.json | epilot snapshot listDependencies

With JSONata filter:

epilot snapshot listDependencies --jsonata 'dependencies'
Sample Response
{
"dependencies": [
{
"type": "string",
"id": "string"
}
]
}