Skip to main content
Glama

generate_contract

Read-only

Genera codigo Solidity seguro para smart contracts usando OpenZeppelin. Soporta NFTs, dynamic NFTs, tokens, marketplaces y DAOs.

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": {
      "type": "<type>",
      "name": "<name>"
    },
    "name": "generate_contract"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesNombre del contrato
typeYesTipo de contrato: nft, dynamic_nft, token, marketplace, dao

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=true, destructiveHint=false and openWorldHint=true, so safety is covered. The description adds that output is OpenZeppelin-based and security-oriented, which is useful, but it never says what the result looks like (raw source text vs. file), whether anything is persisted, or any limits on the generated code.

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?

Two short sentences, front-loaded with the core action and technology. The second sentence duplicates the enum already present in the schema, a minor redundancy, but nothing is padded.

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

Completeness3/5

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

A simple two-parameter tool, but with no output schema the description should say what is returned (Solidity source, contract skeleton, deployment guidance) and it does not. What an agent needs to call it is present; what to expect back is not.

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%: both 'name' and 'type' are documented, and the enum fully enumerates the five contract types. The description's type list merely repeats the enum, adding no format, naming-convention, or validation detail beyond the schema, so baseline 3 applies.

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 artifact: generates secure Solidity smart-contract code using OpenZeppelin, and enumerates supported contract types (NFTs, dynamic NFTs, tokens, marketplaces, DAOs). An agent can immediately tell this is a code-generation tool, and no sibling in the list covers this function, so further differentiation isn't needed.

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 supported contract types imply when the tool applies, but there is no explicit guidance on prerequisites, when not to use it, or how it relates to siblings like describe_nft or agent_check. Usage is inferable rather than stated.

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.