Skip to main content
POST
/
v1
/
datasets
/
{dataset_id}
/
snapshots
Create Dataset Snapshot
curl --request POST \
  --url https://api.cuadra.ai/v1/datasets/{dataset_id}/snapshots \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "notes": "Initial snapshot for production"
}
'
{
  "id": "<string>",
  "datasetId": "<string>",
  "version": 2,
  "recordCount": 1,
  "status": "<string>",
  "createdAt": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

JWT token from Stytch B2B authentication (magic link, SSO, or M2M)

Headers

Idempotency-Key
string | null

Path Parameters

dataset_id
string
required

Dataset ID

Example:

"dataset_abc123"

Body

application/json

Request schema for creating a dataset snapshot.

notes
string | null

Notes for this snapshot

Maximum string length: 2000
Example:

"Initial snapshot for production"

Response

Successful Response

Response schema for a dataset snapshot.

id
string
required

Dataset snapshot ID

Example:

"snap_abc123"

datasetId
string
required

Parent dataset ID

Example:

"ds_xyz789"

version
integer
required

Monotonic snapshot number

Required range: x >= 1
Example:

1

recordCount
integer
required

Number of files in this snapshot

Required range: x >= 0
Example:

42

status
string
required

Status: active | archived

Example:

"active"

createdAt
string<date-time>
required

Creation timestamp (UTC ISO8601)

Example:

"2024-01-15T10:30:00Z"