根据标签和资源组查询Prometheus实例。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
授权信息
下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:
- 操作:是指具体的权限点。
 - 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。
 - 资源类型:是指操作中支持授权的资源类型。具体说明如下:
- 对于必选的资源类型,用前面加 * 表示。
 - 对于不支持资源级授权的操作,用
全部资源表示。 
 - 条件关键字:是指云产品自身定义的条件关键字。
 - 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。
 
| 操作 | 访问级别 | 资源类型 | 条件关键字 | 关联操作 | 
|---|---|---|---|---|
| arms:ListPrometheusInstanceByTagAndResourceGroupId | list | *Prometheus acs:arms:{#regionId}:{#accountId}:prometheus/* | 
  | 无 | 
请求参数
| 名称 | 类型 | 必填 | 描述 | 示例值 | 
|---|---|---|---|---|
| RegionId | string | 是 | 地域 ID。  | cn-hangzhou | 
| ResourceGroupId | string | 否 | 资源组 ID。  | rg-acfmxyexli2**** | 
| Tag | array<object> | 否 | 标签列表。  | |
| object | 否 | 资源的标签。  | ||
| Key | string | 否 | 标签键。  | fpx-tag | 
| Value | string | 否 | 标签值。  | fvt-tag-value | 
返回参数
示例
正常返回示例
JSON格式
{
  "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": [
          {
            "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": "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"
}错误码
访问错误中心查看更多错误码。
变更历史
| 变更时间 | 变更内容概要 | 操作 | 
|---|---|---|
| 2023-12-13 | OpenAPI 返回结构发生变更 | 查看变更详情 | 
| 2023-06-21 | OpenAPI 入参发生变更 | 查看变更详情 | 
| 2023-05-17 | OpenAPI 入参发生变更 | 查看变更详情 | 
| 2023-03-30 | OpenAPI 返回结构发生变更 | 查看变更详情 | 
