Management Plane API > Networking > Logical Routing And Services > Logical Router Ports

Update a Logical Router Port

Modifies the specified logical router port. Required parameters include the
resource_type and logical_router_id. Modifiable parameters include the
resource_type (LogicalRouterUpLinkPort, LogicalRouterDownLinkPort,
LogicalRouterLinkPort, LogicalRouterLoopbackPort, LogicalRouterCentralizedServicePort),
logical_router_id (to reassign the port to a different router), and service_bindings.

Request:

Method:
PUT
URI Path(s):
/api/v1/logical-router-ports/<logical-router-port-id>
Request Headers:
n/a
Query Parameters:
n/a
Request Body:
LogicalRouterCentralizedServicePort+
LogicalRouterDownLinkPort+
LogicalRouterLinkPortOnTIER0+
LogicalRouterLinkPortOnTIER1+
LogicalRouterLoopbackPort+
LogicalRouterUpLinkPort+

Example Request:

PUT https://<nsx-mgr>/api/v1/logical-router-ports/258c50b4-c960-4005-9023-f7946e302162 { "resource_type": "LogicalRouterDownLinkPort", "id": "81096324-23ba-408e-ae24-294a7ba07f60", "display_name": "web-tier router", "logical_router_id": "723c1e3e-c82c-4243-bba0-2e1ef4815143", "mac_address": "02:50:56:56:44:52", "service_bindings": [ { "service_id": { "target_display_name": "DHCP Relay", "is_valid": true, "target_type": "LogicalService", "target_id": "fb5334a1-3c82-4d2b-8adf-65e52e09d2a1" } } ], "linked_logical_switch_port_id": { "target_display_name": "4630aadd-25d7-4c73-b03c-227ac314dfc4", "is_valid": true, "target_type": "LogicalPort", "target_id": "4630aadd-25d7-4c73-b03c-227ac314dfc4" }, "subnets": [ { "ip_addresses": [ "3001::1" ], "prefix_length": 64 } ], "ndra_prefix_config": [ { "network_prefix": { "3001::/64" }, "prefix_preferred_time": 2000, "prefix_valid_time": 5000 } ], "_revision": 2 }

Successful Response:

Response Code:
200 OK
Response Headers:
Content-type: application/json
Response Body:
LogicalRouterCentralizedServicePort+
LogicalRouterDownLinkPort+
LogicalRouterLinkPortOnTIER0+
LogicalRouterLinkPortOnTIER1+
LogicalRouterLoopbackPort+
LogicalRouterUpLinkPort+

Example Response:

{ "resource_type": "LogicalRouterUpLinkPort", "_revision": 3, "id": "258c50b4-c960-4005-9023-f7946e302162", "resource_type": "LogicalRouterDownLinkPort", "id": "81096324-23ba-408e-ae24-294a7ba07f60", "display_name": "web-tier router", "logical_router_id": "723c1e3e-c82c-4243-bba0-2e1ef4815143", "mac_address": "02:50:56:56:44:52", "service_bindings": [ { "service_id": { "target_display_name": "DHCP Relay", "is_valid": true, "target_type": "LogicalService", "target_id": "fb5334a1-3c82-4d2b-8adf-65e52e09d2a1" } } ], "linked_logical_switch_port_id": { "target_display_name": "4630aadd-25d7-4c73-b03c-227ac314dfc4", "is_valid": true, "target_type": "LogicalPort", "target_id": "4630aadd-25d7-4c73-b03c-227ac314dfc4" }, "subnets": [ { "ip_addresses": [ "3001::1", "3001::3bff:fe57:7d29" ], "prefix_length": 64 } ], "ndra_prefixtime_config": [ { "network_prefix": { "3001::/64" }, "prefix_preferred_time": 2000, "prefix_valid_time": 5000 } ], "_last_modified_time": 1458851284244, "_create_time": 1457984402461, "_last_modified_user": "admin", "_system_owned": false, "_create_user": "admin", "_revision": 3 }

Required Permissions:

crud

Feature:

routing_routers

Additional Errors: