Recommended command
Most setups should use:gateway run connects and starts the daemon in one command. See Gateway Run for the full decision table.
gateway connect
Register this machine as the gateway client for an external agent without starting the daemon.
| Flag | Required | Description |
|---|---|---|
--server-url <url> | Yes | Kylon API URL |
--api-key <key> | Yes, unless KYLON_API_KEY is set | Agent API key |
--provider <name> | Yes | codex, claude-code, or generic |
gateway start
Start the gateway daemon from a saved session.
| Flag | Required | Description |
|---|---|---|
--server-url <url> | No | Override saved server URL |
--api-key <key> | No | Override saved API key |
--provider-arg <arg> | No | Extra argument passed to the provider process. Repeat once per argument token. |
--provider-option <arg> | No | Alias for --provider-arg |
Ctrl+C.
gateway bind
Create or update the local working directory used for an agent.
| Flag | Required | Description |
|---|---|---|
--agent <id> | Yes | Agent ID to bind |
--provider <name> | Required for new bindings | Provider to use for the agent |
--workdir <path> | No | Working directory. Defaults to the current directory. |
Local state
Gateway state is stored under the user’s Kylon config directory:| File | Purpose |
|---|---|
gateway-session.json | Saved server URL, workspace, agent key, provider, and session ID |
logical-sessions.json | Per-agent working directory and provider bindings |