NSX-T Data Center REST API

Networking (Switching)

Associated URIs:

API Description API Path

List infra segment ports


List all the ports for an infra.
GET /policy/api/v1/infra/segments/{segment-id}/ports
GET /policy/api/v1/global-infra/segments/{segment-id}/ports
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports

Delete an infra segment port


Delete an infra segment port by giving ID. Please note that this operation will not delete
the segment port from vCenter Server if the port was connected to a Virtual Machine.
Please connect Virtual Machine to another network for the segment port to be deleted
from vCenter Server. Do not provide any parameters to this call unless it is during
VIF restore workflow by NSX container plugin(NCP).
DELETE /policy/api/v1/infra/segments/{segment-id}/ports/{port-id}
DELETE /policy/api/v1/global-infra/segments/{segment-id}/ports/{port-id}
DELETE /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports/{port-id}

Get infra segment port by ID


Get detail information on an infra segment port by giving ID.
GET /policy/api/v1/infra/segments/{segment-id}/ports/{port-id}
GET /policy/api/v1/global-infra/segments/{segment-id}/ports/{port-id}
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports/{port-id}

Patch an infra segment port


Create an infra segment port if it does not exist based on the IDs, or update existing port
information by replacing the port object fields which presents in the request body.
PATCH /policy/api/v1/infra/segments/{segment-id}/ports/{port-id}
PATCH /policy/api/v1/global-infra/segments/{segment-id}/ports/{port-id}
PATCH /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports/{port-id}

Create or update an infra segment port


Create an infra segment port if it does not exist based on the IDs, or update existing port
information by replacing the port object already exists.
PUT /policy/api/v1/infra/segments/{segment-id}/ports/{port-id}
PUT /policy/api/v1/global-infra/segments/{segment-id}/ports/{port-id}
PUT /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports/{port-id}

List all effective profiles for infra segment port


List all effective profiles for this segment port on given enforcement point.
GET /policy/api/v1/infra/segments/{segment-id}/ports/{port-id}/effective-profiles
GET /policy/api/v1/global-infra/segments/{segment-id}/ports/{port-id}/effective-profiles
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segment-id}/ports/{port-id}/effective-profiles

Get infra segment port statistics information


Get infra segment port statistics information.
GET /policy/api/v1/infra/segments/{segments-id}/ports/{port-id}/statistics
GET /policy/api/v1/global-infra/segments/{segments-id}/ports/{port-id}/statistics
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segments-id}/ports/{port-id}/statistics

Get infra segment port status information


Get infra segment port status information.
GET /policy/api/v1/infra/segments/{segments-id}/ports/{port-id}/status
GET /policy/api/v1/global-infra/segments/{segments-id}/ports/{port-id}/status
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/segments/{segments-id}/ports/{port-id}/status

List Tier-1 segment ports


List all the ports for a Tier-1 segment.
GET /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports
GET /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports

Delete a Tier-1 segment port. Please note that this operation will not delete the segment port from vCenter Server if the port was connected to a Virtual Machine. Please connect Virtual Machine to another network for the segment port to be deleted from vCenter Server.


Delete a Tier-1 segment port by giving ID.
DELETE /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
DELETE /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
DELETE /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}

Get Tier-1 segment port by ID


Get detail information on a Tier-1 segment port by giving ID.
GET /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
GET /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}

Patch a Tier-1 segment port


Create a Tier-1 segment port if it does not exist based on the IDs, or update existing port
information by replacing the port object fields which presents in the request body.
PATCH /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
PATCH /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
PATCH /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}

Create or update a Tier-1 segment port


Create a Tier-1 segment port if it does not exist based on the IDs, or update existing port
information by replacing the port object already exists.
PUT /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
PUT /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}
PUT /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}

List all effective profiles for tier-1 segment port


List all effective profiles for this segment port on given enforcement point.
GET /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}/effective-profiles
GET /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}/effective-profiles
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segment-id}/ports/{port-id}/effective-profiles

Get tier-1 segment port statistics information


Get tier-1 segment port statistics information.
GET /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/statistics
GET /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/statistics
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/statistics

Get segment port status information


Get tier1 segment port status information.
GET /policy/api/v1/infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/status
GET /policy/api/v1/global-infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/status
GET /policy/api/v1/orgs/{org-id}/projects/{project-id}/infra/tier-1s/{tier-1-id}/segments/{segments-id}/ports/{port-id}/status