gst-mcp
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
gst-mcp
A Model Context Protocol (MCP) server for Indian GSTIN data. It lets Claude Code, Claude Desktop, Cline, and any other MCP client validate and look up Indian GST Identification Numbers (GSTINs).
A GSTIN is the 15-character tax ID used for India's Goods and Services Tax — e.g. 27AAACR5055K1Z7. This server fills a real gap: there are few MCP servers for Indian data, and GSTIN verification is high-intent for AI coding and research agents.
What it does
Three tools:
Tool | Description | Needs API key? |
| Pure local format + checksum validation. Works offline, no key. | No |
| Live lookup: legal name, registration status, tax jurisdiction, FSSAI license, and registered plant addresses. | Yes ( |
| Validate and resolve many GSTINs in a single call. | Yes ( |
validate_gstin is fully offline — it checks the GSTIN structure and its modulus-36 check digit with no network call, so it always works. gst_lookup and gst_bulk fetch live registration data from gstinapi.com.
Related MCP server: gst-validator-mcp
Quick start
npm install
npm startThat starts the server on stdio (the default transport, recommended for local use). Point your MCP client at it:
{
"mcpServers": {
"gst": {
"command": "node",
"args": ["C:/Users/Aditya Shah/Desktop/Code/gst-mcp/server.js"]
}
}
}Tip: on Windows, write the absolute path with forward slashes (
C:/...) or quote it.
Using it in Claude Code / Claude Desktop
Once connected, you can ask things like:
"Is
27AAACR5055K1Z7a valid GSTIN?" → usesvalidate_gstin"What's the legal name and jurisdiction for
29AAACI1195H1ZI?" → usesgst_lookup
Live data (gst_lookup / gst_bulk)
Live lookups need a free GSTINAPI_KEY from gstinapi.com (free tier: 75 lookups/day, no credit card).
Get a key at https://gstinapi.com.
Create a
.envfile in this folder:cp .env.example .envEdit
.envand paste your key:GSTINAPI_KEY=your-key-hereRestart the server. Without a key,
validate_gstinstill works, butgst_lookupandgst_bulkreturn a clear "key not set" error.
Examples
validate_gstin
{ "name": "validate_gstin", "arguments": { "gstin": "27AAACR5055K1Z7" } }{
"valid": true,
"parsed": {
"gstin": "27AAACR5055K1Z7",
"stateCode": "27",
"stateName": "Maharashtra",
"pan": "AAACR5055K",
"entityCode": "1",
"checkChar": "7"
}
}The validator is strict: it rejects wrong lengths, non-alphanumeric input, unissued state codes (e.g. 00), a 0 entity code, a non-Z reserved position, and a bad check digit. It also normalizes input — lowercase and punctuation like 27-AAACR-5055K1Z7 are accepted.
gst_lookup
{ "name": "gst_lookup", "arguments": { "gstin": "29AAACI1195H1ZI" } }Returns the taxpayer record from gstinapi.com: legal name, status, jurisdiction, FSSAI license number, and registered addresses.
gst_bulk
{ "name": "gst_bulk", "arguments": { "gstins": ["27AAACR5055K1Z7", "29AAACI1195H1ZI"] } }Validates and resolves each GSTIN, returning per-GSTIN results.
How the validator works
A GSTIN has the structure SS AAAAA9999Z C:
SS State code (two digits, 01–38, plus 96/97/99)
AAAAA5 digits
9999 4 digits
Z reserved position, always the letter "Z"
C modulus-36 check digitState code — mapped to a state name using the authoritative GSTIN state-code table (the same table shipped in the
@dlminds/gstin-apipackage). Codes96/97/99are non-geographic (foreign territory / UT / centre jurisdiction).PAN — characters 3–12 must be 5 letters, 4 digits, 1 letter.
Check digit — computed with the official modulus-36 Luhn variant. See https://gstinapi.com/blog/gstin-checksum-algorithm.
Development
npm test # 15 unit tests for the validator
npm run verify # format-check script (also runs the validator cases)
npm start # run the MCP server on stdioThe tests cover format rules, the check-digit algorithm, lowercase/punctuation normalization, and the state-code map.
Project layout
gst-mcp/
├── server.js # MCP server: tool handlers + transport
├── lib/
│ └── gstin.js # Offline validation + live lookup
├── scripts/
│ ├── test.mjs # Unit tests (npm test)
│ ├── verify.mjs # Format checks (npm run verify)
│ └── boot-check.mjs # Boot probe (optional)
├── .env.example # Env vars (copy to .env for live lookups)
└── package.jsonData source & licensing
Live data is provided by gstinapi.com under its free tier. The offline validator uses the official GSTIN state-code table and checksum algorithm. This project is licensed MIT.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Validate Indian GSTINs locally (Verhoeff), extract PAN, identify issuing state.
Validate IBAN, BIC, VAT, national IDs, phones, postal codes offline; 240+ identifiers.
PDF tools + invoice extraction, bank statement parsing, GST reconciliation & GSTIN validation.
Validate EU/UK VAT numbers, Australian ABNs, NZ NZBNs and other tax IDs, one at a time or in bulk.
Related MCP Servers
- AlicenseAqualityAmaintenanceAn offline-first MCP server for Indian financial, tax, and government APIs, providing tools for identity validation (PAN, Aadhaar, GSTIN), tax calculations (Income Tax, TDS, GST), and master data lookups (IFSC, Pincode, HSN/SAC) with zero authentication required.7688MIT
- AlicenseNot gradedqualityDmaintenanceValidates Indian GSTIN numbers with structural checks, embedded PAN extraction, state-code lookup, and mod-36 check character validation, all via local compute.MIT
- AlicenseAqualityCmaintenanceEnables live GSTIN verification, GST return and compliance history lookup, HSN/SAC code searches, and MCA company registry queries through MCP clients.1052 npmMIT
- AlicenseAqualityBmaintenanceEnables agents to search and look up companies in a local mirror of India's MCA master data, decode CINs offline, and validate GSTIN structure and checksums. Every field carries provenance and explicitly flags missing or stale data instead of fabricating it.41MIT