Panargus

Guides

Send traces

SDKs, OpenTelemetry, and the REST API.

Panargus accepts traces in three ways. Each authenticates with an API key sent as a bearer token.

SDKs

Panargus is compatible with the Braintrust SDKs for Python and TypeScript. Set BRAINTRUST_API_URL to your Panargus address and keep the rest of your code as it is.

1import braintrust
2from openai import OpenAI
3
4logger = braintrust.init_logger(project="My Project")
5client = braintrust.wrap_openai(OpenAI())
6
7@braintrust.traced
8def answer(question):
9 return client.chat.completions.create(model="gpt-4o-mini", messages=[{"role": "user", "content": question}])

Spans

Each call becomes a span with a type — task, llm, tool, function or score — and spans nest into a trace. Wrap your own steps with traced to see the plan, tool calls and answer as one tree.

OpenTelemetry

Send OTLP over HTTP to the /otel endpoint and name the project the spans belong to:

1export OTEL_EXPORTER_OTLP_ENDPOINT=https://api.panargus.dev/otel
2export OTEL_EXPORTER_OTLP_HEADERS="Authorization=Bearer <API key>, x-bt-parent=project_name:My Project"

REST API

Insert events directly, which is useful from languages without an SDK. See the REST API reference.