versions
Creates, updates, deletes, gets or lists a versions
resource.
Overview
Name | versions |
Type | Resource |
Id | google.parametermanager.versions |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. [Output only] The resource name of the ParameterVersion in the format projects/*/locations/*/parameters/*/versions/* . |
createTime | string (google-datetime) | Output only. [Output only] Create time stamp |
disabled | boolean | Optional. Disabled boolean to determine if a ParameterVersion acts as a metadata only resource (payload is never returned if disabled is true). If true any calls will always default to BASIC view even if the user explicitly passes FULL view as part of the request. A render call on a disabled resource fails with an error. Default value is False. |
kmsKeyVersion | string | Optional. Output only. [Output only] The resource name of the KMS key version used to encrypt the ParameterVersion payload. This field is populated only if the Parameter resource has customer managed encryption key (CMEK) configured. |
payload | object | Required. Immutable. Payload content of a ParameterVersion resource. This is only returned when the request provides the View value of FULL (default for GET request). (id: ParameterVersionPayload) |
updateTime | string (google-datetime) | Output only. [Output only] Update time stamp |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. [Output only] The resource name of the ParameterVersion in the format projects/*/locations/*/parameters/*/versions/* . |
createTime | string (google-datetime) | Output only. [Output only] Create time stamp |
disabled | boolean | Optional. Disabled boolean to determine if a ParameterVersion acts as a metadata only resource (payload is never returned if disabled is true). If true any calls will always default to BASIC view even if the user explicitly passes FULL view as part of the request. A render call on a disabled resource fails with an error. Default value is False. |
kmsKeyVersion | string | Optional. Output only. [Output only] The resource name of the KMS key version used to encrypt the ParameterVersion payload. This field is populated only if the Parameter resource has customer managed encryption key (CMEK) configured. |
payload | object | Required. Immutable. Payload content of a ParameterVersion resource. This is only returned when the request provides the View value of FULL (default for GET request). (id: ParameterVersionPayload) |
updateTime | string (google-datetime) | Output only. [Output only] Update time stamp |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , parametersId , versionsId | view | Gets details of a single ParameterVersion. |
list | select | projectsId , locationsId , parametersId | pageSize , pageToken , filter , orderBy | Lists ParameterVersions in a given project, location, and parameter. |
create | insert | projectsId , locationsId , parametersId | parameterVersionId , requestId | Creates a new ParameterVersion in a given project, location, and parameter. |
patch | update | projectsId , locationsId , parametersId , versionsId | updateMask , requestId | Updates a single ParameterVersion. |
delete | delete | projectsId , locationsId , parametersId , versionsId | requestId | Deletes a single ParameterVersion. |
render | exec | projectsId , locationsId , parametersId , versionsId | Gets rendered version of a ParameterVersion. |
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 | |
parametersId | string | |
projectsId | string | |
versionsId | string | |
filter | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
parameterVersionId | string | |
requestId | string | |
updateMask | string (google-fieldmask) | |
view | string |
SELECT
examples
- get
- list
Gets details of a single ParameterVersion.
SELECT
name,
createTime,
disabled,
kmsKeyVersion,
payload,
updateTime
FROM google.parametermanager.versions
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND parametersId = '{{ parametersId }}' -- required
AND versionsId = '{{ versionsId }}' -- required
AND view = '{{ view }}';
Lists ParameterVersions in a given project, location, and parameter.
SELECT
name,
createTime,
disabled,
kmsKeyVersion,
payload,
updateTime
FROM google.parametermanager.versions
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND parametersId = '{{ parametersId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND orderBy = '{{ orderBy }}';
INSERT
examples
- create
- Manifest
Creates a new ParameterVersion in a given project, location, and parameter.
INSERT INTO google.parametermanager.versions (
data__name,
data__disabled,
data__payload,
projectsId,
locationsId,
parametersId,
parameterVersionId,
requestId
)
SELECT
'{{ name }}',
{{ disabled }},
'{{ payload }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ parametersId }}',
'{{ parameterVersionId }}',
'{{ requestId }}'
RETURNING
name,
createTime,
disabled,
kmsKeyVersion,
payload,
updateTime
;
# Description fields are for documentation purposes
- name: versions
props:
- name: projectsId
value: string
description: Required parameter for the versions resource.
- name: locationsId
value: string
description: Required parameter for the versions resource.
- name: parametersId
value: string
description: Required parameter for the versions resource.
- name: name
value: string
description: >
Identifier. [Output only] The resource name of the ParameterVersion in the format `projects/*/locations/*/parameters/*/versions/*`.
- name: disabled
value: boolean
description: >
Optional. Disabled boolean to determine if a ParameterVersion acts as a metadata only resource (payload is never returned if disabled is true). If true any calls will always default to BASIC view even if the user explicitly passes FULL view as part of the request. A render call on a disabled resource fails with an error. Default value is False.
- name: payload
value: object
description: >
Required. Immutable. Payload content of a ParameterVersion resource. This is only returned when the request provides the View value of FULL (default for GET request).
- name: parameterVersionId
value: string
- name: requestId
value: string
UPDATE
examples
- patch
Updates a single ParameterVersion.
UPDATE google.parametermanager.versions
SET
data__name = '{{ name }}',
data__disabled = {{ disabled }},
data__payload = '{{ payload }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND parametersId = '{{ parametersId }}' --required
AND versionsId = '{{ versionsId }}' --required
AND updateMask = '{{ updateMask}}'
AND requestId = '{{ requestId}}'
RETURNING
name,
createTime,
disabled,
kmsKeyVersion,
payload,
updateTime;
DELETE
examples
- delete
Deletes a single ParameterVersion.
DELETE FROM google.parametermanager.versions
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND parametersId = '{{ parametersId }}' --required
AND versionsId = '{{ versionsId }}' --required
AND requestId = '{{ requestId }}';
Lifecycle Methods
- render
Gets rendered version of a ParameterVersion.
EXEC google.parametermanager.versions.render
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@parametersId='{{ parametersId }}' --required,
@versionsId='{{ versionsId }}' --required;