traceroot does not auto-instrument Notte. You trace the session with
observe and report its cost yourself, and traceroot stores the cost you report. See Tool and API calls for how reported costs add up.Install
- Python
- TypeScript
traceroot 0.5.0 or later, or @traceroot-ai/traceroot 0.7.0 or later.
Set up
Initialize traceroot once at startup. No integration flag is needed: theobserve wrapper in the next step traces the session.
- Python
- TypeScript
Usage
Notte bills cloud browser sessions by the hour and returns no per-session price, so you estimate the cost from the session’s length. To record it:- Wrap the session in a function traced as a tool span (
type="tool"). - Time the session from start to stop.
- Multiply the hours by the hourly rate and report it with
update_current_span(cost=...)(updateCurrentSpanin TypeScript) before the span closes. Afinallyblock reports it even when the session fails.
- Python
- TypeScript
browse from your agent like any other function. Its span nests under the span that called it, and its cost adds to that trace’s total.
Verify
Run your code and confirm the trace arrives:- In the traceroot UI: Navigate to Tracing > Traces in traceroot Cloud. You should see a
browsespan, at the root or under your agent’s span. Open it to see its cost; the trace’s total cost includes it. - Via the CLI: Run
traceroot traces listto inspect your recent traces from the terminal.
What gets captured
Limitations
- The cost is an estimate: Notte rounds session time according to its own billing policy.
- Residential proxy traffic and LLM tokens are billed separately and are not included.
Next steps
Python SDK Reference
Explore the full Python SDK reference and instrumentation options.
Time used
Report time used at your price per minute or hour