# IranTools Human Bytes Formatter

> IranTools Human Bytes Formatter is a paid API for AI agents from irantools.johnaio281.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-22).

Converts a raw byte count (as string) into a human-readable file size string (e.g. '1.5 MB')

## Facts

- Endpoint: POST https://irantools.johnaio281.workers.dev/api/iran/human_bytes?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-22
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/irantools-human-bytes-formatter-c4c8ef05
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ACCc4NyhZjIayWcATThHK

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 irantools-human-bytes-formatter-c4c8ef05 -d '<json body>'
```

Example prompt: Can you convert 1073741824 bytes into a human-readable file size like '1 GB'?

## When to prefer this

Use this endpoint when you need a quick, pay-per-call byte formatting utility with no API key or signup, especially within pipelines already using the IranTools suite for Persian/Iranian data utilities. Suitable for lightweight formatting needs within serverless or agent workflows.

## Known failure modes

- Missing required 'bytes' field returns validation error
- Non-numeric string in 'bytes' field may cause parsing failure
- Extremely large numbers may produce unexpected formatting
- Payment failure (x402) blocks call if USDC balance is insufficient

## How this service works

Persian and Iranian utilities for AI agents, plus general text/Unicode tooling. Jalali (Solar Hijri) calendar conversion, Iranian national ID / SHEBA / bank card / postal code / economic code validation, province and city lookup, official public holidays, Persian text normalization, keyword extraction, sentence splitting, similarity, HTML stripping, RTL fixing, Unicode homoglyph folding, script detection, NFC/NFD normalization, grapheme counting, date description, business-day counting, slugify, FNV-1a hashing, Shannon entropy, format and encoding detection, byte sizes. Pay per call in USDC on Base via x402 - no signup, no API key, no KYC. The same tools are also exposed as MCP tools at /mcp.

## Output

Returns a human-readable file size string representing the input byte count, such as '1.5 MB', '2 GB', or '512 KB', formatted for display to end users.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "bytes"
 ],
 "properties": {
  "bytes": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "additionalProperties": true
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/irantools-human-bytes-formatter-c4c8ef05/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from irantools.johnaio281.workers.dev](https://www.zero.xyz/host/irantools.johnaio281.workers.dev/llms.txt)
