Skip to content

Commit 0d23a92

Browse files
committed
plugging response
Signed-off-by: rakdutta <[email protected]>
1 parent b423a32 commit 0d23a92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

mcpgateway/services/tool_service.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1433,7 +1433,7 @@ async def connect_to_streamablehttp_server(server_url: str, headers: dict = head
14331433
# Reconstruct ToolResult from modified result
14341434
modified_result = post_result.modified_payload.result
14351435
if isinstance(modified_result, dict) and "content" in modified_result:
1436-
tool_result = ToolResult(content=modified_result["content"])
1436+
tool_result = ToolResult(content=modified_result["content"], structured_content=modified_result["structuredContent"] if "structuredContent" in modified_result else modified_result["structured_content"])
14371437
else:
14381438
# If result is not in expected format, convert it to text content
14391439
tool_result = ToolResult(content=[TextContent(type="text", text=str(modified_result))])

0 commit comments

Comments
 (0)