List a sandbox's snapshots
Snapshots of the sandbox that have not been deleted, newest first. Snapshots outlive their sandbox, so this lists them for a deleted sandbox too.
curl --request GET \
--url https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sandbox_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "mem+fs",
"status": "creating",
"size_bytes": 123,
"resources": {
"vcpu_count": 123,
"memory_mib": 123,
"disk_mib": 123
},
"created_at": "2023-11-07T05:31:56Z",
"template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"ready_at": "2023-11-07T05:31:56Z"
}
]{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}Authorizations
Path Parameters
The unique identifier of the sandbox.
Public sandbox ID: a bare UUID, or the region-tagged form sb-<region>-<uuid> (e.g. sb-use-1b4e28ba-…). Treat as an opaque string; the tagged form routes the request to the sandbox's home region. Endpoints accept both forms interchangeably.
^(sb-[a-z0-9]+-)?[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$Query Parameters
Maximum rows to return (page size). Omit to return the full list unpaginated — the default, preserved for backward compatibility with callers that page client-side. Values above 200 are clamped to 200.
1 <= x <= 200Rows to skip before the page. Combine with limit to paginate.
x >= 0Response
Snapshots, newest first
The sandbox the snapshot was taken from. It may since have been deleted.
mem+fs creating, ready, failed, deleting Bytes the snapshot holds on disk; 0 until ready.
Show child attributes
Show child attributes
The template the captured sandbox was created from.
curl --request GET \
--url https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.superserve.ai/sandboxes/{sandbox_id}/snapshots")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sandbox_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"kind": "mem+fs",
"status": "creating",
"size_bytes": 123,
"resources": {
"vcpu_count": 123,
"memory_mib": 123,
"disk_mib": 123
},
"created_at": "2023-11-07T05:31:56Z",
"template_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"name": "<string>",
"ready_at": "2023-11-07T05:31:56Z"
}
]{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}