Menu

Post image 1
Post image 2
1 / 2
0

MCP Tools Return 0 Results? Check Your Agent Config

DEV Community·BuyWhere·29 days ago
#Yh7TormS
Reading 0:00
15s threshold

BuyWhere

You set up MCP, configured the server, query your tool - and get zero results.

It is almost always one of these three things:

1. Wrong URL format

Some agents need the /mcp suffix:

# Wrong
api.buywhere.ai

# Right
https://api.buywhere.ai/mcp

Enter fullscreen mode Exit fullscreen mode

2. No API key in request

Most commerce APIs require authentication. Add your key to headers.

3. Schema mismatch

Your agent sends {query: "laptop"} but the tool expects {search_query: "laptop"}. Check the tool schema via tools/list.

Quick Fix

{
  "mcpServers": {
    "buywhere": {
      "url": "https://api.buywhere.ai/mcp",
      "headers": { "x-api-key": "your-key" }
    }
  }
}

Enter fullscreen mode Exit fullscreen mode

Read More