Skip to content

Any other OTLP backend

CredenceStack speaks standard OTLP, so any backend or Collector that accepts OTLP traces works with the standard OpenTelemetry settings.

Prerequisites

  • pip install "credencestack[otel]"
  • The backend's OTLP traces endpoint, the protocol it accepts (HTTP/protobuf or gRPC), and any authentication headers.

Configure

export OTEL_EXPORTER_OTLP_ENDPOINT="https://otlp.example.com"        # base URL; /v1/traces is appended
export OTEL_EXPORTER_OTLP_PROTOCOL=http/protobuf                     # or grpc
export OTEL_EXPORTER_OTLP_HEADERS="authorization=Bearer%20${TOKEN}"  # if the backend needs it
export OTEL_RESOURCE_ATTRIBUTES="deployment.environment.name=staging"

If the backend's traces URL does not end in /v1/traces, set OTEL_EXPORTER_OTLP_TRACES_ENDPOINT to the full URL instead.

Run

credencestack otel check
credencestack run -p payments --agent my_agent:policy --otel

Verify

  1. otel check prints OK; the run ends with OTel: exported N span(s).
  2. Look for the service credencestack (or your OTEL_SERVICE_NAME) in the last hour.
  3. Each scenario epoch is a trace named credencestack scenario <id> #<epoch> with an invoke_agent span and execute_tool children; the run is a separate trace linked to them.

Useful views and alerts

  • Failed scenarios: credencestack.result = fail (the span status stays unset for a failed test).
  • Severe findings: credencestack.findings.max_severity = critical.
  • Execution errors: span status ERROR on the scenario span.

If the backend cannot read the GenAI conventions

The spans are ordinary OpenTelemetry spans: names, kinds, attributes and events. A backend without GenAI support still shows the tree and every attribute; only its AI-specific views stay empty.

Debugging locally

  • credencestack otel print shows the spans without exporting.
  • CREDENCESTACK_OTEL_EXPORTER=console prints every span to stderr as it is exported.
  • (CREDENCESTACK_OTEL_EXPORTER=file, CREDENCESTACK_OTEL_FILE=spans.jsonl) writes OTLP/JSON you can inspect or replay into a Collector.

See Troubleshooting.