Skip to main content
Glama
Replaced by its MCP Registry listing

This endpoint is listed in the official MCP Registry as minia2a — hosted x402 API marketplace (HTTP). If you published it, claim ownership there.

x402-margin-calc

Margin Calc: Computes profit, margin percent, and markup percent from cost and price, or derives price from cost and a target margin percent 🆓 5 free trial calls per signed wallet

Input Schema

NameRequiredDescriptionDefault
costNo
priceNo
marginYes
revenueNo
marginPercentNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / allOf
      Added value: +[
      +  {
      +    "anyOf": [
      +      {
      +        "required": [
      +          "cost"
      +        ]
      +      },
      +      {
      +        "required": [
      +          "marginPercent"
      +        ]
      +      },
      +      {
      +        "required": [
      +          "price"
      +        ]
      +      }
      +    ]
      +  }
      +]
    • addedInput schema / required
      Added value: +[
      +  "margin"
      +]
  2. Changed5 schema fields changed
    • removedInput schema / properties / cost / description
      Removed value: -"Cost to process"
    • removedInput schema / properties / margin / description
      Removed value: -"Margin to process"
    • removedInput schema / properties / marginPercent / description
      Removed value: -"MarginPercent to process"
    • removedInput schema / properties / price / description
      Removed value: -"Price to process"
    • removedInput schema / properties / revenue / description
      Removed value: -"Revenue to process"
  3. First observed

TDQS

B3.1/5.0
Behavior3/5

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

No annotations are supplied, so the description carries the full disclosure burden. It does add real behavioral context beyond the schema: the tool is a pure computation, and it has a metered commercial model ('5 free trial calls per signed wallet'), which signals an auth/billing prerequisite an agent would otherwise not know. It still omits what happens when multiple input combinations are supplied, how rounding is handled, and what the response looks like.

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?

One front-loaded sentence carries the core capability, with the pricing note appended. It is efficient and wastes little space, though the emoji and trial-credit tagline sit awkwardly on the end of a functional definition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no annotations, no output schema, zero schema descriptions, and five loosely-typed string parameters, the description would need to explain the input contract and result shape. It does not — the mandatory 'margin' parameter and the 'revenue' parameter are unexplained, and the output (profit, margin %, markup %) is described only by name with no indication of units or formatting.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across five string parameters, and the description only covers three of them (cost, price, marginPercent). Critically, the single globally required parameter 'margin' is never explained, and 'revenue' is never mentioned at all, leaving the agent to guess how 'margin' relates to 'marginPercent' and what form these strings should take.

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 description gives a specific verb and resource ('Computes profit, margin percent, and markup percent') and names the two operating modes (derive from cost+price, or derive price from cost+target margin). It is clear enough to distinguish from a pure markup or ROI calculator at a glance, but it never explicitly points at sibling tools such as x402-markup-calc or x402-profit-margin, so the boundary is inferred rather than stated.

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 '...or derives price from cost and a target margin percent' clause implicitly tells the agent which input combination selects which mode, which is genuine usage guidance. However, there is no explicit when-to-use/when-not-to-use statement and no routing to the near-identical siblings (markup-calc, profit-margin, gross-margin).

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