> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.ibee.co.in/docs/api-reference/gpu-vms/create-gpu-vm-snapshot/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.ibee.co.in/_mcp/server. # Create a GPU VM snapshot POST https://api.ibee.co.in/v1/compute/gpu-vms/{vm_id}/snapshots Content-Type: application/json Creates a recovery snapshot of the root disk, all attached disks, or selected data disks. Requires scope: vm.write. Reference: https://docs.ibee.co.in/docs/api-reference/gpu-vms/create-gpu-vm-snapshot ## Authentication - `Authorization` header (bearer token, required) — IBEE platform API token. Production tokens start with `ibee_prod_key_`; development tokens start with `ibee_dev_key_`. Use a token only with its matching gateway environment. ## Servers - `https://api.ibee.co.in/v1` (Production, default) - `https://api.ibee.co.in/v1` (Development) ## Request ### Path parameters - `vm_id` (string, required) — Virtual machine ID. ### Query parameters - `workspace_id` (string, required) — The positive numeric workspace ID to scope this request to. Zero, negative, and non-numeric values are rejected. ### Body (application/json) This endpoint expects a SnapshotCreateRequest. - `name` (string, required) - `description` (string, optional, nullable) - `mode` (enum, optional, default: all_attached) - Allowed values: `root_only`, `all_attached`, `selective` - `selected_data_volume_ids` (list of string, optional, default: []) - `requested_by` (string, optional, default: api) ## Response ### 200 Snapshot created or queued successfully. - `organization_id` (string, required) - `workspace_id` (string, required) - `snapshot_set_id` (string, required) - `vm_id` (string, required) - `name` (string, required) - `recovery_point_id` (string, required) - `status` (enum, required) - Allowed values: `queued`, `running`, `succeeded`, `failed`, `cancelled` - `created_at` (datetime, required) - `updated_at` (datetime, required) - `organization_name` (string, optional, nullable) - `workspace_name` (string, optional, nullable) - `vm_name` (string, optional, nullable) - `vm_type` (enum, optional) - Allowed values: `cloud`, `gpu` - `description` (string, optional, nullable) - `recovery_point_type` (enum, optional, default: snapshot) - Allowed values: `snapshot` - `capture_scope` (enum, optional, default: all_attached) - Allowed values: `root_only`, `all_attached`, `selective` - `captured_volume_count` (integer, optional, default: 1) - `root_only` (boolean, optional, default: true) - `size_gb` (integer, optional, nullable) - `source_disk_size_gb` (integer, optional, nullable) - `display_size_gb` (integer, optional, nullable) - `display_storage_bytes` (integer, optional, nullable) - `backend_protected_storage_bytes` (integer, optional, nullable) - `protected_storage_bytes` (integer, optional, nullable) - `billing_storage_bytes` (integer, optional, nullable) - `billing_storage_source` (string, optional, default: unavailable) - `metering_status` (string, optional, default: unavailable) - `storage_backend` (string, optional, nullable) - `captured_topology_hash` (string, optional, nullable) - `root_volume_id` (string, optional, nullable) - `root_volume_name` (string, optional, nullable) - `volume_manifest` (list of RecoveryVolumeManifestItem, optional) - `volume_manifest_summary` (RecoveryPointSummary, optional) - `live_drift_summary` (LiveDriftSummary, optional) - `metadata` (map from string to any, optional) ## Errors ### 400 Bad Request Error The request is invalid. - `detail` (ErrorDetail, optional) ### 401 Unauthorized Error The API token is missing or invalid. - `detail` (ErrorDetail, optional) ### 403 Forbidden Error The token is not allowed to access the workspace or does not have the required scope. - `detail` (ErrorDetail, optional) ### 404 Not Found Error The requested resource was not found. - `detail` (ErrorDetail, optional) ### 409 Conflict Error The request conflicts with the current resource state. - `detail` (ErrorDetail, optional) ## Types ### RecoveryVolumeManifestItem - `source_volume_id` (string, required) - `source_volume_name` (string, optional, nullable) - `resource_name` (string, optional, nullable) - `role` (enum, optional, default: data) - Allowed values: `root`, `data` - `size_gb` (integer, optional, nullable) - `display_size_gb` (integer, optional, nullable) - `device_bus` (string, optional, nullable) - `device_slot` (string, optional, nullable) - `boot_index` (integer, optional, nullable) - `attachment_mode` (string, optional, nullable) - `guest_device` (string, optional, nullable) - `device_path` (string, optional, nullable) - `filesystem_uuid` (string, optional, nullable) - `filesystem_type` (string, optional, nullable) - `mount_hint` (string, optional, nullable) - `mount_state_at_capture` (string, optional, nullable) - `mount_instructions` (string, optional, nullable) - `delete_on_termination` (boolean, optional, nullable) - `source_attachment_present` (boolean, optional, default: true) - `artifact_type` (string, optional, nullable) - `artifact_ref` (string, optional, nullable) - `artifact_chain_id` (string, optional, nullable) - `artifact_backup_type` (string, optional, nullable) - `artifact_bytes` (integer, optional, nullable) - `billing_storage_bytes` (integer, optional, nullable) - `storage_usage` (map from string to any, optional, nullable) - `restored_volume_id` (string, optional, nullable) - `restored_resource_name` (string, optional, nullable) - `restored_device_path` (string, optional, nullable) - `restored_target_vm_id` (string, optional, nullable) - `metadata` (map from string to any, optional) ### RecoveryPointSummary - `root_only` (boolean, optional, default: true) - `root_volume_name` (string, optional, nullable) - `data_volume_names` (list of string, optional) - `summary_text` (string, optional, default: Root) ### LiveDriftSummary - `drifted` (boolean, optional, default: false) - `missing_from_live` (list of string, optional) - `new_live_only` (list of string, optional) - `message` (string, optional, nullable) ### ErrorDetail ## Examples **Request** ```json { "name": "string" } ``` **Response** ```json { "organization_id": "string", "workspace_id": "string", "snapshot_set_id": "string", "vm_id": "string", "name": "string", "recovery_point_id": "string", "status": "queued", "created_at": "2024-01-15T09:30:00Z", "updated_at": "2024-01-15T09:30:00Z", "organization_name": "string", "workspace_name": "string", "vm_name": "string", "vm_type": "cloud", "description": "string", "recovery_point_type": "snapshot", "capture_scope": "all_attached", "captured_volume_count": 1, "root_only": true, "size_gb": 1, "source_disk_size_gb": 1, "display_size_gb": 1, "display_storage_bytes": 1, "backend_protected_storage_bytes": 1, "protected_storage_bytes": 1, "billing_storage_bytes": 1, "billing_storage_source": "unavailable", "metering_status": "unavailable", "storage_backend": "string", "captured_topology_hash": "string", "root_volume_id": "string", "root_volume_name": "string", "volume_manifest": [ { "source_volume_id": "string", "source_volume_name": "string", "resource_name": "string", "role": "data", "size_gb": 1, "display_size_gb": 1, "device_bus": "string", "device_slot": "string", "boot_index": 1, "attachment_mode": "string", "guest_device": "string", "device_path": "string", "filesystem_uuid": "string", "filesystem_type": "string", "mount_hint": "string", "mount_state_at_capture": "string", "mount_instructions": "string", "delete_on_termination": true, "source_attachment_present": true, "artifact_type": "string", "artifact_ref": "string", "artifact_chain_id": "string", "artifact_backup_type": "string", "artifact_bytes": 1, "billing_storage_bytes": 1, "storage_usage": {}, "restored_volume_id": "string", "restored_resource_name": "string", "restored_device_path": "string", "restored_target_vm_id": "string", "metadata": {} } ], "volume_manifest_summary": { "root_only": true, "root_volume_name": "string", "data_volume_names": [ "string" ], "summary_text": "Root" }, "live_drift_summary": { "drifted": false, "missing_from_live": [ "string" ], "new_live_only": [ "string" ], "message": "string" }, "metadata": {} } ``` **SDK Code** ```python import requests url = "https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots" querystring = {"workspace_id":"710995"} payload = { "name": "string" } headers = { "Authorization": "Bearer ", "Content-Type": "application/json" } response = requests.post(url, json=payload, headers=headers, params=querystring) print(response.json()) ``` ```javascript const url = 'https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995'; const options = { method: 'POST', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: '{"name":"string"}' }; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995" payload := strings.NewReader("{\n \"name\": \"string\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{\n \"name\": \"string\"\n}" response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.post("https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{\n \"name\": \"string\"\n}") .asString(); ``` ```php request('POST', 'https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995', [ 'body' => '{ "name": "string" }', 'headers' => [ 'Authorization' => 'Bearer ', 'Content-Type' => 'application/json', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995"); var request = new RestRequest(Method.POST); request.AddHeader("Authorization", "Bearer "); request.AddHeader("Content-Type", "application/json"); request.AddParameter("application/json", "{\n \"name\": \"string\"\n}", ParameterType.RequestBody); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = [ "Authorization": "Bearer ", "Content-Type": "application/json" ] let parameters = ["name": "string"] as [String : Any] let postData = JSONSerialization.data(withJSONObject: parameters, options: []) let request = NSMutableURLRequest(url: NSURL(string: "https://api.ibee.co.in/v1/compute/gpu-vms/vm_id/snapshots?workspace_id=710995")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "POST" request.allHTTPHeaderFields = headers request.httpBody = postData as Data let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```