Interface: ConfigureAuthProxyRuntimeOptions
Runtime options for configureAuthProxyRuntime (upstream proxy mode).
Fields:
localBasePath: Path where Robo exposes auth endpoints locally.targetBasePath?: Path on the upstream server (defaults tolocalBasePath).baseUrl: Upstream Robo/Auth.js URL (must include protocol + domain).cookieName?: Session cookie name (defaults toauthjs.session-token).secret?: Optional JWT secret for local decoding (reduces upstream calls; without it every getToken call hits upstream).sessionStrategy:'jwt' | 'database'matching the upstream server.headers?: Extra headers forwarded to upstream (e.g.,X-API-Key).fetch?: Custom fetch implementation (testing, retries, special agents).
⚠️ Security:
baseUrlshould use HTTPS to protect session cookies in transit.- Additional headers may carry secrets; ensure the upstream server validates them.
- Provide
secretwhen possible so JWT decoding happens locally instead of forwarding tokens.
Performance:
- Supplying
secretenables local JWT decoding, cutting proxy traffic roughly in half. - Custom
fetchcan implement retries, keep-alive, or caching.
Edge cases:
targetBasePathdefaults tolocalBasePath. Set explicitly if they differ.cookieNamemust match upstream; mismatches prevent session lookups.sessionStrategymismatch leads togetToken/getServerSessionfailures.
See
configureAuthProxyRuntime