Sentry MCP search_issues fails with "OPENAI_API_KEY required" when EMBEDDED_AGENT_PROVIDER is anthropic
With @sentry/mcp-server running through Claude Desktop on macOS and EMBEDDED_AGENT_PROVIDER set to anthropic plus a valid ANTHROPIC_API_KEY, search_issues and search_events fail with "OPENAI_API_KEY environment variable is required for semantic search", even though the README says the provider supports 'openai' or 'anthropic'. Other tools like find_organizations and get_issue_details work, so the access token and connection are fine. Is this a bug in the semantic search tools, or is an OpenAI key required regardless?
Originally asked on GitHub: https://github.com/getsentry/toolkit/issues/747
4 answers
The issue was closed as completed: a maintainer said on 2026-02-07 that they had made a number of improvements around this behavior and asked the reporter to reopen if it still happened. No one in the thread confirmed the fix worked, so verify it by updating
@sentry/mcp-serverand retrying the same configuration.The reporter ran the stdio MCP server via Claude Desktop on macOS with this env block:
json{ "mcpServers": { "Sentry": { "command": "/opt/homebrew/bin/node", "args": ["/opt/homebrew/lib/node_modules/@sentry/mcp-server/dist/index.js"], "env": { "SENTRY_ACCESS_TOKEN": "<your-token>", "SENTRY_HOST": "<your-host>", "EMBEDDED_AGENT_PROVIDER": "anthropic", "ANTHROPIC_API_KEY": "<your-anthropic-key>" } } } }With that config,
search_issuesandsearch_eventsfailed immediately with "OPENAI_API_KEY environment variable is required for semantic search" whilefind_organizations,find_projects,find_releases, andget_issue_detailsall worked, so the access token and connection were fine. The maintainer asked which package version was in use, but the reporter could not provide one.General advice: run
npm update -g @sentry/mcp-serverand retry; if the error persists, reopen the issue with the package version and exact error text. Keep API keys only in your local MCP client config and do not paste full key values into issue reports.Did this work for you?What @le4ker tried on GitHub (Didn't work)
With EMBEDDED_AGENT_PROVIDER=anthropic and ANTHROPIC_API_KEY set in the Claude Desktop env block, search_issues and search_events failed immediately with the OPENAI_API_KEY required configuration error; other Sentry tools worked.
Source: https://github.com/getsentry/toolkit/issues/747 (opens external site)
Did this work for you?What @dcramer tried on GitHub (Outcome unclear)
A maintainer said they made a number of improvements around this and asked the reporter to reopen if it still happened. No specific version, config change, or workaround was given, and no one confirmed the fix.
Source: https://github.com/getsentry/toolkit/issues/747#issuecomment-3863555732 (opens external site)
Did this work for you?What @le4ker tried on GitHub (Outcome unclear)
The reporter said they did not know the installed version and would retry, reopening the issue if the problem persisted. No result was reported in the thread.
Source: https://github.com/getsentry/toolkit/issues/747#issuecomment-3868358684 (opens external site)
Did this work for you?
Related questions
- Does getsentry/toolkit support granular token scopes (read-only default + 401 upgrade)?
- How to query Sentry issues without OpenAI API calls in the official Sentry MCP server?
- Sentry MCP search_issues/search_events fail: 'Incorrect API key provided' on mcp.sentry.dev
- Sentry MCP `update_issue` ignores forever despite "until it escalates" reply
- How do I get breadcrumbs in Sentry issue details with sentry-mcp?