MCP tool call observability
Nobody has claimed this yet.
- Dominant language
- Clojure
- Stars
- 49.3k
- Forks
- 6.8k
- Avg merge
- 1d 13h
- Merged PRs (30d)
- 653
Description
What problem will this feature request solve?
Metabase does not record MCP tool calls in system logs or usage analytics. There is no setting to increase log verbosity further.
When an MCP session happens, this is the only thing that can get logged:
2026-06-05 19:44:26,447 DEBUG middleware.log :: POST /api/mcp 200 54ms (16 DB calls) App DB connections: 1/7 Jetty threads: 5/50 (2 idle, 0 queued) (156 total active threads) Queries in flight: 5 (0 queued) {:metabase-user-id nil}
Note that metabase-user-id is missing, so this cannot be used for audit purposes.
Describe the solution you'd like.
At a minimum, log MCP tool calls in their own logging namespace, along with the user ID. Token scopes could be nice to have in the logs
Ideally, expose MCP tool calls as part of usage analytics. Prometheus metrics could be nice to have too.
How does this feature request impact you?
Significant observability gap compared to the rest of the product
Additional information
N/A
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the POST /api/mcp entry point and compare its current middleware.log output with the requested logging, usage analytics, and Prometheus observability targets. Clarify which scope is being implemented, then verify that MCP tool calls include the user ID and that the selected audit or metrics output is observable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- clojure, prometheus
- Domain
- api, backend, observability
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Active
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100