datacenters
Creates, updates, deletes, gets or lists a datacenters resource.
Overview​
| Name | datacenters |
| Type | Resource |
| Id | ovh.ovh_cloud_connect.datacenters |
Fields​
The following fields are returned by SELECT queries:
- get
- list
successful operation
| Name | Datatype | Description |
|---|---|---|
id | integer | ID of the datacenter |
name | string | name of the datacenter |
available | boolean | Get availability to add new configuration on it |
region | string | region of the datacenter (af-north-lz-rba, ap-south-mum, ap-southeast-sgp, ap-southeast-syd, ca-east-bhs, ca-east-tor, eu-central-lz-buh, eu-central-lz-prg, eu-central-lz-sof, eu-central-waw, eu-north-lz-cph, eu-north-lz-hel, eu-north-lz-osl, eu-north-lz-sto, eu-south-lz-lis, eu-south-lz-mad, eu-south-lz-mil, eu-south-mil, eu-west-eri, eu-west-gra, eu-west-gra-snc, eu-west-lim, eu-west-lz-ams, eu-west-lz-bru, eu-west-lz-dln, eu-west-lz-lux, eu-west-lz-mnc, eu-west-lz-mrs, eu-west-lz-vie, eu-west-lz-zrh, eu-west-par, eu-west-rbx, eu-west-rbx-snc, eu-west-sbg, eu-west-sbg-snc, us-central-lz-slc, us-central-lz-stl, us-east-lz-atl, us-east-lz-bos, us-east-lz-chi, us-east-lz-dal, us-east-lz-mia, us-east-lz-nyc, us-east-vin, us-west-hil, us-west-lz-den, us-west-lz-lax, us-west-lz-pao, us-west-lz-sea) |
region_type | string | region type of the datacenter (1-AZ, 3-AZ) (wire: regionType) |
OVHcloud Connect Datacenter
| Name | Datatype | Description |
|---|---|---|
id | integer | ID of the datacenter |
name | string | name of the datacenter |
available | boolean | Get availability to add new configuration on it |
region | string | region of the datacenter (af-north-lz-rba, ap-south-mum, ap-southeast-sgp, ap-southeast-syd, ca-east-bhs, ca-east-tor, eu-central-lz-buh, eu-central-lz-prg, eu-central-lz-sof, eu-central-waw, eu-north-lz-cph, eu-north-lz-hel, eu-north-lz-osl, eu-north-lz-sto, eu-south-lz-lis, eu-south-lz-mad, eu-south-lz-mil, eu-south-mil, eu-west-eri, eu-west-gra, eu-west-gra-snc, eu-west-lim, eu-west-lz-ams, eu-west-lz-bru, eu-west-lz-dln, eu-west-lz-lux, eu-west-lz-mnc, eu-west-lz-mrs, eu-west-lz-vie, eu-west-lz-zrh, eu-west-par, eu-west-rbx, eu-west-rbx-snc, eu-west-sbg, eu-west-sbg-snc, us-central-lz-slc, us-central-lz-stl, us-east-lz-atl, us-east-lz-bos, us-east-lz-chi, us-east-lz-dal, us-east-lz-mia, us-east-lz-nyc, us-east-vin, us-west-hil, us-west-lz-den, us-west-lz-lax, us-west-lz-pao, us-west-lz-sea) |
region_type | string | region type of the datacenter (1-AZ, 3-AZ) (wire: regionType) |
Methods​
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get | select | id, service_name | Returns the availability zone's name, region, 1-AZ or 3-AZ type, and whether it accepts a new configuration. | |
list | select | service_name | x_pagination_mode | Returns the IDs of the availability zones this service can connect to. |
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 |
|---|---|---|
api_host | string | The OVHcloud API host. Selected by OVH_ENDPOINT (ovh-eu, ovh-ca or ovh-us; default ovh-eu). (default: api.eu.ovhcloud.com, x-stackQL-envVarSelector: {"envVar":"OVH_ENDPOINT","default":"ovh-eu","values":{"ovh-eu":"api.eu.ovhcloud.com","ovh-ca":"api.ca.ovhcloud.com","ovh-us":"api.us.ovhcloud.com"}}) |
id | integer | Id |
service_name | string (uuid) | Service name (wire: serviceName) |
x_pagination_mode | string | Sent as CachedObjectList-Pages by default so the list returns the full objects rather than their identifiers. (wire: X-Pagination-Mode) |
SELECT examples​
- get
- list
Returns the availability zone's name, region, 1-AZ or 3-AZ type, and whether it accepts a new configuration.
SELECT
id,
name,
available,
region,
region_type
FROM ovh.ovh_cloud_connect.datacenters
WHERE id = '{{ id }}' -- required
AND service_name = '{{ service_name }}' -- required
;
Returns the IDs of the availability zones this service can connect to.
SELECT
id,
name,
available,
region,
region_type
FROM ovh.ovh_cloud_connect.datacenters
WHERE service_name = '{{ service_name }}' -- required
AND x_pagination_mode = '{{ x_pagination_mode }}'
;