# Delx Gross Margin

> Delx Gross Margin is a paid API for AI agents from api.delx.ai, paid per call via x402, $0.003/call, status unknown (last checked 2026-09-13).

Calculates gross profit, gross margin percentage, and profitability from cost and price inputs

## Facts

- Endpoint: POST https://api.delx.ai/api/v1/x402/gross-margin
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-13
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-gross-margin-31edc316
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0l49FMVqpvEUZ3d5x-nHr

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 delx-gross-margin-31edc316 -d '<json body>'
```

Example prompt: What's the gross margin and gross profit if my product costs $42.50 to make and I'm selling it for $79.99?

## When to prefer this

Use this endpoint when you need a fast, cheap, deterministic gross margin calculation as a preflight or analysis step inside an agent workflow — especially when you want stateless, local-only computation with no data retention. Prefer this over general-purpose LLM math when you need machine-readable JSON output, consistent precision, and a guaranteed formula rather than an approximated answer.

## Known failure modes

- Missing required field (cost or price) returns a validation error
- Non-numeric values for cost or price return a type error
- Price of zero may cause division-by-zero handling in margin calculation
- Negative cost or price values may return unexpected or undefined results

## How this service works

Calculate gross profit, gross margin, and profitability. Use it as a bounded preflight or analysis step inside an enterprise agent workflow before data, policy, integration, security, or commercial decisions reach production. Returns deterministic machine-readable JSON for $0.003 USDC via x402 on Base. Execution is first-party, local-only, stateless, memory-only, and has no paid upstream or input retention. Results are advisory; the caller remains responsible for authorization and production co…

## Output

Returns a deterministic JSON object containing gross profit (price minus cost), gross margin percentage, and profitability indicators — all computed locally with no external calls or data retention.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "cost": {
   "type": "number",
   "description": "Input field: cost."
  },
  "price": {
   "type": "number",
   "description": "Input field: price."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "cost": 35,
  "price": 100,
  "schema": "delx/util-gross-margin/v1",
  "profitable": true,
  "gross_profit": 65,
  "gross_margin_percent": 65
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/delx-gross-margin-31edc316/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)
