Skip to main content
Glama

Palgaarvutus

calc_salary
Read-onlyIdempotent

Arvuta ühe (uue) väljamakse maksulahendus: bruto → tulumaks, töötuskindlustus (töötaja ja tööandja), kogumispension, sotsiaalmaks, neto ja tööandja kulu — VÕI neto → vajalik bruto. Vastuses on ka maksuvaba tulu jaotus (kuu piir, varem kasutatud, jääk enne ja pärast seda makset) ja arvutuses kasutatud määrad. Arvutus on marginaalne: arvestab sama töötaja SAMA KUU juba sisestatud väljamakseid (maksuvaba tulu jääk, sotsiaalmaksu miinimum, vähenenud töövõime). Kasuta alati, kui nõu sisaldab maksusummasid (nt „mis oleks bruto, kui neto peab olema X", „kui palju tulumaksu jäi kinni pidamata").

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": {
      "year": "<year>",
      "month": "<month>",
      "personId": "<personId>"
    },
    "name": "calc_salary"
  }
}

Input Schema

NameRequiredDescriptionDefault
netNoSoovitud neto EUR — tagastab vajaliku bruto
typeNoSALARY = töötasu (vaikimisi), BOARD_FEE = juhatuse liikme tasu
yearYesAasta, nt 2026
grossNoBrutosumma EUR — anna gross VÕI net, mitte mõlemat
monthYesKuu 1–12 (väljamakse / TSD kuu)
personIdYesTöötaja id (get_payroll_overview vastusest)
excludePaymentIdNoOlemasoleva väljamakse id (get_payroll_overview maksed[].paymentId), mis jäetakse kontekstist välja — kasuta, kui arvutad ÜMBER juba sisestatud väljamakset (nt „mis peaks 31.03 makse bruto olema, et neto oleks X").

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, so the description is free to add real behavioral context — and it does: the calculation is marginal and pulls in the same employee's same-month payments (tax-free remainder, social-tax minimum, reduced work capacity), and the reply includes the tax-free income split before/after this payment plus the rates applied. It also discloses the gross-XOR-net input contract. Nothing contradicts the read-only annotation.

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?

The core action and the bidirectional modes are front-loaded in the first sentence, with secondary behavior (tax-free split, marginal logic) and the usage trigger following in a sensible order. It is dense but every clause carries information; a slightly tighter split into shorter sentences would help readability.

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, and the description compensates fully by enumerating what comes back (income tax, employee/employer unemployment insurance, pension, social tax, net, employer cost, tax-free income distribution, rates used). For a 7-parameter financial calculation with marginal same-month dependencies, an agent has everything needed to call it correctly.

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 value by framing gross and net as opposite entry directions with different outputs (bruto → full breakdown, neto → required gross) and by tying excludePaymentId to the marginal same-month logic. It does not restate per-parameter details, which are already in the schema.

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?

States a precise verb (calculate) and resource (tax breakdown of one payment) and spells out both directions, gross→net components and net→required gross. The '(uue) väljamakse' scoping and the marginal-calculation note make it distinguishable from the payroll-reading sibling get_payroll_overview without opening any schema.

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?

Gives a strong positive trigger: 'Kasuta alati, kui nõu sisaldab maksusummasid', backed by two concrete user phrasings ('mis oleks bruto, kui neto peab olema X', 'kui palju tulumaksu jäi kinni pidamata'). It also explains when excludePaymentId applies (recalculating an existing payment). It stops short of an explicit when-not-to-use or a named alternative, 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.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources