Gba àwọn àwòrán àìdálẹ̀ tí a tí àmì-ìwé kọ̀ǹpútà, ṣàfihàn àwọn náà àti pa àwọn tí o kò fẹ́.
Returns the snapshots in your account, newest first, 25 per page.
Àwọn ìkúndùǹ tí a fẹ́: snapshots:list
curl -X GET "https://admin.vps.org/api/v1/snapshots/" \
-H "Authorization: Bearer YOUR_API_TOKEN"
import requests
url = "https://admin.vps.org/api/v1/snapshots/"
headers = {"Authorization": "Bearer YOUR_API_TOKEN"}
response = requests.get(url, headers=headers)
for snapshot in response.json()["results"]:
print(snapshot["uuid"], snapshot["label"], snapshot["ready"])
const response = await fetch('https://admin.vps.org/api/v1/snapshots/', {
headers: { 'Authorization': 'Bearer YOUR_API_TOKEN' }
});
const data = await response.json();
console.log(data.results);
{
"count": 1,
"next": null,
"previous": null,
"results": [
{
"uuid": "3f9a1c0e5b7d4e2f8a6c1b3d5e7f9a0b",
"label": "before-upgrade",
"server_hostname": "web-01",
"ready": true,
"deleting": false,
"created_at": "2026-09-14T18:30:00.000000Z",
"size_gb": 3.4
}
]
}
| Àwọn Ààyè-iṣẹ́ | Irú | Àwọn Àkọlé |
|---|---|---|
uuid |
string | Àtòjọ-ètò ìṣàfihàn (àwọn àbùdá hexadecimal 32, kò ní àwọn àgbèwọlé) |
label |
string | Àwọn àmì-ìwé tí a fì pamọ́ láti ìṣàmúlò-ètò náà |
server_hostname |
string | Hostname of the server the snapshot was taken from, or null if that server no longer exists |
ready |
boolean | Àwọn àwọn ààtò àwọn ààtò àwọn ààtò |
deleting |
boolean | Àwọn àwọn ààtò àwọn ààtò àwọn ààtò àwọn ààtò |
created_at |
datetime | Creation time (ISO 8601, UTC) |
size_gb |
number | Ìwọ̀n àwọn ààyè-iṣẹ́ nínú gigabaiti |
Ń pàtó àwọn ààyè-iṣẹ́ àwọn ààyè-iṣẹ́ inú àwọn ààyè-iṣẹ́ inú àwọn ààyè-iṣẹ́ inú. Lò láti fi àwọn ààyè-iṣẹ́ pamọ́ láti sé ìṣàfarawé àwọn ààyè-iṣẹ́ láti inú àwọn ààyè-iṣẹ́.
curl -X GET "https://admin.vps.org/api/v1/snapshots/3f9a1c0e5b7d4e2f8a6c1b3d5e7f9a0b/" \
-H "Authorization: Bearer YOUR_API_TOKEN"
Queues a snapshot of a deployed server and returns the new snapshot's uuid. The snapshot is listed straight away with ready set to false.
Àwọn ìkúndùǹ tí a fẹ́: servers:snapshot
| Àwọn Àtòjọ-ẹ̀yàn | Irú | Ti a nilo | Àwọn Àkọlé |
|---|---|---|---|
action |
string | Bẹ́ẹ̀ni | Ò yẹ ki o jẹ́ àwòrán |
snapshot_label |
string | Bẹ́ẹ̀ni | Àwọn àmì-ìwé láti mọ́ àwòrán |
curl -X POST "https://admin.vps.org/api/v1/servers/8c4f2a1e-5b3d-4e6f-9a7b-1c2d3e4f5a6b/snapshot/" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{"action": "snapshot", "snapshot_label": "before-upgrade"}'
import requests
server_uuid = "8c4f2a1e-5b3d-4e6f-9a7b-1c2d3e4f5a6b"
url = f"https://admin.vps.org/api/v1/servers/{server_uuid}/snapshot/"
headers = {"Authorization": "Bearer YOUR_API_TOKEN"}
data = {"action": "snapshot", "snapshot_label": "before-upgrade"}
response = requests.post(url, headers=headers, json=data)
print(response.json()["snapshot_uuid"])
{
"message": "Snapshot queued successfully",
"snapshot_uuid": "3f9a1c0e5b7d4e2f8a6c1b3d5e7f9a0b"
}
| 200 | Àwọn ìṣàmúlò-ètò |
| 400 | Àwọn ìṣàmúlò-ètò àti àwọn àmì-ìwé àwọn ìṣàmúlò-ètò kò wa, tàbí àwọn sáà kò tí a fi pamọ́ |
| 402 | Kò ní ìṣàmúlò-ètò pàtó fún ìṣàmúlò-ètò nínú fáìlì, tàbí àwọn fátìrì tí a kò pà |
| 404 | Kò rí, tàbí ò jẹ́ àwọn |
Fi àwọn àwòrán pamọ́ sínú ìṣàmúlò-ètò fún ìpàsẹ́ ìpele. ìpàsẹ́ jẹ́ òótọ́ titi tí o tì kù.
Àwọn ìkúndùǹ tí a fẹ́: snapshots:delete
curl -X DELETE "https://admin.vps.org/api/v1/snapshots/3f9a1c0e5b7d4e2f8a6c1b3d5e7f9a0b/" \
-H "Authorization: Bearer YOUR_API_TOKEN"
{
"message": "Snapshot deletion queued"
}
| 202 | A gba: àkóónú náà tí a fi pamọ́ |
| 404 | Kò rí, tàbí ò jẹ́ àwọn |