Skip to main content

vaults

Creates, updates, deletes, gets or lists a vaults resource.

Overview

Namevaults
TypeResource
Idazure.recovery_services.vaults

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
identityobjectIdentity for the resource.
locationstringThe geo-location where the resource lives
propertiesobjectProperties of the vault.
skuobjectThe resource model definition representing SKU
systemDataobjectMetadata pertaining to creation and last modification of the resource.
tagsobjectResource tags.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectsubscriptionId, resourceGroupName, vaultNameGet the Vault details.
list_by_resource_groupselectsubscriptionId, resourceGroupNameRetrieve a list of Vaults.
list_by_subscription_idselectsubscriptionIdFetches all the resources of the specified type in the subscription.
create_or_updateinsertsubscriptionId, resourceGroupName, vaultNamex-ms-authorization-auxiliaryCreates or updates a Recovery Services vault.
updateupdatesubscriptionId, resourceGroupName, vaultNamex-ms-authorization-auxiliaryUpdates the vault.
deletedeletesubscriptionId, resourceGroupName, vaultNameDeletes a vault.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
resourceGroupNamestringThe name of the resource group. The name is case insensitive.
subscriptionIdstringThe ID of the target subscription.
vaultNamestringThe name of the recovery services vault.
x-ms-authorization-auxiliarystring

SELECT examples

Get the Vault details.

SELECT
identity,
location,
properties,
sku,
systemData,
tags
FROM azure.recovery_services.vaults
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND vaultName = '{{ vaultName }}' -- required
;

INSERT examples

Creates or updates a Recovery Services vault.

INSERT INTO azure.recovery_services.vaults (
data__tags,
data__location,
data__identity,
data__properties,
data__sku,
subscriptionId,
resourceGroupName,
vaultName,
x-ms-authorization-auxiliary
)
SELECT
'{{ tags }}',
'{{ location }}',
'{{ identity }}',
'{{ properties }}',
'{{ sku }}',
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ vaultName }}',
'{{ x-ms-authorization-auxiliary }}'
RETURNING
identity,
location,
properties,
sku,
systemData,
tags
;

UPDATE examples

Updates the vault.

UPDATE azure.recovery_services.vaults
SET
data__location = '{{ location }}',
data__tags = '{{ tags }}',
data__properties = '{{ properties }}',
data__sku = '{{ sku }}',
data__identity = '{{ identity }}'
WHERE
subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND vaultName = '{{ vaultName }}' --required
AND x-ms-authorization-auxiliary = '{{ x-ms-authorization-auxiliary}}'
RETURNING
identity,
location,
properties,
sku,
systemData,
tags;

DELETE examples

Deletes a vault.

DELETE FROM azure.recovery_services.vaults
WHERE subscriptionId = '{{ subscriptionId }}' --required
AND resourceGroupName = '{{ resourceGroupName }}' --required
AND vaultName = '{{ vaultName }}' --required
;