List the sandboxes of your orgs.
curl --request GET \
--url https://api.instabox.sh/v1/machines \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.instabox.sh/v1/machines"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.instabox.sh/v1/machines', 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.instabox.sh/v1/machines",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.instabox.sh/v1/machines"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.instabox.sh/v1/machines")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.instabox.sh/v1/machines")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"machines": [
{
"id": "<string>",
"name": "<string>",
"desiredState": "creating",
"state": "creating",
"revision": 123,
"operationId": "<string>",
"template": {
"id": "<string>",
"version": "<string>",
"digest": "<string>",
"kernel": "<string>"
},
"spec": {
"vcpus": 123,
"memMiB": 123,
"persistentDiskGiB": 123,
"rootDiskGiB": 123
},
"storage": {
"sizeGiB": 123,
"mountPath": "/data",
"persistent": true,
"synced": true,
"snapshotSeq": 123
},
"runtime": {
"ready": true,
"processesPreserved": true
},
"autoSuspendAfterSeconds": 123,
"maxRunMinutes": 1073741823,
"runStartedAt": "2023-11-07T05:31:56Z",
"cooldownUntil": "2023-11-07T05:31:56Z",
"metadata": {},
"vault": true,
"guestUser": "alice",
"orgId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"snapshot": {
"id": "<string>"
},
"image": {
"id": "<string>"
},
"lastError": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
},
"archiveAt": "2023-11-07T05:31:56Z",
"deleteAt": "2023-11-07T05:31:56Z",
"readyAt": "2023-11-07T05:31:56Z",
"cooldownReason": "abuse_egress_blocklist",
"abuseLock": {
"at": "2023-11-07T05:31:56Z",
"explanation": "<string>",
"what": "<string>",
"appeal": "<string>",
"dst": "<string>",
"port": 123,
"kind": "<string>",
"count": 123,
"coreShare": 123,
"process": "<string>",
"pool": "<string>"
},
"autoSuspendedAt": "2023-11-07T05:31:56Z",
"envNames": [
"<string>"
],
"free": true,
"earlyAllowanceEnded": true,
"oomKills": 123,
"lastOom": {
"at": "2023-11-07T05:31:56Z",
"pid": 123,
"process": "<string>",
"rssBytes": 123,
"anonRssBytes": 123,
"cgroup": true,
"uid": 123
}
}
],
"nextCursor": "<string>"
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}Machines
List the sandboxes of your orgs.
Your sandboxes and those of the other members of your orgs (docs/orgs.md). API keys: needs one of the scopes machines:read.
GET
/
v1
/
machines
List the sandboxes of your orgs.
curl --request GET \
--url https://api.instabox.sh/v1/machines \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.instabox.sh/v1/machines"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.instabox.sh/v1/machines', 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.instabox.sh/v1/machines",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.instabox.sh/v1/machines"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.instabox.sh/v1/machines")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.instabox.sh/v1/machines")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"machines": [
{
"id": "<string>",
"name": "<string>",
"desiredState": "creating",
"state": "creating",
"revision": 123,
"operationId": "<string>",
"template": {
"id": "<string>",
"version": "<string>",
"digest": "<string>",
"kernel": "<string>"
},
"spec": {
"vcpus": 123,
"memMiB": 123,
"persistentDiskGiB": 123,
"rootDiskGiB": 123
},
"storage": {
"sizeGiB": 123,
"mountPath": "/data",
"persistent": true,
"synced": true,
"snapshotSeq": 123
},
"runtime": {
"ready": true,
"processesPreserved": true
},
"autoSuspendAfterSeconds": 123,
"maxRunMinutes": 1073741823,
"runStartedAt": "2023-11-07T05:31:56Z",
"cooldownUntil": "2023-11-07T05:31:56Z",
"metadata": {},
"vault": true,
"guestUser": "alice",
"orgId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"snapshot": {
"id": "<string>"
},
"image": {
"id": "<string>"
},
"lastError": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
},
"archiveAt": "2023-11-07T05:31:56Z",
"deleteAt": "2023-11-07T05:31:56Z",
"readyAt": "2023-11-07T05:31:56Z",
"cooldownReason": "abuse_egress_blocklist",
"abuseLock": {
"at": "2023-11-07T05:31:56Z",
"explanation": "<string>",
"what": "<string>",
"appeal": "<string>",
"dst": "<string>",
"port": 123,
"kind": "<string>",
"count": 123,
"coreShare": 123,
"process": "<string>",
"pool": "<string>"
},
"autoSuspendedAt": "2023-11-07T05:31:56Z",
"envNames": [
"<string>"
],
"free": true,
"earlyAllowanceEnded": true,
"oomKills": 123,
"lastOom": {
"at": "2023-11-07T05:31:56Z",
"pid": 123,
"process": "<string>",
"rssBytes": 123,
"anonRssBytes": 123,
"cgroup": true,
"uid": 123
}
}
],
"nextCursor": "<string>"
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}{
"error": {
"code": "unauthenticated",
"message": "<string>",
"requestId": "<string>",
"retryable": true,
"operationId": "<string>",
"reason": "missing_key",
"hint": "<string>",
"docs": "<string>",
"docs_url": "<string>",
"requiredScopes": [
"<string>"
],
"retryAfterSeconds": 2,
"at": "2023-11-07T05:31:56Z"
}
}Authorizations
bearerAuthapiKeysessionCookie
Opaque instabox access token (1 hour). Refresh with /v1/auth/refresh (refresh token valid 30 days, rotates on use).
Query Parameters
Opaque nextCursor from a previous page.
Page size.
Required range:
x >= 1key:value (split at the first :); only sandboxes whose metadata has the key with exactly that value. Repeatable; all terms must match (AND).
Was this page helpful?