Using the createPayment() API method with foreign currencies
Problem reported by Richard Cooper 11 years ago
I'm trying to use the createPayment() API method to add a payment to a US dollar bank account.
In my testing I've found a few problems
- The documentation says amount="The total amount paid in pounds". That's not correct. It's actually the total amount in the currency of the bank account being used.
- The documentation doesn't mention the fxRate parameter which is important when creating foreign currency payments
- createPayment() will happily accept a payment to a foreign currencies bank account without requiring fxRate to be supplied. That creates a payment with a NULL fxRate, which would be impossible to create via the website.
That broken payment creates all sorts of problems in the website. For example in the customer's full statement the "total" doesn't equal the sum of the individual payments.
And in the running balance the broken payment is treated as if it had an exchange rate of £1 = $1