MCP tool call returns "Not a valid request: <uuid>" or empty success —in AI Agent Studio
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Monday
Hi all,
I'm running into inconsistent behavior with MCP tool responses in AI Agent Studio and can't identify a clear pattern. Hoping someone from the community or product team can help.
Setup:
- ServiceNow is acting as the MCP client.
- External MCP server registered in sn_mcp_server (using Streamable HTTP transport).
- Tool returns a JSON response (verified correct on the MCP server side every time).
Issue:
I'm seeing two different failure modes when calling tools, with no clear pattern.
Case 1 — Empty response with success status:
The tool returns valid JSON on my MCP server, but in sn_mcp_execution_logs the response field shows up empty:
{
"tool_execution_id": "4400fbb82bec83502cebfccdc891klds",
"response": "",
"status": "success",
"error": null
}Case 2 — "Not a valid request" message:
After modifying the tool response, the same call returns:
{
"tool_execution_id": "0778fbb82bec67502cebfdddc891bf02",
"response": "Not a valid request: f408b81f-3ee2-48a2-8dd8-93c2218afabe",
"status": "success",
"error": null
}Case 3 — Works correctly:
When I reduce the size of the tool's response payload, ServiceNow displays the actual response correctly with no other changes.
Key observations:
- My MCP server returns the correct tool result every single time (verified in server logs).
- In all failing cases, status is "success" and error is null — but the response field is either empty or contains the "Not a valid request" string instead of the actual output.
- The size of the tool response seems related (smaller responses succeed, larger ones fail), but I can't pin down a consistent threshold or pattern.
- The same tool call with identical arguments behaves differently depending on response size.
Questions:
- Has anyone else seen this empty-response or "Not a valid request" behavior with MCP tools in AI Agent Studio?
- Is there a known response size limit on the MCP client side?
- Is there a configurable property to adjust this limit?
- Is the recommended pattern to design tools with pagination/smaller payloads, or is there a fix/workaround?
Any insights, documentation, or shared experiences would be greatly appreciated.
Thanks!
