支持指定NIS网络分析场景,获取详细监控指标趋势数据,包括流量分析场景下的流量指标趋势数据,以及性能观测场景下的性能指标趋势数据等。
接口说明
数据查询结果同步说明:
API 数据跨度 6 小时同步一次,6 小时后才可查询当前网络分析数据。
支持分析场景:
NAT 网关 SNAT IP 流量分析场景
公网流量分析场景
跨域流量分析场景
混合云流量分析场景
公网性能观测大盘场景
跨可用区内网性能观测大盘场景
跨地域内网性能观测大盘场景
公网地域级限速场景
各场景的具体使用方式,请参见此文档。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

授权信息
操作 |
访问级别 |
资源类型 |
条件关键字 |
关联操作 |
nis:GetNisNetworkMetrics |
none |
*全部资源
|
无 | 无 |
请求参数
名称 |
类型 |
必填 |
描述 |
示例值 |
RegionNo |
string |
是 |
地域 ID。 |
cn-shenzhen |
ResourceType |
string |
是 |
按流量转发所使用的阿里云网络资源类型进行分析,取值:
|
AccessInternetIPV4 |
MetricName |
string |
是 |
指标名。取值:
说明
选定时间范围内 RTT 无数据,是因为该时间段里,此连接是长连接,没有触发首次建连。 |
bps |
Dimensions |
array<object> |
是 |
具体业务的 Metric 查询参数集合。各场景参数说明,请参见 GetNisNetworkMetrics 。 |
bps |
object |
否 |
具体业务的 Metric 查询参数。 |
||
Name |
string |
否 |
过滤条件的名字。 |
instanceId |
Value |
string |
否 |
过滤条件的值。 |
eip-sample* |
BeginTime |
integer |
否 |
起始时间,单位 ms,格式 unix 时间戳。未指定时默认查最近 1 小时。起始时间最早可选择 7 天前。 |
1638239092000 |
EndTime |
integer |
否 |
结束时间,单位 ms,格式 unix 时间戳。未指定时默认查最近 1 小时。只指定了 BeginTime 时查 BeginTime 之后的一小时。结束时间距起始时间最多 24 小时。 |
1684373700099 |
ScanBy |
string |
否 |
排序方式,默认 TimestampAscending,取值:
|
TimestampAscending |
UseCrossAccount |
boolean |
否 |
是否使用多账号访问模式,保留参数,暂不支持。 |
false |
AccountIds |
array |
否 |
显式传递子账号 ID。 |
|
string |
否 |
成员账号 ID 列表。 |
118639953821**** |
|
StepMinutes |
integer |
否 |
返回参数
名称 |
类型 |
描述 |
示例值 |
object |
RpcResponse<ArrayList |
||
RequestId |
string |
请求 ID。 |
D5E98683-355B-5867-8D3D-A24755F6895B |
Data |
object |
云网络指标趋势数据对象。 |
|
Unit |
string |
单位。 |
Bits/Second |
Metrics |
array<object> |
指标趋势数据集合。 |
|
object |
指标趋势单时间点数据。 |
||
TimeStamp |
integer |
数据的毫秒时间戳。 |
1690684091100 |
Value |
number |
指标值。 |
88 |
示例
正常返回示例
JSON
格式
{
"RequestId": "D5E98683-355B-5867-8D3D-A24755F6895B",
"Data": {
"Unit": "Bits/Second",
"Metrics": [
{
"TimeStamp": 1690684091100,
"Value": 88
}
]
}
}
错误码
HTTP status code |
错误码 |
错误信息 |
描述 |
---|---|---|---|
400 | IllegalParam.BeginTimeAndEndTime | It only supports querying data for up to 24 hours: %s. | 最大支持查询24小时数据。 |
400 | OperationFailed.DataTooMuch | Too much data has been queried under the specified conditions. Shorten the query time, specify more precise filtering conditions, or try again later. | 指定条件下查询的数据过多,请缩短查询时间、指定更精确过滤条件或者稍后重试。 |
400 | IllegalParam.Dimensions | The specified Dimensions(%s) is illegal. | 指定的Dimensions(%s)参数不合法。 |
400 | IllegalParam.Dimensions.Direction | The specified Dimensions.Direction(%s) is illegal. | 指定的Dimensions.Direction(%s)参数不合法。 |
400 | IllegalParam.Dimensions.InstanceId | The specified Dimensions.InstanceId(%s) is illegal. | 指定的Dimensions.InstanceId(%s)参数不合法。 |
400 | IllegalParam.MetricName | The specified MetricName(%s) is illegal. | 指定的MetricName(%s)参数不合法。 |
400 | IllegalParam.ResourceType | The specified resourceType (%s) is invalid. | 指定的ResourceType变量值(%s)不存在。 |
400 | IllegalParam.Dimensions.DestinationZone | The specified parameter Dimensions.DestinationZone (%s) is illegal. | 指定的参数Dimensions.DestinationZone(%s)不合法。 |
400 | IllegalParam.Dimensions.SourceZone | The specified parameter Dimensions.SourceZone(%s) is illegal. | 指定的参数Dimensions.SourceZone(%s)不合法。 |
400 | IllegalParam.IP | The specified IP address (%s) is invalid. | 指定的IP地址(%s)无效。 |
400 | IllegalParam.RegionNo | The specified parameter RegionNo(%s) is illegal. | 指定的参数RegionNo(%s)不合法。 |
400 | IllegalParam.Dimensions.InspectionTaskId | The specified argument Dimensions.InspectionTaskId(%s) is illegal. | 指定的参数Dimensions.InspectionTaskId(%s)不合法。 |
400 | IllegalParam.Dimensions.DestinationRegionNo | The specified parameter Dimensions.DestinationRegionNo(%s) is illegal. | 指定的Dimensions.DestinationRegionNo(%s)参数非法。 |
400 | IllegalParam.StepMinutes | The specified StepMinutes parameter value is illegal, only %s minutes of data precision is supported. | 指定的StepMinutes参数值不合法,仅支持%s分钟的数据精度。 |
400 | IllegalParam.MaxTimeScope | The query time range exceeds the limit. You can query up to %s days of data. | 查询时间范围超出限制,最大支持查询%s天的数据。 |
400 | IllegalParam.StepMinutesAndTime | In the current query time range, data precision of only %s minutes is supported to ensure performance. | 当前查询时间范围下,为保证性能,仅支持%s分钟的数据精度。 |
404 | ResourceNotFound.InstanceId | The specified InstanceId(%s) does not exist. | 指定的InstanceId(%s)不存在。 |
404 | ResourceNotFound.IpSets | The specified instance does not exist or does not have any acceleration region. | 指定的实例不存在或者没有加速区域。 |
404 | ResourceNotFound.InspectionTaskId | The specified InspectionTaskId(%s) is not found. | 指定的InspectionTaskId(%s)不存在。 |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。