Documentation Index
Fetch the complete documentation index at: https://docs.openclaw.ai/llms.txt
Use this file to discover all available pages before exploring further.
openclaw qr
Generate a mobile pairing QR and setup code from your current Gateway configuration.
Usage
Options
--remote: prefergateway.remote.url; if it is unset,gateway.tailscale.mode=serve|funnelcan still provide the remote public URL--url <url>: override gateway URL used in payload--public-url <url>: override public URL used in payload--token <token>: override which gateway token the bootstrap flow authenticates against--password <password>: override which gateway password the bootstrap flow authenticates against--setup-code-only: print only setup code--no-ascii: skip ASCII QR rendering--json: emit JSON (setupCode,gatewayUrl,auth,urlSource)
Notes
--tokenand--passwordare mutually exclusive.- The setup code itself now carries an opaque short-lived
bootstrapToken, not the shared gateway token/password. - Built-in setup-code bootstrap is node-only. After approval, the primary node token lands with
scopes: []. - The built-in setup-code flow does not return a handed-off operator token; operator access requires a separate approved operator pairing or token flow.
- Mobile pairing fails closed for Tailscale/public
ws://gateway URLs. Private LAN addresses and.localBonjour hosts remain supported overws://, but Tailscale/public mobile routes should use Tailscale Serve/Funnel or awss://gateway URL. - With
--remote, OpenClaw requires eithergateway.remote.urlorgateway.tailscale.mode=serve|funnel. - With
--remote, if effectively active remote credentials are configured as SecretRefs and you do not pass--tokenor--password, the command resolves them from the active gateway snapshot. If gateway is unavailable, the command fails fast. - Without
--remote, local gateway auth SecretRefs are resolved when no CLI auth override is passed:gateway.auth.tokenresolves when token auth can win (explicitgateway.auth.mode="token"or inferred mode where no password source wins).gateway.auth.passwordresolves when password auth can win (explicitgateway.auth.mode="password"or inferred mode with no winning token from auth/env).
- If both
gateway.auth.tokenandgateway.auth.passwordare configured (including SecretRefs) andgateway.auth.modeis unset, setup-code resolution fails until mode is set explicitly. - Gateway version skew note: this command path requires a gateway that supports
secrets.resolve; older gateways return an unknown-method error. - After scanning, approve device pairing with:
openclaw devices listopenclaw devices approve <requestId>