WORKPLANETunnel Gateway
Sign inGet started

Documentation

Install, enroll and expose your first application.

These commands run against this deployment. The connector keeps an outbound connection to the gateway; the gateway never dials your machine.

Prerequisites

  • Node.js 22+ for the connector and CLI.
  • A local service listening on a TCP port (for example localhost:3000).
  • The pinned FRP client binary (v0.61.1) available to the connector, or let the connector resolve it.

1. Sign in and pick an account

# Session cookie is stored in ~/.workplane/session.json (mode 0600)
   npm run cli -- login you@example.com
   npm run cli -- accounts
   npm run cli -- use <accountId>

2. Enroll a connector

Create a short-lived enrollment token in the UI (Connector enrollment) or with the CLI, then run the connector on the target machine.

npm run cli -- enroll --name "studio-mac"
   npm run cli -- connect --token <enrolmentToken> --name "studio-mac"

3. Expose a local port

npm run cli -- expose --connector <connectorId> --name "design-review" \
     --port 3000 --ttl 3600 --access private

The gateway returns a hostname such as https://quiet-harbor.tunnel.example.com. Open it in a browser; the edge authorizes the request before proxying to your connector.

4. Manage the lease

npm run cli -- list
   npm run cli -- inspect <tunnelId>
   npm run cli -- extend <tunnelId> --ttl 7200
   npm run cli -- close <tunnelId>

Closing a tunnel revokes its hostname, removes the proxy at the edge and drops live streams. Closing is idempotent.

REST API and MCP

The API is versioned under /api/v1. Session cookies authenticate the UI; scoped API credentials authenticate automation. MCP tools mirror the tunnel lifecycle (tunnel_create, tunnel_list, tunnel_get,tunnel_extend, tunnel_close) and take identity from the trusted session, never from tool arguments.

Security model: TLS terminates at Traefik, authorization is a forward-auth call to the gateway, and the FRP server only accepts connections from enrolled connectors. Direct access to the FRP listener is not a supported path.