NSX-T Data Center REST API

List NAT rules of the logical router (Deprecated)

Returns paginated list of all user defined NAT rules of the specific
logical router. If a rule_type is provided, only the given type of
rules will be returned. If no rule_type is specified, the rule_type
will be defaulted to NATv4, i.e. only the NATv4 rules will be listed.
Deprecated: This API has been deprecated, please use below Policy APIs
GET /policy/api/v1/infra/tier-0s/<tier-0-id>/nat/<nat-id>/nat-rules
GET /policy/api/v1/global-infra/tier-0s/<tier-0-id>/nat/<nat-id>/nat-rules
GET /policy/api/v1/infra/tier-1s/<tier-1-id>/nat/<nat-id>/nat-rules
GET /policy/api/v1/global-infra/tier-1s/<tier-1-id>/nat/<nat-id>/nat-rules
GET /policy/api/v1/orgs/<org-id>/projects/<project-id>/infra/tier-1s/<tier-1-id>/nat/<nat-id>/nat-rules

Request:

Method:
GET
URI Path(s):
/api/v1/logical-routers/{logical-router-id}/nat/rules
Request Headers:
n/a
Query Parameters:
NatRuleTypeParameter+
Request Body:
n/a

Successful Response:

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

Example Response:

{ "cursor": "003601003000-0000-0404-0000-0000000000181024", "sort_by": "rule_priority", "result_count": 1, "results": [ { "resource_type": "NatRule", "id": "1028", "display_name": "01003000-0000-0404-0000-000000000018", "match_source_network": "80.80.80.1", "action": "SNAT", "logging": false, "translated_ports": "", "match_service": { "resource_type": "L4PortSetNSService", "destination_ports": [ "80", "8080" ], "l4_protocol": "TCP", "source_ports": [] }, "rule_priority": 1024, "translated_network": "172.16.10.10", "enabled": true, "nat_pass": true, "_last_modified_time": 1458852632857, "_create_time": 1458852302781, "_last_modified_user": "admin", "_system_owned": false, "_create_user": "admin", "_revision": 3 } ] }

Required Permissions:

read

Feature:

routing_nat

Additional Errors: