# Drawdown Percent Calculator

> Drawdown Percent Calculator is a paid API for AI agents from api.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-15).

Computes the drawdown percentage from a peak price to a trough price for use in risk reports and path risk analysis.

## Facts

- Endpoint: POST https://api.delx.ai/api/v1/x402/drawdown-pct
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/drawdown-percent-calculator-56807c42
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_RbDfgTUh6vyW6Mjm2gHAs

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 drawdown-percent-calculator-56807c42 -d '<json body>'
```

Example prompt: Calculate the drawdown percent for a position where the peak price was 150 and the trough price was 112 — I need it for my risk report.

## When to prefer this

Use this endpoint when you need a quick, deterministic, local-math drawdown percentage calculation from a known peak and trough pair — especially for risk reports, backtesting pipelines, or any workflow where you already have the two price points and just need the percentage computed reliably without any live market feed or external data dependencies.

## Known failure modes

- Missing peak or trough field returns a validation error
- Trough greater than peak may return an error or a positive/unexpected value — caller should ensure trough <= peak
- Non-integer inputs rejected per schema
- Network or payment authorization failure returns HTTP 402 or 4xx

## How this service works

Drawdown percent from peak to trough for risk reports. Call when measuring path risk on an equity or price series peak/trough pair. Returns drawdown percent as deterministic JSON for $0.001 USDC via x402 on Base. First-party local math only—no RPC, live market feed, API keys, storage, or mediagen. Advisory only; the caller owns capital, risk, and production controls.

## Output

A deterministic JSON object containing the computed drawdown percentage from the supplied peak to trough values, suitable for embedding in risk reports or quantitative pipelines.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "peak": {
   "type": "integer",
   "description": "Input field: peak."
  },
  "trough": {
   "type": "integer",
   "description": "Input field: trough."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "peak": 120,
  "schema": "delx/util-drawdown-pct/v1",
  "trough": 90,
  "drawdown_pct": 25
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/drawdown-percent-calculator-56807c42/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.delx.ai](https://www.zero.xyz/host/api.delx.ai/llms.txt)
