NSX-T Data Center REST API

Get rule statistics

Get statistics of N-S Firewall rule.
- no enforcement point path specified: Stats will be evaluated on each enforcement
point.
- {enforcement_point_path}: Stats are evaluated only on the given enforcement point.

Request:

Method:
GET
URI Path(s):
/policy/api/v1/orgs/{org-id}/projects/{project-id}/vpcs/{vpc-id}/gateway-policies/{gateway-policy-id}/rules/{rule-id}/statistics
Request Headers:
n/a
Query Parameters:
StatisticsRequestParameters+
Request Body:
n/a

Example Request:

GET https://<policy-mgr>/policy/api/v1/orgs/default/projects/project-1/vpcs/vpc-1/gateway-policies/sp-1/rules/rule-1/statistics?enforcement_point_path=/infra/sites/default/enforcement-points/default

Successful Response:

Response Code:
200 OK
Response Headers:
Content-type: application/json
Response Body:
RuleStatisticsListResult+

Example Response:

{ "results" : [ { "rule": "rule-1", "packet_count": 3806, "session_count": 819, "hit_count": 345, "byte_count": 322989, "popularity_index": 85, "max_popularity_index": 85, "max_session_count": 819, "total_session_count": 881 } ], "cursor" : 1, "result_count" : 1 }

Required Permissions:

read

Feature:

policy_edge_fw

Additional Errors: