Skip to content
SolidwayLLM gateway

These pages describe the intended behaviour of the gateway. The open-source release and the enterprise edition are being split out; details will be updated when the first release ships.

Logs and traces

Structured request records, the routing trail, and OTLP export.

Two records are produced per request: a structured request log, and a routing trail.

Request log

One line of structured JSON per completed request:

{
  "ts": "2026-10-07T21:04:11.482Z",
  "request_id": "01J...",
  "route": "POST /v1/messages",
  "provider": "anthropic",
  "model": "claude-sonnet-5-5",
  "status": 200,
  "duration_ms": 812.4,
  "attempts": 1,
  "tokens": { "input": 42, "output": 118, "cached": 0 },
  "cost_usd": 0.00142,
  "workspace": "platform"
}

The field set is stable. Adding a field is a minor change; renaming one is a major change.

Routing trail

The routing trail explains the decision, not just the outcome. It records, in order:

  • Which target was selected, and by what (chain order, weight, session)
  • Why a retry happened, and whether the key rotated
  • Why a hold was placed, released, or skipped
  • Which target ultimately served the request

Reading one trail is enough to answer “why did this request go there?” without correlating several log streams.

The trail is attached to the request, and is included in the 503 body when a chain is exhausted.

Traces

When an OTLP exporter is configured, each upstream attempt becomes a client span, and the request becomes a server span. Trace context is propagated to the provider through a traceparent header.

gen_ai.* attributes follow the OpenTelemetry semantic conventions for generative AI, so dashboards built against those conventions work without translation.

Setting Effect
Content capture off Attributes describe structure and usage only
Content capture on Prompt and completion are recorded, up to a configured size, and truncated past it

Redaction

Header redaction is applied before anything is written. Credentials never appear in a log, a span or a routing trail, including in error paths where the upstream response is quoted back to the caller.

Next