Cairo Coder

Cairo Coder

The most powerful open-source Cairo code generator.

Category
Visit Server

Tools

assist_with_cairo

Provides assistance with Cairo and Starknet development tasks through AI-powered analysis. Call this tool when the user's request involves **writing, refactoring, implementing from scratch, or completing specific parts (like TODOs)** of Cairo code or smart contracts. The tool analyzes the query and context against Cairo/Starknet best practices and documentation, returning helpful information to generate accurate code or explanations. This tool should also be called to get a better understanding of Starknet's ecosystem, features, and capacities.

README

<div align="center"> <img src="./cairo-grey.png" alt="Cairo Coder MCP Logo" width="300"/>

npm version npm downloads GitHub stars License: MIT </div>

Cairo Coder MCP Server

A Model Context Protocol (MCP) server for Cairo and Starknet development assistance via the Cairo Coder API.

Quick Start

Use this MCP server directly with npx:

npx -y @kasarlabs/cairo-coder-api

Configuration

Environment Variables

  • CAIRO_CODER_API_KEY: Your Cairo Coder API key (required)

Claude Desktop Setup

Add this configuration to your claude_desktop_config.json:

{
  "mcpServers": {
    "cairo-coder": {
      "command": "npx",
      "args": ["-y", "@kasarlabs/cairo-coder-api"],
      "env": {
        "CAIRO_CODER_API_KEY": "your-api-key-here"
      }
    }
  }
}

Available Tools

assist_with_cairo

Get help with Cairo and Starknet development tasks.

Parameters:

  • query (string, required): Your Cairo/Starknet development question
  • context (string, optional): Additional context or code snippets

Examples:

// Simple request
{
  "query": "Write a simple Cairo contract that implements a counter"
}

// With context
{
  "query": "How can I optimize this contract?",
  "context": "#[starknet::contract]\nmod Counter {\n    // existing code here\n}"
}

What You Can Do

  • Write Cairo code: Generate smart contracts and Cairo code
  • Refactor code: Improve and optimize existing code
  • Implement features: Complete TODOs and implement specific functionality
  • Learn Starknet: Get contextual information about the Starknet ecosystem
  • Best practices: Receive advice based on Cairo/Starknet documentation

Tips for Better Results

  • Use specific queries (e.g., "Using OpenZeppelin to build an ERC20" instead of just "ERC20")
  • Include relevant code snippets when working with existing code
  • Provide necessary context for more accurate responses

Development

Prerequisites

  • Node.js >= 18
  • npm or yarn

Local Installation

git clone <repository-url>
cd cairo-coder-api
npm install

Available Scripts

npm run build    # Build the project
npm run dev      # Start in development mode
npm start        # Start in production mode

License

MIT

Support

For issues and questions:

Contributing

Contributions are welcome! Please check the contribution guidelines before submitting a PR.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured