# Pricing Math – Tiered Quantity Pricing Calculator

> Pricing Math – Tiered Quantity Pricing Calculator is a paid API for AI agents from pricing-math.x402tookit.com, paid per call via x402, $0.02/call, status unknown (last checked 2026-10-29).

Calculates total cost and average unit price for a given quantity under graduated (per-band) or volume (all-units-at-reached-tier) pricing tiers defined as minQty:unitPrice pairs.

## Facts

- Endpoint: GET https://pricing-math.x402tookit.com/price-tiers?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-29
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pricing-math-tiered-quantity-pricing-calculator-98c2cf68
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_1TZfrdtFIUjaOJq9u7qEO

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability pricing-math-tiered-quantity-pricing-calculator-98c2cf68
```

Example prompt: Using graduated pricing with tiers 1:10, 10:9, 50:8 (minQty:unitPrice), what's the total cost and average unit price if I buy 75 units?

## When to prefer this

Use this endpoint when you need to compute order costs under structured quantity-based pricing with either graduated (staircase) or volume (all-units-at-tier) logic. It is ideal for B2B procurement, wholesale, SaaS seat licensing, or any scenario where unit prices change at defined quantity thresholds. Prefer it over manual calculation when tier structures are complex or when you need a per-band cost breakdown alongside the total.

## Known failure modes

- Missing required tiers or quantity parameters returns an error
- Tiers not starting at minQty of 1 may cause unexpected results
- Non-integer quantity values may be rejected
- Malformed tier string (not minQty:unitPrice,… format) returns a parse error
- Quantity of zero or negative numbers likely returns an error or zero total

## How this service works

Total and average unit price for a quantity under graduated or volume tiers given as minQty:unitPrice pairs.

## Output

Returns total price for the given quantity, average unit price, a per-band breakdown showing units consumed in each tier with subtotals, the total under the alternative pricing mode for comparison, the mode used, and a human-readable summary string.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "tiers",
      "quantity"
     ],
     "properties": {
      "mode": {
       "type": "string",
       "description": "graduated (default: each band at its own price) or volume (all units at the reached tier price)"
      },
      "tiers": {
       "type": "string",
       "description": "Comma-separated minQty:unitPrice, first minQty 1, e.g. 1:10,10:9,50:8"
      },
      "quantity": {
       "type": "number",
       "description": "Whole number of units bought"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "asOf": {
       "type": [
        "null",
        "string"
       ]
      },
      "mode": {
       "type": [
        "null",
        "string"
       ]
      },
      "total": {
       "type": [
        "null",
        "number"
       ]
      },
      "source": {
       "type": [
        "null",
        "string"
       ]
      },
      "reasons": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type": "string"
       }
      },
      "summary": {
       "type": [
        "null",
        "string"
       ]
      },
      "verdict": {
       "type": [
        "null",
        "string"
       ]
      },
      "degraded": {
       "type": [
        "boolean",
        "null"
       ]
      },
      "quantity": {
       "type": [
        "null",
        "number"
       ]
      },
      "breakdown": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type": "object",
        "properties": {
         "toQty": {
          "type": [
           "null",
           "number"
          ]
         },
         "units": {
          "type": [
           "null",
           "number"
          ]
         },
         "fromQty": {
          "type": [
           "null",
           "number"
          ]
         },
         "subtotal": {
          "type": [
  
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pricing-math-tiered-quantity-pricing-calculator-98c2cf68/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from pricing-math.x402tookit.com](https://www.zero.xyz/host/pricing-math.x402tookit.com/llms.txt)
