keys
Creates, updates, deletes, gets or lists a keys
resource.
Overview
Name | keys |
Type | Resource |
Id | azure.key_vault.keys |
Fields
The following fields are returned by SELECT
queries:
- get
- list
The retrieved key.
Name | Datatype | Description |
---|---|---|
id | string | Fully qualified identifier of the key vault resource. |
name | string | Name of the key vault resource. |
location | string | Azure location of the key vault resource. |
properties | object | The properties of the key. |
tags | object | Tags assigned to the key vault resource. |
type | string | Resource type of the key vault resource. |
The retrieved page of keys.
Name | Datatype | Description |
---|---|---|
id | string | Fully qualified identifier of the key vault resource. |
name | string | Name of the key vault resource. |
location | string | Azure location of the key vault resource. |
properties | object | The properties of the key. |
tags | object | Tags assigned to the key vault resource. |
type | string | Resource type of the key vault resource. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | subscriptionId , resourceGroupName , vaultName , keyName | Gets the current version of the specified key from the specified key vault. | |
list | select | subscriptionId , resourceGroupName , vaultName | Lists the keys in the specified key vault. | |
create_if_not_exist | insert | subscriptionId , resourceGroupName , vaultName , keyName , data__properties | Creates the first version of a new key if it does not exist. If it already exists, then the existing key is returned without any write operations being performed. This API does not create subsequent versions, and does not update existing keys. |
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.
Name | Datatype | Description |
---|---|---|
keyName | string | The name of the key to be created. The value you provide may be copied globally for the purpose of running the service. The value provided should not include personally identifiable or sensitive information. |
resourceGroupName | string | The name of the resource group which contains the specified key vault. |
subscriptionId | string | Subscription credentials which uniquely identify Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. |
vaultName | string | The name of the key vault which contains the key to be created. |
SELECT
examples
- get
- list
Gets the current version of the specified key from the specified key vault.
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure.key_vault.keys
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND vaultName = '{{ vaultName }}' -- required
AND keyName = '{{ keyName }}' -- required
;
Lists the keys in the specified key vault.
SELECT
id,
name,
location,
properties,
tags,
type
FROM azure.key_vault.keys
WHERE subscriptionId = '{{ subscriptionId }}' -- required
AND resourceGroupName = '{{ resourceGroupName }}' -- required
AND vaultName = '{{ vaultName }}' -- required
;
INSERT
examples
- create_if_not_exist
- Manifest
Creates the first version of a new key if it does not exist. If it already exists, then the existing key is returned without any write operations being performed. This API does not create subsequent versions, and does not update existing keys.
INSERT INTO azure.key_vault.keys (
data__tags,
data__properties,
subscriptionId,
resourceGroupName,
vaultName,
keyName
)
SELECT
'{{ tags }}',
'{{ properties }}' /* required */,
'{{ subscriptionId }}',
'{{ resourceGroupName }}',
'{{ vaultName }}',
'{{ keyName }}'
RETURNING
id,
name,
location,
properties,
tags,
type
;
# Description fields are for documentation purposes
- name: keys
props:
- name: subscriptionId
value: string
description: Required parameter for the keys resource.
- name: resourceGroupName
value: string
description: Required parameter for the keys resource.
- name: vaultName
value: string
description: Required parameter for the keys resource.
- name: keyName
value: string
description: Required parameter for the keys resource.
- name: tags
value: object
description: |
The tags that will be assigned to the key.
- name: properties
value: object
description: |
The properties of the key to be created.