OwlpaneDOCS
SDKs

Python SDK

Instrument your application with owlpane to stream traces, metrics, and structured logs to Owlpane over OTLP.

Installation

pip install owlpane==0.1.8

Minimal setup

import os
import owlpane

owlpane.start(
    service=os.environ["OTEL_SERVICE_NAME"],
    endpoint=os.environ["OTEL_EXPORTER_OTLP_ENDPOINT"],
    ingest_key=os.environ["OWLPANE_INGEST_KEY"],
)

Environment Variables

VariableDescriptionExample
OTEL_EXPORTER_OTLP_ENDPOINT (or OWLPANE_INGEST_URL)Owlpane OTLP HTTP base URLhttps://ingest.owlpane.com
OWLPANE_INGEST_KEYProject ingest keyowl_ing_...
OTEL_SERVICE_NAMEService name resource attributecheckout-api
OWLPANE_ENVIRONMENTDeploy environmentproduction
OWLPANE_RELEASEDeploy release / version2024.10.0
OWLPANE_METRICS_EXPORT_INTERVAL_MSMetric export cadence in ms (default 5000)5000

Runtime metrics

owlpane.start() enables OpenTelemetry system metrics (CPU, memory) plus CPython runtime gauges (active threads, GC collection count, RSS) exported to /v1/metrics. Tune export cadence with OWLPANE_METRICS_EXPORT_INTERVAL_MS.

See Runtime telemetry for Observability → Runtimes → Python.

Verification

Open Observability → Runtimes → Python (/observability/runtimes/python), Logs (/observability/logs), or Traces (/observability/traces) with the matching deploy environment to confirm telemetry is arriving.

Last updated

On this page