Experimental
DeleteSnapshot deletes a snapshot; deleting an already absent snapshot succeeds.
/v1/snapshots/{snapshot} Connection and access
API connection and authentication guidance
https://connect.docker.com/sandboxes
—
The API base URL. Append the /v1 paths while preserving this URL's path prefix.
Use one of these alternatives. Requirements within an alternative apply together.
bearer
Parameters
snapshot
path
Required
Type:
string
All schema constraints and annotations
{
"type": "string"
}If-Match
header
Required
Type:
string
All schema constraints and annotations
{
"description": "etag is the required precondition, the value the target's last read returned.\nAn absent one refuses etag_required and a stale one etag_mismatch.",
"title": "If-Match",
"type": "string"
}Request and responses
Response
204
No response content is declared.
Response
409
The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state.
An admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held.
application/json
Schema:
Error
deletion_content_lease_held
{
"code": "failedPrecondition",
"message": "deletion_content_lease_held: An admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held."
}deletion_preparation_incomplete
{
"code": "failedPrecondition",
"message": "deletion_preparation_incomplete: The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state."
}Response
412
application/json
Schema:
Error
etag_mismatch
{
"code": "failedPrecondition",
"details": [
{
"@type": "type.googleapis.com/docker.sandboxes.v1.EtagMismatch",
"currentEtag": "v2"
}
],
"message": "etag_mismatch: The precondition is not the resource's current etag. The body carries failedPrecondition naming etag_mismatch and an EtagMismatch detail with the current value."
}Response
428
application/json
Schema:
Error
etag_required
{
"code": "failedPrecondition",
"message": "etag_required: No precondition was sent. The body carries failedPrecondition naming etag_required."
}Response
default
application/json
Schema:
Error
Schema example
{
"code": "notFound",
"details": [],
"message": "sandbox not found"
}Referenced schemas
Complete operation contract
{
"description": "DeleteSnapshot deletes a snapshot; deleting an already absent snapshot succeeds.",
"operationId": "deleteSnapshot",
"parameters": [
{
"description": "The snapshot id.",
"in": "path",
"name": "snapshot",
"required": true,
"schema": {
"type": "string"
}
},
{
"description": "The complete quoted strong entity-tag observed on the resource, including its quotes. Every mutation of an existing resource requires it: an absent value answers 428 and a stale one 412, each carrying failedPrecondition in the body.",
"in": "header",
"name": "If-Match",
"required": true,
"schema": {
"description": "etag is the required precondition, the value the target's last read returned.\nAn absent one refuses etag_required and a stale one etag_mismatch.",
"title": "If-Match",
"type": "string"
}
}
],
"responses": {
"204": {
"description": "Success. The response carries no body."
},
"409": {
"content": {
"application/json": {
"examples": {
"deletion_content_lease_held": {
"summary": "An admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held.",
"value": {
"code": "failedPrecondition",
"message": "deletion_content_lease_held: An admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held."
}
},
"deletion_preparation_incomplete": {
"summary": "The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state.",
"value": {
"code": "failedPrecondition",
"message": "deletion_preparation_incomplete: The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state."
}
}
},
"schema": {
"$ref": "#/components/schemas/Error"
}
}
},
"description": "The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state.\n\nAn admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held."
},
"412": {
"content": {
"application/json": {
"examples": {
"etag_mismatch": {
"summary": "The precondition is not the resource's current etag. The body carries failedPrecondition naming etag_mismatch and an EtagMismatch detail with the current value.",
"value": {
"code": "failedPrecondition",
"details": [
{
"@type": "type.googleapis.com/docker.sandboxes.v1.EtagMismatch",
"currentEtag": "v2"
}
],
"message": "etag_mismatch: The precondition is not the resource's current etag. The body carries failedPrecondition naming etag_mismatch and an EtagMismatch detail with the current value."
}
}
},
"schema": {
"$ref": "#/components/schemas/Error"
}
}
},
"description": "The precondition is not the resource's current etag. The body carries failedPrecondition naming etag_mismatch and an EtagMismatch detail with the current value."
},
"428": {
"content": {
"application/json": {
"examples": {
"etag_required": {
"summary": "No precondition was sent. The body carries failedPrecondition naming etag_required.",
"value": {
"code": "failedPrecondition",
"message": "etag_required: No precondition was sent. The body carries failedPrecondition naming etag_required."
}
}
},
"schema": {
"$ref": "#/components/schemas/Error"
}
}
},
"description": "No precondition was sent. The body carries failedPrecondition naming etag_required."
},
"default": {
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/Error"
}
}
},
"description": "The structured Error body identifies the failure with a stable code and optional typed details."
}
},
"security": [
{
"bearer": []
}
],
"summary": "DeleteSnapshot deletes a snapshot; deleting an already absent snapshot succeeds.",
"tags": [
"Snapshots"
],
"x-sbx-authenticated-only": false,
"x-sbx-conditional-permissions": [],
"x-sbx-error-responses": [
{
"code": "FAILED_PRECONDITION",
"description": "The target's preparation, capture, or import has not finished; deletion is refused until it settles to a terminal state.",
"reason": "deletion_preparation_incomplete"
},
{
"code": "FAILED_PRECONDITION",
"description": "An admitted consumer or live resource holds a content lease on the target; deletion is refused while any lease remains held.",
"reason": "deletion_content_lease_held"
}
],
"x-sbx-plane": "control",
"x-sbx-required-permissions": [
"snapshotsWrite"
],
"x-sbx-serving-surface": "management"
}