Selecting a currency
Learn how to determine whether a currency is supported and how it is prioritized.
Checkouts require a currency
that conforms to the ISO 4217 standard.
However, not all currencies contained in the ISO 4217 list are supported in the Digital River APIs. Instead, the currency
you pass must be supported by the payment method used to fund the transaction.
You should also remember that the currency
you send in a POST/checkouts
or POST/checkouts/{id}
always takes priority over the value you pass when creating the payment source.
Supported currencies
Refer to the Payment method guide to access a list of available currencies for each supported payment method.
If the currency
you send in a create or update Checkout request that is not supported by the source, you receive the following error:
You might also receive a 409 Conflict
response that contains a code
of invalid_parameter
. In this case, the error could have been thrown because currency
consisted of incorrect characters, an obsolete, Euro-zone currency, or another currency no longer in circulation.
How currency is prioritized
For some payment methods, it's required that you set currency
in the configuration object of createSource()
, while for others it's optional.
However, if you do pass currency
, and then attach the source to a checkout, the source's currency
doesn't need to match the checkout's currency
. Both values just have to be supported by the underlying payment method.
The checkout's currency
always takes priority over the source's currency
. This means, upon order creation, we generate a charge in the checkout's currency
.
The following example demonstrates this concept. In this case, a payment source created in USD
is attached to a checkout with a currency
of HKD
. After the checkout is converted to an order, the order's payment.charges[].currency
is also HKD
.
Last updated