Skip to main content

settings

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

Overview

Namesettings
TypeResource
Idgoogle.resourcesettings.settings

Fields

NameDatatypeDescription
namestringThe resource name of the setting. Must be in one of the following forms: projects/{project_number}/settings/{setting_name} folders/{folder_id}/settings/{setting_name} * organizations/{organization_id}/settings/{setting_name} For example, "/projects/123/settings/gcp-enableMyFeature"
effectiveValueobjectThe data in a setting value.
etagstringA fingerprint used for optimistic concurrency. See UpdateSetting for more details.
localValueobjectThe data in a setting value.
metadataobjectMetadata about a setting which is not editable by the end user.

Methods

NameAccessible byRequired ParamsDescription
folders_settings_getSELECTfoldersId, settingsIdReturns a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist.
folders_settings_listSELECTfoldersIdLists all the settings that are available on the Cloud resource parent.
organizations_settings_getSELECTorganizationsId, settingsIdReturns a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist.
organizations_settings_listSELECTorganizationsIdLists all the settings that are available on the Cloud resource parent.
projects_settings_getSELECTprojectsId, settingsIdReturns a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist.
projects_settings_listSELECTprojectsIdLists all the settings that are available on the Cloud resource parent.
folders_settings_patchUPDATEfoldersId, settingsIdUpdates a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist. Returns a google.rpc.Status with google.rpc.Code.FAILED_PRECONDITION if the setting is flagged as read only. Returns a google.rpc.Status with google.rpc.Code.ABORTED if the etag supplied in the request does not match the persisted etag of the setting value. On success, the response will contain only name, local_value and etag. The metadata and effective_value cannot be updated through this API. Note: the supplied setting will perform a full overwrite of the local_value field.
organizations_settings_patchUPDATEorganizationsId, settingsIdUpdates a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist. Returns a google.rpc.Status with google.rpc.Code.FAILED_PRECONDITION if the setting is flagged as read only. Returns a google.rpc.Status with google.rpc.Code.ABORTED if the etag supplied in the request does not match the persisted etag of the setting value. On success, the response will contain only name, local_value and etag. The metadata and effective_value cannot be updated through this API. Note: the supplied setting will perform a full overwrite of the local_value field.
projects_settings_patchUPDATEprojectsId, settingsIdUpdates a specified setting. Returns a google.rpc.Status with google.rpc.Code.NOT_FOUND if the setting does not exist. Returns a google.rpc.Status with google.rpc.Code.FAILED_PRECONDITION if the setting is flagged as read only. Returns a google.rpc.Status with google.rpc.Code.ABORTED if the etag supplied in the request does not match the persisted etag of the setting value. On success, the response will contain only name, local_value and etag. The metadata and effective_value cannot be updated through this API. Note: the supplied setting will perform a full overwrite of the local_value field.

SELECT examples

Lists all the settings that are available on the Cloud resource parent.

SELECT
name,
effectiveValue,
etag,
localValue,
metadata
FROM google.resourcesettings.settings
WHERE foldersId = '{{ foldersId }}';

UPDATE example

Updates a settings resource.

/*+ update */
UPDATE google.resourcesettings.settings
SET
localValue = '{{ localValue }}',
etag = '{{ etag }}',
name = '{{ name }}'
WHERE
foldersId = '{{ foldersId }}'
AND settingsId = '{{ settingsId }}';