Square SCA Card Declined After Verification - A verification is required to process this payment

Trying to update my Square integration for SCA. Worked once, got the verification screen, entered in the 123456 verification code and payment was successful.

Then I no longer got a verification screen. FINALLY figured out it was selecting a different location that was not in the UK when the first time it did.

Now I am getting the verification screen but get a declined message.

"Card declined. A verification is required to process this payment. "

Why would it be declined AFTER I went through the verification process?

Thanks

To follow up, I am passing the verification token to the charge transaction like this:

$transaction_api = new \SquareConnect\Api\TransactionApi();

$request_body = array (
“card_nonce” => $nonce,
“verificationToken” => $token,
“amount_money” => array (
“amount” => $charge_amount,
“currency” => $currency
),
“idempotency_key” => uniqid()
);

Then

$result = $transaction_api->charge($access_token, $location_id, $request_body);

Hi @tag welcome to the forums!

What is your application id and the location_id being used? I can take a look at our logs. However, I want to call out that the Transactions API is currently deprecated and is planned to be fully retired (no longer guaranteed to work) in September of 2021. You should migrate to the Payments API as soon as possible.

Application ID: sandbox-sq0idb-jqjNaCcEs0LeT6F0Rw3gBA
Location ID: LHZQ1T68EFC4A

Thanks for that information! I took a look at our logs and found that we’re not actually receiving the verification token, which is why you’re receiving that error. Looking at the code you provided above, I believe you need to change verificationToken to verification_token (underscore vs camelCase).

Also, I would like to note that we do have a new PHP SDK that I strongly recommend you to migrate to. While the old SDK will not stop working, it is technically deprecated and is no longer receiving new features or updates. Please let me know if you have additional questions or concerns!

That fix it. Thank you for your assistance.

1 Like

Hello ,

i am also having the same issue , i am testing in sandbox mode .
onlu visa and master card details are working

Discover card details gives erro

:wave: What’s the error you’re getting with the test value?