Skip to main content
Glama
ComplyEaze

ComplyEaze Bridge: TallyPrime MCP server for Claude Desktop

Official

stock_summary

Read-only

Retrieves closing stock value per item as of 31 March and verifies the total against Tally's own Stock Summary, including inventory integration status.

Instructions

Return the stock summary: the closing stock value per stock item as of a date, with the total of those values checked against Tally's own Stock Summary, and whether inventory is integrated with the accounts. The top-level state is one of three. value_total_matched: the items are returned, and their closing values add up to the sum of the top-level lines of Tally's own Stock Summary; only that total was compared, so value_total_matched can stand beside partial true when some items have no closing value. no_stock_items: Tally's own stock item count is 0, the item list is empty and the Stock Summary is empty; items is an empty list. not_established: no item is returned (items is null), reason says why and remediation says what to do next: tally_stock_summary_differs (the report has a total the items do not add up to), tally_stock_summary_shows_no_value (the items carry a value and the report has no amount; an empty report is not told apart from one Tally did not render) or stock_values_not_comparable (nothing could be compared). Such a result carries unchecked_comparison in place of tie_out, for investigation only: neither side is a stock value or a total, the items' side adds only the closing values present, and the closing-value total of a matched read is the only thing this tool checks. A not_established result is not held for paging, and it replaces any earlier read of the same date. A closing quantity is returned only where Tally's own plain Stock Summary shows the same item by name with the same quantity, unit and amount (closing.quantity.state agreed, with amount and unit); every other item says why not (none_sent, unread, inside_stock_group, report_has_no_line, report_name_not_unique, report_differs). In the captures the report listed only what sits directly under the root, so an item inside a stock group is taken to have no line and no quantity is returned for it (inside_stock_group); totals.closing_quantity_unread_count counts quantities that could not be read (a compound unit, or a unit with a space), which do not refuse the read. checks says per field what is checked, checked_per_item or not_checked: the closing-value total is checked; the closing quantity is checked item by item; each value on its own, the names, parents and base units, and whether the date was honoured are not. as_of (YYYYMMDD or YYYY-MM-DD) must be a 31 March, not before the book's start or after today. The only period measured is the period ending 31 March 2026; other years' 31 March are admitted but unmeasured, and any other date is refused as stock_summary_as_of_not_measured before any request. The period runs from 1 April (or the book's start, if later) to as_of. Each item carries name, guid, parent, base_unit and closing; closing holds value exactly as Tally sends it, and quantity (a state, with amount and unit when it is agreed). Empty is not zero: an empty closing value is returned as null and counted in totals.empty_closing_value_count, and a value sent as 0.00 is a value. Signs are kept, as in the trial balance: a negative value is a debit, which is stock held, and Tally's own Stock Summary screen shows it as a positive value (measured on one synthetic company, licensed TallyPrime 7.1 Silver). value_sum adds the values with their signs, so stock held gives a negative sum, and totals.value_sum_signs is always as_sent_negative_is_debit; value_sum is written at the scale of the values it adds, and is null with partial true whenever any item's closing value is empty. The opening quantity and value are read but not returned, because their as-at date is unmeasured. inventory reports integrated, inventory_on and batchwise as yes, no or unknown (unknown does not refuse), and basis states what Tally reported (ISINTEGRATED); how the books use these values (as closing stock, or against a Stock-in-Hand ledger) is not measured. An item valued at zero or with no value adds nothing to either total, so only Tally's own stock item count vouches for it; that count followed the one delete measured (one synthetic company, one sample), which is not proof of a complete list (checks.item_list_complete is not_checked). item_count_cross_check reports rows, tally_count and status: items are returned only when the two are equal. Otherwise the read is refused as stock_summary_item_count_differs (both numbers under counts); a count Tally did not give refuses as stock_summary_read_failed with cause stock_item_count_unavailable, and a Stock Summary this Tally does not recognise with cause stock_report_unknown. items (1 to 50 GUIDs, each once) filters what is returned from the held read; a GUID not found is listed under items_not_found, not refused, and totals, tie_out and item_count_cross_check still cover the whole book. The inventory flags, the stock items and the Stock Summary are each read twice inside one company, mode and book-extent bracket, or the read is refused. A book whose inventory is off is refused as stock_not_enabled, Education mode is refused, and a company split by year, whose sibling companies share the GUID, is refused (stock_summary_read_failed, cause company_flags_not_one_row). Small books only: the items are read whole only when the master-alteration mark (it counts masters of every kind) times an assumed worst-case row fits 16,000,000 bytes, a mark of at most 874; a larger book is refused before any item request as stock_summary_too_large, with size, and retrying refuses again. Typical stock-heavy client books refuse today. A row count or response size past what was admitted refuses as stock_summary_bound_premise_violated, or stock_summary_extent_changed if the book moved. Limits: company totals only, with no godown or batch split and no rates. The row shape and the tie were measured on one synthetic book on one licensed TallyPrime 7.1 (the tie also once on a client book); other releases, dates and books are not measured. An item's name and parent are masked under mask_parties, because stock names can carry a customer's or supplier's name (Tally's reserved root as a parent is left as it is); guid is not masked and is what items filters on. A first page (offset 0) always reads afresh and holds the read; a later page for the same date is served from it while the book extent, including ALTVCHID and ALTMSTID, is unchanged, and each result reports snapshot. Pass the first page's snapshot_id on later pages to have the call refused as listing_snapshot_changed instead of continuing from a different read (cause book_changed_since_first_page, or snapshot_not_held for an id not held). A change that moves neither mark is not seen, so a later page can be up to 10 minutes old after such a change. Each call appends metadata-only receipt lines (tool, company, counts, request and response fingerprints; no book content) to ComplyEaze Bridge's local log on this computer; it writes nothing to Tally.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
as_ofYesThe last day of the stock period, a 31 March (YYYYMMDD or YYYY-MM-DD). The period runs from 1 April, or the book's start if later.
itemsNoOptional: 1 to 50 stock item GUIDs, each once, to return only those items. A GUID not found is listed under items_not_found; the totals still cover the whole book.
limitNoThe most rows to return on this page. The default and the maximum are this server's row limit (500 unless it is configured otherwise).
offsetNoHow many rows to skip before this page: 0, the default, is the first page.
snapshot_idNoOptional, on a later page only: the first page's snapshot_id, so the call is refused (listing_snapshot_changed) rather than continuing from a different read.
company_guidYesThe company's company_guid, as list_companies returns it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.4.3
    • addedInput schema / properties / as_of / description
      Added value: +"The last day of the stock period, a 31 March (YYYYMMDD or YYYY-MM-DD). The period runs from 1 April, or the book's start if later."
    • addedInput schema / properties / company_guid / description
      Added value: +"The company's company_guid, as list_companies returns it."
    • addedInput schema / properties / items / description
      Added value: +"Optional: 1 to 50 stock item GUIDs, each once, to return only those items. A GUID not found is listed under items_not_found; the totals still cover the whole book."
    • removedInput schema / properties / limit / default
      Removed value: -500
    • addedInput schema / properties / limit / description
      Added value: +"The most rows to return on this page. The default and the maximum are this server's row limit (500 unless it is configured otherwise)."
    • addedInput schema / properties / offset / description
      Added value: +"How many rows to skip before this page: 0, the default, is the first page."
    • addedInput schema / properties / snapshot_id / description
      Added value: +"Optional, on a later page only: the first page's snapshot_id, so the call is refused (listing_snapshot_changed) rather than continuing from a different read."
  2. First observedv0.4.1

TDQS

A4.1/5.0
Behavior5/5

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

With readOnlyHint/destructiveHint already covering the safety profile, the description adds far more: does not write to Tally, appends metadata-only receipt lines to a local log, masks item names and parents under mask_parties, staleness of up to 10 minutes on later pages, and the full set of refusal codes with causes. The non-idempotent nature (fresh read on offset 0, snapshot-served later pages) is disclosed and consistent with idempotentHint=false. No contradiction.

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

Conciseness2/5

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

The return-value description is front-loaded, but the body is an undifferentiated wall of run-on sentences with no headings or grouping, running to hundreds of words. Much is redundant with the schema, and critical facts are buried mid-paragraph. Adequately sized only because the tool is complex; structurally poor.

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?

There is no output schema, so the description carries the full return-shape burden, and it does so exhaustively: the three `state` values, `checks` per-field coverage, item field shape (`name`, `guid`, `parent`, `base_unit`, `closing`), signs convention, `value_sum` scale, totals counters, and every refusal cause. Nothing an agent needs to interpret or invoke the tool correctly 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 baseline is 3, but the description genuinely adds meaning: `as_of` constraints (31 March, within book start and today, unmeasured-year behavior), `items` semantics (not-found GUIDs listed, totals/tie_out still cover the whole book), and `snapshot_id` refusal behavior (`listing_snapshot_changed`, `snapshot_not_held`). These go beyond the schema text rather than repeating it.

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 first clause states a specific verb and resource — 'Return the stock summary: the closing stock value per stock item as of a date' — with the tie-out and inventory-integration checks named up front. An agent can tell this is a per-item closing-stock read rather than a trial balance or generic ledger read. It never names a sibling tool explicitly to differentiate itself, so it lands at 4 rather than 5.

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

Usage Guidelines4/5

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

Strong conditional guidance: `as_of` must be a 31 March not before book start or after today, only the period ending 31 March 2026 is measured, Education mode and inventory-off books are refused, and small books only (mark <= 874) are admitted. These effectively define when the tool may be used, and paging guidance (pass the first page's snapshot_id) is given. It stops short of naming an alternative tool to use instead when refused, so not a 5.

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