Starknet MCP Server

SSE

by MCP-Mirror

241 downloads Not rated yet MIT license

About

A comprehensive Model Context Protocol (MCP) server for the Starknet blockchain. It enables AI agents to query blockchain data, manage wallets, and interact with smart contracts using natural language, serving developers and AI assistants like Claude and GPT.

Details

Transport
SSE
License
MIT license

Explore

- Starknet Integration: Full Starknet blockchain integration using Starknet.js
- Network Support: Supports both Mainnet and Sepolia testnet
- StarknetID Integration: Resolution of Starknet IDs to addresses and vice versa
- Native Token Support: Support for both ETH and STRK native tokens
- Smart Contract Interaction: Call and query Starknet smart contracts
- Dual Transport: Run as stdio server or HTTP server for different integration needs
- AI-Ready: Designed to be used with Claude, GPT, and other AI assistants

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name Starknet MCP Server
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

- Bun 1.0.0 or higher (recommended)
- Node.js 18.0.0 or higher

To install starknet-mcp-server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @mcpdotdirect/starknet-mcp-server --client claude

The easiest way to get started is to use npx to run the package directly:


npx @mcpdotdirect/starknet-mcp-server

npx @mcpdotdirect/starknet-mcp-server http

This will automatically download and run the latest version without needing to install it first.

If you plan to use it frequently, you can install it globally:


npm install -g @mcpdotdirect/starknet-mcp-server

bash

If you want to run from source or develop locally:


npm install

The server uses the following default configuration:

- Default Network: Mainnet
- Server Port: 3000 (HTTP mode)
- Server Host: 0.0.0.0 (accessible from any network interface)

These values are hardcoded in the application. If you need to modify them, you can edit the following files:

- For network configuration: src/core/chains.ts
- For server configuration: src/server/http-server.ts

You can run the Starknet MCP Server in two modes:

bash

// Example of using the MCP client to check an ETH balance using Starknet ID
const mcp = new McpClient("http://localhost:3000");

const result = await mcp.invokeTool("get_starknet_eth_balance", {
address: "vitalik.stark", // Starknet ID instead of address
network: "mainnet"
});

console.log(result);
// {
// wei: "1000000000000000000",
// ether: "1.0"
// }

When using this server with AI assistants like Claude or GPT:

1. Configure your AI assistant to use this MCP server
2. The assistant can then use tools to interact with Starknet
3. Example queries:
- "What's the ETH balance of address 0x04d07e40e93398ed3c76981e449d3446f7c4e52aac5b3e8a37d7b0ca30845a5d?"
- "Look up the Starknet ID for address 0x04d07e40e93398ed3c76981e449d3446f7c4e52aac5b3e8a37d7b0ca30845a5d"
- "What's in the latest block on Starknet mainnet?"
- "Get information about transaction 0x7e3a33ab42f2e24184763563b7b8482b53e3b89831ebc3eacf29d4d11f5198"
- "Resolve the Starknet ID vitalik.stark to an address"

get_starknet_chain_info

Get information about a Starknet network

get_supported_starknet_networks

Get a list of supported Starknet networks

get_starknet_eth_balance

Get the ETH balance for a Starknet address or Starknet ID

get_starknet_token_balance

Get the balance of any token for an address

get_starknet_strk_balance

Get the STRK token balance for an address

get_starknet_native_balances

Get all native token balances (ETH and STRK) for an address

resolve_starknet_name

Get the Starknet ID for an address

resolve_starknet_address

Get the address for a Starknet ID

get_starknet_profile

Get the full Starknet ID profile for an address

validate_starknet_domain

Check if a string is a valid Starknet ID

get_starknet_block

Get information about a specific block

get_starknet_block_transactions

Get transactions in a specific block

get_starknet_transaction

Get details about a transaction

get_starknet_transaction_receipt

Get transaction receipt

check_starknet_transaction_status

Check if a transaction is confirmed

call_starknet_contract

Call a read-only function on a contract

get_starknet_contract_class

Get the class (ABI and other information) of a contract

execute_starknet_contract

Execute a contract call (write operation)

get_starknet_token_info

Get information about a token

get_starknet_token_supply

Get the total supply of a token

check_starknet_nft_ownership

Check if an address owns a specific NFT

get_starknet_nft_balance

Get the number of NFTs owned by an address

transfer_starknet_eth

Transfer ETH from one account to another (amounts in human-readable format)

transfer_starknet_strk

Transfer STRK from one account to another (amounts in human-readable format)

transfer_starknet_token

Transfer ERC20 tokens from one account to another (amounts in human-readable format)

This server implements the following MCP tools:

- get_starknet_chain_info: Get information about a Starknet network
- get_supported_starknet_networks: Get a list of supported Starknet networks

- get_starknet_eth_balance: Get the ETH balance for a Starknet address or Starknet ID
- get_starknet_token_balance: Get the balance of any token for an address
- get_starknet_strk_balance: Get the STRK token balance for an address
- get_starknet_native_balances: Get all native token balances (ETH and STRK) for an address

- resolve_starknet_name: Get the Starknet ID for an address
- resolve_starknet_address: Get the address for a Starknet ID
- get_starknet_profile: Get the full Starknet ID profile for an address
- validate_starknet_domain: Check if a string is a valid Starknet ID

- get_starknet_block: Get information about a specific block
- get_starknet_block_transactions: Get transactions in a specific block

- get_starknet_transaction: Get details about a transaction
- get_starknet_transaction_receipt: Get transaction receipt
- check_starknet_transaction_status: Check if a transaction is confirmed

- call_starknet_contract: Call a read-only function on a contract
- get_starknet_contract_class: Get the class (ABI and other information) of a contract
- execute_starknet_contract: Execute a contract call (write operation)

- get_starknet_token_info: Get information about a token
- get_starknet_token_supply: Get the total supply of a token
- check_starknet_nft_ownership: Check if an address owns a specific NFT
- get_starknet_nft_balance: Get the number of NFTs owned by an address

- transfer_starknet_eth: Transfer ETH from one account to another (amounts in human-readable format)
- transfer_starknet_strk: Transfer STRK from one account to another (amounts in human-readable format)
- transfer_starknet_token: Transfer ERC20 tokens from one account to another (amounts in human-readable format)

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "starknet mcp server": {
            "mcpdotdirect_starknet-mcp-server": {
                "command": "npx",
                "args": [
                    "-y",
                    "@smithery/cli",
                    "install",
                    "@mcpdotdirect/starknet-mcp-server",
                    "--client",
                    "claude"
                ]
            }
        }
    }
}

McpServers

{
    "mcpdotdirect_starknet-mcp-server": {
        "command": "npx",
        "args": [
            "-y",
            "@smithery/cli",
            "install",
            "@mcpdotdirect/starknet-mcp-server",
            "--client",
            "claude"
        ]
    }
}

smithery badge
License: MIT
TypeScript
MCP
Starknet.js

A comprehensive Model Context Protocol (MCP) server for the Starknet blockchain. This server provides AI agents with the ability to interact with Starknet networks, query blockchain data, manage wallets, and interact with smart contracts.

<a href="https://glama.ai/mcp/servers/@mcpdotdirect/starknet-mcp-server">
Starknet Server MCP server
</a>

📋 Contents

- Overview
- Features
- Supported Networks
- Prerequisites
- Installation
- Server Configuration
- Usage
- API Reference
- Tools
- Resources
- Prompts
- Usage with AI Assistants
- Security Considerations
- Project Structure
- Development Conventions
- Documentation
- License

🔭 Overview

The Starknet MCP Server leverages the Model Context Protocol to provide blockchain services to AI agents. It offers a comprehensive interface to the Starknet ecosystem, powering AI assistants with the ability to interact with Starknet blockchain data and operations through natural language.

Key capabilities include:
- Reading blockchain state (balances, transactions, blocks)
- Interacting with Cairo smart contracts
- Transferring tokens (ETH, STRK, and other ERC20 tokens)
- Working with NFTs and token metadata
- Resolving StarknetID domains (similar to ENS for Ethereum)
- Making both read and write operations with proper transaction handling

All services are exposed through a consistent interface of MCP tools and resources, making it easy for AI agents to discover and use Starknet blockchain functionality. Every tool that accepts Starknet addresses also supports StarknetID, automatically resolving human-readable identities to addresses behind the scenes.

✨ Features

- Starknet Integration: Full Starknet blockchain integration using Starknet.js
- Network Support: Supports both Mainnet and Sepolia testnet
- StarknetID Integration: Resolution of Starknet IDs to addresses and vice versa
- Native Token Support: Support for both ETH and STRK native tokens
- Smart Contract Interaction: Call and query Starknet smart contracts
- Dual Transport: Run as stdio server or HTTP server for different integration needs
- AI-Ready: Designed to be used with Claude, GPT, and other AI assistants

Blockchain Information

- Query chain information (chain ID, latest block) - Explore block details and transactions - View transaction receipts and status - Get address information and contract data

Native Token Operations

- Get ETH and STRK balances for any address - Transfer ETH and STRK between accounts - View combined native token balances

Token Operations

- Get ERC20 token balances and information - Transfer ERC20 tokens - View token supply and metadata - Check token ownership

NFT Operations

- Check NFT ownership by token ID - Get NFT collection information - View NFT balances for addresses

Smart Contract Interaction

- Call read-only contract functions - Execute contract writes with transaction confirmation - Get contract storage information - View ABIs and contract class information

StarknetID

- Resolve Starknet addresses to Starknet IDs - Resolve Starknet IDs to addresses - Get complete Starknet ID profiles with verification data - Validate Starknet domains

🔧 Networks Supported

The server supports the following Starknet networks:

- Mainnet: The primary Starknet production network
- Sepolia: Starknet's testnet on Ethereum's Sepolia

🛠️ Prerequisites

- Bun 1.0.0 or higher (recommended)
- Node.js 18.0.0 or higher

📦 Installation

Installing via Smithery

To install starknet-mcp-server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @mcpdotdirect/starknet-mcp-server --client claude

Option 1: Use without installation (npx)

The easiest way to get started is to use npx to run the package directly:

```bash

No reviews yet — be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.