# Basic Utils Agent – Statistics Median

> Basic Utils Agent – Statistics Median is a paid API for AI agents from basic-utils-agent.up.railway.app, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-13).

Computes the median value from a list of up to 10,000 numeric values.

## Facts

- Endpoint: POST https://basic-utils-agent.up.railway.app/statistics/median
- 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/basic-utils-agent-statistics-median-896cec1f
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ECeTx_f9LLbboMopN2Y9_

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 basic-utils-agent-statistics-median-896cec1f -d '<json body>'
```

Example prompt: Can you find the median of these numbers: 4, 7, 2, 9, 1, 5, 8, 3, 6?

## When to prefer this

Choose this endpoint when you need a fast, reliable median calculation on a numeric array of up to 10,000 values and want to offload the computation rather than run it locally. Particularly useful within agent workflows where statistical descriptive metrics are needed on the fly without spinning up a data science stack.

## Known failure modes

- Empty array submitted — may return an error or undefined result
- Array exceeds 10,000 elements — may be rejected or truncated
- Non-numeric values in the array — schema validation failure
- Malformed JSON request body — 400 Bad Request
- Service unavailable on Railway — 502 or timeout

## How this service works

A versatile utility agent offering calculator, statistics, datetime, and unit conversion services.

## Output

Returns a JSON object with a single field 'median' containing the computed median value of the submitted numeric array. For odd-length arrays this is the middle value; for even-length arrays it is the average of the two middle values.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "data": {
   "type": "array",
   "items": {
    "type": "number"
   },
   "description": "List of numeric values for statistical analysis. Maximum length: 10000"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "median": 3
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/basic-utils-agent-statistics-median-896cec1f/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from basic-utils-agent.up.railway.app](https://www.zero.xyz/host/basic-utils-agent.up.railway.app/llms.txt)
