Back to Samples

Currency denomination

It is a sample code that would retrieve a user’s input for a foreign currency amount and determines
a mix of currency to satisfy this amount based on what is available in inventory.
What it’s doing:
For a simple example, the user requests 5,245 CAD and the available denominations are 5, 10, 20, 100, 500.
Assume the browser sends the location_id, currency_code, and amount entered by the user to the system.

Denomination information: Amount:



Denomination result: