Skip to main content
Glama

Discount Price Calculator

discount_percent_off
Read-only

Compute the final checkout total after stacked percentage discounts, a fixed coupon, and a tax assumption. Sequential discounts are NOT additive.

Input Schema

NameRequiredDescriptionDefault
couponNoFixed coupon applied after all discounts
taxPctNoTax percent
discount1NoFirst discount percent (0-100)
discount2NoSecond discount percent (0-100)
originalPriceYesOriginal price

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already establish this as a safe, read-only, closed-world computation, so the bar is lower. The description adds the key behavioral rule that discounts stack sequentially rather than additively, which is the main thing an agent could get wrong.

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

Conciseness5/5

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

Two tight sentences with zero filler, and the critical non-additive warning is front-loaded where it will be read before the agent fills the schema.

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 name the output (final checkout total), which is sufficient. It could mention rounding/currency or what happens when only originalPrice is supplied, but nothing essential is missing for correct invocation.

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 earns an extra point by clarifying the relationship between parameters that the schema does not state: discounts apply sequentially and the coupon is fixed, giving meaning to how discount1/discount2 combine.

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 and resource: computing the final checkout total from stacked percentage discounts, a fixed coupon, and tax. It is clearly distinguished from generic sibling calculators like 'percentage' by naming the exact input composition, though it never names an alternative tool explicitly.

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

Usage Guidelines3/5

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

The note that sequential discounts are NOT additive is genuinely useful usage context, and 'a tax assumption' signals this is a modeling tool. However, there is no explicit when-to-use vs when-not-to-use guidance and no pointer to any sibling calculator for simpler percentage math.

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.