# convertaddress
convertaddress coin from to_address_format
The convertaddress
method converts an input address to a specified address format.
For example, this method can be used to convert a BCH address from legacy to cash address format and vice versa.
Or this can be used to convert an ETH address from single to mixed case checksum format.
# Arguments
Structure | Type | Description |
---|---|---|
coin | string | the name of the coin address context |
from | string | input address |
to_address_format | object | address format to which the input address should be converted |
to_address_format.format | string (enum) | address format to which the input address should be converted, possible values: mixedcase for ETH/ERC20 coins; cashaddress or standard for UTXO coins |
to_address_format.network | string (enum) | network prefix for cashaddress format. Possible values: bitcoincash for BCH mainnet; bchtest for BCH testnet; bchreg for BCH regtest |
# Response
Structure | Type | Description |
---|---|---|
result.address | string | the result of address conversion |