format_mcp_request
Format a complete MCP request with proper JSON escaping
This record as markdown: /tools/caravanglory-cocos-mcp-server/format-mcp-request.md
What format_mcp_request does on Cocos
AI agents call format_mcp_request as a supporting operation in Cocos workflows.
Why format_mcp_request is rated Low
This tool appears to format/prepare an MCP request with JSON escaping - it's a utility/helper function that structures data rather than reading, writing, executing, or destructively modifying anything. It doesn't retrieve data, create/modify persistent state, run code, delete data, or move money. It's purely a formatting/serialization utility.
From the tool's definition Format a complete MCP request with proper JSON escaping
Attacks that exploit this kind of access
The rule that runs format_mcp_request safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Cocos, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For format_mcp_request, this is the rule to start with:
format_mcp_request gets a rate cap, and everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Cocos, apply this rule, and every format_mcp_request call is checked against it from then on.
Questions about format_mcp_request
Format a complete MCP request with proper JSON escaping. It is categorised as a Other tool in the Cocos MCP Server, which means it performs auxiliary operations.
Register the Cocos MCP server in PolicyLayer and add a rule for format_mcp_request: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Cocos. Nothing to install.
format_mcp_request is a Other tool with low risk. Read-only tools are generally safe to allow by default.
Yes. Add a rate_limit block to the format_mcp_request rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for format_mcp_request. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
format_mcp_request is provided by the Cocos MCP server (caravanglory/cocos-mcp-server). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Cocos, and thousands of servers like it.
This server
Across the catalogue