#hanis-paymentintent-3ds

1 messages · Page 1 of 1 (latest)

real pollenBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

unreal cargo
#

HI 👋

How are you collecting payments?

violet wagon
#

With php, js

unreal cargo
#

Payment Element, Checkout?

violet wagon
#

I create this create.php where is this:

<?php
session_start();
require_once './vendor/autoload.php';
require_once './secrets.php';

$stripe = new \Stripe\StripeClient($stripeSecretKey);

function calculateOrderAmount(array $items): int {
    $payment = $_SESSION['priceAll'] * 100;
    return $payment;

}

header('Content-Type: application/json');

try {
    $jsonStr = file_get_contents('php://input');
    $jsonObj = json_decode($jsonStr);

    $paymentIntent = $stripe->paymentIntents->create([
        'amount' => calculateOrderAmount($jsonObj->items),
        'currency' => 'czk',
    //'setup_future_usage' => 'off_session',
        'automatic_payment_methods' => [
            'enabled' => true,
        ],
    'payment_method_options' => [
            'card' => [
          'request_three_d_secure' => 'any',
         ],
        ],
    ]);
    $paymentIntent->confirmation_method = 'manual';

    $output = [
        'clientSecret' => $paymentIntent->client_secret,
    ];

    echo json_encode($output);
} catch (Error $e) {
    http_response_code(500);
    echo json_encode(['error' => $e->getMessage()]);
}


#

When I prepairing payment intent

unreal cargo
#

You are already requesting 3DS in the payment_method_options

#

You can also implement a radar rule to more strictly require 3DS if you are using Radar for Fraud Teams

#

hanis-3ds

violet wagon
#

reply: You can also implement a radar rule to more strictly require 3DS if you are using Radar for Fraud Teams
do i have to?

unreal cargo
#

No you don't have to

violet wagon
#

Can you help me, how to applyed?

#

And then it will require the 3d secure after each one?

unreal cargo
#

I don't know what those words mean.

violet wagon
#

If I manage to do this, will he always want it?

unreal cargo
#

will he always want it?

#

I don't know what that means

violet wagon
#

Will 3d secure always be active?

#

Sorry I´m using Google translator

unreal cargo
#

When you set request_three_d_secure to any, Stripe requires your customer to perform authentication to complete the payment successfully if 3DS authentication is available for a card. If it’s not available for the given card, the payment proceeds normally.

#

from our docs

violet wagon
#

And do I have to add that to what I sent?

violet wagon
#
'payment_method_options' => [
            'card' => [
          'request_three_d_secure' => 'any',
         ],
        ],```
unreal cargo
#

Yes you do, that is what I was referring to

violet wagon
#

But it didn't force me always

real pollenBOT
unreal cargo
#

Do you have some example payment intents where you did not go through 3DS?

violet wagon
#

Yes, I tried this and it didn't work through 3DS

lofty lily
#

hanis-paymentintent-3ds

#

@violet wagon sorry all you said is "you tried, didn't work". Can you provide detailed information about what you tried exactly, with the exact PaymentIntent id?

violet wagon
#

Okay, wait

#

You could also add to this chat @winter forge ? We're working on it together

lofty lily
#

you just did

violet wagon
#

Wait, if I tag someone, will I add them? 😄

lofty lily
#

you can see the list of people in this thread on the right, and yes that's how Discord works

violet wagon
#

@winter forge -Help me describe it.

winter forge
#

Hello, thank you for adding me, we tried multiple cards and multiple payments, but it never gave us 3d secure, even though the cards support it

the last of the payments:
pi_3O9XnKFtFz2alZaW0XMXkFq4

Alternatively pm_1O9XnsFtFz2alZaWJGXPFLpj if you'd rather have that id.

In the strip it says:
3D Secure authentication succeeded
This transaction has been authenticated with 3D Secure 2. The customer was authenticated via a frictionless flow, without any additional input from them.

Although it didn't require me to authenticate, the payment went through on its own

"request_three_d_secure" has "any" (see evendata)

we have no idea what to do :/

lofty lily
#

The customer was authenticated via a frictionless flow
that literally means 3DS2 did happen 🙂

#

3DS2 gives an option where we provide information to the bank about your device/customer session and they can make an informed decision on whether 3DS has to escalate to a "friction" flow where you enter the code or validate in your app. More and more banks do frictionless

winter forge
#

ok now i understand, you can close this, thank you!