--- id: opentelemetry-instrumentation-openai-agents version: "0.62.3" license: Apache-2.0 license_treatment: permissive maintenance: active --- # opentelemetry-instrumentation-openai-agents — OpenTelemetry OpenAI Agents instrumentation License: permissive · Maintenance: active · Downloads: 2.5M/mo ## What it is and what it does This package is an OpenTelemetry instrumentation plugin that automatically captures traces from OpenAI Agents workflows. When enabled, it records agent reasoning steps, tool invocations, and decision-making as spans that flow into your observability backend, giving you visibility into how agents behave without modifying your agent code. It ships with privacy controls: by default it logs prompts, completions, and embeddings to span attributes for debugging, but you can disable this via the TRACELOOP_TRACE_CONTENT environment variable if your data is sensitive. The package depends on the core OpenTelemetry API and instrumentation framework, plus AI-specific semantic conventions, and installs with low friction as a pure Python wheel. Use it for: - Debug agent behavior by inspecting tool calls, reasoning steps, and LLM interactions in your observability platform. - Monitor production agent workflows to detect failures, latency spikes, or unexpected tool usage patterns. - Correlate agent traces with upstream requests and downstream services using OpenTelemetry's distributed tracing. - Evaluate agent quality by analyzing prompts and completions in traces without modifying agent code. - Reduce trace data size by disabling content logging in privacy-sensitive environments. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Adds distributed tracing to OpenAI Agents workflows, capturing agent reasoning, tool calls, and decision steps as OpenTelemetry spans for observability and debugging. Yes, if you run OpenAI Agents in production or development and use OpenTelemetry for observability. The package is actively maintained, has no known vulnerabilities, installs cleanly, and solves a real problem—agent workflows are otherwise a black box. The privacy controls are essential if you handle sensitive user data. Install it if you already have an OpenTelemetry backend; skip it if you have no observability infrastructure. ## Install pip install opentelemetry-instrumentation-openai-agents uv add opentelemetry-instrumentation-openai-agents poetry add opentelemetry-instrumentation-openai-agents ## Installing opentelemetry-instrumentation-openai-agents Before you install: Low friction: pure Python wheel with four runtime dependencies on established OpenTelemetry packages. Actively maintained with a release 4 days old and no known vulnerabilities. License in practice: Apache-2.0 permissive license allows use in most commercial and open-source projects without significant restriction. Quickstart: pip install opentelemetry-instrumentation-openai-agents from opentelemetry.instrumentation.openai_agents import OpenAIAgentsInstrumentor OpenAIAgentsInstrumentor().instrument() Requires Python 3.10 or later; requires an OpenTelemetry tracer backend already configured to receive spans. Verify before relying: - Whether this instrumentation works with all OpenAI Agents framework versions or has specific version constraints. - Performance overhead of instrumentation on agent execution latency and span volume. - Whether TRACELOOP_TRACE_CONTENT=false fully redacts sensitive data or only disables logging to span attributes. ## Package facts - License: Apache-2.0 (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 2.5M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags openai agents tracing, opentelemetry instrumentation, agentic workflow observability, llm agent monitoring, distributed tracing for agents, openai agents debugging, span instrumentation, observability, openai-agents, tracing [View on SkillFed](https://skillfed.io/packages/opentelemetry-instrumentation-openai-agents) · [View on PyPI](https://pypi.org/project/opentelemetry-instrumentation-openai-agents/)