Skip to content

ProxyOptions

View as Markdown

Defined in: proxy.ts:21

Property Type Description Defined in
allowedHosts? string[] Hostnames the proxy answers to, matched against the request’s Host header (port stripped; X-Forwarded-Host is ignored). A non-empty list REPLACES the default (add the loopback names yourself if you still need them). Entries are bare hostnames with no scheme or port; IPv6 literals are bracketed ([::1]). Entries are trimmed and lowercased, and empty ones dropped. Defaults to env UNCAGE_ALLOWED_HOSTS (comma-separated, same rules), else loopback only: localhost, 127.0.0.1, [::1] (any port). proxy.ts:36
basePath? string The route prefix the handler is mounted under. Defaults to /api/uncage. proxy.ts:27
endpoint? string Defaults to env UNCAGE_URL, else http://127.0.0.1:4783. proxy.ts:23
token? string Defaults to env UNCAGE_TOKEN, else the contents of ~/.uncage/token (read lazily). proxy.ts:25