Configuration
Every option for the .NET and Node add-ons, the React provider, the browser packages, and the command line, and every environment variable, with its default.
On this page 7 sections
ASP.NET Core
Pass options to builder.Services.AddWizeLens(o => { ... }).
| Option | Default | Description |
|---|---|---|
Enabled |
WIZELENS_, else Development only |
Turn WizeLens on or off. |
Dashboard |
WIZELENS_, else Development only |
Serve the dashboard, read API, and MCP.false is send-only. |
Hud |
WIZELENS_, else true |
While the dashboard is served, put the HUD on the app's HTML pages, with its script at {BasePath}/. |
BasePath |
/ |
Where the dashboard and API live. |
Service |
OTEL_, else the app name |
Name shown for this service. |
Storage |
Sqlite, or Memory when send-only |
Sqlite (survives restarts) or Memory. |
StoragePath |
. |
SQLite file, relative to the content root. |
MaxTraces |
2000 |
Traces kept in memory and on disk. |
MaxAge |
24h |
Traces older than this are dropped. |
Mcp |
false |
Expose the read-only MCP endpoint at {BasePath}/. |
RedactKeys |
see Redaction | Key fragments whose values are redacted.WIZELENS_ adds more. |
NPlusOneThreshold |
5 |
Repeats in one trace that count as N+1. |
SlowQueryMs |
100 |
Queries at or above this are slow. |
CaptureResponseBody |
false |
Keep the first 16 KB of text and JSON responses. |
TraceStaticFiles |
WIZELENS_, else false |
Trace files served as they are (images, fonts, scripts) that succeed. |
ReportPackages |
true, or false when WIZELENS_ |
With a hub or the cloud set, send the app's NuGet package names and versions once at start, for the known-vulnerability check on the Security page. |
Endpoint /Token |
WIZELENS_ /WIZELENS_ |
Also send everything to a hub or the cloud. |
TrustedRemotes |
WIZELENS_ (comma-separated) |
APIs on another origin that the browser calls, like https:/: their part of a call joins its trace here. |
Project |
WIZELENS_ |
Groups this service with others on a shared hub. |
Release |
WIZELENS_, else OTEL_, else the entry assembly's informational version |
The app's version, kept on every span (service.) for release markers, version compares, and Problems. |
Sampling. |
WIZELENS_, else 1 |
Share of traces kept (0 to 1). |
Sampling. |
WIZELENS_, else true |
Keep every trace with an error. |
Sampling. |
WIZELENS_, else 1000 |
Keep every trace with a server-side span this long (null turns it off). |
Logs. |
WIZELENS_, else true |
Keep log lines written outside a request (startup, jobs, timers). |
Logs. |
WIZELENS_, else Information |
Lowest level kept for lines outside a request. |
Logs. |
WIZELENS_, else 1 |
Share of lines outside a request below Warning that are kept (0 to 1). |
CaptureMetrics |
true |
Read every Meter in the app. |
MetricsInterval /MetricsMaxAge |
10 s / |
How often metrics are taken, and how long they are kept in memory. |
Tags. /Tags. |
none / |
Tag rules for the dashboard, such as new("checkout", "route:/, and built-in tags to turn off. |
app.UseWizeLens() adds the middleware and maps the dashboard. An app that is not a WebApplication also calls
endpoints.MapWizeLens() inside UseEndpoints.
Node
Pass options to createWizeLens({ ... }), or to registerWizeLens({ ... }) on Next.js.
| Option | Default | Description |
|---|---|---|
service |
(required) | Name shown for this service. |
enabled |
WIZELENS_, else on unless NODE_ |
Turn WizeLens on or off. |
dashboard |
WIZELENS_, else on unless NODE_ |
Serve the dashboard, read API, and MCP.false is send-only. |
hud |
WIZELENS_, else true |
While the dashboard is served, put the HUD on the app's HTML pages, with its script at {basePath}/.WizeLensProvider. |
basePath |
/ |
Where the dashboard and API live. |
storage |
"sqlite", or "memory" when send-only |
"sqlite" or "memory". |
storagePath |
{cwd}/ |
SQLite file. |
maxTraces /maxAgeMs |
2000 / |
How much is kept. |
mcp |
false |
Expose the read-only MCP endpoint. |
redactKeys |
see Redaction | Key fragments whose values are redacted.WIZELENS_ adds more. |
tags |
none | { rules: [{ name, query, color? }], disableBuiltIns: ["bot"] }: tag rules for the dashboard, and built-in tags to turn off. |
instrumentFetch |
true |
Trace outgoing fetch and undici calls. |
instrumentHttp |
true |
Trace outgoing node:http and node:https calls (axios, got, node-fetch v2, AWS SDK). |
captureConsole |
true |
Copy console. lines into the trace, or outside a request as loose lines. |
traceQueriesOutsideRequests |
false |
Database adapters also trace queries outside a request. |
publicEndpoint |
auto | Override X-WizeLens-Endpoint, for example behind a proxy. |
audit |
console. |
Where MCP audit lines go. |
slowQueryMs /nPlusOneThreshold |
100 /5 |
Insight thresholds. |
captureResponseBody |
false |
Keep the first 16 KB of text and JSON responses. |
traceStaticFiles |
WIZELENS_, else false |
Trace files served as they are (images, fonts, scripts) that succeed. |
reportPackages |
true |
With a hub or the cloud set, send the installed package names and versions once at start, for the known-vulnerability check on the Security page.WIZELENS_ also turns it off. |
logToConsole |
false |
Lines you write with wizelens. also go to the console. |
uiDir |
the dashboard build in the package | Serve the dashboard from another folder. |
endpoint /token |
WIZELENS_ /WIZELENS_ |
Also send everything to a hub or the cloud. |
trustedRemotes |
WIZELENS_ (comma-separated) |
APIs on another origin that the browser calls, like https:/: their part of a call joins its trace here. |
project |
WIZELENS_ |
Groups this service with others on a shared hub. |
release |
WIZELENS_, else OTEL_, else npm_ |
The app's version, kept on every span (service.) for release markers, version compares, and Problems. |
sampling |
{ rate: WIZELENS_ |
See Sampling. |
sourceMaps |
dev servers on localhost |
{ dirs, origins, fetch }: where browser stacks find their maps; false turns it off. |
logs |
{ outside: true, minLevel: "info", rate: 1 }, or the WIZELENS_ variables |
Log lines written outside a request. |
captureMetrics |
true |
Sample the runtime every metricsIntervalMs. |
metricsIntervalMs /metricsMaxAgeMs |
10 s / |
How often metrics are taken, and how long they are kept in memory. |
ignore(path) |
nextIgnore |
Next.nextIgnore(path) in it too. |
React
Props on WizeLensProvider.
| Prop | Default | Description |
|---|---|---|
endpoint |
/ |
WizeLens base path or URL on your API. |
enabled |
true |
Pass import. (or similar). |
hud |
"auto" |
The in-page HUD."auto" shows it when {endpoint}/ answers.true shows it; false hides it and also stops reading traces back, for a send-only server. |
propagateTo |
same origin | Which requests get a traceparent header. |
release |
from the build plugin | The web app's version, kept on browser spans for release markers and version compares, and so stacks find the right source maps. |
slowMs |
500 |
Requests at or over this many ms show as "warning". |
capturePages |
true |
Send page views, React render stats, and browser errors. |
captureConsole |
true |
Copy browser console calls into the page view's trace (at most 500 per page). |
resolveFrames |
true |
Read the page's own source maps (dev servers serve them) so errors group by your source. |
user |
none | The signed-in user, sent as enduser. on every browser span. |
userName |
none | The signed-in user's display name, sent as user. for the Users page. |
<WizeLensUser id name /> sets the user from anywhere under the root. See React.
Browser
Options for initWizeLens({ ... }) from @wizeworks/lens-browser, @wizeworks/lens-angular, and
@wizeworks/lens-svelte, and for app.use(WizeLensPlugin, { ... }) from @wizeworks/lens-vue.
| Option | Default | Description |
|---|---|---|
endpoint |
/ |
WizeLens base path or URL on your API. |
enabled |
true |
Pass import. (or similar). |
propagateTo |
same origin | Which requests get a traceparent header. |
release |
from the build plugin | The web app's version (service.), for release markers and source maps. |
user /userName |
none | The signed-in user (enduser.) and display name (user.).lens.. |
capturePages |
true |
Send page views, Web Vitals, and browser errors. |
captureConsole |
true |
Copy browser console calls into the page view's trace (at most 500 per page). |
captureXhr |
true |
Trace XMLHttpRequest calls too (Angular's HttpClient, axios). |
resolveFrames |
true |
Read the page's own source maps so errors group by your source. |
flushIntervalMs |
1000 |
How often browser spans are sent, in ms. |
hud |
"auto" |
The in-page HUD."auto" asks {endpoint}/ once and shows it when the server's read API answers.true shows it; false hides it and reads nothing back. |
slowMs |
500 |
The HUD shows requests at or over this many ms as "warning". |
readServer |
follows hud |
Read traces back from the server after each call. |
serverStatsDelayMs |
400 |
With readServer, how long to wait after a response before reading its server stats. |
maxRecent |
30 |
How many recent requests lens. keeps. |
framework |
none | Render stats and timings from a UI framework. |
router |
none | Vue only: a vue-router instance. |
lens |
none | Vue only: use this running instance instead of starting one. |
The script tag takes data-endpoint, data-release, data-enabled="false", data-console="false",
data-xhr="false", data-hud (auto, true, or false; default auto), and data-slow-ms. Svelte's
trackNavigation takes mode ("history" or "hash") and lens. See
Vue, Angular, Svelte, and plain JS.
Command line
@wizeworks/lens-cli and its Vite, webpack, and Next.js plugins upload browser source maps.
| Flag | Plugin option | Variable | Default |
|---|---|---|---|
--endpoint |
endpoint |
WIZELENS_ |
http:/ |
--token |
token |
WIZELENS_ |
none |
--release |
release |
WIZELENS_, then npm_ |
the package. version |
--project |
project |
WIZELENS_ |
none (hub only; the cloud takes it from the key) |
--url-prefix |
urlPrefix |
none | |
--delete |
deleteAfterUpload |
off | |
upload |
true; false skips the upload |
||
failOnError |
false; true fails the build when the upload fails |
See Source maps.
Environment variables
| Variable | Used by | Means |
|---|---|---|
WIZELENS_ |
. |
Turn WizeLens on (true) or off (false). |
WIZELENS_ |
. |
Serve the dashboard, read API, and MCP (true), or send only (false). |
WIZELENS_ |
. |
Put the HUD on the app's HTML pages while the dashboard is served (true), or not (false).true. |
WIZELENS_ |
. |
Send to this hub or cloud. |
WIZELENS_ |
. |
The hub token, or a cloud ingest key. |
WIZELENS_ |
. |
Project name on a shared hub. |
WIZELENS_ |
. |
The app's version (service. on every span), and the release the command line stores maps under. |
NODE_, ASPNETCORE_, deployment. |
Node, . |
The environment the service reports, which the dashboard's environment picker lists.NODE_ (default development); .deployment. resource attribute (OTEL_). |
OTEL_ |
. |
The app's version when WIZELENS_ is not set. |
OTEL_ |
. |
The service name. |
WIZELENS_ |
. |
false stops the package report for the known-vulnerability check.true. |
WIZELENS_ |
. |
Keep log lines outside a request (true/false). |
WIZELENS_ |
. |
Lowest level kept outside a request: trace, debug, info, warn, error, critical. |
WIZELENS_ |
. |
Share of lines outside a request below warn that are kept, 0 to 1. |
WIZELENS_ |
. |
Sampling rate, 0 to 1. |
WIZELENS_, WIZELENS_ |
. |
What sampling always keeps. |
WIZELENS_, WIZELENS_ |
Java, Python, Go | Request and response bodies; SQL parameters. |
WIZELENS_ |
Go | Request and response headers.true. |
WIZELENS_ |
Python | logging lines.true. |
WIZELENS_ |
. |
More key fragments to redact. |
WIZELENS_ |
Node auto install | Hooks to leave off, comma-separated. |
An on/off variable takes true or false, 1 or 0, on or off, or yes or no. Anything else logs a warning and
the default is used.
Java also reads each WIZELENS_* variable as a system property: -Dwizelens.sample.rate=0.1.
Redaction
Before anything is stored, a value is replaced with [redacted] when its key contains any of: authorization, cookie,
password, passwd, secret, token, apikey, api_key, or connectionstring (any case). This covers attributes,
database parameter names, and headers.
Set-Cookiekeeps each cookie's name and flags:sid=[redacted]; Path=/; HttpOnly.- URL queries keep their keys:
?token=[redacted]&page=2. - JWTs, AWS, Stripe, GitHub, Slack, and Google keys, private keys, and card numbers found inside any value or log line
become a typed marker, such as
[redacted:jwt]or[redacted:card].
RedactKeys (.NET) and redactKeys (Node) replace the list, so include the defaults you want to keep. Every SDK adds
to it with WIZELENS_REDACT_KEYS. Hub and cloud projects add more keys under Thresholds and hidden keys.