India Stack MCP
# 🇮🇳 India Stack MCP
**Give Claude, Cursor and any MCP-compatible AI assistant Indian superpowers:** IFSC lookup, pincode lookup, GSTIN / PAN / UPI ID validation and the official holiday calendar, all in one install.
[](https://github.com/PriyuK/india-stack-mcp/actions/workflows/ci.yml)
[](https://www.npmjs.com/package/india-stack-mcp)
[](LICENSE)
```
You: Which branch is IFSC SBIN0000691, and does it support UPI?
Claude: That's State Bank of India, New Delhi Main Branch, 11 Sansad Marg,
New Delhi 110001. It supports UPI, NEFT, RTGS and IMPS.
You: Is 27AAPFU0939F1ZV a real-looking GSTIN?
Claude: Yes. The format and checksum are valid. It's registered in
Maharashtra and the embedded PAN (AAPFU0939F) belongs to a firm.
You: When's the next government holiday?
Claude: Christmas Day on 25 December 2026, then Republic Day on 26 January 2027.
```
No API keys. Validators run fully offline; IFSC and pincode use free public data.
## Tools
| Tool | What it does | Network |
|---|---|---|
| `lookup_ifsc` | Bank, branch, address, MICR, SWIFT and UPI/NEFT/RTGS/IMPS support for an IFSC code | Razorpay IFSC API |
| `lookup_pincode` | District, state and every post office for a 6-digit pincode | India Post (postalpincode.in) |
| `validate_gstin` | Format, state code, embedded PAN and **checksum** of a GST number | Offline |
| `validate_pan` | PAN format and holder type (individual, company, HUF, firm, trust, LLP…) | Offline |
| `validate_upi_id` | UPI ID format and the app/bank behind the handle (`@okaxis` → Google Pay) | Offline |
| `india_holidays` | Full year list, "is this date a holiday?", or the next N holidays | Offline |
## Install
You need Node.js 18 or newer.
### Claude Desktop
Add this to `claude_desktop_config.json` (Settings → Developer → Edit Config):
```json
{
"mcpServers": {
"india-stack": {
"command": "npx",
"args": ["-y", "india-stack-mcp"]
}
}
}
```
### Claude Code
```bash
claude mcp add india-stack -- npx -y india-stack-mcp
```
### Cursor
Add to `~/.cursor/mcp.json`:
```json
{
"mcpServers": {
"india-stack": { "command": "npx", "args": ["-y", "india-stack-mcp"] }
}
}
```
### VS Code, Windsurf, Cline and others
Any client that supports stdio MCP servers works with the command `npx -y india-stack-mcp`.
## What it does *not* do
Being honest about limits:
- **Validation is not verification.** A GSTIN with a valid checksum may still be cancelled; a well-formed PAN or UPI ID may not exist. Use official portals for KYC.
- **Holidays** are the DoPT gazetted list for Central Government offices in Delhi/New Delhi (2026 and 2027). State, bank and restricted holidays differ.
- IFSC and pincode data come from third-party public services and can lag behind real changes.
## Develop
```bash
git clone https://github.com/PriyuK/india-stack-mcp.git
cd india-stack-mcp
npm install
npm test # offline tests
npm run test:live # also hits the IFSC and pincode APIs
npm run build
npx @modelcontextprotocol/inspector node dist/index.js # try it in a browser
```
## Roadmap
Ideas welcome. Good first issues:
- [ ] State-wise and bank holidays (RBI list)
- [ ] Vehicle registration number parser (`KA01AB1234` → Karnataka, Bengaluru Central RTO)
- [ ] Aadhaar format + Verhoeff checksum (format only, no lookups)
- [ ] Amount in words in the Indian system (₹1,25,000 → "One lakh twenty-five thousand")
- [ ] HSN / SAC code lookup for GST
- [ ] Indian phone number parser (operator circle)
## Contributing
PRs are very welcome; see [CONTRIBUTING.md](CONTRIBUTING.md). If this saved you time, a ⭐ helps others find it.
## Credits
- IFSC data: [razorpay/ifsc](https://github.com/razorpay/ifsc)
- Pincode data: India Post via [postalpincode.in](https://api.postalpincode.in)
- Holiday lists: Department of Personnel & Training, Government of India
## License
[MIT](LICENSE)
TDQS
Scored across 6 tools
Each tool targets a clearly distinct Indian identifier or dataset: PAN, UPI ID, GSTIN, IFSC, pincode, and holidays. Although GSTIN embeds a PAN, the descriptions make the distinction explicit (format/checksum validation vs. PAN holder-type decoding), so an agent can reliably select the right tool.
Five of six tools follow a clean verb_noun snake_case pattern (validate_pan, validate_upi_id, validate_gstin, lookup_ifsc, lookup_pincode). Only india_holidays deviates with a noun-only name, a minor inconsistency that is still readable.
Six tools is well within the ideal range and each corresponds to a distinct, non-overlapping capability. Nothing feels padded or missing for a focused India Stack validation/lookup server.
The surface covers the core Indian identifiers (PAN, GSTIN, UPI, IFSC, pincode) plus holidays, with clear lifecycle coverage for validation and lookup. Minor gaps exist—no Aadhaar validation and no reverse lookups (e.g., bank/branch search by name)—but agents can work around these.