VietQR MCP Toolkit
# VietQR MCP Toolkit (`vietqr-mcp-toolkit`)
**Zero-dependency Python 3.10+ Model Context Protocol (MCP) Server & CLI** for generating **Vietnam Napas247 VietQR payment links** and **print-ready A4 HTML freelance/agency invoices** directly from AI agents (Claude Desktop, Cursor, Windsurf, Antigravity) or terminal scripts.
- **Web Version (No Install Required):** [Free Live VietQR & 5 Solopreneur Tools](https://tranhoangtu-it.github.io/kiemtien247-store/tools/index.html)
- **Full Automation & Commercial White-Label Suite:** [KiemTien247 Digital Store](https://tranhoangtu-it.github.io/kiemtien247-store/)
---
## Features / Tính năng nổi bật
- **0 External Dependencies:** Pure Python 3.10+ standard library (`json`, `urllib`, `argparse`, `html`). Runs instantly with `python vietqr_mcp.py`.
- **20+ Supported Napas247 Banks:** `VCB`, `MB`, `TCB`, `ACB`, `CTG` (VietinBank), `BIDV`, `VPB`, `TPB`, `STB`, `HDB`, `VIB`, `SHB`, `MSB`, `OCB`, `SEAB`, `VBA`, and more.
- **MCP JSON-RPC 2.0 Stdio Server:** Exposes 3 tools to AI coding assistants & agent workflows:
1. `generate_vietqr_payment_url` — Creates Napas247 VietQR image URL + Markdown checkout snippet.
2. `generate_freelance_invoice_html` — Produces print-to-PDF A4 HTML invoices with auto-calculated totals and an embedded VietQR payment block.
3. `list_supported_vietnam_banks` — Lists bank shorthands and 6-digit Napas BINs.
---
## Quick Start (CLI & MCP)
### 1. Verify Locally (`--self-test`)
```bash
git clone https://github.com/tranhoangtu-it/vietqr-mcp-toolkit.git
cd vietqr-mcp-toolkit
python vietqr_mcp.py --self-test
```
### 2. Run as CLI
```bash
# Generate a VietQR payment link
python vietqr_mcp.py qr --bank VCB --account 9946611993 --amount 484500 --memo "KT247 PRO"
# Generate a printable A4 HTML invoice with embedded VietQR
python vietqr_mcp.py invoice --client "Acme Studio" --items "[{\"description\":\"AI Workflow Setup\",\"qty\":1,\"unit_price_usd\":49}]" --bank VCB --account 9946611993 --out invoice.html
```
### 3. Connect to Claude Desktop / Cursor / Windsurf (`mcpServers`)
Add this block to your MCP client configuration file:
```json
{
"mcpServers": {
"vietqr-toolkit": {
"command": "python",
"args": ["/path/to/vietqr-mcp-toolkit/vietqr_mcp.py"]
}
}
}
```
---
## Commercial Pro License, Custom Setup & Sponsorship
The core CLI and MCP server are MIT-licensed. For founders, agencies, and solopreneurs who want ready-to-sell commercial systems:
| Package | Price | Includes | Instant Access |
| :--- | :--- | :--- | :--- |
| **AI Solo Starter Vault** | **$19** | 50+ Mega-Prompts + 5 Web Tools Pack | [View Offer](https://tranhoangtu-it.github.io/kiemtien247-store/products/hero-ai-solo-starter-vault.html) |
| **Turnkey Passive Income OS (White-Label)** | **$49** | Complete Commercial License + 9-Archetype Storefront + Auto Email Funnel | [View Offer](https://tranhoangtu-it.github.io/kiemtien247-store/products/hero-turnkey-passive-income-os.html) |
| **Done-For-You 2-Hour Setup** | **$99** | 1-on-1 Installation, Custom Bank VietQR + Cloud Tunnel + Live Launch | [View Offer](https://tranhoangtu-it.github.io/kiemtien247-store/products/hero-dfy-2h-system-setup.html) |
### Sponsor via VietQR (Vietnam Napas247)
- **Bank:** Vietcombank (`VCB`)
- **Account No:** `9946611993` (`TRAN HOANG TU`)
- **Direct Coffee / Sponsor Link:** https://img.vietqr.io/image/VCB-9946611993-compact2.png?addInfo=SPONSOR%20VIETQR%20MCP
TDQS
Scored across 3 tools
The three tools target clearly different outputs: a VietQR payment URL/Markdown block, an invoice HTML document, and a bank reference list. Although the invoice tool embeds a VietQR block, its purpose and output format are distinct enough that an agent can select correctly.
All tool names use consistent snake_case and follow a predictable verb-first pattern: generate_* and list_*. The naming clearly indicates both the action and the resource being produced or retrieved.
Three tools are well matched to this narrow VietQR/invoice domain. Each tool has a clear, non-redundant role, and there are no excessive or filler operations.
The surface covers the core workflows: bank discovery, VietQR payment URL generation, and invoice generation with an embedded payment block. Minor gaps exist around validation or verification of bank/account inputs and possibly richer invoice customization, but core usage is covered.