Skip to main content
Glama

Sales Tax Calculator API - add or reverse sales tax for one or many amounts

sales_tax_calculator
Read-onlyIdempotent

Add sales tax to net prices or back out sales tax from totals (single or batch amounts), using a custom rate %, US state base rate (all 50 states + DC) and optional local city/county rate. Runs on our server, files are deleted right after the call, nothing stored. Free: 5 calls/day per IP. Paid: Radar API key (from €15/mo at https://radarbg.com/pricing#starter via X-API-Key) or $0.001/call via x402 at https://radarbg.com/x402/sales-tax-calculator.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "mode": "add",
      "amounts": "49.99\n120\n8.50",
      "ratePercent": "8.25"
    },
    "name": "sales_tax_calculator"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNoadd (price -> total) or reverse (total -> net + tax)add
stateNo2-letter US state code for base rate, e.g. CA, TX, NY (optional)
amountsYesPrices or totals, newline-separated (or JSON array)
ratePercentNoCustom tax rate % (optional if state is given)8.25
localPercentNoOptional local city/county rate % to add

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.3/5.0
Behavior5/5

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

Goes well beyond the readOnly/openWorld/idempotent annotations by disclosing the privacy posture (server-side run, files deleted after the call, nothing stored), the free-tier rate limit (5 calls/day per IP), and exactly how to authenticate (X-API-Key from a paid plan, or $0.001/call via x402). Those are the operational facts an agent needs before invoking a paid, rate-limited endpoint.

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-loads the computational purpose in the first sentence, then appends operational terms (privacy, quota, pricing). Dense but nearly every clause carries information; the pricing URL and long payment sentence are the only slightly bulky element.

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 still covers usage mode, rate sourcing, access, cost, and caching/storage behavior, which is most of what a caller needs. It does not indicate what a batch response looks like (e.g., whether per-amount net/tax/total breakdown is returned), leaving one real gap for a no-output-schema tool.

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 the enum for mode, the newline-separated amounts format, and the state/local/rate fields are already documented in structured fields. The description adds only a little framing (50 states + DC coverage, local rate is optional) and no format or precedence detail beyond the schema, which is the expected baseline when the schema does the heavy lifting.

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?

Names specific verbs (add sales tax / back out sales tax) and the resource (net prices or totals), and delimits scope precisely as US sales tax with 50 states + DC plus optional local rates — which implicitly separates it from the EU VAT sibling. An agent can tell both what it computes and which inputs drive the rate.

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?

The two operating modes are stated plainly ('add sales tax to net prices or back out sales tax from totals') and the rate-source choice (custom rate % versus state base rate plus optional local rate) is laid out, giving clear context for selection. It stops short of naming an exclusion or pointing at the eu_vat_calculator sibling for non-US jurisdictions, so it is good context rather than full routing guidance.

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