Requested amount & currency

Requested Amount and Currency allow you to specify the value a deposit should have, in a range of currencies (including fiat).

When using getDepositAddress or getDepositUrl with a referenceId , you may additionally specify the amount you expect to receive in a range of currencies. If amount-matching is enabled in the Developer-settings on AkashicPay, the referenceId will only be attached to the callback for a deposit matching the requested amount.

Important Points

  • Amount-matching is optional and can be configured on the Dashboard's developer settings.

    • It is enabled by default

  • Amounts are matched up to 2 decimal places.

  • If specifying a currency different from the one of the deposit, the exchange rate at the time of requesting the address/url is used (particularly relevant for amounts in fiat)

  • Callbacks are still sent for all deposit (if the callback URL is correctly configured), regardless of matching or not. The difference is the inclusion of the referenceId and depositRequest fields

    • depositRequest will have the exchangeRate and requestedValue (see Deposit Callback for details)

Supported Currencies

You may request an amount in the following fiat currencies:

  • CNY (Renminbi/Chinese Yuan)

  • HKD (Hong Kong Dollar)

  • TWD (New Taiwan Dollar)

  • USD (United States Dollar)

  • CHF (Swiss Franc)

  • EUR (Euro)

  • IDR (Indonesian Rpiah)

  • INR (Indian Rupee)

  • JPY (Japanese Yen)

  • KHR (Cambodian Riel)

  • KRW (South Korean Won)

  • MYR (Malaysian Ringgit)

  • PHP (Philippine Peso)

  • SGD (Singapore Dollar)

  • THB (Thai Baht)

  • VND (Vietnamese Đồng)

And the following cryptocurrencies:

  • TRX (Tron)

  • ETH (Ethereum)

  • USDT (TRX)

  • USDT (ETH)

The deposit may be settled in any of the supported cryptocurrencies:

  • TRX (Tron)

  • ETH (Ethereum)

  • USDT (TRX)

  • USDT (ETH)

Example

Note: The code on this page should be regarded as pseudocode. Refer to the pages in the documentation describing the specific functions for details in every supported language.

Let's say you want user user1 to make a deposit with value equivalent to 10 CNY and that you want the user to use the Tron Network. First, you would ask for a deposit address like so:

AkashicPay.getDepositAddressWithRequestedValue('TRX', 'user1', 'order-123', 'CNY', '10.00')

In return, you would get an address to supply to the user. You can inform them to deposit an amount of cryptocurrency equivalent to 10 CNY into that address.

At the time of this request, imagine 1 TRX is worth 2 CNY exactly. If the user then makes a deposit of 5 TRX, the order will be satisfied and the callback will include the following extra fields (see Deposit Callback for complete callback details):

{
...,
"referenceId": "order-123",
"depositRequest": {
    "exchangeRate": "2.00"
    "requestedValue": {
        "amount": "10.00",
        "currency": "CNY"
        },
    },
...
}

However, if the user instead deposited e.g. 10 TRX the order would not be satisfied and the above fields would not be included in the callback (though a callback is still sent!). Only upon an exact match will the order be satisfied and the callback populated.

NOTE: Deposit-Requests expire after 1 Day (24hrs)!

  • After 24 hours, a user may still deposit and you will still receive the funds, but the referenceId will have expired and no amount-matching will take place.

Last updated

Was this helpful?