Create Snapshot of Virtual Machine
You can manually create a snapshot of an Azure VM with the specified ID.
Note |
When you create a snapshot manually, Veeam Backup for Microsoft Azure detects if there is a snapshot chain for the processed Azure VM. If the snapshot chain exists, Veeam Backup for Microsoft Azure continues the existing chain. Otherwise, the created snapshot starts a new snapshot chain for the processed Azure VM. |
Request
To create a snapshot of a specific Azure VM, send the HTTP POST request to the //virtualMachines/takeSnapshot endpoint.
HTTP Request
POST https://<hostname>/api/v3/virtualMachines/takeSnapshot |
Request Headers
The request contains the following headers.
Header | Required | Value | Description |
---|---|---|---|
Authorization | Required | Bearer <Access-Token> | Authenticates a client who sends the request to the server. Must contain the access token for the current logon session in the Bearer <Access-Token> format. |
Request Body
To create the snapshot, send the following parameters in the request body.
Parameter | Type | Description |
---|---|---|
azureAccountId | string | Specifies an Azure account whose permissions Veeam Backup for Microsoft Azure will use to create a cloud-native snapshot. |
virtualMachines | array[string] | The list of Azure VM for whose snapshot Veeam Backup for Microsoft Azure must create. |
additionalTags | array[string] | [Applies when you want to assign custom tags] Specifies a tag key (key parameter) and value for each custom tag (value parameter). |
copyOriginalTags | boolean | Defines whether to assign tags of virtual disks attached to processed Azure VMs. The default value is true. |
Set the parameter values in the following format:
{ "azureAccountId": "string", "snapshotSettings": { "additionalTags": [ { "name": "string", "value": "string" } ], "copyOriginalTags": true }, "backupItems": { "virtualMachines": [ { "id": "string" } ] } } |
Response
The server returns the following response to the client.
Response Codes
A successfully completed operation returns a response code 202 (Accepted).
Response Headers
The response to this request contains the following headers. The response may also include additional standard HTTP headers.
Header | Value | Description |
---|---|---|
Content-length | integer | Identifies the length of the response body message, in bytes. |
Content-type |
| Identifies the media type of the response body message. |
Response Body
In the response body, Veeam Backup for Microsoft Azure returns the session ID of the snapshot removal operation. For the session log details, see Get Session Log Details.
Example
The following request creates a cloud-native snapshot in the original location of an Azure VM with the ID 1, and assigns to the created snapshot tags of virtual disks attached to the processed Azure VM.
|