Skip to main content
Glama

Taokeh MCP server

Replaced by its MCP Registry listing

This endpoint is listed in the official MCP Registry as mcp. If you published it, claim ownership there.

File a pending contra set-off draft settling one side in full (approved on its review page in Taokeh)

create_contra_draft

Files a pending draft of Contra set-off: what a customer owes the company is set off against what the company owes the same business as a supplier. Customers and suppliers are separate records, so whether they are one business is the approver's call: the review page shows the two side by side, with any same name, BRN or TIN. The two sides set off the same ringgit amount; one side is settled in full: every invoice at exactly what it still owes (open_invoices outstanding), or every bill at exactly what is still owed on it (search_documents docType bill, outstanding). A part set-off, or an invoice or bill with a live credit or debit note against it, is recorded by hand on Banking → Contra set-off. Every named document must be open; a refusal lists what each named document still owes. Nothing is posted until an admin or bookkeeper approves it on its review page (no one-tap approval); approval records it exactly as the contra page does: A/R and A/P both go down by the amount, no money moves and no tax is charged. The result carries both sides, the amount and the journal lines. Refused at filing and approval in the page's words: the sides not equal, a document of another customer or supplier, a foreign-currency document, an amount over what a document owes, a date in a locked period. One contra draft per customer and supplier pair waits at a time; if a document is paid, credited or set off before approval, approval refuses and nothing is posted.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "date": "<date>",
      "customerId": "<customerId>",
      "vendorId": "<vendorId>",
      "invoiceAllocations": "<invoiceAllocations>",
      "billAllocations": "<billAllocations>"
    },
    "name": "create_contra_draft"
  }
}

Input Schema

NameRequiredDescriptionDefault
dateYesThe set-off date, YYYY-MM-DD.
memoNoA memo printed on the contra note.
noteNoA short note for the reviewer: where the figures came from.
vendorIdYesThe supplier side, from resolve_vendor.
customerIdYesThe customer side, from resolve_customer.
needsReviewNotrue flags the draft for the reviewer.
billAllocationsYesThe supplier's open bills (search_documents, docType `bill`) and the ringgit set off on each, [{purchaseId, amount}]. No bill with a live debit note.
invoiceAllocationsYesThe customer's open invoices (open_invoices) and the ringgit set off on each, [{saleId, amount}]. No invoice with a live credit or debit note.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Added

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only say it is a non-read-only, non-destructive, non-idempotent write. The description adds substantial context beyond that: nothing is posted until an admin or bookkeeper approves; approval reduces A/R and A/P with no money movement and no tax; one draft per customer/supplier pair; and stale documents cause refusal at approval. This is exactly the behavioral detail an agent needs for a mutation tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

It is one dense, unstructured paragraph of roughly 180 words. Nearly every sentence carries useful content, but the refusal reasons, approval effects, and one-draft-per-pair rule are interleaved rather than grouped, making it harder to scan than a short bulleted structure would be.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter mutation tool with no output schema, the description covers the workflow end to end: input sources, the equal-amount/full-settlement constraint, the approval gate, the accounting effect, the refusal cases, and the shape of the result ('both sides, the amount and the journal lines'). Nothing essential is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3. The description still adds business meaning to the allocation arrays that the schema does not: the two sides must set off the same ringgit amount, one side must be settled in full, and amounts must equal each document's outstanding balance with no live credit/debit note. That constrains how invoiceAllocations and billAllocations must be built.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence names a specific verb ('Files a pending draft') and resource ('Contra set-off') and immediately defines the concept as offsetting a customer receivable against a supplier payable for the same business. An agent can distinguish this from create_journal_draft or create_payment_draft without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It explicitly states when NOT to use it: part set-offs and documents with a live credit or debit note must be recorded by hand on Banking → Contra set-off. It also names the source tools (open_invoices, search_documents) and the approval path, leaving nothing to inference about routing.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources