# Percentage Calculator API

> Percentage Calculator API is a paid API for AI agents from api.x402node.dev, paid per call via x402, $0.0022/call, status unknown (last checked 2026-09-13).

Computes percent operations including percent of a value, percent change between two values, and percent increase/decrease

## Facts

- Endpoint: GET https://api.x402node.dev/math/percentage
- Price: $0.0022/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/api-x402node-dev-60460296
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_8tySVjR77Rg7U-AuTG9Vz

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 api-x402node-dev-60460296
```

Example prompt: What is 18% of 245, and what's the percent change if that number increases to 312?

## When to prefer this

Use this endpoint when you need programmatic, server-side percentage computations embedded in an agent workflow — especially for tip calculations, discount pricing, margin analysis, or percent change reporting where you need a reliable numeric result without implementing math logic yourself.

## Known failure modes

- Missing required input values X or Y returns 400 error
- Invalid operation type returns 400 bad request
- Non-numeric inputs return validation error
- Division by zero when Y is zero in 'what percent' operations
- Payment not provided or insufficient USDC returns 402 Payment Required

## How this service works

Percentage calculator, percent of, percent change, percent increase decrease, what percentage, tip calculator, discount calculator, markup, margin. Compute percent operations: X percent of Y, what percent X is of Y, percent change from X to Y, X increased or decreased by Y percent. Accepts payment on Base or Solana — either network works.

## Output

Returns the computed numeric result of the requested percentage operation, such as the calculated amount, the percentage value, or the percent change between two numbers, depending on the operation type specified.

## 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",
     "properties": {
      "a": {
       "type": "string",
       "description": "First input (optional)"
      },
      "b": {
       "type": "string",
       "description": "Second input (optional)"
      },
      "op": {
       "type": "string",
       "description": "Op (optional)"
      }
     }
    }
   },
   "additionalProperties": false
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/api-x402node-dev-60460296/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.x402node.dev](https://www.zero.xyz/host/api.x402node.dev/llms.txt)
