Skip to main content
Glama

BillTally

Check Supplier Bill or Receipt Math

extract_financial_documents
Read-onlyIdempotent

Extracts supplier name, bill number, dates, payment terms, currency, line items, subtotal, sales tax, and total from supplier bills, bank statements, receipts, and agreements. Performs cent-level fixed-decimal math checking (verifying that the sum of line items plus tax equals the billed total) and returns exact differences, a plain-English summary, a 1099-NEC review flag, and a polite supplier correction note when an overcharge is found.

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": {
      "raw_text": "<raw_text>"
    },
    "name": "extract_financial_documents"
  }
}

Input Schema

NameRequiredDescriptionDefault
api_keyNoOptional BillTally Pro API key for high-volume monthly bill checks (5,000 docs/mo).
raw_textYesRaw supplier bill, receipt, or statement text, table, or structured document content to verify.
workspace_idNoOptional workspace identifier for monthly bill-check quota tracking.
currency_hintNoOptional 3-letter ISO currency code hint such as USD, EUR, or GBP.
document_typeNoType of financial document being checked (invoice, bank_statement, receipt, contract, or auto).auto
strict_reconciliationNoWhen true, enforces cent-exact verification across every line item (Quantity multiplied by Unit Price) and sales tax total.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

B3.2/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false and openWorldHint=false, so the safety profile is fully covered and the description does not contradict it. The description does add genuine value beyond annotations by disclosing what comes back: exact differences, a plain-English summary, a 1099-NEC review flag, and a supplier correction note on overcharge. It does not say what happens when reconciliation fails or how strict_reconciliation=false changes output, leaving some behavioral gaps.

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

Conciseness4/5

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

Two sentences, front-loaded with the extraction scope and then the math-check behavior, with no filler or marketing padding. The long field enumeration is dense but each item tells the agent what it will receive, so it earns its space.

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

Completeness4/5

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

With no output schema, the description carries the return-value burden and does so by listing the extracted fields and the four output artifacts (differences, summary, 1099-NEC flag, correction note). For a six-parameter, single-required-input tool this is largely sufficient; only the interaction between strict_reconciliation and the reported differences, and any quota/auth implications of api_key, are left unexplained.

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

Parameters3/5

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

Schema description coverage is 100%, so all six parameters including the document_type enum and the strict_reconciliation default are already documented in the schema, setting the baseline at 3. The description mentions currency, payment terms, and the 1099-NEC flag, which loosely maps to currency_hint and the review output, but it adds no new semantics for api_key, workspace_id, or how auto document typing behaves.

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

Purpose4/5

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

The description names a specific verb ('Extracts') plus a concrete field list (supplier name, bill number, dates, payment terms, currency, line items, subtotal, tax, total) and adds a distinct second capability: cent-level reconciliation math with exact differences. That is well beyond a tautology. It stops short of 5 because it never names or contrasts the sibling tools (e.g. reconcile_invoices_with_bank_ledger), so the agent must infer the boundary itself.

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

Usage Guidelines2/5

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

There is no explicit when-to-use or when-not-to-use guidance, and no alternative is named despite three plausible siblings. The only implicit signal is that it works on a single supplied document's text and checks its internal arithmetic, which a careful agent could infer, but nothing states the selection condition.

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