List all services in a Consul datacenter
GET /api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/consul/datacenters/{consul_datacenter}/services
GET /api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/consul/datacenters/{consul_datacenter}/servicesInteractive request editor loads with JavaScript.
X-API-KEY<token>
In: header
Path Parameters
service_registry_id*string
Service registry ID.
Length
1 <= lengthgateway_group_id*string
Gateway group ID.
Length
1 <= lengthconsul_datacenter*string
Consul datacenter name.
Length
1 <= lengthResponse Body
application/json
curl -X GET "$API_BASE_URL/api/gateway_groups/86fb9981-d9d2-4555-9df8-91ae92129335/service_registries/86fb9981-d9d2-4555-9df8-91ae92129335/consul/datacenters/dc1/services"Successfully retrieved the list of Consul services.
{
"list": [
"web",
"api",
"consul"
],
"total": 3
}Invalid arguments. Error details will be provided in the response.
Complete operation details and schema variants
GET /api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/consul/datacenters/{consul_datacenter}/services
List all services in a Consul datacenter
IAM Action: gateway:GetServiceRegistry, Resource: arn:api7:gateway:gatewaygroup/%s
Parameters
service_registry_id(path, string, required): Service registry ID.gateway_group_id(path, string, required): Gateway group ID.consul_datacenter(path, string, required): Consul datacenter name.
Responses
200: Successfully retrieved the list of Consul services.- allOf variant 1
list(array, optional): An array of resources.total(integer, optional): Total number of objects.- allOf variant 2
list(array, optional): An array of Consul services.total(object, optional):400: Invalid arguments. Error details will be provided in the response.
cURL
curl -X GET '$API_BASE_URL/api/gateway_groups/{gateway_group_id}/service_registries/{service_registry_id}/consul/datacenters/{consul_datacenter}/services'