Snapshots API


Get a environment's snapshots

GET /environments/:environment/snapshots

Response

          Status: 200 OK
          Content-Type: application/json; charset=utf-8
          
            
          {
            "snapshots": [
              {
                "id": 12,
                "created_at": "2017-10-10T15:59:35+00:00",
                "updated_at": "2017-10-10T15:59:35+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/86",
                "server": "https://api.engineyard.com/servers/127",
                "volume": "https://api.engineyard.com/volumes/147",
                "provider": "https://api.engineyard.com/providers/198",
                "account": "https://api.engineyard.com/accounts/f0ad5bbc-cb58-4df9-931b-44c3e5d69eeb",
                "snapshot_server_request": "https://api.engineyard.com/requests/dc3073ff-5515-4a53-836c-db528e79b109"
              },
              {
                "id": 13,
                "created_at": "2017-10-10T15:59:35+00:00",
                "updated_at": "2017-10-10T15:59:35+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/86",
                "server": "https://api.engineyard.com/servers/127",
                "volume": "https://api.engineyard.com/volumes/148",
                "provider": "https://api.engineyard.com/providers/198",
                "account": "https://api.engineyard.com/accounts/f0ad5bbc-cb58-4df9-931b-44c3e5d69eeb",
                "snapshot_server_request": "https://api.engineyard.com/requests/dc3073ff-5515-4a53-836c-db528e79b109"
              }
            ]
          }
            
          








Get a server's snapshot request's snapshots

GET /servers/:server/snapshots/:request

Response

          Status: 200 OK
          Content-Type: application/json; charset=utf-8
          
            
          {
            "snapshots": [
              {
                "id": 8,
                "created_at": "2017-10-10T15:59:19+00:00",
                "updated_at": "2017-10-10T15:59:19+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/85",
                "server": "https://api.engineyard.com/servers/126",
                "volume": "https://api.engineyard.com/volumes/145",
                "provider": "https://api.engineyard.com/providers/196",
                "account": "https://api.engineyard.com/accounts/346083bd-536c-4708-b82b-5a6b4a34c7de",
                "snapshot_server_request": "https://api.engineyard.com/requests/28891f96-ddb0-4741-ba52-f3e112f7068f"
              },
              {
                "id": 9,
                "created_at": "2017-10-10T15:59:19+00:00",
                "updated_at": "2017-10-10T15:59:19+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/85",
                "server": "https://api.engineyard.com/servers/126",
                "volume": "https://api.engineyard.com/volumes/146",
                "provider": "https://api.engineyard.com/providers/196",
                "account": "https://api.engineyard.com/accounts/346083bd-536c-4708-b82b-5a6b4a34c7de",
                "snapshot_server_request": "https://api.engineyard.com/requests/28891f96-ddb0-4741-ba52-f3e112f7068f"
              }
            ]
          }
            
          








Get a server's snapshots

GET /servers/:server/snapshots

Response

          Status: 200 OK
          Content-Type: application/json; charset=utf-8
          
            
          {
            "snapshots": [
              {
                "id": 6,
                "created_at": "2017-10-10T15:59:06+00:00",
                "updated_at": "2017-10-10T15:59:06+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/84",
                "server": "https://api.engineyard.com/servers/125",
                "volume": "https://api.engineyard.com/volumes/143",
                "provider": "https://api.engineyard.com/providers/194",
                "account": "https://api.engineyard.com/accounts/b45dde37-1478-4f09-9556-31391e4d5098",
                "snapshot_server_request": "https://api.engineyard.com/requests/67abab29-f38b-413d-bf84-5110864d8f61"
              },
              {
                "id": 7,
                "created_at": "2017-10-10T15:59:06+00:00",
                "updated_at": "2017-10-10T15:59:06+00:00",
                "deleted_at": null,
                "state": "starting",
                "progress": 0,
                "size": 15,
                "region": {
                  "id": "us-east-1",
                  "name": "US East (N. Virginia)"
                },
                "snaplocked": false,
                "mount": null,
                "grade": "unknown",
                "arch": 64,
                "environment": "https://api.engineyard.com/environments/84",
                "server": "https://api.engineyard.com/servers/125",
                "volume": "https://api.engineyard.com/volumes/144",
                "provider": "https://api.engineyard.com/providers/194",
                "account": "https://api.engineyard.com/accounts/b45dde37-1478-4f09-9556-31391e4d5098",
                "snapshot_server_request": "https://api.engineyard.com/requests/67abab29-f38b-413d-bf84-5110864d8f61"
              }
            ]
          }
            
          








Get a snapshot

GET /snapshots/:snapshot

Response

          Status: 200 OK
          Content-Type: application/json; charset=utf-8
          
            
          {
            "snapshot": {
              "id": 4,
              "created_at": "2017-10-10T15:58:53+00:00",
              "updated_at": "2017-10-10T15:58:53+00:00",
              "deleted_at": null,
              "state": "starting",
              "progress": 0,
              "size": 15,
              "region": {
                "id": "us-east-1",
                "name": "US East (N. Virginia)"
              },
              "snaplocked": false,
              "mount": null,
              "grade": "unknown",
              "arch": 64,
              "environment": "https://api.engineyard.com/environments/83",
              "server": "https://api.engineyard.com/servers/124",
              "volume": "https://api.engineyard.com/volumes/141",
              "provider": "https://api.engineyard.com/providers/192",
              "account": "https://api.engineyard.com/accounts/2be4612a-0370-472d-938e-f63f101534e7",
              "snapshot_server_request": "https://api.engineyard.com/requests/ccf13aa0-7828-4b5e-b89e-d23536695adb"
            }
          }
            
          








Snapshot a server

POST /servers/:server/snapshot

Response

          Status: 200 OK
          Content-Type: application/json; charset=utf-8
          
            
          {
            "request": {
              "type": "snapshot_server",
              "id": "8407c787-fbb1-4b33-987a-bd2d94b415af",
              "created_at": "2017-10-10T15:58:39+00:00",
              "started_at": "2017-10-10T15:58:39+00:00",
              "finished_at": "2017-10-10T15:58:40+00:00",
              "message": null,
              "request_status": "Finished: Snapshot server (8407c787-fbb1-4b33-987a-bd2d94b415af) (less than a minute ago)",
              "successful": true,
              "updated_at": "2017-10-10T15:58:40+00:00",
              "read_channel": null,
              "stage": "snapshots.perform",
              "dependencies": "https://api.engineyard.com/requests/8407c787-fbb1-4b33-987a-bd2d94b415af/dependencies",
              "stages": "https://api.engineyard.com/requests/8407c787-fbb1-4b33-987a-bd2d94b415af/stages",
              "account": "https://api.engineyard.com/accounts/1a37f2d7-ae6f-414d-8963-2ed92236f1d5",
              "requester": "https://api.engineyard.com/requests/8407c787-fbb1-4b33-987a-bd2d94b415af/requester",
              "messages": "https://api.engineyard.com/requests/8407c787-fbb1-4b33-987a-bd2d94b415af/messages",
              "callback_url": "https://api.engineyard.com/requests/8407c787-fbb1-4b33-987a-bd2d94b415af/callback",
              "progress": false,
              "resource": "https://api.engineyard.com/servers/123/snapshots/8407c787-fbb1-4b33-987a-bd2d94b415af"
            }
          }