Exchange API Use Case
Learn a typical use case of Cripto InterCombio Exchange API:
- API — get a list of currently available currencies from the getCurrencies or getCurrenciesFull response.
- GUI — ask a user to select an exchange currency pair.
- GUI — ask a user to enter an exchange amount.
- API — call the getExchangeAmount method to get an estimated amount.
- GUI - deduct
networkFeefrom the estimated amount (amountTo) to get the exchange amount. - GUI — show the calculated amount to user.
- GUI — ask a user for confirmation.
- GUI — ask a user for their wallet address to send coins after the exchange.
- API — call the validateAddress method to validate the user wallet address for a given currency.
- API — call the createTransaction method to get the address for sending user funds.
- GUI — ask user to send coins to the address for the exchange.
info
For the currencies with multiple outputs in a transaction (BTC, LTC, etc), we do not accept more than one output per address in one transaction.