Skip to main content
Glama
klever-io
by klever-io

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
MODENoServer mode (http, mcp, or public)http
PORTNoHTTP server port (only for http mode)3000
NODE_ENVNoNode environment (development or production)development
REDIS_URLNoRedis URL (only if STORAGE_TYPE=redis)
CORS_ORIGINSNoComma-separated allowed origins for public mode
STORAGE_TYPENoStorage backend (memory or redis)memory
RATE_LIMIT_APINoAPI endpoint requests/min per IP for public mode30
RATE_LIMIT_MCPNoMCP endpoint requests/min per IP for public mode60
BODY_SIZE_LIMITNoMax request body size for public mode1mb
MEMORY_MAX_SIZENoMaximum contexts for in-memory storage10000

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{}
prompts
{}
resources
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
query_contextA

Search the Klever VM knowledge base for smart contract development context. Returns structured JSON with matching entries, scores, and pagination. Use this for precise filtering by type or tags; use search_documentation for human-readable "how do I..." answers.

get_contextA

Retrieve a single knowledge base entry by its unique ID. Returns the full entry including content, metadata, tags, and related context IDs. Use this after query_context or find_similar to get complete details for a specific entry.

find_similarA

Find knowledge base entries similar to a given entry by comparing tags and content. Returns related contexts ranked by similarity score. Useful for discovering related patterns, examples, or documentation after finding one relevant entry.

get_knowledge_statsA

Get summary statistics of the Klever VM knowledge base. Returns total entry count, counts broken down by context type (code_example, best_practice, security_tip, etc.), and a sample entry title for each type. Useful for understanding what knowledge is available before querying.

enhance_with_contextA

Augment a natural-language query with relevant Klever VM knowledge base context. Extracts Klever-specific keywords, finds matching entries, and returns the original query combined with relevant code examples and documentation in markdown. Use this to enrich a user prompt before answering Klever development questions.

search_documentationA

Search Klever VM documentation and knowledge base. Returns human-readable markdown with titles, descriptions, and code snippets. Covers koperator CLI syntax (sc invoke, sc create, sc upgrade), --args type prefixes, --values payment flags, contract metadata flags, ABI decoding, and all smart contract development topics. ALWAYS use this tool first when you need to know the correct flags or argument syntax for koperator commands. Use this instead of query_context when you need formatted developer documentation.

analyze_contractA

Analyze Klever smart contract Rust source code for common issues. Checks for missing imports, missing #[klever_sc::contract] macro, missing endpoint annotations, payable handlers without call_value usage, storage mappers without #[storage_mapper], and missing event definitions. Returns findings with severity (error/warning/info) and links to relevant knowledge base entries.

get_balanceA

Get the KLV or KDA token balance for a Klever blockchain address. Returns the balance in the smallest unit (for KLV: 1 KLV = 1,000,000 units with 6 decimal places). Optionally specify an asset ID to query a specific KDA token balance instead of KLV.

get_accountA

Get full account details for a Klever blockchain address including nonce, balance, frozen balance, allowance, and permissions. Use this when you need comprehensive account state beyond just the balance.

get_asset_infoA

Get complete properties and configuration for any asset on the Klever blockchain (KLV, KFI, KDA tokens, NFT collections). Returns supply info, permissions (CanMint, CanBurn, etc.), roles, precision, and metadata. Note: string fields like ID, Name, Ticker are base64-encoded in the raw response.

query_scA

Execute a read-only query against a Klever smart contract (VM view call). Returns the contract function result as base64-encoded return data. Arguments must be base64-encoded. Use this to read contract state without modifying it.

get_transactionA

Get transaction details by hash from the Klever blockchain. Returns sender, receiver, status, block info, contracts, and receipts. Uses the API proxy for indexed data.

get_blockA

Get block information from the Klever blockchain by nonce (block number). If no nonce is provided, returns the latest block. Returns hash, timestamp, proposer, number of transactions, and other block metadata.

list_validatorsA

List active validators on the Klever blockchain network. Returns validator addresses, names, commission rates, delegation info, and staking amounts.

send_transferA

Build an unsigned KLV or KDA token transfer transaction on the Klever blockchain. Returns the unsigned transaction data and hash for client-side signing. The MCP server NEVER handles private keys — signing must be done externally.

deploy_scA

Build an unsigned smart contract deployment transaction for the Klever blockchain. Provide either wasmPath (preferred — reads the file server-side) or wasmHex. Returns the unsigned transaction for client-side signing. The MCP server NEVER handles private keys.

invoke_scA

Build an unsigned smart contract invocation transaction on the Klever blockchain. Calls a state-changing endpoint on a deployed contract. Returns the unsigned transaction for client-side signing. For read-only calls, use query_sc instead.

freeze_klvA

Build an unsigned Freeze KLV transaction on the Klever blockchain. Freezing KLV provides energy/bandwidth for network operations and enables staking rewards. Returns the unsigned transaction for client-side signing.

add_contextA

Add a new knowledge entry to the Klever VM context store. Use this to save code examples, best practices, security tips, or documentation that can later be retrieved via query_context or search_documentation. Returns the generated ID of the new entry.

init_klever_projectA

Scaffold a new Klever smart contract project using the SDK. Creates the Rust project structure via ksc new and generates automation scripts (build, deploy, upgrade, query, test, interact). Requires Klever SDK installed at ~/klever-sdk/. Run check_sdk_status first to verify.

add_helper_scriptsA

Add build, deploy, upgrade, query, test, and interact automation scripts to an existing Klever smart contract project. Creates a scripts/ directory with bash scripts and updates .gitignore. Run this from the project root directory (where Cargo.toml is located). This tool generates scaffold files — for koperator CLI syntax reference (correct flags like --args, --values for payments), use search_documentation instead.

check_sdk_statusA

Check whether the Klever SDK is installed and report the status of each component. Returns JSON with installation state and versions for: ksc (smart contract compiler), koperator (blockchain CLI), VM library (libvmexeccapi), and wallet key file. Run this before init_klever_project or install_klever_sdk to verify prerequisites.

install_klever_sdkA

Download and install Klever SDK tools to ~/klever-sdk/. Fetches the latest versions from the Klever CDN, installs binaries, and downloads required VM library dependencies. Supports macOS (arm64/amd64) and Linux. Run check_sdk_status first to see what is already installed.

Prompts

Interactive templates invoked by user choice

NameDescription
create_smart_contractGuided workflow to create a complete Klever smart contract
add_featureAdd a feature to an existing Klever smart contract
debug_errorDiagnose and fix a Klever smart contract compiler or runtime error
review_contractComprehensive security and quality review of a Klever smart contract

Resources

Contextual data attached and managed by the client

NameDescription
Klever Knowledge Base IndexOverview of all knowledge categories with entry counts and descriptions

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/klever-io/mcp-klever-vm'

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