Skip to main content

references

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

Overview

Namereferences
TypeResource
Idgoogle.apigee.references

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringRequired. The resource id of this reference. Values must match the regular expression [\w\s-.]+.
descriptionstringOptional. A human-readable description of this reference.
refersstringRequired. The id of the resource to which this reference refers. Must be the id of a resource that exists in the parent environment and is of the given resource_type.
resourceTypestringThe type of resource referred to by this reference. Valid values are 'KeyStore' or 'TrustStore'.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
organizations_environments_references_getselectorganizationsId, environmentsId, referencesIdGets a Reference resource.
organizations_environments_references_createinsertorganizationsId, environmentsIdCreates a Reference in the specified environment.
organizations_environments_references_updatereplaceorganizationsId, environmentsId, referencesIdUpdates an existing Reference. Note that this operation has PUT semantics; it will replace the entirety of the existing Reference with the resource in the request body.
organizations_environments_references_deletedeleteorganizationsId, environmentsId, referencesIdDeletes a Reference from an environment. Returns the deleted Reference resource.

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
environmentsIdstring
organizationsIdstring
referencesIdstring

SELECT examples

Gets a Reference resource.

SELECT
name,
description,
refers,
resourceType
FROM google.apigee.references
WHERE organizationsId = '{{ organizationsId }}' -- required
AND environmentsId = '{{ environmentsId }}' -- required
AND referencesId = '{{ referencesId }}' -- required;

INSERT examples

Creates a Reference in the specified environment.

INSERT INTO google.apigee.references (
data__name,
data__description,
data__resourceType,
data__refers,
organizationsId,
environmentsId
)
SELECT
'{{ name }}',
'{{ description }}',
'{{ resourceType }}',
'{{ refers }}',
'{{ organizationsId }}',
'{{ environmentsId }}'
RETURNING
name,
description,
refers,
resourceType
;

REPLACE examples

Updates an existing Reference. Note that this operation has PUT semantics; it will replace the entirety of the existing Reference with the resource in the request body.

REPLACE google.apigee.references
SET
data__name = '{{ name }}',
data__description = '{{ description }}',
data__resourceType = '{{ resourceType }}',
data__refers = '{{ refers }}'
WHERE
organizationsId = '{{ organizationsId }}' --required
AND environmentsId = '{{ environmentsId }}' --required
AND referencesId = '{{ referencesId }}' --required
RETURNING
name,
description,
refers,
resourceType;

DELETE examples

Deletes a Reference from an environment. Returns the deleted Reference resource.

DELETE FROM google.apigee.references
WHERE organizationsId = '{{ organizationsId }}' --required
AND environmentsId = '{{ environmentsId }}' --required
AND referencesId = '{{ referencesId }}' --required;