Skip to content

[BUG] Cannot get any MCP tool calls working at all in Claude Code, despite them working in Claude Desktop #467

@SamFold

Description

@SamFold

Environment

  • Platform (select one):
    • [ X] Anthropic API
    • AWS Bedrock
    • Google Vertex AI
    • Other:
  • Claude CLI version: 0.2.39
  • Operating System: Mac OS 15.3.1
  • Terminal: iTerm2

Bug Description

I have tools for say Google Searches and Web Scraping which both work fine in Claude Desktop app.

I then added these tools to Claude Code using claude mcp add-from-claude-desktop.

I see those servers as connected when I run Claude Code. E.g. google-search "connected"

However, when I try and get claude code to run these tools I always get the same error no matter my prompt:

API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"tools.11.custom.name: String should match pattern '^[a-zA-Z0-9_-]{1,64}$'"}}

Steps to Reproduce

  1. Add a tool to local Claude desktop app. E.g. https://github.com/adenot/mcp-google-search
  2. Confirm tool works in Claude desktop
  3. Add tool to Claude Code and try and make it work.

Expected Behavior

I expect Claude Code to run the Google Search

Actual Behavior

Claude Code produced the folowing error:
⎿  API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"tools.11.custom.name: String should match pattern '^[a-zA-Z0-9_-]{1,64}$'"}}

Additional Context

No other context.

Image

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions