skillfed

openinference-instrumentation-mcp

OpenInference MCP Instrumentation

openinference-instrumentation-mcp v2.0.5 193.0K downloads/30d#9,854 on PyPI1,147
Permissive license Apache-2.0 Active released

What it is and what it does

This package adds OpenTelemetry instrumentation to the MCP Python SDK, enabling distributed tracing by propagating trace context from the caller into MCP tool executions. It integrates with the OpenInference framework and observability platforms like Arize Phoenix and Arize AX. Currently, it focuses on context propagation rather than generating new telemetry data itself—the primary use case is connecting existing spans across MCP boundaries so that tool calls and their execution can be viewed as part of a single trace.

The package depends on openinference-instrumentation, opentelemetry-api, opentelemetry-instrumentation, and wrapt. It is marked as Production/Stable and actively maintained, with support for modern Python versions.

Use it for:

  • Connect traces from an LLM application into MCP tool executions for end-to-end observability.
  • Debug MCP tool call latency and failures by viewing them in the context of the parent request trace.
  • Correlate MCP tool behavior with upstream application logic in a distributed tracing platform.
  • Monitor MCP tool call patterns and performance metrics through OpenTelemetry-compatible backends.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Auto-instruments MCP tool calls to propagate OpenTelemetry context between the caller and the tool execution, enabling distributed tracing across MCP interactions.

Yes, if you are already using MCP with Python and need distributed tracing or observability. The low install friction, active maintenance, permissive license, and zero known vulnerabilities make it a safe addition. Install it only if you have an OpenTelemetry collector or observability platform in place to consume the context propagation it enables.

Install

openinference-instrumentation-mcp on PyPI

pip

pip install openinference-instrumentation-mcp

uv

uv add openinference-instrumentation-mcp

poetry

poetry add openinference-instrumentation-mcp

Installing openinference-instrumentation-mcp

Before you install

Low friction installation with a pure-Python wheel. Actively maintained as of 2026-08-14 with recent release history; no known vulnerabilities.

License in practice

Apache-2.0 permissive license allows use in commercial and proprietary projects with minimal restrictions.

Quickstart

pip install openinference-instrumentation-mcp

from openinference.instrumentation.mcp import MCP_INSTRUMENTATION
from opentelemetry import trace

# Instrumentation enables context propagation for MCP tool calls
MCP_INSTRUMENTATION.instrument()

Requires Python 3.10 or later (supports up to 3.14); OpenTelemetry API and instrumentation packages must be installed.

Verify before relying

  • Whether context propagation works with all MCP SDK versions or has version constraints beyond the package metadata.
  • Performance overhead of instrumentation in high-throughput MCP tool call scenarios.
  • Compatibility with non-OpenTelemetry tracing backends or observability platforms.

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (<3.15,>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 4 — openinference-instrumentation, opentelemetry-api, opentelemetry-instrumentation, wrapt
Maintenance actively maintained — 13 days since the last release
Last repo commit
First released
Downloads 192,976/month — #9,854 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: openinference_instrumentation_mcp-2.0.5-py3-none-any.whl

Development Status :: 5 - Production/StableIntended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14

Tags

mcp instrumentationopentelemetry mcpdistributed tracing mcpcontext propagation mcpmcp observabilityopeninference mcp
observabilitydistributed-tracingmcp

More Monitoring packages

tqdm

Wraps any iterable to display a real-time…

copyleft · top 100 on PyPI

opentelemetry-semantic-conventions

Provides generated Python code for…

permissive · top 100 on PyPI

opentelemetry-sdk

Provides the reference implementation of the…

permissive · top 100 on PyPI

opentelemetry-api

Provides the abstract API and interfaces for…

permissive · top 100 on PyPI

opentelemetry-exporter-otlp-proto-http

Exports OpenTelemetry observability data to an…

permissive · top 1,000 on PyPI

opentelemetry-instrumentation

Provides automatic instrumentation commands and…

permissive · top 1,000 on PyPI

openinference-instrumentation-openai

Auto-instruments OpenAI Python SDK calls to…

permissive · top 5,000 on PyPI

openinference-instrumentation-claude-agent-sdk

Auto-instruments Claude Agent SDK calls to emit…

permissive · top 15,000 on PyPI

openinference-instrumentation

Provides utility functions to convert typed…

permissive · top 5,000 on PyPI

openinference-instrumentation-google-adk

Auto-instruments Google ADK applications to…

permissive · top 15,000 on PyPI

openinference-instrumentation-dspy

Auto-instruments DSPy applications to generate…

permissive · top 15,000 on PyPI

openinference-instrumentation-openai-agents

Auto-instruments OpenAI Agents SDK to emit…

permissive · top 5,000 on PyPI

openinference-instrumentation-agno

Auto-instruments Agno Agent applications to…

permissive · top 15,000 on PyPI

opentelemetry-instrumentation-mcp

Adds distributed tracing to MCP (Model Context…

permissive · top 5,000 on PyPI

openinference-instrumentation-bedrock

Automatically instruments AWS Bedrock API calls…

permissive · top 15,000 on PyPI

opentracing

Provides the OpenTracing API for Python,…

permissive · top 5,000 on PyPI