List a folder of a snapshot
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://vms.dev/api/v1/snapshots/{id}/tree', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://vms.dev/api/v1/snapshots/{id}/tree \
--header 'Authorization: Bearer <token>'import requests
url = "https://vms.dev/api/v1/snapshots/{id}/tree"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"snapshotId": "<string>",
"sandboxId": "<string>",
"path": "<string>",
"entries": [
{
"name": "<string>",
"path": "<string>",
"type": "file",
"size": 4503599627370495,
"mode": "<string>",
"uid": 4503599627370495,
"gid": 4503599627370495,
"target": "<string>",
"modifiedAt": "2023-11-07T05:31:56Z"
}
]
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}Snapshots
List a folder of a snapshot
Returns the saved files and folders in one folder of a snapshot. A snapshot holds the saved files: the files and folders that are different from the base image. It works with no running sandbox, also after the sandbox is deleted, until its saved files are deleted. Needs the snapshots:read scope.
GET
/
v1
/
snapshots
/
{id}
/
tree
List a folder of a snapshot
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://vms.dev/api/v1/snapshots/{id}/tree', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://vms.dev/api/v1/snapshots/{id}/tree \
--header 'Authorization: Bearer <token>'import requests
url = "https://vms.dev/api/v1/snapshots/{id}/tree"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"snapshotId": "<string>",
"sandboxId": "<string>",
"path": "<string>",
"entries": [
{
"name": "<string>",
"path": "<string>",
"type": "file",
"size": 4503599627370495,
"mode": "<string>",
"uid": 4503599627370495,
"gid": 4503599627370495,
"target": "<string>",
"modifiedAt": "2023-11-07T05:31:56Z"
}
]
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}{
"error": {
"code": "no_capacity",
"message": "<string>",
"requestId": "<string>",
"retryAfterSeconds": 4503599627370495,
"sandboxId": "<string>"
}
}