PEAK Account MCP Server
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., "@PEAK Account MCP Servershow me unpaid invoices from last month"
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.
PEAK Account MCP Server
MCP (Model Context Protocol) server for PEAK Account — a Thai cloud accounting platform. It lets AI assistants like Claude manage your PEAK data through natural language, using the official PEAK Open API.
Unlike a browser-scraping approach, this server talks to PEAK's documented REST API and authenticates with HMAC-SHA1 request signing — no headless browser required. 136 tools cover the full API surface.
Features
Master data — Contacts, Products, Services, Payment Methods
Sales / Income — Quotations, Invoices, Receipts, Credit Notes, Billing Notes (create/get/list/edit/void/approve, payments, e-Tax Invoice / e-Receipt, file attachments, async queue)
Purchases / Expense — Purchase Orders, Expenses, Credit Note Expenses, Billing Note Expenses (create/get/list/edit/void/approve, payments, received tax invoice, attachments)
Accounting & misc — Daily Journals, Account Codes, Tags, Classifications, Invitations, File Vault
Note on "delete": PEAK is an accounting system — posted documents are voided (
void_*), never hard-deleted, to preserve the audit trail.
How authentication works
Every PEAK API request carries four headers:
Header | Value |
| Current UTC time, |
|
|
| Issued by PEAK for your business |
| Fetched from |
The client token is obtained by POST /api/v1/clienttoken with body { "peakClientToken": { "connectId": "...", "connectKey": "..." } }, signed with Time-Stamp + Time-Signature. The success response is { "PeakClientToken": { "token": "…", "resCode": "200", "resDesc": "Token Authorized" } }.
The server generates Time-Stamp/Time-Signature fresh per request, caches the client token, and refreshes it automatically on a 401.
Rate limits (enforced by PEAK)
Policy | Scope | Limit |
Client token |
| 10 requests / minute |
File upload |
| 2 requests / minute |
GET concurrency | per User-Token | 10 concurrent |
POST concurrency | per User-Token | 5 concurrent |
Exceeding a limit returns HTTP 429. The client automatically backs off (honoring retryAfterSeconds) and retries.
Setup
Prerequisites
Node.js 18+
A PEAK Developer account with Connect ID, Connect Key, and User Token — see peakaccount.com/developers. API access requires the PEAK PRO Plus package (฿12,000/year) or higher; UAT/sandbox is free for 3 months.
Install & build
npm install
npm run buildConfigure
Copy .env.example to .env and fill in your credentials:
PEAK_ENV=uat # "uat" (sandbox) or "production"
PEAK_CONNECT_ID=... # sent in /clienttoken body
PEAK_CONNECT_KEY=... # sent in /clienttoken body
PEAK_USER_TOKEN=... # per-business token, sent as header
# PEAK_SIGNATURE_ENCODING=base64 # switch to "hex" if auth fails
# PEAK_SIGNATURE_SECRET=connectId # switch to "connectKey" if auth failsVerify auth (recommended first step)
export $(grep -v '^#' .env | xargs) # load .env into the shell
npm run auth-checkThis acquires a client token and prints masked headers. If it fails:
TimeSignature Unauthorized→ tryPEAK_SIGNATURE_ENCODING=hex, thenPEAK_SIGNATURE_SECRET=connectKey.Validate User Failed→ checkPEAK_CONNECT_ID/PEAK_CONNECT_KEY.
Claude Desktop / Claude Code integration
{
"mcpServers": {
"peakaccount": {
"command": "node",
"args": ["/path/to/PeakAccountMcp/dist/index.js"],
"env": {
"PEAK_ENV": "uat",
"PEAK_CONNECT_ID": "your-connect-id",
"PEAK_CONNECT_KEY": "your-connect-key",
"PEAK_USER_TOKEN": "your-user-token"
}
}
}
}Environments
PEAK_ENV selects the base URL (confirmed from the PEAK OpenAPI servers block):
| Default base URL | Override env var |
|
|
|
|
|
|
Tool design
Read tools (
get_*,list_*) take an optionalparamsobject mapped to the endpoint's query string (e.g.{ "id": "…" }or{ "currentPage": 1, "pageSize": 20 }).Write tools (
create_*,update_*,void_*,approve_*,record_*_payment, …) take adataobject sent as the JSON request body. Field names must match the PEAK API schema for that endpoint.File tools (
attach_file_to_*,upload_file_vault) take afilePathplus optionalfields.
📋 Payload cheat sheet
Field names below are taken from the PEAK OpenAPI definitions. Numeric enums (type, taxStatus, vatType, isCheque, bankId, …) must be looked up in the numeric reference. Always confirm against the API reference for your account.
Create a contact — create_contact
Documents are wrapped in PeakContacts.contacts[]:
{
"data": {
"PeakContacts": {
"contacts": [
{
"name": "บริษัท ตัวอย่าง จำกัด",
"type": 2,
"taxNumber": "0105557000000",
"branchCode": "00000",
"address": "123 ถนนตัวอย่าง",
"subDistrict": "ท่าแร้ง",
"district": "บางเขน",
"province": "กรุงเทพมหานคร",
"country": "Thailand",
"postCode": "10220",
"email": "contact@example.com",
"callCenterNumber": "021234567",
"contactFirstName": "สมชาย",
"contactLastName": "ใจดี"
}
]
}
}
}Key fields: name* (name only, no legal prefix), type* (2 = juristic, 5 = individual — see numeric ref), prefixNameType (for individuals), taxNumber, branchCode (5 digits), address parts, contactFirstName/LastName/Email, purchaseAccount/sellAccount (chart-of-accounts codes), bankAccount (bankId, bankBranch, bankAccountNo, bankAccountName).
Issue an invoice (income) — create_invoice
Wrapped in peakInvoices.invoices[]; getResult trims the response:
{
"data": {
"peakInvoices": {
"invoices": [
{
"issuedDate": "2026-07-19",
"dueDate": "2026-08-18",
"contactId": "917c3e8f-b315-4968-b8cc-08e2220d8682",
"reference": "SO-2026-001",
"remark": "ค่าบริการที่ปรึกษา",
"taxStatus": 1,
"isTaxInvoice": 1,
"products": [
{
"productCode": "SV001",
"description": "ค่าบริการที่ปรึกษา เดือน ก.ค.",
"quantity": 1,
"price": 10000,
"discount": "0",
"vatType": 1
}
]
}
],
"getResult": 1
}
}
}Header fields: code (auto if omitted), issuedDate*, dueDate, contactId or contactCode, reference, remark, taxStatus (VAT status — numeric), isTaxInvoice, discountTotal, tags[]. preTaxAmount/vatAmount/netAmount auto-calc if null.
Line item (products[]): productId/productCode, description, accountCode, quantity, price, discount, vatType, withHoldingTaxAmount.
create_invoice_allinoneuses the same body but also approves the document in one call. To bill from a quotation, usecreate_invoice_by_quotation.
Record a payment on an invoice — inline or record_invoice_payment
Payments can be embedded in the document via paidPayments, or recorded later against an approved invoice:
{
"data": {
"paidPayments": {
"paymentDate": "20260720",
"withHoldingTaxAmount": "0",
"payments": [
{
"amount": 10700,
"isCheque": 0,
"paymentMethodCode": "PM-CASH",
"note": "รับโอนพร้อมเพย์"
}
]
}
}
}Payment fields: amount*, paymentMethodId/paymentMethodCode, isCheque (0/1), cheque (object when isCheque=1), accountCode/accountSubCode, note. paymentDate is yyyyMMdd.
Record an expense (รายจ่าย) — create_expense
Same document shape as invoices, wrapped in peakExpenses.expenses[]:
{
"data": {
"peakExpenses": {
"expenses": [
{
"issuedDate": "2026-07-19",
"dueDate": "2026-07-19",
"contactId": "917c3e8f-b315-4968-b8cc-08e2220d8682",
"reference": "BILL-8842",
"remark": "ค่าอินเทอร์เน็ตสำนักงาน",
"taxStatus": 1,
"isTaxInvoice": 1,
"products": [
{
"description": "ค่าบริการอินเทอร์เน็ต 1 เดือน",
"accountCode": "540104",
"quantity": 1,
"price": 800,
"vatType": 1
}
],
"paidPayments": {
"paymentDate": "20260719",
"payments": [
{ "amount": 856, "isCheque": 0, "paymentMethodCode": "PM-CASH" }
]
}
}
],
"getResult": 1
}
}
}For input-VAT (ภาษีซื้อ), use create_expense_received_tax_invoice. create_expense_allinone creates + approves.
VAT / Tax
VAT is embedded in each line item (vatType) and document (taxStatus), not a separate resource. To issue electronic tax documents:
Output VAT (ภาษีขาย):
create_invoice_etax,create_receipt_etax,create_credit_note_etaxInput VAT (ภาษีซื้อ):
create_expense_received_tax_invoice
VAT return reports (ภ.พ.30) are not exposed by the API.
Reads
// get_contact
{ "params": { "id": "917c3e8f-b315-4968-b8cc-08e2220d8682" } }
// list_invoices
{ "params": { "currentPage": 1, "pageSize": 20 } }Async queue
Some documents process asynchronously. Submit with enqueue_* and poll with get_*_queue (e.g. enqueue_invoice → get_invoice_queue).
🧰 All 136 tools
Legend: 🔍 read (GET, takes params) · ✏️ write (POST, takes data) · 📎 file (multipart, takes filePath)
Master Data — Contacts, Products, Services, Payment Methods (19)
# | Tool | Type | Description |
1 |
| ✏️ write | Create a contact (customer/supplier) in PEAK. |
2 |
| 🔍 read | Get a single contact by id (pass { id }). |
3 |
| 🔍 read | List contacts with optional paging/search params. |
4 |
| ✏️ write | Edit an existing contact. |
5 |
| 🔍 read | List contact groups. |
6 |
| ✏️ write | Create a product. |
7 |
| 🔍 read | Get a single product by id. |
8 |
| 🔍 read | List products with optional paging/search params. |
9 |
| ✏️ write | Edit an existing product. |
10 |
| ✏️ write | Adjust product stock quantity. |
11 |
| 🔍 read | List product units. |
12 |
| ✏️ write | Create a service. |
13 |
| 🔍 read | Get a single service by id. |
14 |
| 🔍 read | List services with optional paging/search params. |
15 |
| ✏️ write | Edit an existing service. |
16 |
| 🔍 read | List service units. |
17 |
| ✏️ write | Create a payment method. |
18 |
| 🔍 read | Get/list payment methods. |
19 |
| ✏️ write | Transfer funds between payment methods. |
Sales / Income — Quotations, Invoices, Receipts, Credit Notes, Billing Notes (61)
# | Tool | Type | Description |
1 |
| ✏️ write | Create a quotation (draft). |
2 |
| ✏️ write | Create + approve a quotation in one call. |
3 |
| 🔍 read | Get a single quotation by id. |
4 |
| 🔍 read | List quotations with optional paging/filter params. |
5 |
| ✏️ write | Edit an existing quotation. |
6 |
| ✏️ write | Void a quotation. |
7 |
| ✏️ write | Approve a quotation. |
8 |
| ✏️ write | Submit a quotation to the async processing queue. |
9 |
| 🔍 read | Poll the status of a queued quotation. |
10 |
| ✏️ write | Set queue priority for a quotation. |
11 |
| 📎 file | Attach a file to a quotation. |
12 |
| ✏️ write | Create an invoice (draft). |
13 |
| ✏️ write | Create + approve an invoice in one call. |
14 |
| ✏️ write | Create an invoice from a quotation. |
15 |
| 🔍 read | Get a single invoice by id. |
16 |
| 🔍 read | List invoices with optional paging/filter params. |
17 |
| 🔍 read | List invoices for a specific contact. |
18 |
| ✏️ write | Edit an existing invoice. |
19 |
| ✏️ write | Void an invoice. |
20 |
| ✏️ write | Approve an invoice. |
21 |
| ✏️ write | Record a payment against an invoice. |
22 |
| ✏️ write | Void a recorded invoice payment. |
23 |
| ✏️ write | Issue an e-Tax Invoice for an invoice. |
24 |
| ✏️ write | Submit an invoice to the async processing queue. |
25 |
| 🔍 read | Poll the status of a queued invoice. |
26 |
| ✏️ write | Set queue priority for an invoice. |
27 |
| 📎 file | Attach a file to an invoice. |
28 |
| ✏️ write | Create a receipt (draft). |
29 |
| ✏️ write | Create + approve a receipt in one call. |
30 |
| ✏️ write | Create a receipt from an invoice. |
31 |
| ✏️ write | Create a receipt from a quotation. |
32 |
| ✏️ write | Create a receipt from a billing note. |
33 |
| 🔍 read | Get a single receipt by id. |
34 |
| 🔍 read | List receipts with optional paging/filter params. |
35 |
| ✏️ write | Edit an existing receipt. |
36 |
| ✏️ write | Void a receipt. |
37 |
| ✏️ write | Approve a receipt. |
38 |
| ✏️ write | Issue an e-Receipt for a receipt. |
39 |
| ✏️ write | Issue an e-Tax Invoice for a receipt. |
40 |
| ✏️ write | Submit a receipt to the async processing queue. |
41 |
| 🔍 read | Poll the status of a queued receipt. |
42 |
| ✏️ write | Set queue priority for a receipt. |
43 |
| 📎 file | Attach a file to a receipt. |
44 |
| ✏️ write | Create a credit note. |
45 |
| 🔍 read | Get a single credit note by id. |
46 |
| 🔍 read | List credit notes with optional paging/filter params. |
47 |
| ✏️ write | Void a credit note. |
48 |
| ✏️ write | Issue an e-Receipt for a credit note. |
49 |
| ✏️ write | Issue an e-Tax Invoice for a credit note. |
50 |
| ✏️ write | Submit a credit note to the async processing queue. |
51 |
| 🔍 read | Poll the status of a queued credit note. |
52 |
| 📎 file | Attach a file to a credit note. |
53 |
| ✏️ write | Create a billing note. |
54 |
| 🔍 read | Get a single billing note by id. |
55 |
| 🔍 read | List billing notes with optional paging/filter params. |
56 |
| ✏️ write | Record a payment against a billing note. |
57 |
| ✏️ write | Void a recorded billing note payment. |
58 |
| ✏️ write | Void a billing note. |
59 |
| ✏️ write | Submit a billing note to the async processing queue. |
60 |
| 🔍 read | Poll the status of a queued billing note. |
61 |
| 📎 file | Attach a file to a billing note. |
Purchases / Expense — Purchase Orders, Expenses, Credit/Billing Note Expenses (43)
# | Tool | Type | Description |
1 |
| ✏️ write | Create a purchase order (draft). |
2 |
| ✏️ write | Create + approve a purchase order in one call. |
3 |
| 🔍 read | Get a single purchase order by id. |
4 |
| 🔍 read | List purchase orders with optional paging/filter params. |
5 |
| ✏️ write | Edit an existing purchase order. |
6 |
| ✏️ write | Void a purchase order. |
7 |
| ✏️ write | Approve a purchase order. |
8 |
| ✏️ write | Submit a purchase order to the async processing queue. |
9 |
| 🔍 read | Poll the status of a queued purchase order. |
10 |
| ✏️ write | Set queue priority for a purchase order. |
11 |
| 📎 file | Attach a file to a purchase order. |
12 |
| ✏️ write | Create an expense (draft). |
13 |
| ✏️ write | Create + approve an expense in one call. |
14 |
| ✏️ write | Create an expense from a purchase order. |
15 |
| 🔍 read | Get a single expense by id. |
16 |
| 🔍 read | List expenses with optional paging/filter params. |
17 |
| 🔍 read | List expenses for a specific contact. |
18 |
| ✏️ write | Edit an existing expense. |
19 |
| ✏️ write | Void an expense. |
20 |
| ✏️ write | Approve an expense. |
21 |
| ✏️ write | Record a payment against an expense. |
22 |
| ✏️ write | Void a recorded expense payment. |
23 |
| ✏️ write | Create a received tax invoice for an expense. |
24 |
| ✏️ write | Submit an expense to the async processing queue. |
25 |
| 🔍 read | Poll the status of a queued expense. |
26 |
| ✏️ write | Set queue priority for an expense. |
27 |
| 📎 file | Attach a file to an expense. |
28 |
| ✏️ write | Create a credit note expense. |
29 |
| 🔍 read | Get a single credit note expense by id. |
30 |
| 🔍 read | List credit note expenses. |
31 |
| ✏️ write | Void a credit note expense. |
32 |
| ✏️ write | Submit a credit note expense to the queue. |
33 |
| 🔍 read | Poll the status of a queued credit note expense. |
34 |
| 📎 file | Attach a file to a credit note expense. |
35 |
| ✏️ write | Create a billing note expense. |
36 |
| 🔍 read | Get a single billing note expense by id. |
37 |
| 🔍 read | List billing note expenses. |
38 |
| ✏️ write | Record a payment against a billing note expense. |
39 |
| ✏️ write | Void a recorded billing note expense payment. |
40 |
| ✏️ write | Void a billing note expense. |
41 |
| ✏️ write | Submit a billing note expense to the queue. |
42 |
| 🔍 read | Poll the status of a queued billing note expense. |
43 |
| 📎 file | Attach a file to a billing note expense. |
Accounting & Misc — Daily Journals, Tags, Classifications, File Vault (13)
# | Tool | Type | Description |
1 |
| ✏️ write | Create a daily journal entry. |
2 |
| 🔍 read | Get a single daily journal by id. |
3 |
| ✏️ write | Void a daily journal entry. |
4 |
| 🔍 read | Get the chart of account codes. |
5 |
| ✏️ write | Submit a daily journal to the async processing queue. |
6 |
| ✏️ write | Attach a tag to a record. |
7 |
| ✏️ write | Remove a tag from a record. |
8 |
| 🔍 read | Get classification groups. |
9 |
| 🔍 read | Get classifications for a transaction. |
10 |
| ✏️ write | Create a transaction classification. |
11 |
| ✏️ write | Void/remove a transaction classification. |
12 |
| ✏️ write | Create an invitation. |
13 |
| 📎 file | Upload a file to the PEAK File Vault. |
Notes / open items
The passthrough
data/paramsdesign keeps the server correct across all endpoints. As per-endpoint schemas are confirmed against UAT, individual tools can be given stricter typed inputs.Time-Signatureencoding (base64 vs hex) and secret source (connectId vs connectKey) are configurable — confirm the working combination on your account vianpm run auth-check.Numeric enums (
type,taxStatus,vatType,bankId,prefixNameType, …) — see the numeric reference.
License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
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/savekikiz/PeakAccountMCP'
If you have feedback or need assistance with the MCP directory API, please join our Discord server