# Gross Profit Distribution Histogram

> Gross Profit Distribution Histogram is a paid API for AI agents from market.datapackvibe.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-22).

Bins up to 200 gross profit observations (revenue minus cost of sales) into equal-width histogram bins, returning bin edges, counts, formula, units, and limitations as JSON.

## Facts

- Endpoint: POST https://market.datapackvibe.com/x402/assistant-finance-gross-profit-histogram?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/gross-profit-distribution-histogram-45b84f3b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_hBdmFqf6fWccX2yXl5SAy

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 gross-profit-distribution-histogram-45b84f3b -d '<json body>'
```

Example prompt: Can you bin my gross profit data into 10 equal-width histogram buckets? Here are my observations: period 1 revenue $500,000 cost of sales $310,000, period 2 revenue $480,000 cost of sales $295,000, period 3 revenue $520,000 cost of sales $330,000 — I want the bin edges, counts, and the formula used.

## When to prefer this

Choose this endpoint when you need a statistical frequency distribution (histogram) of gross profit values across multiple observations — specifically when you want equal-width bins with explicit edge definitions for use in charts or further analysis. Prefer this over a summary statistics endpoint when the shape or spread of the distribution matters, not just mean/median. Best for datasets of 2–200 periods where gross profit = revenue − cost of sales is the right metric (not operating profit or net profit).

## Known failure modes

- Fewer than 2 rows supplied — minimum 2 observations required
- More than 200 rows supplied — exceeds maximum item count
- bins parameter outside 1–30 range — validation error returned
- Missing required fields (revenue or cost_of_sales) on any row — schema validation failure
- Negative cost_of_sales values — field requires non-negative numbers
- Revenue or cost_of_sales values exceeding ±1 trillion — out of range
- Inconsistent currencies across rows — no conversion performed, results may be misleading

## How this service works

Gross profit - Distribution histogram: Bin up to 200 calculated observations into equal-width bins, including edge definitions. Metric: Gross profit. Supplied figures only; returns JSON with formula, units and limitations. One of 50 calculators with 20 analysis modes. No live feed, financial advice or trade execution. 0.01 USDC includes one bounded distribution histogram report.

## Output

A JSON response containing the histogram bin edges (defining equal-width intervals), the count of gross profit observations in each bin, the formula used (gross profit = revenue − cost of sales), the currency/units assumption, and any limitations of the analysis. Up to 30 bins across up to 200 input rows.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "bins": {
   "type": "integer",
   "default": 5,
   "maximum": 30,
   "minimum": 1
  },
  "rows": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "revenue",
     "cost_of_sales"
    ],
    "properties": {
     "revenue": {
      "type": "number",
      "default": 10000,
      "maximum": 1000000000000,
      "minimum": -1000000000000,
      "description": "Amount in a consistent supplied currency and reporting period"
     },
     "cost_of_sales": {
      "type": "number",
      "default": 6000,
      "maximum": 1000000000000,
      "minimum": 0,
      "description": "Amount in a consistent supplied currency and reporting period"
     }
    },
    "additionalProperties": false
   },
   "default": [
    {
     "revenue": 10000,
     "cost_of_sales": 6000
    },
    {
     "revenue": 11000,
     "cost_of_sales": 6600.000000000001
    },
    {
     "revenue": 10000,
     "cost_of_sales": 6000
    },
    {
     "revenue": 11000,
     "cost_of_sales": 6600.000000000001
    }
   ],
   "maxItems": 200,
   "minItems": 2
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/gross-profit-distribution-histogram-45b84f3b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from market.datapackvibe.com](https://www.zero.xyz/host/market.datapackvibe.com/llms.txt)
