Page MenuHomePhabricator

Log client side error for adyen to look into "Typed card number does not match card brand" errors
Closed, ResolvedPublic

Description

We have seen a handful of donors report issues inserting their card details into the donation form, reporting messages that say "typed card number does not match card brand" and "details do not match card type".

Examples:

#1356917: "Have tried to donate more than once but receive a message that my card number doesn’t match the card type. Don’t know what is going on here, but I am confident the information I am entering is correct. Payment method was my Master debit card, which I have previously used to donate to Wikipedia. Can’t do a screen shot without leaving my debit card details on the screen! But the message , in red, is “Typed card number doesn't match card brand”. Web address used is https://payments.wikimedia.org/index.php?title=Special:AdyenCheckoutGateway&appeal=JimmyQuote&country=AU&currency=AUD&payment_method=cc&recurring=0&uselang=en&amount=26&utm_key=vw_1920%7Evh_1039%7EotherAmt_0%7Eptf_1%7Etime_4. Browser is Firefox and it is up to date. Device is a desktop computer running Windows 11, which again, is up to date."

#1371243: "Tried to donate $10, but your webpage does not accept the details of the card. Error message says “details do not match the card type”. Attempted entering details twice, but with the same error. I clearly hit the credit card button. The first four digits of the card are 5402, which should indicate a MasterCard. I used the Vivaldi v5.3.x web browser, and my PC is running Win 10."

#1380442: "I’d like to help, but your online site refuses to recognize my credit card number. The error message says, “Typed card number doesn’t match card brand” - which seems odd, since there’s no place to specify which credit card brand I’m using in the first place. Obviously it’s a tech glitch, because I have no problem using my Visa card for other purchases online."

#1380620: "I have tried several times to donate through the link but it just keeps giving me a message that says "Typed card number does not match card brand" even though I chose "mastercard" and I am certain my card is Mastercard."

We have followed up for more details as we have been unable to reproduce this, but donors are reluctant to share screenshots in case their card numbers are visible.

This is low level, but we'd like to figure it out - and find a workaround for donors.
Any input would be welcome!

Event Timeline

@EMartin @jgleeson because "Typed card number doesn’t match card brand” is such a specific message, would it be worth asking Adyen if / how it originates from their part of the donation flow? Or do we think this might be generated from our part of the form?

I can email Jake if the former.

@MBeat33, We generate the text in the error message after Adyen sends us an error code on the front end related to this problem. We might need to dig into it to confirm it's not being misapplied if the donors are confident it's the right card & brand.

The error text is mentioned in T299788: Translations for the adyen big bundle campaign forms

Ah got it, thanks for the helpful info.

FYI We got another one of these today.

#1380433: "Error Message: "Typed card number doesn't match card brand". I have tried several cards, all of which work for other purchases and get same response." In this one, the donor says they tried 5 different cards and the same error appeared.

This definitely feels like a new thing - did something change? It is odd that we are suddenly seeing these.

Confirming I have raised this with Adyen as well. I will advise their response.

These are how we map the Adyen error codes to friendlier ones in the form:

Adyen errorOur error
error.va.sf-cc-num.01Invalid card number
error.va.sf-cc-num.02Typed card number doesn't match card brand
error.va.sf-cc-num.03Unsupported card entered
error.va.sf-cc-dat.01Card too old
error.va.sf-cc-dat.02Date too far in the future

In order to investigate further why some shoppers are getting error “Typed card number doesn’t match card brand” when trying to make a donation can you please provide:
Which integration type are you using? Components / Drop-in or APIs?
A screen recording showing the issue. Please make sure to have the Developer Tools open on the Console and Network tab so that we can see if any error is being displayed.

Above email is from Adyen, so if FR-tech can give the information on it would be helpful to send it to Adyen team for further information.

Email from Adyen, can FR-tech please respond on this?

Adyen Support
1:06 PM (1 hour ago)
to emartin@wikimedia.org, jake.leininger@adyen.com, me

Hi Evelyn,

We can see how you are integrating, but we always verify with the merchant in case there is some integration in place that we are not aware of. What I can see is that you are integrating using Checkout API v68. Can you please confirm this? If this is the case, then this means that the integration is all built by you so we would need more information from your side in order to understand why some of your shoppers are not able to donate. As a starting point we usually look at the errors in the console and network tab, as here we can see what requests are being sent to us and what the responses are, plus any other errors related to your frontend. This might already highlight the issue at hand or might provide guidance into the next steps. Also, a date, time and time zone of when issue occurred would also be helpful as we could try to check if we can see anything in our logs.

@AnnWF - Does this mean Adyen needs to fix this on their side?

From Adyen:

Adyen Support
5:12 PM (0 minutes ago)
to me, emartin@wikimedia.org, mbeattie@wikimedia.org, jake.leininger@adyen.com

Hi Rakhi,

I've read the link you shared and the issue was mainly on the test environment and the thread was closed after the below comment, which means that the "unsupported card error" is expected behaviour when you are trying to enter a card that is not passed in the brands array.
Image_2023-10-30_09-16-46.png

Looking at your /paymentMethods call, you are passing the brands that your donators are reporting on, i.e. Mastercard and Visa. The below is taken from one of your /paymentMethods call. This means that the github issue you are referring to does not apply to your case.

"brands" : [
   "visa",
   "mc",
   "amex",
   "cup",
   "diners",
   "discover",
   "jcb"
],

If your tech team still thinks that this github issue applies to your case, can they provide more information as to why they think so maybe I am not fully comprehending how this applies to your case?

Ideally please provide the information I requested earlier so that we can have a better understanding of the issue at hand and guide you accordingly.
A screen recording showing the issue. Please make sure to have the Developer Tools open on the Console and Network tab so that we can see if any error is being displayed.
Please let me know if you have any questions.

Further from Adyen:

Adyen Support
7:22 PM (7 minutes ago)
to me, mbeattie@wikimedia.org, jake.leininger@adyen.com, emartin@wikimedia.org

Hi Rikhi,

Further to my previous email, I have been investigating more the issue and found that you do have a number of unsuccessful attempts on your merchant account. These are failing with errorMessage: "Bin Details not found for the given card number". This error is usually given when the BIN (the first 4-6 digits of a card) is unknown to us. Issuers release new bins on a monthly basis, which have to be included in the scheme updates and subsequently added to our bin tables. The bin table updates are manual, and take place every couple of weeks.
So it could take some days for the bin to be operative.That leaves a bit of a window of time where a newly issued bin won't be recognized by our validation.

The problem is that since you are sending encrypted card data I am unable to see the affected BIN so I am unable to confirm if the above is what you are experiencing. If you have knowledge of the exact bin, please share it with me, and I can check our tables, or if you are able to reproduce and record your screen (as I have previously asked) this could give an indication if this is the issue at hand.

In the meantime I am checking internally if there is anything else I can check on my side.

Please let me know if you have any questions.

greg triaged this task as High priority.Oct 30 2023, 8:03 PM

@RKumar_WMF did you send over any of the bin numbers mentioned in the top of the ticket? There's at least 5402. We don't save those anywhere on our end (unless they did successfully donate with the same card and they are in Adyen's console)

For a recording, I tried my MasterCard but couldn't get the error to show up. I haven't been able to replicate it.

For the version we are using JS 5.39.0 and Checkout API v68

I am unable to send BIN since the donation has not come through. But I am checking if sending previous donation BIN would help.

So the issue is that adyen is support following brands
"brands" : [

"visa",
"mc",
"amex",
"cup",
"diners",
"discover",
"jcb"

],

which according to user's message that they are using 5402 as master credit card should be fine, which then Adyen reported that they are slowly update their bin,
which might be the root issue while not place to confirm that. The problem then is if this is the case (unknown bin), could we still pass the credentials to Adyen and then make our customer less confused?

Hi @AnnWF Wenjun- The above question is for whom? Do you want me to ask Adyen?

Hi @AnnWF - can we confirm what is blocking progress on this for FR-Tech? tx

Yes this is the question did Ayden.

Hi @AnnWF Wenjun- The above question is for whom? Do you want me to ask Adyen?

Yes! This is a question for Adyen and yes could you help me to ask Adyen and add fr-tech to that email thread. Thanks!

For that bin outdate issue:

Since we do not record our donor's card and they do not recommend to remove the validation, because there could still be transaction costs plus on top of that it is considered a security risk, such as in BIN attacks.
so this situation will happen again, unless we can provide concrete example (date, time and time zone) next time.

will try to log the client side error with the info they requested and see if that is helpful for future investigation

Change 975934 had a related patch set uploaded (by Wfan; author: Wfan):

[mediawiki/extensions/DonationInterface@master] Log card verification error with datetime and timezone

https://gerrit.wikimedia.org/r/975934

Change 975934 merged by jenkins-bot:

[mediawiki/extensions/DonationInterface@master] Log card verification error with datetime and timezone

https://gerrit.wikimedia.org/r/975934

XenoRyet set Final Story Points to 4.
AnnWF renamed this task from "Typed card number does not match card brand" errors to Log client side error for adyen to look into "Typed card number does not match card brand" errors.Jan 29 2024, 8:31 PM