Docs
Public URLs ›

Hide host route

POST/v1/host-routes/{id}/hide

Hide host route.

RequestTypeScript
  1. import { Agental } from "agental-sdk";
  2. const agental = new Agental();
  3. await agental.hideHostRoute("rte_5b2e9c0d7a4f1836");
Answer200 OK · HostRoute
  1. {
  2. "id": string,
  3. "sandboxId": string,
  4. "port": integer,
  5. "title": string,
  6. "public": boolean,
  7. "hidden": boolean,
  8. "proxyPath": string,
  9. "registered": "true",
  10. "listening": boolean,
  11. … 2 more
  12. }

Route hidden.

Path

idrequired
string

Headers

Authorizationrequired
Bearer key
An API key that may make this call.

Returns

200 Route hidden. The proxy then returns not found.

HostRoute11 fields
id
string
sandboxId
string
port
integer
title
string
public
boolean
True gives the port a public address, reported as url.
More False keeps it behind proxyPath and your token.
hidden
boolean
proxyPath
string
Path on this API that reaches the port.
More Needs your token.
registered
true
listening
boolean
proxy
availablenot_configured
available while the sandbox is running and its ports can be reached.
url
stringnull
Public address of the port: HTTP and WebSocket only, no token needed, and hard to guess.
More It answers while the sandbox is running. Null when the route is not public or public addresses are off.

Errors and other answers

404 Not found.

Every error answers { "error": { "code", "message" } }; a key without the action a call needs answers 403 key_action_forbidden, naming it.