:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
chore(taxonomy): document MCP events and properties (#58417)
Lucas Fariaae46d850bbbd
diff --git a/frontend/src/taxonomy/core-filter-definitions-by-group.json b/frontend/src/taxonomy/core-filter-definitions-by-group.jsonindex 7fe2ff4f8abe..29b7c640da53 100644--- a/frontend/src/taxonomy/core-filter-definitions-by-group.json+++ b/frontend/src/taxonomy/core-filter-definitions-by-group.json@@ -659,20 +659,35 @@"label": "AI Tags (LLM)"},"$ai_target_event_id": {- "description": "The unique identifier of the event being evaluated.",+ "description": "Deprecated \u2014 use $ai_target_id with $ai_target_type instead. The unique identifier of the event being evaluated.","examples": ["c9222e05-8708-41b8-98ea-d4a21849e761"],"label": "AI Target Event ID (LLM)"},"$ai_target_event_type": {- "description": "The type of event being evaluated (e.g., $ai_generation).",+ "description": "Deprecated \u2014 use $ai_target_type instead. The type of event being evaluated (e.g., $ai_generation).","examples": ["$ai_generation","$ai_span"],"label": "AI Target Event Type (LLM)"},+ "$ai_target_id": {+ "description": "Identifier of the entity this evaluation targets. Pair with $ai_target_type to know which ID space it belongs to (event UUID, trace ID, etc.).",+ "examples": [+ "c9222e05-8708-41b8-98ea-d4a21849e761"+ ],+ "label": "AI Target ID (LLM)"+ },+ "$ai_target_type": {+ "description": "ID space of $ai_target_id. `generation_uuid` resolves against `events.uuid`; `trace_id` resolves against the `$ai_trace_id` property.",+ "examples": [+ "generation_uuid",+ "trace_id"+ ],+ "label": "AI Target Type (LLM)"+ },"$ai_temperature": {"description": "The temperature parameter used in the request to the LLM API.","examples": [@@ -1803,6 +1818,86 @@],"label": "Locale"},+ "$mcp_client_name": {+ "description": "The MCP client that initiated the connection. Common values are coding agents (Claude Code, Codex) and chat clients (Claude desktop, Claude on web).",+ "examples": [+ "claude-code",+ "codex-mcp-client",+ "Anthropic/ClaudeAI"+ ],+ "label": "MCP client name"+ },+ "$mcp_client_version": {+ "description": "The version of the MCP client that initiated the connection.",+ "label": "MCP client version"+ },+ "$mcp_duration_ms": {+ "description": "Wall-clock duration of the MCP tool or resource call, in milliseconds.",+ "examples": [+ 42,+ 1280+ ],+ "label": "MCP duration (ms)",+ "type": "Numeric"+ },+ "$mcp_intent": {+ "description": "Free-text description of why the agent is calling this tool, written by the agent itself. Comes from a context argument the client supplied at call time, or \u2014 if none was supplied \u2014 from an intentFallback the MCP server provides.",+ "examples": [+ "Listing recent error tracking issues to triage a spike in 500s.",+ "Fetching the trace referenced by the inbox signal to inspect the user message."+ ],+ "label": "MCP intent"+ },+ "$mcp_intent_source": {+ "description": "Where $mcp_intent came from. 'context_parameter' means the client supplied it directly on the call; 'inferred' means the MCP server derived it via its intentFallback.",+ "examples": [+ "context_parameter",+ "inferred"+ ],+ "label": "MCP intent source"+ },+ "$mcp_is_error": {+ "description": "Whether the MCP tool call failed. True if the tool returned an error result or threw an exception.",+ "label": "MCP is error"+ },+ "$mcp_parameters": {+ "description": "The arguments the client passed when invoking the tool. Large strings and sensitive keys (tokens, API keys, etc.) are redacted before capture.",+ "label": "MCP parameters"+ },+ "$mcp_resource_name": {+ "description": "The name of the MCP resource, prompt, or tool the event refers to.",+ "label": "MCP resource name"+ },+ "$mcp_response": {+ "description": "The response the MCP server returned. Large strings and sensitive keys are redacted before capture.",+ "label": "MCP response"+ },+ "$mcp_server_name": {+ "description": "The advertised name of the MCP server that handled the request.",+ "examples": [+ "PostHog"+ ],+ "label": "MCP server name"+ },+ "$mcp_server_version": {+ "description": "The advertised version of the MCP server that handled the request.",+ "label": "MCP server version"+ },+ "$mcp_source": {+ "description": "Constant identifier for the analytics SDK that emitted the event. Lets you separate events from different SDK versions or unrelated MCP servers.",+ "examples": [+ "posthog_mcp_analytics"+ ],+ "label": "MCP source"+ },+ "$mcp_tool_name": {+ "description": "The name of the MCP tool that was invoked. Only present on mcp_tool_call.",+ "examples": [+ "execute-sql",+ "feature-flag-get-all"+ ],+ "label": "MCP tool name"+ },"$network_bluetooth": {"description": "Whether the user was on Bluetooth when the event was sent.","examples": [@@ -2808,6 +2903,11 @@],"label": "Distinct ID"},+ "duration_ms": {+ "description": "Older unprefixed variant of $mcp_duration_ms. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_duration_ms for new dashboards.",+ "label": "Duration (ms, unprefixed)",+ "type": "Numeric"+ },"epik": {"description": "Pinterest Click ID","label": "epik"@@ -2848,6 +2948,10 @@"description": "Impact Click ID","label": "irclid"},+ "is_error": {+ "description": "Older unprefixed variant of $mcp_is_error. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_is_error for new dashboards.",+ "label": "Is error (unprefixed)"+ },"li_fat_id": {"description": "LinkedIn First-Party Ad Tracking ID","label": "li_fat_id"@@ -2856,6 +2960,64 @@"description": "Mailchimp Campaign ID","label": "mc_cid"},+ "mcp_client_name": {+ "description": "Older unprefixed variant of $mcp_client_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_name for new dashboards.",+ "examples": [+ "claude-code",+ "codex-mcp-client"+ ],+ "label": "MCP client name (unprefixed)"+ },+ "mcp_client_version": {+ "description": "Older unprefixed variant of $mcp_client_version. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_version for new dashboards.",+ "label": "MCP client version (unprefixed)"+ },+ "mcp_consumer": {+ "description": "The upstream surface that initiated the MCP request. 'posthog-code' means the request came through PostHog Code; 'slack' means it was triggered from Slack.",+ "examples": [+ "posthog-code",+ "slack"+ ],+ "label": "MCP consumer"+ },+ "mcp_mode": {+ "description": "Which tool-registration mode the MCP server ran in for this request. 'single-exec' means the v2 wrapper that exposes one tool; the alternative exposes every tool individually.",+ "label": "MCP mode"+ },+ "mcp_oauth_client_name": {+ "description": "The OAuth client name captured during the MCP handshake, when the connection used OAuth.",+ "label": "MCP OAuth client name"+ },+ "mcp_protocol_version": {+ "description": "The MCP protocol version negotiated during initialize.",+ "label": "MCP protocol version"+ },+ "mcp_region": {+ "description": "The region the MCP server routed the request to.",+ "examples": [+ "us",+ "eu"+ ],+ "label": "MCP region"+ },+ "mcp_transport": {+ "description": "The transport the MCP client used to connect to the server.",+ "examples": [+ "stdio",+ "sse",+ "streamable_http"+ ],+ "label": "MCP transport"+ },+ "mcp_version": {+ "description": "Server-resolved MCP version. May differ from the version the client reported because of the mcp-version-2 feature flag.",+ "examples": [+ 1,+ 2+ ],+ "label": "MCP server version (internal)",+ "type": "Numeric"+ },"msclkid": {"description": "Microsoft Click ID","label": "msclkid"@@ -2889,6 +3051,10 @@],"label": "Referrer application"},+ "resource_name": {+ "description": "Older unprefixed variant of $mcp_resource_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_resource_name for new dashboards.",+ "label": "Resource name (unprefixed)"+ },"revenue": {"description": "The revenue associated with the event. By default, this is in USD, but the currency property can be used to specify a different currency.","examples": [@@ -2908,6 +3074,10 @@"ignored_in_assistant": true,"label": "Token"},+ "tool_name": {+ "description": "Older unprefixed variant of $mcp_tool_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_tool_name for new dashboards.",+ "label": "Tool name (unprefixed)"+ },"ttclid": {"description": "TikTok Click ID","label": "ttclid"@@ -3168,6 +3338,78 @@"Deep link opened": {"description": "When a user opens the mobile app via a deep link.","label": "Deep link opened"+ },+ "mcp feedback submitted": {+ "description": "Fires when a user submits feedback through the MCP server's feedback tool.",+ "label": "MCP feedback submitted"+ },+ "mcp init": {+ "description": "MCP initialization event emitted by the mcpcat library. Fires for all traffic today (alongside mcp_initialize where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability; until then, filter on this event if you need coverage across all clients, or on mcp_initialize if you only want the @posthog/mcp-enabled slice.",+ "label": "MCP init"+ },+ "mcp organization switched": {+ "description": "Fires when a user switches the active organization in their MCP session.",+ "label": "MCP organization switched"+ },+ "mcp project switched": {+ "description": "Fires when a user switches the active project in their MCP session.",+ "label": "MCP project switched"+ },+ "mcp tool call": {+ "description": "Tool-call event emitted by the mcpcat library. Fires for all traffic today (alongside mcp_tool_call where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ "label": "MCP tool call (mcpcat)"+ },+ "mcp tool response": {+ "description": "Tool-response event emitted by the mcpcat library. Tool responses are also carried inline on mcp_tool_call (under $mcp_response) for @posthog/mcp-enabled traffic. Will be retired once @posthog/mcp reaches general availability.",+ "label": "MCP tool response (mcpcat)"+ },+ "mcp_custom": {+ "description": "A custom MCP analytics event emitted by a server through the SDK's custom-event API. Properties depend on what the caller passed.",+ "label": "MCP custom event"+ },+ "mcp_initialize": {+ "description": "Fires when an MCP client completes the handshake with the server. Carries the client and server name/version so you can break down usage by client.",+ "label": "MCP initialize"+ },+ "mcp_mcpcat:identify": {+ "description": "Identify event emitted by the mcpcat library. Fires for all traffic today (alongside posthog_identify where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ "label": "MCP identify (mcpcat)"+ },+ "mcp_posthog:identify": {+ "description": "Identify event emitted by PostHog's in-tree MCP analytics path. Fires for all traffic today (alongside posthog_identify where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ "label": "MCP identify (in-tree)"+ },+ "mcp_prompt_get": {+ "description": "Fires when an MCP prompt is fetched by a client. Includes the prompt name.",+ "label": "MCP prompt fetched"+ },+ "mcp_prompts_list": {+ "description": "Fires when an MCP client requests the list of available prompts.",+ "label": "MCP prompts listed"+ },+ "mcp_resource_read": {+ "description": "Fires when an MCP resource is fetched by a client. Includes the resource name.",+ "label": "MCP resource read"+ },+ "mcp_resources_list": {+ "description": "Fires when an MCP client requests the list of available resources.",+ "label": "MCP resources listed"+ },+ "mcp_tool_call": {+ "description": "Fires every time an MCP server tool is invoked. Includes the tool name, wall-clock duration, error state, and (when the client supplied a context argument) the agent's stated intent.",+ "label": "MCP tool call"+ },+ "mcp_tool_called": {+ "description": "Tool-call event emitted by PostHog's in-tree MCP analytics path. Fires for all traffic today (alongside mcp_tool_call where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability; until then, filter on this event if you need coverage across all clients, or on mcp_tool_call if you only want the @posthog/mcp-enabled slice.",+ "label": "MCP tool called (in-tree)"+ },+ "mcp_tools_list": {+ "description": "Fires when an MCP client requests the list of available tools. Useful for measuring discovery \u2014 i.e. whether new clients are finding the server.",+ "label": "MCP tools listed"+ },+ "posthog_identify": {+ "description": "Fires when an MCP session becomes associated with an identified user, or when the identity changes for an existing session. Used to attribute subsequent events to a real user instead of an anonymous session.",+ "label": "MCP identify"}},"groups": {@@ -3813,20 +4055,35 @@"label": "AI Tags (LLM)"},"$ai_target_event_id": {- "description": "The unique identifier of the event being evaluated.",+ "description": "Deprecated \u2014 use $ai_target_id with $ai_target_type instead. The unique identifier of the event being evaluated.","examples": ["c9222e05-8708-41b8-98ea-d4a21849e761"],"label": "AI Target Event ID (LLM)"},"$ai_target_event_type": {- "description": "The type of event being evaluated (e.g., $ai_generation).",+ "description": "Deprecated \u2014 use $ai_target_type instead. The type of event being evaluated (e.g., $ai_generation).","examples": ["$ai_generation","$ai_span"],"label": "AI Target Event Type (LLM)"},+ "$ai_target_id": {+ "description": "Identifier of the entity this evaluation targets. Pair with $ai_target_type to know which ID space it belongs to (event UUID, trace ID, etc.).",+ "examples": [+ "c9222e05-8708-41b8-98ea-d4a21849e761"+ ],+ "label": "AI Target ID (LLM)"+ },+ "$ai_target_type": {+ "description": "ID space of $ai_target_id. `generation_uuid` resolves against `events.uuid`; `trace_id` resolves against the `$ai_trace_id` property.",+ "examples": [+ "generation_uuid",+ "trace_id"+ ],+ "label": "AI Target Type (LLM)"+ },"$ai_temperature": {"description": "The temperature parameter used in the request to the LLM API.","examples": [@@ -5361,6 +5618,86 @@],"label": "Locale"},+ "$mcp_client_name": {+ "description": "The MCP client that initiated the connection. Common values are coding agents (Claude Code, Codex) and chat clients (Claude desktop, Claude on web).",+ "examples": [+ "claude-code",+ "codex-mcp-client",+ "Anthropic/ClaudeAI"+ ],+ "label": "MCP client name"+ },+ "$mcp_client_version": {+ "description": "The version of the MCP client that initiated the connection.",+ "label": "MCP client version"+ },+ "$mcp_duration_ms": {+ "description": "Wall-clock duration of the MCP tool or resource call, in milliseconds.",+ "examples": [+ 42,+ 1280+ ],+ "label": "MCP duration (ms)",+ "type": "Numeric"+ },+ "$mcp_intent": {+ "description": "Free-text description of why the agent is calling this tool, written by the agent itself. Comes from a context argument the client supplied at call time, or \u2014 if none was supplied \u2014 from an intentFallback the MCP server provides.",+ "examples": [+ "Listing recent error tracking issues to triage a spike in 500s.",+ "Fetching the trace referenced by the inbox signal to inspect the user message."+ ],+ "label": "MCP intent"+ },+ "$mcp_intent_source": {+ "description": "Where $mcp_intent came from. 'context_parameter' means the client supplied it directly on the call; 'inferred' means the MCP server derived it via its intentFallback.",+ "examples": [+ "context_parameter",+ "inferred"+ ],+ "label": "MCP intent source"+ },+ "$mcp_is_error": {+ "description": "Whether the MCP tool call failed. True if the tool returned an error result or threw an exception.",+ "label": "MCP is error"+ },+ "$mcp_parameters": {+ "description": "The arguments the client passed when invoking the tool. Large strings and sensitive keys (tokens, API keys, etc.) are redacted before capture.",+ "label": "MCP parameters"+ },+ "$mcp_resource_name": {+ "description": "The name of the MCP resource, prompt, or tool the event refers to.",+ "label": "MCP resource name"+ },+ "$mcp_response": {+ "description": "The response the MCP server returned. Large strings and sensitive keys are redacted before capture.",+ "label": "MCP response"+ },+ "$mcp_server_name": {+ "description": "The advertised name of the MCP server that handled the request.",+ "examples": [+ "PostHog"+ ],+ "label": "MCP server name"+ },+ "$mcp_server_version": {+ "description": "The advertised version of the MCP server that handled the request.",+ "label": "MCP server version"+ },+ "$mcp_source": {+ "description": "Constant identifier for the analytics SDK that emitted the event. Lets you separate events from different SDK versions or unrelated MCP servers.",+ "examples": [+ "posthog_mcp_analytics"+ ],+ "label": "MCP source"+ },+ "$mcp_tool_name": {+ "description": "The name of the MCP tool that was invoked. Only present on mcp_tool_call.",+ "examples": [+ "execute-sql",+ "feature-flag-get-all"+ ],+ "label": "MCP tool name"+ },"$network_bluetooth": {"description": "Whether the user was on Bluetooth when the event was sent.","examples": [@@ -6336,6 +6673,11 @@],"label": "Distinct ID"},+ "duration_ms": {+ "description": "Older unprefixed variant of $mcp_duration_ms. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_duration_ms for new dashboards.",+ "label": "Duration (ms, unprefixed)",+ "type": "Numeric"+ },"email": {"description": "The email address of the user.","examples": [@@ -6386,6 +6728,10 @@"description": "Impact Click ID Data from the last time this user was seen.","label": "Latest irclid"},+ "is_error": {+ "description": "Older unprefixed variant of $mcp_is_error. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_is_error for new dashboards.",+ "label": "Is error (unprefixed)"+ },"li_fat_id": {"description": "LinkedIn First-Party Ad Tracking ID Data from the last time this user was seen.","label": "Latest li_fat_id"@@ -6394,6 +6740,64 @@"description": "Mailchimp Campaign ID Data from the last time this user was seen.","label": "Latest mc_cid"},+ "mcp_client_name": {+ "description": "Older unprefixed variant of $mcp_client_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_name for new dashboards.",+ "examples": [+ "claude-code",+ "codex-mcp-client"+ ],+ "label": "MCP client name (unprefixed)"+ },+ "mcp_client_version": {+ "description": "Older unprefixed variant of $mcp_client_version. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_version for new dashboards.",+ "label": "MCP client version (unprefixed)"+ },+ "mcp_consumer": {+ "description": "The upstream surface that initiated the MCP request. 'posthog-code' means the request came through PostHog Code; 'slack' means it was triggered from Slack.",+ "examples": [+ "posthog-code",+ "slack"+ ],+ "label": "MCP consumer"+ },+ "mcp_mode": {+ "description": "Which tool-registration mode the MCP server ran in for this request. 'single-exec' means the v2 wrapper that exposes one tool; the alternative exposes every tool individually.",+ "label": "MCP mode"+ },+ "mcp_oauth_client_name": {+ "description": "The OAuth client name captured during the MCP handshake, when the connection used OAuth.",+ "label": "MCP OAuth client name"+ },+ "mcp_protocol_version": {+ "description": "The MCP protocol version negotiated during initialize.",+ "label": "MCP protocol version"+ },+ "mcp_region": {+ "description": "The region the MCP server routed the request to.",+ "examples": [+ "us",+ "eu"+ ],+ "label": "MCP region"+ },+ "mcp_transport": {+ "description": "The transport the MCP client used to connect to the server.",+ "examples": [+ "stdio",+ "sse",+ "streamable_http"+ ],+ "label": "MCP transport"+ },+ "mcp_version": {+ "description": "Server-resolved MCP version. May differ from the version the client reported because of the mcp-version-2 feature flag.",+ "examples": [+ 1,+ 2+ ],+ "label": "MCP server version (internal)",+ "type": "Numeric"+ },"msclkid": {"description": "Microsoft Click ID Data from the last time this user was seen.","label": "Latest msclkid"@@ -6427,6 +6831,10 @@],"label": "Referrer application"},+ "resource_name": {+ "description": "Older unprefixed variant of $mcp_resource_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_resource_name for new dashboards.",+ "label": "Resource name (unprefixed)"+ },"revenue": {"description": "The revenue associated with the event. By default, this is in USD, but the currency property can be used to specify a different currency.","examples": [@@ -6446,6 +6854,10 @@"ignored_in_assistant": true,"label": "Token"},+ "tool_name": {+ "description": "Older unprefixed variant of $mcp_tool_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_tool_name for new dashboards.",+ "label": "Tool name (unprefixed)"+ },"ttclid": {"description": "TikTok Click ID Data from the last time this user was seen.","label": "Latest ttclid"diff --git a/posthog/taxonomy/taxonomy.py b/posthog/taxonomy/taxonomy.pyindex c08d896e517f..76bd9ff81a46 100644--- a/posthog/taxonomy/taxonomy.py+++ b/posthog/taxonomy/taxonomy.py@@ -289,6 +289,89 @@ CORE_FILTER_DEFINITIONS_BY_GROUP: dict[str, dict[str, CoreFilterDefinition]] = {"label": "Deep link opened","description": "When a user opens the mobile app via a deep link.",},+ # Events emitted by the @posthog/mcp analytics SDK. @posthog/mcp is rolled out behind a+ # feature flag (currently enabled only for some PostHog staff for internal testing). For+ # traffic where it's enabled, these events fire *alongside* the older events further down;+ # for traffic where it's not, only the older events fire. Once @posthog/mcp reaches general+ # availability the older events will be retired.+ "mcp_tool_call": {+ "label": "MCP tool call",+ "description": "Fires every time an MCP server tool is invoked. Includes the tool name, wall-clock duration, error state, and (when the client supplied a context argument) the agent's stated intent.",+ },+ "mcp_tools_list": {+ "label": "MCP tools listed",+ "description": "Fires when an MCP client requests the list of available tools. Useful for measuring discovery — i.e. whether new clients are finding the server.",+ },+ "mcp_initialize": {+ "label": "MCP initialize",+ "description": "Fires when an MCP client completes the handshake with the server. Carries the client and server name/version so you can break down usage by client.",+ },+ "mcp_resources_list": {+ "label": "MCP resources listed",+ "description": "Fires when an MCP client requests the list of available resources.",+ },+ "mcp_resource_read": {+ "label": "MCP resource read",+ "description": "Fires when an MCP resource is fetched by a client. Includes the resource name.",+ },+ "mcp_prompts_list": {+ "label": "MCP prompts listed",+ "description": "Fires when an MCP client requests the list of available prompts.",+ },+ "mcp_prompt_get": {+ "label": "MCP prompt fetched",+ "description": "Fires when an MCP prompt is fetched by a client. Includes the prompt name.",+ },+ "mcp_custom": {+ "label": "MCP custom event",+ "description": "A custom MCP analytics event emitted by a server through the SDK's custom-event API. Properties depend on what the caller passed.",+ },+ "posthog_identify": {+ "label": "MCP identify",+ "description": "Fires when an MCP session becomes associated with an identified user, or when the identity changes for an existing session. Used to attribute subsequent events to a real user instead of an anonymous session.",+ },+ # Older MCP events. Today these are the only events that fire for traffic where @posthog/mcp+ # isn't enabled yet, and they fire alongside the @posthog/mcp events for traffic where it is.+ # Not deprecated today — @posthog/mcp is still in internal testing — but slated for removal+ # once @posthog/mcp reaches general availability. They come from two sources:+ # - the mcpcat library PostHog used before @posthog/mcp existed+ # - PostHog's in-tree trackEvent path inside the MCP server+ "mcp init": {+ "label": "MCP init",+ "description": "MCP initialization event emitted by the mcpcat library. Fires for all traffic today (alongside mcp_initialize where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability; until then, filter on this event if you need coverage across all clients, or on mcp_initialize if you only want the @posthog/mcp-enabled slice.",+ },+ "mcp_mcpcat:identify": {+ "label": "MCP identify (mcpcat)",+ "description": "Identify event emitted by the mcpcat library. Fires for all traffic today (alongside posthog_identify where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ },+ "mcp_posthog:identify": {+ "label": "MCP identify (in-tree)",+ "description": "Identify event emitted by PostHog's in-tree MCP analytics path. Fires for all traffic today (alongside posthog_identify where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ },+ "mcp_tool_called": {+ "label": "MCP tool called (in-tree)",+ "description": "Tool-call event emitted by PostHog's in-tree MCP analytics path. Fires for all traffic today (alongside mcp_tool_call where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability; until then, filter on this event if you need coverage across all clients, or on mcp_tool_call if you only want the @posthog/mcp-enabled slice.",+ },+ "mcp tool call": {+ "label": "MCP tool call (mcpcat)",+ "description": "Tool-call event emitted by the mcpcat library. Fires for all traffic today (alongside mcp_tool_call where @posthog/mcp is enabled). Will be retired once @posthog/mcp reaches general availability.",+ },+ "mcp tool response": {+ "label": "MCP tool response (mcpcat)",+ "description": "Tool-response event emitted by the mcpcat library. Tool responses are also carried inline on mcp_tool_call (under $mcp_response) for @posthog/mcp-enabled traffic. Will be retired once @posthog/mcp reaches general availability.",+ },+ "mcp project switched": {+ "label": "MCP project switched",+ "description": "Fires when a user switches the active project in their MCP session.",+ },+ "mcp organization switched": {+ "label": "MCP organization switched",+ "description": "Fires when a user switches the active organization in their MCP session.",+ },+ "mcp feedback submitted": {+ "label": "MCP feedback submitted",+ "description": "Fires when a user submits feedback through the MCP server's feedback tool.",+ },},"elements": {"tag_name": {@@ -2434,6 +2517,137 @@ CORE_FILTER_DEFINITIONS_BY_GROUP: dict[str, dict[str, CoreFilterDefinition]] = {"label": "AI user prompt (LLM)","description": "The user prompt text sent to the LLM.",},+ # Core MCP properties emitted by the @posthog/mcp analytics SDK. All wire keys are+ # $mcp_*-prefixed so they don't collide with autocapture or other product properties.+ "$mcp_source": {+ "label": "MCP source",+ "description": "Constant identifier for the analytics SDK that emitted the event. Lets you separate events from different SDK versions or unrelated MCP servers.",+ "examples": ["posthog_mcp_analytics"],+ },+ "$mcp_tool_name": {+ "label": "MCP tool name",+ "description": "The name of the MCP tool that was invoked. Only present on mcp_tool_call.",+ "examples": ["execute-sql", "feature-flag-get-all"],+ },+ "$mcp_resource_name": {+ "label": "MCP resource name",+ "description": "The name of the MCP resource, prompt, or tool the event refers to.",+ },+ "$mcp_duration_ms": {+ "label": "MCP duration (ms)",+ "description": "Wall-clock duration of the MCP tool or resource call, in milliseconds.",+ "type": "Numeric",+ "examples": [42, 1280],+ },+ "$mcp_is_error": {+ "label": "MCP is error",+ "description": "Whether the MCP tool call failed. True if the tool returned an error result or threw an exception.",+ },+ "$mcp_server_name": {+ "label": "MCP server name",+ "description": "The advertised name of the MCP server that handled the request.",+ "examples": ["PostHog"],+ },+ "$mcp_server_version": {+ "label": "MCP server version",+ "description": "The advertised version of the MCP server that handled the request.",+ },+ "$mcp_client_name": {+ "label": "MCP client name",+ "description": "The MCP client that initiated the connection. Common values are coding agents (Claude Code, Codex) and chat clients (Claude desktop, Claude on web).",+ "examples": ["claude-code", "codex-mcp-client", "Anthropic/ClaudeAI"],+ },+ "$mcp_client_version": {+ "label": "MCP client version",+ "description": "The version of the MCP client that initiated the connection.",+ },+ "$mcp_intent": {+ "label": "MCP intent",+ "description": "Free-text description of why the agent is calling this tool, written by the agent itself. Comes from a context argument the client supplied at call time, or — if none was supplied — from an intentFallback the MCP server provides.",+ "examples": [+ "Listing recent error tracking issues to triage a spike in 500s.",+ "Fetching the trace referenced by the inbox signal to inspect the user message.",+ ],+ },+ "$mcp_intent_source": {+ "label": "MCP intent source",+ "description": "Where $mcp_intent came from. 'context_parameter' means the client supplied it directly on the call; 'inferred' means the MCP server derived it via its intentFallback.",+ "examples": ["context_parameter", "inferred"],+ },+ "$mcp_parameters": {+ "label": "MCP parameters",+ "description": "The arguments the client passed when invoking the tool. Large strings and sensitive keys (tokens, API keys, etc.) are redacted before capture.",+ },+ "$mcp_response": {+ "label": "MCP response",+ "description": "The response the MCP server returned. Large strings and sensitive keys are redacted before capture.",+ },+ # PostHog-specific MCP properties added by the PostHog MCP server on top of the SDK's core+ # set. They identify which deployment, transport, and consumer produced the event. The+ # @posthog/mcp SDK will continue to carry these — they're not on a deprecation path.+ "mcp_protocol_version": {+ "label": "MCP protocol version",+ "description": "The MCP protocol version negotiated during initialize.",+ },+ "mcp_transport": {+ "label": "MCP transport",+ "description": "The transport the MCP client used to connect to the server.",+ "examples": ["stdio", "sse", "streamable_http"],+ },+ "mcp_consumer": {+ "label": "MCP consumer",+ "description": "The upstream surface that initiated the MCP request. 'posthog-code' means the request came through PostHog Code; 'slack' means it was triggered from Slack.",+ "examples": ["posthog-code", "slack"],+ },+ "mcp_mode": {+ "label": "MCP mode",+ "description": "Which tool-registration mode the MCP server ran in for this request. 'single-exec' means the v2 wrapper that exposes one tool; the alternative exposes every tool individually.",+ },+ "mcp_region": {+ "label": "MCP region",+ "description": "The region the MCP server routed the request to.",+ "examples": ["us", "eu"],+ },+ "mcp_oauth_client_name": {+ "label": "MCP OAuth client name",+ "description": "The OAuth client name captured during the MCP handshake, when the connection used OAuth.",+ },+ "mcp_version": {+ "label": "MCP server version (internal)",+ "description": "Server-resolved MCP version. May differ from the version the client reported because of the mcp-version-2 feature flag.",+ "type": "Numeric",+ "examples": [1, 2],+ },+ # Unprefixed MCP properties from the older code paths (the mcpcat library and PostHog's+ # in-tree trackEvent path). They overlap with the $mcp_*-prefixed core properties above+ # and will be retired once @posthog/mcp reaches general availability — they are not yet+ # deprecated, because @posthog/mcp is still in internal testing.+ "mcp_client_name": {+ "label": "MCP client name (unprefixed)",+ "description": "Older unprefixed variant of $mcp_client_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_name for new dashboards.",+ "examples": ["claude-code", "codex-mcp-client"],+ },+ "mcp_client_version": {+ "label": "MCP client version (unprefixed)",+ "description": "Older unprefixed variant of $mcp_client_version. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_client_version for new dashboards.",+ },+ "tool_name": {+ "label": "Tool name (unprefixed)",+ "description": "Older unprefixed variant of $mcp_tool_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_tool_name for new dashboards.",+ },+ "resource_name": {+ "label": "Resource name (unprefixed)",+ "description": "Older unprefixed variant of $mcp_resource_name. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_resource_name for new dashboards.",+ },+ "duration_ms": {+ "label": "Duration (ms, unprefixed)",+ "description": "Older unprefixed variant of $mcp_duration_ms. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_duration_ms for new dashboards.",+ "type": "Numeric",+ },+ "is_error": {+ "label": "Is error (unprefixed)",+ "description": "Older unprefixed variant of $mcp_is_error. Emitted on events from the pre-@posthog/mcp code paths; prefer $mcp_is_error for new dashboards.",+ },"$csp_document_url": {"label": "Document URL","description": "The URL of the document where the violation occurred.",