# Unit Convert – Ethereum/Token Unit Converter

> Unit Convert – Ethereum/Token Unit Converter is a paid API for AI agents from 402.com.tr, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-27).

Converts an amount between Ethereum denominations (wei, gwei, ether, etc.) or arbitrary token decimal scales with integer-exact precision.

## Facts

- Endpoint: GET https://402.com.tr/api/x402/unit-convert?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-27
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/unit-convert-ethereum-token-unit-converter-4b1f30b4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_952WTQekxJDQtSuSy1thg

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 unit-convert-ethereum-token-unit-converter-4b1f30b4
```

Example prompt: Convert 1500000000 wei to ether — I need the exact value with no rounding.

## When to prefer this

Use this endpoint when you need integer-exact, lossless unit conversion between Ethereum denominations (wei through ether) or arbitrary ERC-20 token decimal scales. Prefer it over client-side arithmetic when working in sandboxed agent environments without native BigInt support, or when auditability of the conversion is important. Ideal for transaction building, DeFi workflows, and any situation where floating-point errors in ETH/token amounts are unacceptable.

## Known failure modes

- Missing required 'amount' query parameter returns an error
- Unrecognized unit names for 'from' or 'to' return an error
- Non-numeric amount string causes a parse error
- Very large numbers may require special handling depending on response format
- Payment failure (insufficient USDC balance) blocks the request at the x402 layer

## How this service works

Convert an amount between wei, kwei, mwei, gwei, szabo, finney and ether — or between any token decimals (pass a number like 6 for USDC). Integer-exact, no precision loss. Pass amount, from, to. Pure compute, sub-cent — the unit-conversion commodity agents call constantly when building transactions. Not financial advice.

## Output

Returns the converted amount in the target unit as an integer-exact value, with no floating-point precision loss. Response includes the converted amount and likely metadata about the units used.

## 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"
     ],
     "type": "string"
    },
    "pathParams": {
     "type": "object"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "amount"
     ],
     "properties": {
      "to": {
       "type": "string",
       "description": "To unit (or decimals number)"
      },
      "from": {
       "type": "string",
       "description": "From unit (or decimals number)"
      },
      "amount": {
       "type": "string",
       "description": "Amount"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/unit-convert-ethereum-token-unit-converter-4b1f30b4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 402.com.tr](https://www.zero.xyz/host/402.com.tr/llms.txt)
