units_convert
Exact big-number conversion between base units and display units: wei/gwei/ether, lamports/SOL, or any token with a given number of decimals. 0.001 USDC per call via x402.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | wei, gwei, ether, lamports, sol, or units | |
| from | Yes | wei, gwei, ether, lamports, sol, or units (base units) | |
| value | Yes | Amount to convert | |
| decimals | No | Token decimals when from/to is units vs token (default 18) | |
| paymentProof | No | Payment proof: USDC tx hash on Polygon or Base (0x...) or Solana tx signature. Omit on the first call to receive the 402 payment instructions, pay, then call again with the proof. |