Skip to main content
Glama

CraftCI - Automated UX Craft & Billing-Safety CI Gate

craft_audit_code_snippet

Read-onlyIdempotent

Run the full 20-rule CraftCI static, UI posture, and billing-safety audit on a code snippet or file list and return score, grade, and remediations.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "code": "<code>"
    },
    "name": "craft_audit_code_snippet"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeYesSource code to audit
filenameNoVirtual file path (e.g. src/checkout.ts)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so safety is fully covered structurally. The description adds useful context the annotations don't carry: the rule count (20), the three audit domains, and the shape of the result (score, grade, remediations). It omits anything about cost, size limits, or how remediations are structured, so it is additive but not rich.

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?

A single front-loaded sentence with the verb first, the scope in the middle, and the return value last. No filler, no restatement of the tool name or title.

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?

For a two-parameter read-only analysis tool with full schema coverage and no output schema, the description supplies what the agent most needs: what is checked and what comes back. Only minor gaps remain, such as input size expectations and how to interpret grade versus score.

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%, so both parameters are already documented, making 3 the baseline. The one added signal is the phrase 'code snippet or file list,' which suggests multi-file input even though the schema accepts only a single `code` string plus one `filename`; that is mildly ambiguous rather than clarifying.

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 (run audit) and resource (code snippet), plus the scope (20-rule CraftCI static, UI posture, and billing-safety checks) and the return value (score, grade, remediations). This is far more specific than the name alone, but it never names or contrasts the sibling tools such as craft_verify_billing_safety, which overlaps on the billing-safety domain.

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

Usage Guidelines2/5

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

There is no when-to-use, when-not-to-use, or alternative-tool guidance. An agent reading this knows what the tool does but not whether to reach for it instead of craft_verify_billing_safety or craft_generate_ci_gate when the intent is billing safety or gate creation.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.