@havahr/mcp-calculators
v0.2.0
Published
HavaHR MCP server for Malaysian statutory payroll calculators (EPF, SOCSO, EIS, PCB).
Downloads
62
Maintainers
Readme
@havahr/mcp-calculators
Local Model Context Protocol server for Malaysian statutory payroll math — EPF, SOCSO, EIS, PCB, and employer cost — using the same engine as the free calculators on havahr.com.
Public install guide: havahr.com/tools/malaysia-payroll-mcp
Estimates only — not official advice. Confirm with KWSP / PERKESO / LHDN or a payroll professional for filing.
What you get
| Tool | Purpose |
|------|---------|
| calculate_malaysia_payroll | Net pay + EPF/SOCSO/EIS/PCB + employer contributions |
| calculate_epf | KWSP contributions |
| calculate_socso | PERKESO Category 1/2 |
| calculate_eis | SIP contributions + citizen/PR eligibility |
| calculate_pcb | Monthly tax deduction (MTD) estimate |
| calculate_employer_cost | Gross + employer statutory outlay |
| calculate_overtime | EA 1955 overtime & public holiday pay (1.5×/2×/3×) with 45h/104h compliance checks |
| calculate_leave_proration | Annual leave proration for mid-year joiners/leavers |
| check_employment_act_coverage | Employment Act 1955 coverage check (RM4,000 threshold) |
| calculate_hrd_corp_levy | HRD Corp (HRDF) levy — mandatory 1% or voluntary 0.5% |
Safety
- No auth, workspace data, or network calls from calculator tools
- Pure calculation (bundled HavaHR statutory tables)
- Keep this package calculator-only — do not add authenticated ESS tools here
Requirements
- Node.js 20+
- An MCP host that supports local stdio servers (Cursor, Claude Desktop, Claude Code, ChatGPT desktop / Codex, VS Code, Windsurf, Zed, …)
Install (public)
Add to your host config:
{
"mcpServers": {
"havahr-calculators": {
"command": "npx",
"args": ["-y", "@havahr/mcp-calculators"]
}
}
}ChatGPT desktop / Codex (~/.codex/config.toml):
[mcp_servers.havahr-calculators]
command = "npx"
args = ["-y", "@havahr/mcp-calculators"]- VS Code: use root key
serversinstead ofmcpServers(.vscode/mcp.json). - Zed: use root key
context_serversinsettings.json. - Claude Code:
claude mcp add --transport stdio havahr-calculators -- npx -y @havahr/mcp-calculators - Codex CLI:
codex mcp add havahr-calculators -- npx -y @havahr/mcp-calculators(not chatgpt.com in the browser)
Restart the host after saving.
Run manually
npx -y @havahr/mcp-calculatorsLogs go to stderr; stdout is reserved for MCP JSON-RPC.
Install (monorepo contributors)
cd /ABSOLUTE/PATH/TO/hava4
npm install
npm run build -w @havahr/mcp-calculatorsThen point your host at packages/mcp-calculators/dist/index.js, or run:
npm start -w @havahr/mcp-calculatorsTry it
Ask your host:
What is take-home pay for RM4,000 gross in Malaysia at age 43?
Sanity check: EPF employee ≈ RM440, employer ≈ RM520.
Related
- Web calculators: Payroll calculator hub
- Product: HavaHR
