Management Plane API > Networking > VPN > Statistics > L2VPN Session Statistics

Get L2VPN session statistics

Get statistics of a L2VPN session. Query parameter source=realtime is the only supported source.

Request:

Method:
GET
URI Path(s):
/api/v1/vpn/l2vpn/sessions/<session-id>/statistics
Request Headers:
n/a
Query Parameters:
DataSourceParameters+
Request Body:
n/a

Example Request:

GET https://<nsx-mgr>/api/v1/vpn/l2vpn/sessions/f962173f-ac03-4d08-8366-56a41779f61d/statistics?source=realtime

Successful Response:

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

Example Response:

{ "tap_traffic_counters": [ { "bytes_out": 0, "packets_out": 0, "bytes_in": 0, "packets_in": 0, "packets_sent_error": 0, "packets_receive_error": 0 } ], "session_id": "1f74abad-caec-4889-87e3-ebe9dfa1ad24", "display_name": "l2vpnsession", "traffic_statistics_per_logical_switch": [ { "bum_bytes_in": 0, "bytes_out": 0, "bum_packets_out": 0, "packets_out": 0, "bytes_in": 42, "bum_packets_in": 0, "packets_in": 3, "packets_sent_error": 0, "packets_receive_error": 3, "logical_switch": { "target_type": "LogicalSwitch", "target_id": "2efdb4b5-f221-4ea0-857a-51133321b07f" }, "bum_bytes_out": 0 }, { "bum_bytes_in": 0, "bytes_out": 0, "bum_packets_out": 0, "packets_out": 0, "bytes_in": 42, "bum_packets_in": 0, "packets_in": 3, "packets_sent_error": 0, "packets_receive_error": 3, "logical_switch": { "target_type": "LogicalSwitch", "target_id": "785fd137-933f-4e83-b2be-23c6d2757432" }, "bum_bytes_out": 0 } ], "partial_stats": false }

Required Permissions:

read

Feature:

vpn

Additional Errors: