# ForgeMesh Shape Math Calculator

> ForgeMesh Shape Math Calculator is a paid API for AI agents from x402.forgemesh.io, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-13).

Calculates area, perimeter, and diagonal length for circles, rectangles, triangles, and 3D shapes from plain numeric dimensions, including Heron's formula for triangles given three sides.

## Facts

- Endpoint: POST https://x402.forgemesh.io/area-perimeter-calculator
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forgemesh-shape-math-calculator-f149d4bc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_qcSyNCB87BPEHXYAMuoLl

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 forgemesh-shape-math-calculator-f149d4bc -d '<json body>'
```

Example prompt: Calculate the area, perimeter, and diagonal length of a rectangle that's 12.5 meters wide and 8.3 meters tall.

## When to prefer this

Use this endpoint when you need precise geometric calculations — area, perimeter, or diagonal — for standard shapes including circles, rectangles, triangles, and 3D variants (sphere, cylinder, cone, cube, rectangular prism). Ideal for flooring and construction estimates, land-plot sizing, classroom geometry, or CAD pre-checks where an exact numeric result is required rather than an approximation.

## Known failure modes

- Missing required dimensions for the specified shape — returns error indicating which parameters are needed
- Invalid shape type string not matching the enum — returns unrecognized shape error
- Non-numeric values passed for dimension fields — returns parse/validation error
- Degenerate shape inputs (e.g. triangle sides violating triangle inequality) — may return NaN or error

## How this service works

Shape math calculator for area, perimeter, and diagonal length of circles, rectangles, and triangles from plain numeric dimensions — includes Heron's formula for triangles given three sides. Useful for flooring estimates, land-plot sizing, classroom geometry problems, and CAD pre-checks where an exact figure is needed, not an approximation.

## Output

Returns computed geometric properties (area, perimeter, diagonal) for the requested shape based on the provided dimensions. For triangles with three sides, Heron's formula is applied to derive area.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "a": {
   "type": "string"
  },
  "b": {
   "type": "string"
  },
  "c": {
   "type": "string"
  },
  "base": {
   "type": "string"
  },
  "side": {
   "type": "string"
  },
  "shape": {
   "type": "string",
   "description": "circle|rectangle|triangle|sphere|cylinder|cone|cube|rectangular_prism"
  },
  "width": {
   "type": "string"
  },
  "height": {
   "type": "string"
  },
  "length": {
   "type": "string"
  },
  "radius": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "shape": "sphere",
  "volume": 523.598776,
  "surface_area": 314.159265
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forgemesh-shape-math-calculator-f149d4bc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.forgemesh.io](https://www.zero.xyz/host/x402.forgemesh.io/llms.txt)
