Configuration
The CLI resolves each setting in this order, highest wins:
- CLI flags, for example
--workspace,--api-key,--output,--timeout. - Environment variables, the
POLYLANE_*set plus the standardNO_COLORandDO_NOT_TRACK. - The config file at
~/.polylane/config.json. - Built-in defaults: domain
api.polylane.com, timeout 300 seconds, outputtextin a terminal andjsonwhen piped.
Config file
~/.polylane/config.json is written with file mode 0600 and accepts six keys: domain, workspace_id, api_key, output, timeout, and telemetry. Manage it through the CLI:
polylane config show
polylane config set --key output --value json
polylane config set --key workspace_id --value ws_0f3a9c2e5b7d4816a2c9e0f4b6d8a1c3
config show prints the resolved configuration, the auth method in use, and the config file path. API keys are masked in the output.
Workspace IDs must match ws_ followed by 32 lowercase letters and digits. To set the default workspace by slug instead of ID, use workspace use:
polylane workspace use acme-inc
OAuth credentials live separately in ~/.polylane/credentials.json, also mode 0600, and refresh automatically when the access token nears expiry. See Authentication.
Environment variables
POLYLANE_API_KEY: authenticate without storing a key on disk.POLYLANE_WORKSPACE_ID: set the workspace for the current shell.POLYLANE_API_DOMAIN: point at a different API hostname. Hostname only, no protocol.POLYLANE_OUTPUT: forcetextorjsonoutput.POLYLANE_TIMEOUT: request timeout in seconds.POLYLANE_VERBOSE: enable verbose logging.POLYLANE_TELEMETRY=0: disable telemetry for this environment.DO_NOT_TRACK=1: the universal telemetry opt-out. Overrides every other telemetry setting, including the config file.NO_COLOR: disable ANSI colors.
Telemetry
Anonymous usage telemetry is on by default. It records the command name, flag names but never their values, the count of positional arguments but never their values, exit code and error category, durations, CLI and Node versions, operating system details, an anonymous per-install identifier, and the workspace ID. It never records credentials, user IDs, emails, file paths, command output, or full error messages.
polylane telemetry status # exactly what gets sent, and where
polylane telemetry disable # persistent opt-out, written to the config file
polylane telemetry enable
Precedence for the telemetry decision: DO_NOT_TRACK, then POLYLANE_TELEMETRY, then the config file, then the default of on. There is no per-invocation flag; telemetry is a per-install choice.
Files on disk
Everything the CLI stores lives under ~/.polylane (directory mode 0700):
| File | Contents |
|---|---|
config.json | Saved settings: domain, workspace, API key, output, timeout, telemetry |
credentials.json | OAuth tokens |
telemetry.json | Anonymous install ID and run counters |
update-state.json | Update check state |
Delete the directory to reset the CLI completely. A fresh install ID is generated on the next run.
Scripting
Drive the Polylane CLI from shell scripts, CI jobs, and coding agents with JSON output, stable exit codes, and non-interactive mode.
Browser extension
Chat with a Polylane agent from any browser tab. The extension reads the page you are on, attaches it as context, and can act on supported provider dashboards.