list_tier1_gateways
Retrieve all Tier-1 gateways with their linked Tier-0 paths and route advertisement details to manage NSX network routing configurations.
Instructions
List all Tier-1 gateways with linked Tier-0 path and route advertisement.
Args: target: Optional NSX Manager target name from config. Uses default if omitted.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| target | No |
Output Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |
Implementation Reference
- vmware_nsx/ops/inventory.py:122-135 (handler)The actual implementation of the Tier-1 gateway list retrieval logic, fetching data from the NSX policy API.
def list_tier1_gateways(client: NsxClient) -> list[dict]: """List all Tier-1 gateways.""" items = client.get_all("/policy/api/v1/infra/tier-1s") return [ { "id": _sanitize(t.get("id", "")), "display_name": _sanitize(t.get("display_name", "")), "tier0_path": _sanitize(t.get("tier0_path", "")), "failover_mode": t.get("failover_mode", ""), "route_advertisement_types": t.get("route_advertisement_types", []), "type": t.get("type", ""), } for t in items ] - mcp_server/server.py:143-152 (registration)MCP tool registration and handler wrapper for list_tier1_gateways.
def list_tier1_gateways(target: str | None = None) -> list[dict]: """List all Tier-1 gateways with linked Tier-0 path and route advertisement. Args: target: Optional NSX Manager target name from config. Uses default if omitted. """ from vmware_nsx.ops.inventory import list_tier1_gateways as _list_tier1s client = _get_connection(target) return _list_tier1s(client)