Skip to main content

realms

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

Overview

Namerealms
TypeResource
Idgoogle.cloudnumberregistry.realms

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringRequired. Identifier. The resource name of the Realm.
aggregatedDataobjectOutput only. Aggregated data for the Realm. Populated only when the view is AGGREGATE. (id: RealmAggregatedData)
createTimestring (google-datetime)Output only. The time at which the Realm was created.
discoveryMetadataobjectOutput only. Discovery metadata of the Realm. (id: DiscoveryMetadata)
ipVersionstringOptional. IP version of the Realm. (IP_VERSION_UNSPECIFIED, IPV4, IPV6)
labelsobjectOptional. User-defined labels.
managementTypestringOptional. Management type of the Realm. (MANAGEMENT_TYPE_UNSPECIFIED, CNR, USER)
registryBookstringRequired. Name of the RegistryBook that claims the Realm.
trafficTypestringRequired. Traffic type of the Realm. (TRAFFIC_TYPE_UNSPECIFIED, UNSET, INTERNET, PRIVATE, LINKLOCAL)
updateTimestring (google-datetime)Output only. The time at which the Realm was last updated.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, realmsIdviewGets details of a single Realm.
listselectprojectsId, locationsIdfilter, view, pageSize, pageToken, orderByLists Realms in a given project and location.
createinsertprojectsId, locationsIdrealmId, requestIdCreates a new Realm in a given project and location.
patchupdateprojectsId, locationsId, realmsIdupdateMask, requestIdUpdates the parameters of a single Realm.
deletedeleteprojectsId, locationsId, realmsIdrequestId, forceDeletes a single Realm.

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
locationsIdstring
projectsIdstring
realmsIdstring
filterstring
forceboolean
orderBystring
pageSizeinteger (int32)
pageTokenstring
realmIdstring
requestIdstring
updateMaskstring (google-fieldmask)
viewstring

SELECT examples

Gets details of a single Realm.

SELECT
name,
aggregatedData,
createTime,
discoveryMetadata,
ipVersion,
labels,
managementType,
registryBook,
trafficType,
updateTime
FROM google.cloudnumberregistry.realms
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND realmsId = '{{ realmsId }}' -- required
AND view = '{{ view }}'
;

INSERT examples

Creates a new Realm in a given project and location.

INSERT INTO google.cloudnumberregistry.realms (
data__registryBook,
data__labels,
data__name,
data__managementType,
data__ipVersion,
data__trafficType,
projectsId,
locationsId,
realmId,
requestId
)
SELECT
'{{ registryBook }}',
'{{ labels }}',
'{{ name }}',
'{{ managementType }}',
'{{ ipVersion }}',
'{{ trafficType }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ realmId }}',
'{{ requestId }}'
RETURNING
name,
done,
error,
metadata,
response
;

UPDATE examples

Updates the parameters of a single Realm.

UPDATE google.cloudnumberregistry.realms
SET
data__registryBook = '{{ registryBook }}',
data__labels = '{{ labels }}',
data__name = '{{ name }}',
data__managementType = '{{ managementType }}',
data__ipVersion = '{{ ipVersion }}',
data__trafficType = '{{ trafficType }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND realmsId = '{{ realmsId }}' --required
AND updateMask = '{{ updateMask}}'
AND requestId = '{{ requestId}}'
RETURNING
name,
done,
error,
metadata,
response;

DELETE examples

Deletes a single Realm.

DELETE FROM google.cloudnumberregistry.realms
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND realmsId = '{{ realmsId }}' --required
AND requestId = '{{ requestId }}'
AND force = '{{ force }}'
;