MCP Ethers Wallet

formatUnits

Convert a value to a decimal string with specified units

Input Schema

NameRequiredDescriptionDefault
unitYesThe number of decimals or unit name (e.g., 'gwei', 18)
valueYesThe value to format

Input Schema (JSON Schema)

{ "properties": { "unit": { "description": "The number of decimals or unit name (e.g., 'gwei', 18)", "type": [ "string", "number" ] }, "value": { "description": "The value to format", "type": "string" } }, "required": [ "value", "unit" ], "type": "object" }