List routers

Returns the Zero Trust routers the caller's org owns.

GET /v1/network/routers

Addresshttps://api.hanzo.ai/v1/network/routers
MethodGET
Operationget_network_routers
AuthAuthorization: Bearer $HANZO_API_KEY

Returns the Zero Trust routers the caller's org owns.

One row per real ZT edge-router tagged with the org's "org-<org>" role attribute, carrying the controller's own health signal: "online" when connected, "disabled" when administratively disabled, "offline" otherwise. region is filled only from a "region-<slug>" role attribute and omitted when the router carries none, so the column renders "—" rather than a guess.

The read degrades rather than erroring: a deployment with no ZT credential, and a controller that cannot be reached, both answer 200 with an empty list.

Request

GET /v1/network/routers takes no parameters and no body — the credential is the whole request.

Response

StatusBodyMeaning
200network.routerListok
defaultproblem-detailsrefused

200 body — 5 fields.

FieldInTypeAlwaysDescription
routersbodynetwork.routerView[]—Routers is one row per ZT edge-router tagged with the caller's org role.
routers[].idbodystring—ID is the ZT edge-router's id.
routers[].namebodystring—Name is the edge-router's name, falling back to its id when it has none.
routers[].regionbodystring—Region comes from a "region-<slug>" role attribute and is omitted when the router carries none, so the column renders "—" rather than a guess.
routers[].statusbodystring—Status is the controller's own health signal: "online" when connected, "disabled" when administratively disabled, "offline" otherwise.

Failure carries the platform error shape — see Errors.

Examples

hanzo network routers
import { Configuration, NetworkApi } from 'hanzoai';

const api = new NetworkApi(new Configuration({ accessToken: process.env.HANZO_API_KEY }));
const { data } = await api.getNetworkRouters();
from hanzoai.cloud import ApiClient, Configuration
from hanzoai.cloud.api import NetworkApi

client = ApiClient(Configuration(access_token=os.environ["HANZO_API_KEY"]))
result = NetworkApi(client).get_network_routers()
cfg := hanzoai.NewConfiguration()
cfg.AddDefaultHeader("Authorization", "Bearer "+os.Getenv("HANZO_API_KEY"))
client := hanzoai.NewAPIClient(cfg)

resp, _, err := client.NetworkAPI.GetNetworkRouters(context.Background()).Execute()
if err != nil {
	return err
}
use hanzo_client::apis::{configuration::Configuration, network_api};

let mut cfg = Configuration::new();
cfg.bearer_access_token = std::env::var("HANZO_API_KEY").ok();

let result = network_api::get_network_routers(&cfg, Default::default()).await?;
import ai.hanzo.cloud.ApiClient;
import ai.hanzo.cloud.api.NetworkApi;

ApiClient client = new ApiClient();
client.setBearerToken(System.getenv("HANZO_API_KEY"));

var result = new NetworkApi(client).getNetworkRouters();
curl https://api.hanzo.ai/v1/network/routers \
  -H "Authorization: Bearer $HANZO_API_KEY"

MCP reaches network through the network tool, which names its 7 operations with its own verbs — this one among them, under a name only MCP declares. describe explains any of them:

curl -X POST https://api.hanzo.ai/v1/mcp \
  -H "Content-Type: application/json" \
  -d '{
       "jsonrpc": "2.0",
       "id": 1,
       "method": "tools/call",
       "params": {
         "name": "describe",
         "arguments": {
           "op": "list_networks"
         }
       }
     }'

Network API · All Hanzo APIs · Interactive reference

Was this page useful?