Skip to main content
Glama

Check HotPocket contract API usage

check_contract_api
Read-onlyIdempotent

Performs heuristic static analysis to verify a HotPocket Node.js contract uses the contract API correctly, including entry point, state persistence, and async consensus operations.

Instructions

Heuristic static check that a HotPocket Node.js contract uses the contract API correctly: an hpc.init(...) entry point, reading ctx (users / lclSeqNo), persisting ONLY through the consensused state mechanism (no arbitrary fs writes to non-state paths), handling ctx.users I/O, using ctx.lclSeqNo for time (not Date.now), and awaiting async consensus ops. Severity-rated with fix + why. Sibling to check_determinism — guidance, NOT a proof.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
sourceYesthe HotPocket contract JS/TS source to check

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
summaryNo
findingsNo
Behavior4/5

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

Annotations already indicate readOnlyHint=true and idempotentHint=true. The description adds significant context: it is a heuristic (not exhaustive), static check, outputs severity-rated results with fixes and reasoning. No contradictions; the description enriches understanding beyond annotations.

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

Conciseness4/5

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

The description is moderately concise, front-loading the core purpose and then detailing specific checks. While it lists many items, each serves to clarify scope. Could be slightly more streamlined, but overall efficient.

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?

Given that an output schema exists (not shown but indicated), the description adequately covers the tool's functionality and output nature (severity-rated with fix + why). For a static analysis tool with one parameter, the description is sufficiently complete.

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 coverage is 100% with a single parameter clearly described as 'the HotPocket contract JS/TS source to check'. The description does not add further detail or examples for the parameter, so it meets the baseline without adding extra value.

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

Purpose5/5

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

The description clearly states the tool performs a heuristic static check of HotPocket Node.js contract API usage, listing specific aspects checked (e.g., hpc.init entry point, ctx usage, state persistence). It also distinguishes itself from the sibling tool check_determinism, making the purpose unambiguous.

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 description mentions it is a sibling to check_determinism and notes it provides guidance rather than proof, implying a difference in rigor. However, it lacks explicit guidance on when to use this tool versus alternatives like recommend_pattern or check_hook_compat, leaving the agent to infer usage context.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Hugegreencandle/evernode-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server