# Crypto Unit Converter (ETH ↔ Wei)

> Crypto Unit Converter (ETH ↔ Wei) is a paid API for AI agents from api.api-agent-ia.ch, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-23).

Converts cryptocurrency values between units (e.g. ETH to wei, gwei to ETH) given a source unit, target unit, and numeric value

## Facts

- Endpoint: GET https://api.api-agent-ia.ch/convertir-unites?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/crypto-unit-converter-eth-wei-bd991d27
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0ONBBet5D6hwcS67wWJ82

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 crypto-unit-converter-eth-wei-bd991d27
```

Example prompt: Convert 2.5 ETH to wei for me — what's the equivalent value in wei?

## When to prefer this

Use this endpoint when you need precise, server-side conversion between Ethereum denomination units (ETH, gwei, wei) without implementing the math locally. Particularly useful in agents handling smart contract interactions, gas calculations, or displaying blockchain values to users in a preferred denomination.

## Known failure modes

- Missing required query parameters (valeur, unite_source, or unite_cible) returns an error
- Unsupported unit names result in an error response
- Non-numeric value in valeur field causes a parse error
- Payment not included triggers a 402 Payment Required response

## How this service works

Need to convert ETH, gwei or wei without floating-point errors? Converts an amount between these units with exact decimal math, up to 28 significant digits ($0.001 per call).

## Output

A JSON object containing the input value, the source unit, the target unit, and the converted output value as a string (e.g. {valeur_entree: '1', unite_source: 'eth', unite_cible: 'wei', valeur_sortie: '1000000000000000000'})

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "valeur",
      "unite_source",
      "unite_cible"
     ],
     "properties": {
      "valeur": {
       "type": "string"
      },
      "unite_cible": {
       "type": "string"
      },
      "unite_source": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "unite_cible": "gwei",
  "unite_source": "eth",
  "valeur_entree": "1.5",
  "valeur_sortie": "1500000000.0"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/crypto-unit-converter-eth-wei-bd991d27/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.api-agent-ia.ch](https://www.zero.xyz/host/api.api-agent-ia.ch/llms.txt)
