Skip to main content
Glama
vuluu2k

WebCake Storefront MCP

by vuluu2k

debug_function

Run JavaScript functions in debug mode to view execution results and console logs without deploying. Validate storefront code before publishing.

Instructions

Run JS code in debug mode (without deploying). Returns execution result and console logs

Input Schema

NameRequiredDescriptionDefault
paramsNoTest parameters
contentYesJS code to debug
function_nameYesFunction name to run

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.31.8

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare readOnlyHint=false, which is a thin signal, so the description carries most of the burden. It usefully discloses that nothing is deployed and that execution result plus console logs are returned, but says nothing about execution side effects, timeouts, or permissions.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short clauses, zero filler, with the core action and the key constraint front-loaded. Every word earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema, and the description does briefly cover the return values (execution result and console logs). Parameters are fully documented in the schema, so the only minor gap is the lack of any note on execution semantics or failure behavior.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% with three well-documented parameters (content, function_name, params), so the schema does the heavy lifting. The description adds no additional meaning about how content and function_name relate or how params are passed.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Run JS code'), plus a scoping qualifier ('in debug mode, without deploying') and the return content. It is clear what the tool does, though it never names the closely related sibling run_function, so differentiation has to be inferred from 'without deploying'.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The parenthetical '(without deploying)' implies this is the safe, non-deploying counterpart to run_function, which is useful implied guidance. However, there is no explicit 'use this when.../use X instead' statement, so the agent must infer the routing rule.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools