gateways
Creates, updates, deletes, gets or lists a gateways
resource.
Overview
Name | gateways |
Type | Resource |
Id | google.apigateway.gateways |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. Resource name of the Gateway. Format: projects/{project}/locations/{location}/gateways/{gateway} |
apiConfig | string | Required. Resource name of the API Config for this Gateway. Format: projects/{project}/locations/global/apis/{api}/configs/{apiConfig} |
createTime | string (google-datetime) | Output only. Created time. |
defaultHostname | string | Output only. The default API Gateway host name of the form {gateway_id}-{hash}.{region_code}.gateway.dev . |
displayName | string | Optional. Display name. |
labels | object | Optional. Resource labels to represent user-provided metadata. Refer to cloud documentation on labels for more details. https://cloud.google.com/compute/docs/labeling-resources |
state | string | Output only. The current state of the Gateway. |
updateTime | string (google-datetime) | Output only. Updated time. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. Resource name of the Gateway. Format: projects/{project}/locations/{location}/gateways/{gateway} |
apiConfig | string | Required. Resource name of the API Config for this Gateway. Format: projects/{project}/locations/global/apis/{api}/configs/{apiConfig} |
createTime | string (google-datetime) | Output only. Created time. |
defaultHostname | string | Output only. The default API Gateway host name of the form {gateway_id}-{hash}.{region_code}.gateway.dev . |
displayName | string | Optional. Display name. |
labels | object | Optional. Resource labels to represent user-provided metadata. Refer to cloud documentation on labels for more details. https://cloud.google.com/compute/docs/labeling-resources |
state | string | Output only. The current state of the Gateway. |
updateTime | string (google-datetime) | Output only. Updated time. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , gatewaysId | Gets details of a single Gateway. | |
list | select | projectsId , locationsId | pageSize , pageToken , filter , orderBy | Lists Gateways in a given project and location. |
create | insert | projectsId , locationsId | gatewayId | Creates a new Gateway in a given project and location. |
patch | update | projectsId , locationsId , gatewaysId | updateMask | Updates the parameters of a single Gateway. |
delete | delete | projectsId , locationsId , gatewaysId | Deletes a single Gateway. |
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 |
---|---|---|
gatewaysId | string | |
locationsId | string | |
projectsId | string | |
filter | string | |
gatewayId | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets details of a single Gateway.
SELECT
name,
apiConfig,
createTime,
defaultHostname,
displayName,
labels,
state,
updateTime
FROM google.apigateway.gateways
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND gatewaysId = '{{ gatewaysId }}' -- required;
Lists Gateways in a given project and location.
SELECT
name,
apiConfig,
createTime,
defaultHostname,
displayName,
labels,
state,
updateTime
FROM google.apigateway.gateways
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND orderBy = '{{ orderBy }}';
INSERT
examples
- create
- Manifest
Creates a new Gateway in a given project and location.
INSERT INTO google.apigateway.gateways (
data__labels,
data__displayName,
data__apiConfig,
projectsId,
locationsId,
gatewayId
)
SELECT
'{{ labels }}',
'{{ displayName }}',
'{{ apiConfig }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ gatewayId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: gateways
props:
- name: projectsId
value: string
description: Required parameter for the gateways resource.
- name: locationsId
value: string
description: Required parameter for the gateways resource.
- name: labels
value: object
description: >
Optional. Resource labels to represent user-provided metadata. Refer to cloud documentation on labels for more details. https://cloud.google.com/compute/docs/labeling-resources
- name: displayName
value: string
description: >
Optional. Display name.
- name: apiConfig
value: string
description: >
Required. Resource name of the API Config for this Gateway. Format: projects/{project}/locations/global/apis/{api}/configs/{apiConfig}
- name: gatewayId
value: string
UPDATE
examples
- patch
Updates the parameters of a single Gateway.
UPDATE google.apigateway.gateways
SET
data__labels = '{{ labels }}',
data__displayName = '{{ displayName }}',
data__apiConfig = '{{ apiConfig }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND gatewaysId = '{{ gatewaysId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
done,
error,
metadata,
response;
DELETE
examples
- delete
Deletes a single Gateway.
DELETE FROM google.apigateway.gateways
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND gatewaysId = '{{ gatewaysId }}' --required;