Observability: Find the request. See what happened.
You keep an audit log of LLM requests by recording every gateway call: request ID, timings, the model that answered and its cost. nRouter's request logs hold exactly that — without capturing prompt or response bodies — and 7-day logs export as CSV for review.
Watch a request leave a trail.
How observability works.
Find the request by its ID.
Every authenticated response returns x-nr-request-id so you can open its matching log record.
- Correlates response headers to the matching gateway log record and trace
- Attach caller tags in x-nr-tags or nrouter_tags, stripped before dispatch
- Pre-authentication refusals do not create tenant request log rows
Compare gateway and model time.
See how much time was spent in recorded gateway checks versus waiting on the model response.
- Records gateway step timings from authentication through cost settlement
- Does not measure internal upstream provider execution or client app code
- Marks trace coverage as truncated or unfinished if event caps are reached
Check which model answered and its cost.
Verify the served model, token counts, routing path, and settled USD cost on the request record.
- Buffered responses return settled USD cost in x-nr-request-cost when priced
- Streamed calls send headers first and settle cost on the log row after
- Unknown prices report x-nr-cost-status: unpriced rather than $0
Export 7-day request logs as CSV.
Filter pay-as-you-go logs across a 7-day retention window by model, key, status, or tag and export CSV.
- 7-day request log retention on pay as you go; 18-month org audit logs
- Caller tags and user IDs are stored as metadata if you supply them
FAQs
What data is captured in request logs, and is personal data ever stored?
Request logging does not capture prompt or response bodies. Log rows record structured routing, timing, token, status, and billing metadata correlated by x-nr-request-id. Metadata-only does not mean personal-data-free: custom attribution tags (x-nr-tags and nrouter_tags, which are stripped before provider dispatch) and end-user identifiers passed in user are stored with the log record if you send them. Separately, if you enable response caching, cached entries store the response body—which can include echoed prompt content—for the cache TTL.
What does a request trace cover, and what is outside its scope?
A request trace records gateway step timings—such as authentication, guardrail checks, routing selection, credit reservation, upstream wait time, and settlement—on authenticated requests. It does not provide visibility inside an upstream provider’s internal model execution or your surrounding application code, and requests refused before authentication cannot produce a tenant log row. Trace depth follows your organization trace setting (and can be lowered per call with x-nr-trace), and the recorder explicitly marks coverage as truncated or unfinished if a trace reaches its event cap.
How is cost reported on buffered versus streaming requests?
On buffered requests, settlement runs before headers return, so priced responses carry the settled USD amount in x-nr-request-cost with x-nr-cost-status: exact. On streaming requests, response headers are sent before the first token arrives, when final token usage does not exist yet; initial stream headers report x-nr-cost-status: unpriced, and the settled cost is written to the request log row after the stream completes. If a request’s price cannot be determined, cost status remains unpriced rather than reporting $0.
How does request logging affect request latency?
Request logging is part of gateway settlement, not a zero-latency background step. On buffered text calls, the gateway records the settled spend row and discharges the credit hold before returning response headers to the caller. On streaming calls, headers and tokens stream first and settlement is recorded when the stream finishes.
How long are request logs retained, and how does plan access work?
Pay as you go is the standard self-serve plan and retains searchable request logs and traces for 7 days. Longer retention windows (up to 30 days) apply only to custom enterprise agreements and grandfathered legacy subscriptions, which are no longer sold. Organization audit logs are retained for 18 months. Request logs, trace inspection, and CSV export are included on pay as you go, while trace depth is governed by your organization settings and SIEM audit streaming is reserved for enterprise agreements.
How can I export logs or integrate with external monitoring today?
You can filter request logs in the dashboard and export them as CSV at any time, and your application can record the x-nr-request-id, x-nr-model, x-nr-latency-ms, and x-nr-request-cost response headers directly in your own telemetry. In the dashboard, saving a destination and sending a test event only verifies that the address is reachable; automatic log delivery is not available as a live customer guarantee, so use CSV export and response headers for external analysis.
- Request logs and step traces record gateway execution steps on authenticated requests; pre-authentication refusals do not create tenant log rows, and traces do not measure internal upstream provider execution. Recorded step traces can report truncated or unfinished coverage when event caps are reached.
- Buffered responses return settled USD cost in x-nr-request-cost with x-nr-cost-status: exact when pricing is known, or omit x-nr-request-cost with x-nr-cost-status: unpriced when a price cannot be determined. Streamed responses send headers before tokens are generated and settle cost on the log row after the stream finishes.
- Request logging does not capture prompt or response bodies, though caller tags (x-nr-tags and nrouter_tags, stripped before provider dispatch) and end-user identifiers (user) are stored as metadata and may contain personal data if you supply it. Optional response caching separately stores cached response bodies for its TTL. Request logs are retained for 7 days on pay as you go (up to 30 days under enterprise terms or grandfathered plans), organization audit logs are retained for 18 months, and CSV export is available in the dashboard.