tencent cloud

APIs

DescribeNatGatewayFlowMonitorDetail

Baixar
Modo Foco
Tamanho da Fonte
Última atualização: 2026-09-15 11:12:49

1. API Description

Domain name for API request: vpc.intl.tencentcloudapi.com.

This API is used to query the traffic monitoring details of a NAT gateway.

  • You can only use this API to query a single gateway instance. The input parameter NatGatewayId supports at most one value, and it must be passed.- If the gateway has traffic, but no data is returned when this API is called, please check whether gateway traffic monitoring is enabled in the corresponding gateway details page in the console.

A maximum of 20 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DescribeNatGatewayFlowMonitorDetail.
Version Yes String Common Params. The value used for this API: 2017-03-12.
Region Yes String Common Params. For more information, please see the list of regions supported by the product.
TimePoint Yes Timestamp ISO8601 Point in time. It indicates the moment to query. When the aggregation granularity is 60 or 300, the system queries the aggregation cycle starting from the latest whole minute. When the aggregation granularity is 3600, the system queries the aggregation cycle starting from the latest hour. When the aggregation granularity is 86400, the system queries the aggregation cycle starting from the latest whole day. Example: 2019-03-24T10:51:23+08:00.
NatGatewayId Yes String NAT gateway ID, for example: nat-ig8xpno8.
TopN No Integer Displays top-ranked data. Default value: 10, indicating that the top 10 ranked data is displayed by default. Maximum value: 100.
OrderField No String Sorting field. Valid values: InPkg, OutPkg, InTraffic, and OutTraffic. Standard NAT gateways additionally support ConcurrentConnectionCount and NewConnectionRate. Default value: OutTraffic.
AggregationTimeRange No Integer Aggregation time granularity. Valid values: 60, 300, 3600, and 86400, corresponding to aggregation queries by 1 minute, 5 minutes, 1 hour, and 1 day.
AllMetricMode No Boolean Specifies whether to query all metrics. Default value: True, which indicates that all metrics are queried.

3. Output Parameters

Parameter Name Type Description
TotalCount Integer Number of objects meeting conditions.
NatGatewayFlowMonitorDetailSet Array of NatGatewayFlowMonitorDetail Gateway traffic monitoring details.
RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

4. Example

Example1 Querying the Traffic Monitoring Details of a Standard NAT Gateway

This example shows you how to query the traffic monitoring details of a standard NAT gateway.

Input Example

https://vpc.intl.tencentcloudapi.com/?Action=DescribeNatGatewayFlowMonitorDetail
&TimePoint=2021-12-10T09:02:01+08:00
&NatGatewayId=nat-lz6rjk7n
&OrderField=OutTraffic
&<Common request parameters>

Output Example

{
    "Response": {
        "NatGatewayFlowMonitorDetailSet": [
            {
                "OutTraffic": 15925824,
                "PrivateIpAddress": "2.2.2.188",
                "InPkg": 71466,
                "OutPkg": 57276,
                "InTraffic": 13526553,
                "ConcurrentConnectionCount": 999,
                "NewConnectionRate": 888
            }
        ],
        "TotalCount": 1,
        "RequestId": "d9b0cd80-3b86-4e03-8fc9-bc7de311bc73"
    }
}

5. Developer Resources

SDK

TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

Command Line Interface

6. Error Code

The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

Error Code Description
InternalError.ModuleError Internal module error.
InvalidParameterValue Parameter value error.
InvalidParameterValue.Malformed Invalid input format.
InvalidParameterValue.Range The parameter value is not within the specified range.
ResourceNotFound The resource does not exist.
UnsupportedOperation The operation is not supported.

Ajuda e Suporte

Esta página foi útil?

comentários