Skip to main content
Glama

Upsert Tax Rates

upsert_tax_rates
DestructiveIdempotent

Create or update tax rates by name (max 100 per call, case-insensitive match) — the direct fix for the 'tenant has no tax rate configured' blocker on item creation. percentage (0-100) is required when creating; updates are preserve-on-omit. isDefault=true moves the default flag (exactly one live rate stays default). validateOnly=true dry-runs every row. Partial success with per-row errors; resubmitting converges. Requires an operator (unpinned) credential — tax rates are tenant-wide settings.

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": {
      "taxRates": "<taxRates>"
    },
    "name": "upsert_tax_rates"
  }
}

Input Schema

NameRequiredDescriptionDefault
taxRatesYesTax-rate rows to create/update (max 100). name is required per row.
validateOnlyNotrue = dry-run: validate + probe every row and report the would-be action per row, writing nothing.

Output Schema

NameRequiredDescriptionDefault
rowsNo
totalNo
failedNo
createdNo
updatedNo
uomsCreatedNo
validateOnlyNo
enabledCustomersNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the annotations: adds the per-call row cap, preserve-on-omit update semantics, partial success with per-row errors, idempotent resubmission ('resubmitting converges'), and the credential requirement ('requires an operator (unpinned) credential — tax rates are tenant-wide settings'). That auth/permission disclosure is exactly the kind of context annotations cannot express.

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?

Front-loaded with the action and identity rule, then the blocker context, then behavioral caveats. Dense and largely waste-free, though the em-dash-chained phrasing is telegraphic and a reader must re-parse the percentage clause to attach it to creation vs. update.

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?

Output schema exists so return shape needn't be described, yet the description still covers the failure model (partial success, per-row errors) and convergence, plus permission requirements and the default-flag side effect. For a destructive, tenant-wide upsert, nothing an agent needs before calling 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 description coverage is 100%, so the schema already explains name, percentage, isDefault, code, and validateOnly; the description's baseline would be 3. It earns higher by adding semantics not in the schema: the case-insensitive name match, the invariant that exactly one live rate stays default when isDefault=true, and the convergence guarantee on resubmission.

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?

States a specific verb pair and resource: 'Create or update tax rates by name', plus the matching rule (case-insensitive) and the batch cap (max 100). The upsert-by-name identity implicitly distinguishes it from save_tax_rate and delete_tax_rate, but no sibling is named explicitly, which keeps it short of a 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?

Gives a concrete triggering situation — 'the direct fix for the tenant has no tax rate configured blocker on item creation' — and a dry-run path via validateOnly. It does not state when to prefer save_tax_rate or another write tool instead, so the alternative-selection guidance is incomplete.

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