Skip to content

Retrieve the virtual network routing table

Request

Returns routes for one or all virtual networks, with optional filtering by network name, network ID, destination IP, or destination node name.


Requires nodes::service:vpn-routes or nodes::remote-execute permission.

Security
JWTAuthorizer
Path
nodeIDstringrequired

Node ID

Query
waitinteger

Pass 1 to block until the node responds and return its output.

Value:1
Bodyapplication/json
networkIdstring

Filter by virtual network ID (takes precedence over network)

networkstring

Virtual network name filter. Use any to return all networks.

Example:"virtual-network"
domainstring

Domain filter when combined with network

ipstring

Filter routes that cover this IP address

Example:"10.0.0.5"
deststring

Filter by destination node name. Use any to return all.

curl -i -X POST \
  'https://apidocs.trustgrid.io/_mock/node/{nodeID}/trigger/vpn-routes?wait=1' \
  -H 'Authorization: Bearer <YOUR_JWT_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "networkId": "string",
    "network": "virtual-network",
    "domain": "string",
    "ip": "10.0.0.5",
    "dest": "string"
  }'

Responses

OK

Bodyapplication/json
outputobject
Response
{ "output": { "networks": [] } }