Server type
Hosted (mcp.apify.com) and local (stdio via @apify/actors-mcp-server)
MCP Client
Other: raw JSON-RPC 2.0 probes (newline-delimited over stdio, plain POSTs
over streamable HTTP), no MCP client library, so the reproduction below is
exact requests
Operating System
macOS
What happened?
tools/call with the arguments key omitted is rejected with JSON-RPC
-32602 before validation runs. The MCP spec marks
CallToolRequest.params.arguments as optional (the SDK's
CallToolRequestSchema has arguments: z.ZodOptional<...>), so omitting
the key for a tool with no required fields is spec-conformant, but every
such call fails. search-actors declares "required": [] and every field
has a default; the identical call with arguments: {} succeeds.
I reproduced this on hosted mcp.apify.com (serverInfo 0.15.4, streamable
HTTP), on the published npm 0.15.4 over stdio, and on master 4bf6ecb
over stdio. All three behave the same:
| Call |
Result |
search-actors, no arguments key |
-32602 "Missing arguments for tool" |
search-actors, arguments: {} |
ok, 5 Actors |
fetch-actor-details, no arguments key |
-32602 "Missing arguments for tool" |
fetch-actor-details, arguments: {} |
-32602 "root: must have required property 'actor'" |
The fourth row shows a secondary cost: for a tool that does have required
fields, the blanket guard masks the specific validation message that #337
standardized. With {} the client learns which property is missing; without
the key it gets the generic text plus the fetch-actor-details pointer,
which is dead advice for internal tools (that pointer is #1214).
The guard is if (!args) in src/mcp/tool_call_engine.ts:171, surfaced as
McpError(InvalidParams) in src/mcp/legacy_server.ts:469. It predates the
shared validation (git log -S traces it to #28), and both protocol
adapters run it through prepareToolCall (legacy_server.ts:426,
stateless_server.ts:213); I verified the stateless path through the unit
harness with the same result.
This is not a synthetic client shape. A stock mark3labs/mcp-go v1.0.0
client with Arguments unset sends (captured on the wire via tee):
{"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"search-actors"}}
because the field is declared with json:"arguments,omitempty", and every
such call fails with the -32602 above; with an empty map it succeeds.
(The official modelcontextprotocol/go-sdk is unaffected: its CallTool
normalizes unset arguments to {}.) On 0.15.4, four tools declare no
required fields and each fails this way: search-actors,
get-actor-run-list, get-dataset-list, get-key-value-store-list.
Steps to reproduce
- Start the server with no token:
node dist/stdio.js --tools search-actors,fetch-actor-details --telemetry-enabled false
(env APIFY_TOKEN="").
- Complete
initialize and send notifications/initialized.
- Send
{"method":"tools/call","params":{"name":"search-actors"}} (no
arguments key).
- Send the same call with
"arguments": {}.
Expected result
The two calls behave the same: an omitted arguments validates as an empty
object, so search-actors runs with its defaults, and a tool with required
fields returns the specific -32602 from the shared validation.
Actual result
Step 3 returns:
{"code":-32602,"message":"MCP error -32602: Missing arguments for tool \"search-actors\".\nPlease provide the required arguments for this tool. Check the tool's input schema using fetch-actor-details tool to see what parameters are required."}
Step 4 returns the search results (5 Actors).
Node.js version
v24.2.0
Apify MCP Server version
Hosted mcp.apify.com (serverInfo 0.15.4), published npm 0.15.4, and
master 4bf6ecb built from source
MCP server configuration
{
"command": "node",
"args": ["dist/stdio.js", "--tools", "search-actors,fetch-actor-details", "--telemetry-enabled", "false"],
"env": { "APIFY_TOKEN": "", "TELEMETRY_ENABLED": "false" }
}
Error logs
No transport or server error. The failure is the JSON-RPC error response
above.
Additional context
Defaulting an absent arguments to {} before validation would fix both
rows at once: no-required tools run, and required-field tools get the
specific validation error from #337.
AI assistance: I used Claude Code to search the codebase and to script and
run the JSON-RPC probes. I reviewed the requests, the cited source lines,
and this text myself; every result above comes from those runs.
Server type
Hosted (mcp.apify.com) and local (stdio via
@apify/actors-mcp-server)MCP Client
Other: raw JSON-RPC 2.0 probes (newline-delimited over stdio, plain POSTs
over streamable HTTP), no MCP client library, so the reproduction below is
exact requests
Operating System
macOS
What happened?
tools/callwith theargumentskey omitted is rejected with JSON-RPC-32602before validation runs. The MCP spec marksCallToolRequest.params.argumentsas optional (the SDK'sCallToolRequestSchemahasarguments: z.ZodOptional<...>), so omittingthe key for a tool with no required fields is spec-conformant, but every
such call fails.
search-actorsdeclares"required": []and every fieldhas a default; the identical call with
arguments: {}succeeds.I reproduced this on hosted
mcp.apify.com(serverInfo0.15.4, streamableHTTP), on the published npm
0.15.4over stdio, and on master4bf6ecbover stdio. All three behave the same:
search-actors, noargumentskey-32602"Missing arguments for tool"search-actors,arguments: {}fetch-actor-details, noargumentskey-32602"Missing arguments for tool"fetch-actor-details,arguments: {}-32602"root: must have required property 'actor'"The fourth row shows a secondary cost: for a tool that does have required
fields, the blanket guard masks the specific validation message that #337
standardized. With
{}the client learns which property is missing; withoutthe key it gets the generic text plus the
fetch-actor-detailspointer,which is dead advice for internal tools (that pointer is #1214).
The guard is
if (!args)insrc/mcp/tool_call_engine.ts:171, surfaced asMcpError(InvalidParams)insrc/mcp/legacy_server.ts:469. It predates theshared validation (
git log -Straces it to #28), and both protocoladapters run it through
prepareToolCall(legacy_server.ts:426,stateless_server.ts:213); I verified the stateless path through the unitharness with the same result.
This is not a synthetic client shape. A stock
mark3labs/mcp-gov1.0.0client with
Argumentsunset sends (captured on the wire viatee):because the field is declared with
json:"arguments,omitempty", and everysuch call fails with the
-32602above; with an empty map it succeeds.(The official
modelcontextprotocol/go-sdkis unaffected: itsCallToolnormalizes unset arguments to
{}.) On0.15.4, four tools declare norequired fields and each fails this way:
search-actors,get-actor-run-list,get-dataset-list,get-key-value-store-list.Steps to reproduce
node dist/stdio.js --tools search-actors,fetch-actor-details --telemetry-enabled false(env
APIFY_TOKEN="").initializeand sendnotifications/initialized.{"method":"tools/call","params":{"name":"search-actors"}}(noargumentskey)."arguments": {}.Expected result
The two calls behave the same: an omitted
argumentsvalidates as an emptyobject, so
search-actorsruns with its defaults, and a tool with requiredfields returns the specific
-32602from the shared validation.Actual result
Step 3 returns:
Step 4 returns the search results (5 Actors).
Node.js version
v24.2.0
Apify MCP Server version
Hosted
mcp.apify.com(serverInfo0.15.4), published npm0.15.4, andmaster
4bf6ecbbuilt from sourceMCP server configuration
{ "command": "node", "args": ["dist/stdio.js", "--tools", "search-actors,fetch-actor-details", "--telemetry-enabled", "false"], "env": { "APIFY_TOKEN": "", "TELEMETRY_ENABLED": "false" } }Error logs
No transport or server error. The failure is the JSON-RPC error response
above.
Additional context
Defaulting an absent
argumentsto{}before validation would fix bothrows at once: no-required tools run, and required-field tools get the
specific validation error from #337.
AI assistance: I used Claude Code to search the codebase and to script and
run the JSON-RPC probes. I reviewed the requests, the cited source lines,
and this text myself; every result above comes from those runs.