cmek_config
Creates, updates, deletes, gets or lists a cmek_config resource.
Overview
| Name | cmek_config |
| Type | Resource |
| Id | google.discoveryengine.cmek_config |
Fields
The following fields are returned by SELECT queries:
- projects_locations_get_cmek_config
| Name | Datatype | Description |
|---|---|---|
name | string | Required. The name of the CmekConfig of the form projects/{project}/locations/{location}/cmekConfig or projects/{project}/locations/{location}/cmekConfigs/{cmek_config}. |
isDefault | boolean | Output only. The default CmekConfig for the Customer. |
kmsKey | string | Required. KMS key resource name which will be used to encrypt resources projects/{project}/locations/{location}/keyRings/{keyRing}/cryptoKeys/{keyId}. |
kmsKeyVersion | string | Output only. KMS key version resource name which will be used to encrypt resources /cryptoKeyVersions/{keyVersion}. |
lastRotationTimestampMicros | string (int64) | Output only. The timestamp of the last key rotation. |
notebooklmState | string | Output only. Whether the NotebookLM Corpus is ready to be used. |
singleRegionKeys | array | Optional. Single-regional CMEKs that are required for some VAIS features. |
state | string | Output only. The states of the CmekConfig. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
projects_locations_get_cmek_config | select | projectsId, locationsId | Gets the CmekConfig. | |
projects_locations_update_cmek_config | update | projectsId, locationsId | setDefault | Provisions a CMEK key for use in a location of a customer's project. This method will also conduct location validation on the provided cmekConfig to make sure the key is valid and can be used in the selected location. |
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 |
|---|---|---|
locationsId | string | |
projectsId | string | |
setDefault | boolean |
SELECT examples
- projects_locations_get_cmek_config
Gets the CmekConfig.
SELECT
name,
isDefault,
kmsKey,
kmsKeyVersion,
lastRotationTimestampMicros,
notebooklmState,
singleRegionKeys,
state
FROM google.discoveryengine.cmek_config
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
;
UPDATE examples
- projects_locations_update_cmek_config
Provisions a CMEK key for use in a location of a customer's project. This method will also conduct location validation on the provided cmekConfig to make sure the key is valid and can be used in the selected location.
UPDATE google.discoveryengine.cmek_config
SET
data__name = '{{ name }}',
data__kmsKey = '{{ kmsKey }}',
data__singleRegionKeys = '{{ singleRegionKeys }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND setDefault = {{ setDefault}}
RETURNING
name,
done,
error,
metadata,
response;