Skip to main content
Glama

contract_deploy

Deploy a smart contract from a KMS wallet and receive the contract address synchronously before transaction confirmation.

Instructions

Deploy a smart contract from a KMS wallet (signs a contract-creation tx with to: null + data: bytecode). The bytecode is full creation calldata — creation bytecode + ABI-encoded constructor args, concatenated client-side (run402 does NOT compile Solidity). Returns the deterministic CREATE address synchronously in contract_address — known before confirmation, no polling needed to know where the contract lives. Same pricing as contract_call: chain gas at-cost + $0.000005 KMS sign fee.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
project_idYesThe project ID
wallet_idYesThe KMS contract wallet ID (cwlt_...) that will sign + own the new contract
chainYesEVM chain (must match the wallet's chain)
bytecodeYesFull creation calldata as 0x-prefixed hex (creation bytecode + ABI-encoded constructor args, concatenated client-side). Non-empty, even-length, ≤ 128 KB. run402 does NOT compile Solidity.
valueNoOptional native-token value in wei to attach to the deploy (decimal string)
idempotency_keyNoOptional idempotency key — same key + same bytecode returns same call_id without re-broadcasting
Behavior4/5

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

With no annotations, the description fully discloses key behaviors: the signing process, synchronous return of deterministic CREATE address, and pricing details ('chain gas at-cost + $0.000005 KMS sign fee'). It does not cover all edge cases (e.g., insufficient funds) but provides significant transparency.

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?

The description is a single, well-structured paragraph of four sentences. Each sentence adds essential information: purpose, bytecode details, return behavior, pricing. There is no redundancy or waste.

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 the complexity of deploying a smart contract and the absence of an output schema or annotations, the description covers key aspects: how to prepare bytecode, synchronous address return, and pricing. It could mention error scenarios but is otherwise complete.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3. The description adds value beyond the schema by explaining the bytecode composition (creation bytecode + ABI-encoded constructor args concatenated client-side) and the idempotency key behavior, enhancing understanding.

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's purpose: 'Deploy a smart contract from a KMS wallet.' It specifies the action (deploy), the resource (smart contract), and the mechanism (signs a contract-creation tx). This distinguishes it from siblings like contract_call, which call existing contracts.

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

Usage Guidelines4/5

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

The description provides clear context for when to use the tool, including required client-side preparation of bytecode ('run402 does NOT compile Solidity'). It does not explicitly state when not to use it or provide alternatives, but the context is sufficient.

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/kychee-com/run402'

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