1. Conduid
  2. Developer Tools
  3. Zerodha MCP
MCP server · Developer Tools

Zerodha MCP

Zerodha MCP with buy-stock and sell-stock tools

Unclaimed last commit a year ago devtools
41Fair

Scored 5 months ago · breakdown

About Zerodha MCP

Zerodha MCP is an MCP server published by saiabhiramjaini in the Developer Tools category: zerodha MCP with buy-stock and sell-stock tools.

The repository has 3 stars and 0 forks, with the last commit a year ago. Six months or more without a commit doesn't mean the server is broken, but check the open issues before depending on it in production.

Install

From source
git clone https://github.com/saiabhiramjaini/Zerodha-MCP

This server has no ConduID identity, so agent calls to it are not receipted. Pin the version you install and review the source before granting it credentials.

Tools (2)

buy-stockBuys the stock from zerodha trading account for the given tradingsymbol and quantity to the user. It executes a real order.

Parameters not published.

sell-stockSells the stock from zerodha trading account for the given tradingsymbol and quantity to the user. It executes a real order.

Parameters not published.

Ask AI

✦

Ask AI about Zerodha MCP

Powered by Claude · Grounded in docs

I know everything about Zerodha MCP. Ask me about installation, configuration, usage, or troubleshooting.

Security checks

Static checks derived from the repository 7 days ago. Heuristics on the source, not an audit.

  • ✓README presentThe repository ships documentation.
  • !License declaredNo license file. Legally you have no right to use it in a product.
  • !Tests presentNo tests found. Behaviour changes may go unnoticed between versions.
  • ✓Dependencies pinnedA lockfile pins dependency versions.
  • ✓No dynamic code executionSource scan found no eval, dynamic Function, or shell execution.
  • !Scoped permissionsDoesn't declare a permission scope. Assume it can do anything its process can.

README

Zerodha MCP

Zerodha MCP (Model Context Protocol) integrates with the Zerodha Kite API to provide programmatic trading capabilities via conversational tools. This project demonstrates how to build an MCP-compatible agent with tools to buy and sell stocks in real-time using the Zerodha trading platform.

Features

  • MCP server integration using @modelcontextprotocol/sdk
  • Tool to buy stocks via Zerodha
  • Tool to sell stocks via Zerodha
  • Secure access token generation
  • Modular code structure using TypeScript and Bun runtime

Project Structure

zerodha-mcp/
├── README.md
├── getAccessToken.ts       // Used to generate and test the access token
├── index.ts                // Initializes the MCP server and tools
├── package.json
├── trade.ts                // Contains buy/sell order functions
└── tsconfig.json

Getting Started

Prerequisites

  • Node.js alternative: Bun (v1.2.10 or higher)
  • A Zerodha developer account with API key and secret
  • A valid request token (refer to the video link below for guidance)

Installation

Clone the repository:

git clone https://github.com/saiabhiramjaini/Zerodha-MCP.git
cd Zerodha-MCP

Install dependencies using Bun:

bun install

Environment Setup

Create a .env file in the root directory with the following variables:

KITE_API_KEY=your_kite_api_key
KITE_API_SECRET=your_kite_api_secret
KITE_REQUEST_TOKEN=your_generated_request_token
KITE_ACCESS_TOKEN=your_generated_access_token

To learn how to get your access token, refer to this video guide

Run the MCP Server

bun run index.ts

This will start the MCP server and expose two tools:

  • buy-stock
  • sell-stock

Tools

1. buy-stock

Executes a real BUY order on Zerodha.

Inputs:

  • tradingsymbol: string (e.g., "INFY")
  • quantity: number (e.g., 10)

Returns: Confirmation with order ID or an error message.

2. sell-stock

Executes a real SELL order on Zerodha.

Inputs:

  • tradingsymbol: string
  • quantity: number

Returns: Confirmation with order ID or an error message.

Videos

Tech Stack

README fetched from the repository 7 days ago. The original is authoritative.

Questions

About Zerodha MCP

How do I install Zerodha MCP?

No package has been published for this server, so install it from source: clone the repository and follow its README.

Is Zerodha MCP safe to use with an AI agent?

Its trust score is 41 out of 100 (fair). It passes 3 of the 6 static security checks run so far; the failures are listed above. It has no ConduID identity yet, so agent calls to it are not receipted.

Is Zerodha MCP still maintained?

The last commit was a year ago. That's long enough that you should check whether the maintainer is responding to issues before depending on it.