Skip to main content
To trace an app without editing it, launch it through the botgauge command. The launcher reads its settings from the environment, starts tracing, and turns on the producer for each installed framework whose extra is installed. Versions BotGauge hasn’t verified are traced too. See versions not verified.
terminal
You don’t need init() under the launcher.

What gets exported

What you see depends on what is installed in the environment. An app that never imports botgauge still gets its LLM spans exported, but without session or agent ids. To group spans by session, wrap the work in tracing.turn() and tracing.agent() as the framework samples do.

Loading a .env file

--env-file handles comments, export prefixes, and quotes. Variables already set in the environment win over the file, and the flag can be repeated. Your app sees the file’s other variables too. An unreadable file stops the launcher before your app starts.
Your app’s own load_dotenv() runs too late for the launcher. Always use --env-file for zero-code runs, and keep the .env file out of version control.

Use --strict as a CI gate

botgauge instrument --strict refuses to start your app when BotGauge would trace a framework at a version that isn’t verified, or when instrumentation problems occur. It exits 1 with a message like botgauge: --strict: not starting the application: version not verified: openai (...).
terminal
Setting BOTGAUGE_STRICT=1 has the same effect. Frameworks you trace yourself, declared with BOTGAUGE_PRODUCER_OWNER=<framework>=customer, aren’t checked.

Keeping your own instrumentation

BotGauge’s exporter reads only BOTGAUGE_API_KEY and BOTGAUGE_ENDPOINT. It never uses OTEL_EXPORTER_OTLP_*, so your own collector’s endpoint and headers stay separate and never receive the BotGauge key. If your app already calls .instrument() itself, BotGauge leaves it alone instead of instrumenting twice. Set BOTGAUGE_PRODUCER_OWNER=<framework>=customer to make that explicit.

Launch your app with one command

Get your API key from BotGauge and run botgauge instrument to start tracing.

Try BotGauge →

Next steps

Pick your framework on the supported frameworks page for a tested zero-code sample, or tune what leaves your app with capture and redaction.