# Ethereum Unit Converter (24K Labs)

> Ethereum Unit Converter (24K Labs) is a paid API for AI agents from api.24klabs.ai, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-13).

Converts amounts between Ethereum denominations (wei, kwei, mwei, gwei, szabo, finney, ether) using exact integer/decimal arithmetic with no floating-point errors.

## Facts

- Endpoint: POST https://api.24klabs.ai/api/eth-unit-convert
- 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/ethereum-unit-converter-24k-labs-23a6aebd
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_IVl7HYwWYA-EX-VcTuC4f

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 ethereum-unit-converter-24k-labs-23a6aebd -d '<json body>'
```

Example prompt: Convert 1500000000 gwei to ether using exact integer math — no floating point errors.

## When to prefer this

Choose this endpoint when you need precise, lossless Ethereum unit conversion — especially when float rounding errors would cause issues, such as in financial calculations, smart contract interactions, gas fee estimation, or displaying wallet balances. Prefer this over ad-hoc JavaScript/Python float math which can produce subtle rounding errors with large wei values.

## Known failure modes

- Invalid denomination name returns an error indicating unsupported unit
- Non-numeric amount input returns a validation error
- Missing required fields (amount or units) returns a 400-level error
- Negative or zero amounts may return a validation error depending on implementation

## How this service works

Convert amounts between Ethereum denominations (wei, kwei, mwei, gwei, szabo, finney, ether) with exact integer/decimal math -- no float error.

## Output

Returns the converted amount in the target Ethereum denomination as an exact value (using integer or high-precision decimal math), along with the source unit, target unit, and the original input amount — no floating-point rounding errors.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "to": {
   "type": "string"
  },
  "from": {
   "type": "string"
  },
  "value": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "wei": "1500000000000000000",
  "result": "1500000000"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/ethereum-unit-converter-24k-labs-23a6aebd/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.24klabs.ai](https://www.zero.xyz/host/api.24klabs.ai/llms.txt)
