Skip to content

Snapshots API

All endpoints need a bearer token:

http
Authorization: Bearer <jwt-or-apikey>

A snapshot is an on-node, point-in-time image of a pod that restores in place. If you want a copy that restores as a separate new pod, you want backups instead. The difference is explained in Snapshots vs backups.

The snapshot object

json
{
  "id": "...",
  "name": "auto-2026-07-17",
  "podId": "...",
  "type": "manual",
  "status": "completed",
  "createdAt": "2026-07-17T03:00:00Z"
}

type is manual or auto. status is pending, completed, or failed. A failed snapshot may also carry an error string.

List snapshots for a pod

http
GET /api/pods/:id/snapshots

Returns a plain array of snapshots (manual and auto), newest first.

Create a manual snapshot

http
POST /api/pods/:id/snapshots

No body. Needs at least $3 of account credit like other creates (402 otherwise). Response 202 with the new snapshot in pending status - it finishes in the background.

bash
curl -X POST https://cloud-api.microapps.io/api/pods/$POD_ID/snapshots \
  -H "Authorization: Bearer $TOKEN"

You can keep 4 manual snapshots per pod - the fifth slot is always held back for the auto schedule. At the limit you get 400, so delete one first. The same number is on GET /api/user/account as maxSnapshotsPerPod if you would rather read it than hardcode it.

Restore from a snapshot

http
POST /api/pods/:id/snapshots/:snapId/restore

No body. Response 202:

json
{ "message": "Snapshot restore started" }

The pod rolls back in place and moves through Restoring while it happens. Two rules:

  • The pod must be Running or Stopped. (No need to stop it yourself first - restore handles that.)
  • The snapshot must be completed. You can't restore one that's still pending or failed.

When the restore finishes, the pod is left Stopped - start it again when you're ready.

Restoring is destructive

Anything written after the snapshot was taken is gone. Want to keep the current state too? Take a manual snapshot first, then restore.

Delete a snapshot

http
DELETE /api/pods/:id/snapshots/:snapId

Response 200 ({"message":"Snapshot deleted"}). Immediate and irreversible.

Set the auto snapshot schedule

http
PUT /api/pods/:id/snapshot-schedule
json
{ "schedule": "daily" }

schedule is one of:

ValueMeaning
""Disabled - no automatic snapshots.
"daily"Every day at 3:00 AM UTC.
"weekly"Every Sunday at 3:00 AM UTC.
"monthly"The 1st of every month at 3:00 AM UTC.
bash
curl -X PUT https://cloud-api.microapps.io/api/pods/$POD_ID/snapshot-schedule \
  -H "Authorization: Bearer $TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"schedule":"daily"}'

One slot is held back for the schedule, so a full set of manual snapshots never blocks it. Automatic snapshots rotate among themselves and fill whatever the manual ones are not using: four manual snapshots leave room for one automatic one, none leaves room for five. Your manual snapshots are never touched by the schedule.

See also

Built for the long tail.