列举服务。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
eas:ListServices |
get |
*Service
|
无 | 无 |
请求语法
GET /api/v2/services HTTP/1.1
请求参数
名称 |
类型 |
必填 |
描述 |
示例值 |
Sort |
string |
否 |
排序字段。按时间戳类型默认倒序排序。 |
CreateTime |
Order |
string |
否 |
排序方式,取值如下:
|
asc |
Filter |
string |
否 |
模糊匹配字段。只支持按服务名字模糊匹配。 |
foo |
PageNumber |
integer |
否 |
服务列表的请求页码,默认为 1。 |
1 |
PageSize |
integer |
否 |
分页查询时设置的每页显示的服务数量,默认为 100。 |
100 |
GroupName |
string |
否 |
服务群组名称,如何获取服务群组名称,请参见ListServices 。 |
foo |
ParentServiceUid |
string |
否 |
Band 成员服务对应的主服务 ID。 |
eas-m-ijafy3c8cxxxx |
ServiceType |
string |
否 |
服务类型,取值如下:
枚举值:
|
Standard |
Label |
object |
否 |
按标签过滤。 |
|
string |
否 |
按 |
{"key1":"value1","key2":null} |
|
ServiceStatus |
string |
否 |
服务运行的状态。 枚举值:
|
Running |
ServiceName |
string |
否 |
服务名。 |
echo_test |
ServiceUid |
string |
否 |
服务 UID。 |
eas-m-c9iw3yitxxxx |
ResourceName
deprecated
|
string |
否 |
服务所属的资源组名称或 ID。 |
eas-r-hd0qwy8cxxxx |
WorkspaceId |
string |
否 |
工作空间 ID。 |
1234** |
QuotaId |
string |
否 |
配额 ID。 |
quota1**** |
Gateway |
string |
否 |
私有网关 ID。 |
gw-1uhcqmsc7x22****** |
Role |
string |
否 |
服务角色。 枚举值:
|
LLMGateway |
ResourceType |
string |
否 |
服务所使用的资源类型,取值如下:
枚举值:
|
PublicResource |
IncludeNoWorkspace |
boolean |
否 |
是否包含不属于任何工作空间的服务。默认为 true。 |
true |
ResourceAliasName |
string |
否 |
资源组的自定义名称。 |
example |
ResourceId |
string |
否 |
资源组的 ID。如何查询资源组 ID,请参见 ListResources 。 |
eas-r-asdas**** |
ResourceBurstable |
boolean |
否 |
服务是否开启弹性资源池。 枚举值:
|
true |
CronscalerEnabled |
boolean |
否 |
服务是否开启定时扩缩容。 枚举值:
|
true |
AutoscalerEnabled |
boolean |
否 |
服务是否开启弹性伸缩。 枚举值:
|
true |
TrafficState |
string |
否 |
返回参数
名称 |
类型 |
描述 |
示例值 |
object |
返回结果。 |
||
RequestId |
string |
请求 ID。 |
40325405-579C-4D82**** |
Services |
array |
服务列表。 |
|
Service |
服务实例。 |
||
PageNumber |
integer |
返回查询的服务列表的当前页码。 |
1 |
PageSize |
integer |
返回每页显示的服务数量。 |
100 |
TotalCount |
integer |
服务总数。 |
2 |
示例
正常返回示例
JSON
格式
{
"RequestId": "40325405-579C-4D82****",
"Services": [
{
"ServiceGroup": "my_group",
"Memory": 1024,
"Cpu": 1,
"Image": "registry.cn-shanghai.aliyuncs.com/eas/echo_cn-shanghai:v0.0.1-20210129111320",
"Gpu": 0,
"TotalInstance": 1,
"AccessToken": "MzJiMDI5MDliODc0MTlkYmI0ZDhlYmExYjczYTIyZTE3Zm********",
"ResourceBurstable": true,
"InternetEndpoint": "http://10123*****.cn-shanghai.aliyuncs.com/api/predict/echo",
"ResourceAlias": "my_resource",
"Status": "Running",
"TrafficState": "standalone",
"RequestId": "40325405-579C-4D82********",
"Resource": "eas-r-xxxxxxx",
"SecondaryInternetEndpoint": "http://10123*****.cn-shanghai.aliyuncs.com/api/predict/async_path.echo\n",
"Labels": [
{
"LabelValue": "value1",
"LabelKey": "key1"
}
],
"Namespace": "echo",
"Weight": 100,
"Role": "Queue",
"SecondaryIntranetEndpoint": "http://10123*****.vpc.cn-shanghai.aliyuncs.com/api/predict/async_path.echo\n",
"PendingInstance": 0,
"ServiceName": "echo",
"SafetyLock": "dangerous",
"Region": "cn-shanghai",
"AppType": "LLM",
"InstanceCountInResource": {
"Quota": 10,
"Public": 10,
"Dedicated": 10
},
"IntranetEndpoint": "http://10123*****.vpc.cn-shanghai.aliyuncs.com/api/predict/echo",
"QuotaId": "quotaxxxxx",
"Message": "Service start successfully",
"CurrentVersion": 1,
"RunningInstance": 1,
"WorkspaceId": "123445",
"CallerUid": "20123*******",
"Reason": "RUNNING",
"Source": "dsw",
"ServiceId": "eas-m-xxasdat",
"AppVersion": "v1",
"CronscalerEnabled": true,
"ServiceConfig": "{\"metadata\":{\"cpu\":1,\"instance\":1,\"memory\":1024},\"name\":\"echo\",\"processor_entry\":\"libecho.so\",\"processor_path\":\"http://oss-cn-hangzhou-zmf.aliyuncs.com/059247/echo_processor_release.tar.gz\",\"processor_type\":\"cpp\"}",
"Gateway": "gw-xxxxxx",
"AppSpecName": "llama_7b_fp16",
"GPUCorePercentage": 50,
"GPUMemory": 20,
"AppConfig": "{\"ModelStorage\":\"oss\"}",
"CreateTime": "2021-01-29T11:13:20Z",
"AutoscalerEnabled": true,
"ExtraData": "{\"blue_green_services\":[\"test\",\"testxxxx\"]}",
"LatestVersion": 1,
"UpdateTime": "2021-01-29T11:13:20Z",
"ServiceUid": "eas-m-xxasdat\n",
"ParentUid": "11234*******",
"RoleAttrs": "{\"ApproxMaxLength\":null,\"Length\":null,\"MaxPayloadBytes\":null}"
}
],
"PageNumber": 1,
"PageSize": 100,
"TotalCount": 2
}
错误码
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。