File tree Expand file tree Collapse file tree 5 files changed +444
-555
lines changed
Expand file tree Collapse file tree 5 files changed +444
-555
lines changed Original file line number Diff line number Diff line change @@ -779,6 +779,54 @@ class SPANDATA:
779779 Example: "req_123abc"
780780 """
781781
782+ MCP_TOOL_RESULT_CONTENT = "mcp.tool.result.content"
783+ """
784+ The result/output content from an MCP tool execution.
785+ Example: "The weather is sunny"
786+ """
787+
788+ MCP_TOOL_RESULT_CONTENT_COUNT = "mcp.tool.result.content_count"
789+ """
790+ The number of items/keys in the MCP tool result.
791+ Example: 5
792+ """
793+
794+ MCP_TOOL_RESULT_IS_ERROR = "mcp.tool.result.is_error"
795+ """
796+ Whether the MCP tool execution resulted in an error.
797+ Example: True
798+ """
799+
800+ MCP_PROMPT_RESULT_MESSAGE_CONTENT = "mcp.prompt.result.message_content"
801+ """
802+ The message content from an MCP prompt retrieval.
803+ Example: "Review the following code..."
804+ """
805+
806+ MCP_PROMPT_RESULT_MESSAGE_ROLE = "mcp.prompt.result.message_role"
807+ """
808+ The role of the message in an MCP prompt retrieval (only set for single-message prompts).
809+ Example: "user", "assistant", "system"
810+ """
811+
812+ MCP_PROMPT_RESULT_MESSAGE_COUNT = "mcp.prompt.result.message_count"
813+ """
814+ The number of messages in an MCP prompt result.
815+ Example: 1, 3
816+ """
817+
818+ MCP_RESOURCE_RESULT_CONTENT = "mcp.resource.result.content"
819+ """
820+ The result/output content from an MCP resource read.
821+ Example: "File contents..."
822+ """
823+
824+ MCP_TRANSPORT = "mcp.transport"
825+ """
826+ The transport method used for MCP communication.
827+ Example: "pipe" (stdio), "tcp" (HTTP/WebSocket/SSE)
828+ """
829+
782830
783831class SPANSTATUS :
784832 """
Original file line number Diff line number Diff line change 1212
1313try :
1414 import mcp .server .lowlevel # noqa: F401
15- import mcp .server .fastmcp # noqa: F401
1615except ImportError :
1716 raise DidNotEnable ("MCP SDK not installed" )
1817
@@ -28,10 +27,9 @@ def setup_once():
2827 Patches MCP server classes to instrument handler execution.
2928 """
3029 from sentry_sdk .integrations .mcp .lowlevel import patch_lowlevel_server
31- from sentry_sdk .integrations .mcp .fastmcp import patch_fastmcp_server
3230
31+ # Patch server classes to instrument handlers
3332 patch_lowlevel_server ()
34- patch_fastmcp_server ()
3533
3634
3735__all__ = ["MCPIntegration" ]
You can’t perform that action at this time.
0 commit comments