jazzcash-mcp
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@jazzcash-mcpCheck wallet balance for 03001234567"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
jazzcash-mcp
MCP server for the JazzCash payment gateway (Pakistan). Exposes Mobile Wallet payments, CNIC-enabled Mobile Account payments, Over-The-Counter (OTC) vouchers, status inquiry, and refunds as MCP tools. Requests are signed with JazzCash's HMAC-SHA256 secure hash, and responses are hash-verified.
Tools (5)
Tool | Type | Description |
| write | Mobile Wallet (MWALLET) payment |
| write | CNIC-enabled Mobile Account payment (MWALLET) |
| write | Over-The-Counter (OTC) voucher — returns a voucher number redeemed offline at an outlet |
| read | Transaction status inquiry ( |
| write, destructive | Refund a transaction ( |
Related MCP server: paymongo-mcp
Quick Start
{
"mcpServers": {
"jazzcash": {
"command": "npx",
"args": ["-y", "@theyahia/jazzcash-mcp"],
"env": {
"JAZZCASH_MERCHANT_ID": "<YOUR_MERCHANT_ID>",
"JAZZCASH_PASSWORD": "<YOUR_PASSWORD>",
"JAZZCASH_INTEGRITY_SALT": "<YOUR_SALT>",
"JAZZCASH_ENV": "sandbox"
}
}
}
}Environment Variables
Variable | Required | Default | Description |
| Yes | — | Merchant ID from the JazzCash portal |
| Yes | — | Merchant password |
| Yes | — | HMAC integrity salt (shared secret) |
| No |
|
|
| No | — | Full base URL override (e.g. for staging); takes precedence over |
The server fails fast at startup if the three required credentials are missing.
Amounts
All amount parameters are in PKR rupees (e.g. 5000 = 5000 PKR). The server converts to paisa
(amount × 100, no decimal point) before signing, because JazzCash's pp_Amount is expressed in the
lowest denomination. So 5000 is sent to JazzCash as pp_Amount=500000.
Sandbox vs Production
Environment | Host |
sandbox (default) |
|
production |
|
The default is sandbox for safety. Set JAZZCASH_ENV=production (or a full JAZZCASH_BASE_URL) to go live.
Verify endpoints against your merchant portal. JazzCash exposes the same operation under slightly different path/version conventions depending on the merchant-account generation, and the modern token-wallet endpoint differs from the documented Payment API. The endpoint paths in
src/config.tsare best-evidence canonical values cross-checked against the official docs and multiple integrations; confirm the exact paths and whetherpp_Versionis expected against the per-merchant API URLs shown in your JazzCash merchant portal before transacting real money.
Security
Request signing — every request carries an HMAC-SHA256
pp_SecureHash(integrity salt as both the prepended prefix and the HMAC key; empty fields excluded; lowercase hex). Verified against the official worked test vector in the test suite.Response verification — responses that include a
pp_SecureHashare recomputed and compared (constant-time); a mismatch raises an error rather than returning unverified data.No secret leakage —
pp_Password/pp_SecureHashare stripped from tool output, and upstream error bodies are never echoed back to the model (only redacted to stderr).
Demo Prompts
"Create a JazzCash payment of 5000 PKR to 03001234567"
"Check the status of transaction TXN-001"
"Refund 3000 PKR for transaction TXN-001"
"Create an OTC voucher for 2000 PKR for 03001234567 (CNIC 123456)"
Removed in 2.0 (and why)
2.0.0 removed three tools that targeted JazzCash endpoints which do not exist, verified against the
official documentation and multiple independent integrations:
get_balance— JazzCash has no balance-inquiry API.redeem_voucher— voucher redemption happens offline at a JazzCash outlet, not via a merchant API.inquire_transaction— duplicatedcheck_payment_status; both now use the canonicalPaymentInquiry/Inquire.
Other breaking changes: create_mobile_account_payment now uses the real MWALLET transaction type (there
is no MA type), create_voucher now issues an OTC voucher, amounts are in rupees (auto-converted to
paisa), and txn_ref is optional (auto-generated when omitted). See CHANGELOG.md.
Development
npm install
npm run build # tsc → dist/
npm test # vitest (schema, hash test-vector, response verification, fetch mocking)
npm run dev # run from source via tsxLicense
MIT
This server cannot be installed
Maintenance
Latest Blog Posts
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/theYahia/jazzcash-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server