首页 ListPrometheusInstanceByTagAndResourceGroupId

ListPrometheusInstanceByTagAndResourceGroupId

更新时间: 2026-06-12 07:18:48

Queries Prometheus instances by tag and resource group.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

RegionId

string

Yes

The region ID of the Prometheus instance.

cn-hangzhou

ResourceGroupId

string

No

The ID of the resource group.

rg-acfmxyexli2****

Tag

array<object>

No

The tags.

object

No

The tag of the resource.

Key

string

No

The key of the tag.

fpx-tag

Value

string

No

The value of the tag.

fvt-tag-value

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

Id of the request

4789C3E9-A85A-524B-B97B-9D2B14BA06BC

Data

object

The returned struct.

PrometheusInstances

array<object>

The queried Prometheus instances.

array<object>

ClusterId

string

The ID of the Prometheus instance.

c9d5dda1aeca64220853ace304baeb03d

RegionId

string

The region ID.

cn-shanghai

UserId

string

The ID of the user.

1672753017899***

ClusterName

string

The name of the Prometheus instance.

prom1

ClusterType

string

The instance type. Valid values:

  • remote-write: Prometheus instance for Remote Write

  • ecs: Prometheus instances for ECS

  • cloud-monitor: Prometheus instance for Alibaba Cloud services in the Chinese mainland

  • cloud-product: Prometheus instance for Alibaba Cloud services outside the Chinese mainland

  • global-view: global aggregation instance

  • aliyun-cs: Prometheus instance for Container Service

ecs

VpcId

string

The ID of the virtual private cloud (VPC).

vpc-8vbtp1fsm8mir18l8rl0u

VSwitchId

string

The ID of the vSwitch.

vsw-f8z73vcja1tqnw90aav5a

SecurityGroupId

string

The ID of the security group.

sg-f8zd1toc10wmbi1v5rom

SubClustersJson

string

The child instances of the global aggregation instance. The value is a JSON string.

[ { "headers": {}, "regionId": "cn-hangzhou", "sourceType": "AlibabaPrometheus", "extras": {}, "clusterId": "c39a1048921e04fceb039db2fb****", "sourceName": "arms-luyao-test", "dataSource": "", "userId": "167275301789****" }, { "headers": {}, "regionId": "cn-beijing", "sourceType": "AlibabaPrometheus", "extras": {}, "clusterId": "c6b6485496d5b400abde22cb47b5****", "sourceName": "agent-321-测试", "dataSource": "", "userId": "167275301789****" }, { "headers": {}, "regionId": "cn-zhangjiakou", "sourceType": "AlibabaPrometheus", "extras": {}, "clusterId": "c261a4f3200c446659133f1ade78****", "sourceName": "zaifeng-cardinality-01", "dataSource": "", "userId": "167275301789****" } ]

RemoteReadIntraUrl

string

The internal URL for remote read.

http://cn-beijing-intranet.arms.aliyuncs.com:9090/api/v1/prometheus/xxx/api/v1/read

RemoteReadInterUrl

string

The public URL for remote read.

http://cn-beijing.arms.aliyuncs.com:9090/api/v1/prometheus/xxx/api/v1/read

RemoteWriteIntraUrl

string

The internal URL for remote write.

http://cn-beijing-intranet.arms.aliyuncs.com/prometheus/xxx/api/v3/write

RemoteWriteInterUrl

string

The public URL for remote write.

https://cn-beijing.arms.aliyuncs.com/prometheus/xxx/api/v3/write

PushGatewayIntraUrl

string

The internal URL for Pushgateway.

http://cn-beijing-intranet.arms.aliyuncs.com/prometheus/xxx/api/v2

PushGatewayInterUrl

string

The public URL for Pushgateway.

https://cn-beijing.arms.aliyuncs.com/prometheus/xxx/api/v2

HttpApiIntraUrl

string

The internal URL for the HTTP API.

http://cn-beijing-intranet.arms.aliyuncs.com:9090/api/v1/prometheus/xxx

HttpApiInterUrl

string

The public URL for the HTTP API.

https://cn-beijing.arms.aliyuncs.com:9443/api/v1/prometheus/xxx

AuthToken

string

The authorization token.

GciOiJIUzI1NiJ9***

PaymentType

string

The billing method. Valid values:

  • PREPAY: subscription

  • POSTPAY: pay-as-you-go

POSTPAY

GrafanaInstanceId

string

The ID of the Grafana workspace.

grafana-rnggfvhlcdl6m71l**

ResourceGroupId

string

The ID of the resource group to which the Prometheus instance belongs.

rg-acfmz7nocpeidcy

ResourceType

string

The resource type.

PROMETHEUS

Tags

array<object>

The list of tags.

object

The tag.

TagKey

string

The tag key.

ac-cus-tag-3

TagValue

string

The tag value.

asg-2vc8qq7x89o11rus9uvu

Code

string

The response code. The status code 200 indicates that the request was successful. Other status codes indicate that the request failed.

200

Message

string

The returned message.

message

Examples

Success response

JSON format

{
  "RequestId": "4789C3E9-A85A-524B-B97B-9D2B14BA06BC",
  "Data": {
    "PrometheusInstances": [
      {
        "ClusterId": "c9d5dda1aeca64220853ace304baeb03d",
        "RegionId": "cn-shanghai",
        "UserId": "1672753017899***",
        "ClusterName": "prom1",
        "ClusterType": "ecs",
        "VpcId": "vpc-8vbtp1fsm8mir18l8rl0u",
        "VSwitchId": "vsw-f8z73vcja1tqnw90aav5a",
        "SecurityGroupId": "sg-f8zd1toc10wmbi1v5rom",
        "SubClustersJson": "[\n  {\n    \"headers\": {},\n    \"regionId\": \"cn-hangzhou\",\n    \"sourceType\": \"AlibabaPrometheus\",\n    \"extras\": {},\n    \"clusterId\": \"c39a1048921e04fceb039db2fb****\",\n    \"sourceName\": \"arms-luyao-test\",\n    \"dataSource\": \"\",\n    \"userId\": \"167275301789****\"\n  },\n  {\n    \"headers\": {},\n    \"regionId\": \"cn-beijing\",\n    \"sourceType\": \"AlibabaPrometheus\",\n    \"extras\": {},\n    \"clusterId\": \"c6b6485496d5b400abde22cb47b5****\",\n    \"sourceName\": \"agent-321-测试\",\n    \"dataSource\": \"\",\n    \"userId\": \"167275301789****\"\n  },\n  {\n    \"headers\": {},\n    \"regionId\": \"cn-zhangjiakou\",\n    \"sourceType\": \"AlibabaPrometheus\",\n    \"extras\": {},\n    \"clusterId\": \"c261a4f3200c446659133f1ade78****\",\n    \"sourceName\": \"zaifeng-cardinality-01\",\n    \"dataSource\": \"\",\n    \"userId\": \"167275301789****\"\n  }\n]",
        "RemoteReadIntraUrl": "http://cn-beijing-intranet.arms.aliyuncs.com:9090/api/v1/prometheus/xxx/api/v1/read",
        "RemoteReadInterUrl": "http://cn-beijing.arms.aliyuncs.com:9090/api/v1/prometheus/xxx/api/v1/read",
        "RemoteWriteIntraUrl": "http://cn-beijing-intranet.arms.aliyuncs.com/prometheus/xxx/api/v3/write",
        "RemoteWriteInterUrl": "https://cn-beijing.arms.aliyuncs.com/prometheus/xxx/api/v3/write",
        "PushGatewayIntraUrl": "http://cn-beijing-intranet.arms.aliyuncs.com/prometheus/xxx/api/v2",
        "PushGatewayInterUrl": "https://cn-beijing.arms.aliyuncs.com/prometheus/xxx/api/v2",
        "HttpApiIntraUrl": "http://cn-beijing-intranet.arms.aliyuncs.com:9090/api/v1/prometheus/xxx\n",
        "HttpApiInterUrl": "https://cn-beijing.arms.aliyuncs.com:9443/api/v1/prometheus/xxx",
        "AuthToken": "GciOiJIUzI1NiJ9***",
        "PaymentType": "POSTPAY",
        "GrafanaInstanceId": "grafana-rnggfvhlcdl6m71l**",
        "ResourceGroupId": "rg-acfmz7nocpeidcy",
        "ResourceType": "PROMETHEUS",
        "Tags": [
          {
            "TagKey": "ac-cus-tag-3",
            "TagValue": "asg-2vc8qq7x89o11rus9uvu"
          }
        ]
      }
    ]
  },
  "Code": "200",
  "Message": "message"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.

阿里云首页 可观测监控 Prometheus 版 相关技术圈