Skip to main content
A log probe inserts a log statement at a specific line of your production code without requiring a code change or redeployment. When execution reaches the instrumented line, HyperProbe evaluates your message template — substituting live variable values into any ${expression} placeholders — and emits the rendered log to the HyperProbe panel in VS Code. Your application never pauses; the log is captured and forwarded asynchronously. Log probes are the fastest way to add observability to a code path you did not think to instrument ahead of time. Instead of adding a console.log, pushing a commit, waiting for a deploy, and reproducing the issue, you place a log probe directly from your editor and see output within seconds of the next request hitting that line.

Creating a log probe

1

Open the HyperProbe panel in VS Code

Click the HyperProbe icon in the activity bar, then select Insert a Log from the probe type list.
2

Select your source

Choose the target service, environment, and commit from the Source dropdown.
3

Set the file path and line number

Enter the relative path to the file (for example, src/payments/processor.ts) and the line number where the log should fire.
4

Write the log message

Enter the message template in the Log Message field. Use ${expression} syntax to embed any variable or expression available at that line.
Processing payment for user ${user.id}, amount: ${order.total}
Auth token present: ${!!request.headers.authorization}
Cart has ${cart.items.length} items, subtotal: ${cart.subtotal}
5

Set the log level

Choose a severity level from the Log Level dropdown: INFO, WARN, ERROR, or DEBUG. The level is included in the rendered output and can be used to filter results.
6

Set the hit limit and condition

Adjust the hit limit (default 100) and optionally add a condition expression. Then click Create.

Configuration reference

body.uiFilePath
string
required
Relative path to the source file. For example, src/payments/processor.ts.
body.uiLineNumber
number
required
Line number where the log probe fires. Must be a positive integer.
body.template
string
required
The log message template. Use ${expression} placeholders to interpolate runtime values. For example: User ${user.name} placed order ${order.id}.
body.logLevel
string
default:"INFO"
Severity level of the emitted log. Accepts INFO, WARN, ERROR, or DEBUG.
body.hitLimit
number
default:"100"
Maximum number of log emissions before the probe auto-expires. Accepts 1–1000. Defaults to 100.
body.condition
string
A boolean expression that must evaluate to true for the probe to emit a log. Leave blank to log on every execution.
body.lifetime
string
default:"An Hour"
How long the probe remains active. Accepts An Hour or A Day.

Template syntax

The log message template supports ${expression} interpolation. Each ${...} block is evaluated in the scope of the instrumented line at the moment the probe fires, and the result is coerced to a string.
User: ${user.email}, role: ${user.role}
Request ID: ${request.headers['x-request-id']}
If an expression in the template throws an error or refers to an undefined variable, HyperProbe substitutes the error description in place of the value rather than dropping the entire log line.

Log levels

LevelWhen to use
INFOGeneral informational messages about normal execution flow.
WARNConditions that are unexpected but not immediately harmful.
ERRORFailures or error states that indicate something went wrong.
DEBUGDetailed diagnostic information useful during active investigation.

Viewing log output

Open the HyperProbe panel and click a log probe to open the inspector. Each captured emission appears as a rendered log entry showing the full evaluated message and the timestamp. Use the hit navigation controls to page through multiple emissions in order.
Use the condition field to limit log output to specific users, request types, or error states. For example, user.id === 'usr_42601' ensures you only see logs for the specific user you are investigating, even on a high-traffic endpoint.

Hit limit defaults

Log probes default to a hit limit of 100, which is intentionally higher than the snapshot default of 1. Because log messages are lightweight — just a rendered string per emission — they are safe to capture at moderate frequency. Reduce the hit limit if you are instrumenting a very hot path and do not need that many samples.
On extremely high-throughput code paths, even a lightweight log probe with a high hit limit can accumulate data quickly. Set a condition to narrow the probe’s scope before increasing the hit limit beyond the default.