providerSnapshots
Snapshots of [provider volumes](/docs/reference/api/provider-volumes), made with `providerVolumes.snapshot` and converged by the `vps.provider-resources` reconciler. Reading takes `compute:volumes:read`, deleting and restoring `compute:volumes:manage`, on `provider-snapshot/{id}`. A snapshot books no quota and bills `vps.snapshot.gib.hours` (the GiB the provider reports) from `ready` until deleted.
Snapshots of provider volumes, made with providerVolumes.snapshot and converged by the vps.provider-resources reconciler. Reading takes compute:volumes:read, deleting and restoring compute:volumes:manage, on provider-snapshot/{id}. A snapshot books no quota and bills vps.snapshot.gib.hours (the GiB the provider reports) from ready until deleted.
All 4 methods are served by @better-compute/server 0.3.0.
| Method | Kind | Authorization | Phase | Status |
|---|---|---|---|---|
list | read | compute:volumes:read @ compute-tenant + items | v1.0 | registered |
get | read | compute:volumes:read @ compute-provider-snapshot | v1.0 | registered |
delete | mutation | compute:volumes:manage @ compute-provider-snapshot | v1.0 | registered |
restore | mutation | compute:volumes:manage @ compute-provider-snapshot | v1.0 | registered |
list
POST /api/compute/providerSnapshots/list
Returns the tenant's snapshots in the order they were made (at most 1000), optionally of one volume. Deleted ones only with includeDeleted.
- Kind: read
- Authorization:
compute:volumes:read@compute-tenant+ items - Module:
vps - Phase: v1.0 (registered)
Input
| Field | Type | Required | Constraints |
|---|---|---|---|
tenantId | string | yes | at most 128 characters; matches ^[A-Za-z0-9._:-]{1,128}$ |
volumeId | string | at most 57 characters; matches ^pvol_[0-9a-hjkmnp-tv-z]{26,52}$ | |
includeDeleted | boolean | default false |
get
POST /api/compute/providerSnapshots/get
Returns one snapshot: its volume, name, region, size and state.
- Kind: read
- Authorization:
compute:volumes:read@compute-provider-snapshot - Module:
vps - Phase: v1.0 (registered)
Input
| Field | Type | Required | Constraints |
|---|---|---|---|
tenantId | string | yes | at most 128 characters; matches ^[A-Za-z0-9._:-]{1,128}$ |
snapshotId | string | yes | at most 58 characters; matches ^psnap_[0-9a-hjkmnp-tv-z]{26,52}$ |
delete
POST /api/compute/providerSnapshots/delete
Marks the snapshot for deletion and returns it deleting; the reconciler deletes it at the provider and publishes providerVolume.snapshot.deleted. Deleting a snapshot being deleted returns it. A volume restored from it is not affected.
- Kind: mutation
- Authorization:
compute:volumes:manage@compute-provider-snapshot - Module:
vps - Phase: v1.0 (registered)
Input
| Field | Type | Required | Constraints |
|---|---|---|---|
tenantId | string | yes | at most 128 characters; matches ^[A-Za-z0-9._:-]{1,128}$ |
snapshotId | string | yes | at most 58 characters; matches ^psnap_[0-9a-hjkmnp-tv-z]{26,52}$ |
restore
POST /api/compute/providerSnapshots/restore
Creates a new volume from a ready snapshot (INVALID_STATE otherwise), in the snapshot's pool and region, and returns it pending, as providerVolumes.create does: sizeGiB is at least the snapshot's (INVALID_INPUT; absent, the snapshot's size) and books diskGiB, the name is unique in the tenant, and the same idempotencyKey returns the same volume. The volume keeps the snapshot's filesystem: filesystem is INVALID_INPUT (a format could wipe the restored data). Only a volume snapshot this deployment made restores (the provider refuses any other, INVALID_STATE). A snapshot of a shared volume does not restore yet: UNSUPPORTED (details.reason sharedRestore). Decided on the snapshot.
- Kind: mutation
- Authorization:
compute:volumes:manage@compute-provider-snapshot - Module:
vps - Phase: v1.0 (registered)
Input
| Field | Type | Required | Constraints |
|---|---|---|---|
tenantId | string | yes | at most 128 characters; matches ^[A-Za-z0-9._:-]{1,128}$ |
snapshotId | string | yes | at most 58 characters; matches ^psnap_[0-9a-hjkmnp-tv-z]{26,52}$ |
name | string | yes | at most 42 characters; matches ^[a-z]([-a-z0-9]{0,40}[a-z0-9])?$ |
description | string | at most 256 characters | |
sizeGiB | integer | 1-16384 | |
deleteWithInstance | boolean | default false | |
idempotencyKey | string | yes | at most 128 characters; matches ^[A-Za-z0-9._:-]{1,128}$ |
Better Compute is created by Sean Filimon
Last updated
providerAddresses
Reserved public addresses on a provider account (DigitalOcean reserved IPv4 and IPv6 first), assigned to the account's [instances](/docs/reference/api/instances). Every call records what the tenant wants and returns at once; the `vps.provider-resources` reconciler converges the provider through `ProviderImpl.addresses`. Reading takes `compute:addresses:read`, everything else `compute:addresses:manage`, on `provider-address/{id}`. An address books one `addresses` quota on the pool and bills `vps.address.hours` from `ready` until deleted. A DigitalOcean reserved IP carries no name or tag, so the row is the ownership record: one address is recorded by at most one live row, and it keeps the provider's fingerprint from the reserve where there is one (a reserved IPv6's reservation time; a reserved IPv4 has none). An address released at the provider outside better-compute (gone, mismatched, or handed to a later reserve) goes to `error` for good: never re-adopted, assigned or released, and its delete makes no provider call.
providerVolumes
Block volumes and shared volumes (network file shares) on a provider account (DigitalOcean Block Storage and Network File Storage first), next to the account's [instances](/docs/reference/api/instances). Every call records what the tenant wants and returns at once, usually `pending`; the `vps.provider-resources` reconciler then converges the provider through `ProviderImpl.volumes` without blocking on provider actions, and writes back what it saw (`state` is `pending`, `ready`, `updating`, `deleting`, `deleted` or `error`, with the provider's `message`). Reading takes `compute:volumes:read`, everything else `compute:volumes:manage`, on `provider-volume/{id}`. A volume books its `sizeGiB` on the tenant's `diskGiB` quota for the pool and bills from `ready` until deleted: a block volume `vps.volume.gib.hours`, a shared volume `vps.share.gib.hours`. Once created, a volume is only read: one deleted at the provider outside better-compute goes to `error` and is never created again (its data is gone; delete it). See the [provider volumes guide](/docs/guides/vps/provider-volumes).