Issue
The issue in this article is that a customer was unable to pay with an American Express card, even when the payment method was configured correctly in Quickpay. After providing the payment information in the payment window; Quickpay responded with the error “The card type used is not supported”.
![This is an image of the error generated from Quickpay.](https://fjakkarin.com/wp-content/uploads/2024/07/IMG-20240724-WA0000-edited.jpg)
Context
To fully understand this issue and solution it is helpful to understand the context for the functionality.
In this context the system e-conomic is used for invoicing. This system has a integration option with the payment service Quickpay. You can read more about this integration on this page. With this integration the seller can offer the customers to pay their invoices online using Quickpay; the following quote is for the integration page:
When you send your customers an invoice from e-conomic, they receive a guide and a link where they will be able to pay the invoice using credit card.
Quickpay offers a range of payment options. For each of these options, there needs to be a acquirer agreement to enable the payment options (the details of this process are outside the scope of this article).
In this context the systems are configured with a acquirer agreement with Nets. This agreement supports the payment options: Dankort, Visa, MasterCard and American Express.
The last significant detail is that the system owner is a Greenlandic company. Greenlandic companies operate in some aspects in a sphere between the danish and greenlandic structure. For example in regards to acquirer agreements, the greenlandic companies contact danish acquirer providers. This is the reason for using the provider Nets. The default currency in Greenland is the danish krone.
Debugging
Now, that we have an understanding of the context in which this issue occurred, lets dig deeper into the issue.
After being made aware of the failed payment the first sign from the system was the missing American Express icon from the payment window. This issue was also confirmed by the Quickpay support staff, by providing this debug message:
WARN Invalid payment methods: [
{
"brand"=>"american-express",
"cardnumber_length"=>[15, 19],
"cvd_length"=>4
}
]
active acquirers: [
"nets",
"teller"
]
selected:
lock: []
available payment methods: [
"3d-dankort",
"3d-mastercard",
"3d-mastercard-debet",
"3d-visa",
"3d-visa-electron",
"dankort",
"mastercard",
"mastercard-debet",
"visa",
"visa-electron"
]
From the message is is clear, that the american-express option is missing from the available payment methods list. Why?
The acquirer settings for American Express where correct; this was confirmed by the support staff as well. But the Quickpay service gave us a hint, that not all was well.
In Quickpay it is possible to specify the standard payment option. This is on the page the settings > integration and you can read more about the different combination on this page.
This option was used to specify that american-express should be the only available option. This resulted in a failed payment window, meaning that there was something fishy with the configuration setting for American Express in Quickpay.
Confirm issue with payment_methods
As a side-note, this issue could also be confirmed by using the URL parameter: payment_methods=american-express.
Read more on the e-conomic integration page.
Summery: The payment American Express method is missing from the payment window and when the Quickpay service is forced to display the same payment method; it results in a error: The payment card is not supported.
Where could the issue be: could this be an issue with acquirer or was there a configuration issue we were missing in the Quickpay.
Solution
While we were exploring issues with the acquirer, the Quickpay support came with a suggestion:
Try changing the country in the settings from Greenland to Denmark.
This did the trick. Now, the American Express logo showed up on the payment window and subsequently the customer could make her payment.
As an engineer, we always search for understanding, and it turned out that the agreement with American Express was explicit to a company registered in Denmark (which a Greenlandic company is, as they are all part of the danish company register). At least, this was the explanation that the support staff provided.