Management Plane API > Networking > Logical Switching > Logical Switch Ports

Get realized state & location of a logical port

Returns transport node id for a specified logical port. Also returns
information about all address bindings of the specified logical port. This
includes address bindings discovered via various snooping methods like ARP
snooping, DHCP snooping etc. and addressing bindings that are realized
based on user configuration.

Request:

Method:
GET
URI Path(s):
/api/v1/logical-ports/<lport-id>/state
Request Headers:
n/a
Query Parameters:
n/a
Request Body:
n/a

Example Request:

GET https://<nsx-mgr>/api/v1/logical-ports/9467676a-aeae-46f7-90f1-c771e02d1669/state

Successful Response:

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

Example Response:

{ "id": "9467676a-aeae-46f7-90f1-c771e02d1669", "transport_node_ids": [], "discovered_bindings": [ { "source": "ARP_SNOOPING" "binding": { ip_address: "192.168.1.10", mac_address: "aa:bb:cc:dd:ee:ff", vlan: "" } "binding_timestamp": 1457127071089 }, { "source": "DHCP_SNOOPING" "binding": { ip_address: "192.168.1.10", mac_address: "aa:bb:cc:dd:ee:ff", vlan: "" } "binding_timestamp": 1457127071089 } ], "realized_bindings": [ { "source": "USER_DEFINED" "binding": { ip_address: "192.168.1.10", mac_address: "aa:bb:cc:dd:ee:ff", vlan: "" } "binding_timestamp": 1117127071050 }, ] }

Required Permissions:

read

Feature:

switching_ports

Additional Errors: