#.n0tnull

1 messages ยท Page 1 of 1 (latest)

noble oxideBOT
#

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.

pure meadow
#

๐Ÿ‘‹ happy to help

#

what seems to be the issue?

thorn adder
#

I am trying to implement the card setup with validation.
I tried using stripe.confirmSetupIntent but the validation never happens.
If I use the PaymentLauncher (which is incompatible with my architecture), I have the validation but the credit card token (pm_) is not accessible in case of success.

pure meadow
#

what guide are you following?

thorn adder
#

I can't use the PaymentSheet as I have my own UI

river vine
#

Hey! Taking over for my colleague. When you say that you have your own UI, you mean you collect the card details using your own forms ?

thorn adder
#

Yes

river vine
#

Are you PCI - DSS compliant ?

thorn adder
#

I have no idea, so probably not

river vine
#

If you are not PCI DSS compliant then you need to use PaymentSheet

thorn adder
#

I am not storing these card info, only sending them to Stripe.

river vine
#

yes but you have access to them

#

if you have a leak somone else could store them

thorn adder
#

As I would with any widget or view...

river vine
#

you can only if you are Pci dss otherwise you need to use strope widgets (e.g. payment sheet)

thorn adder
#

But I can access these payment info via your elements too... ๐Ÿค”

river vine
#

how?

thorn adder
#

It's still a view that I have access too, no?

river vine
#

no you cand get access to the card details for example

#

there is no public getter

thorn adder
#

So I can't use my custom UI that I have been using for the past 4 years (with one being with Stripe) ?

river vine
#

(with one being with Stripe) ?
what you mean by this ?

thorn adder
#

Your CardInputWidget is not OK to use ?

river vine
#

yes you can use our elements of course

thorn adder
#

So how can I setup a card validation after the user entered his card into your widget ?

thorn adder
#

That's exactly what I was testing. But when I would need the payment token ("pm_") which I can't get with this method ๐Ÿ˜ฌ

#

The info is in the InternalPaymentResult but lost in the final PaymentResult

river vine
#

What you mean by it got lost ?

thorn adder
#
    PaymentLauncher.InternalPaymentResultCallback {
    return PaymentLauncher.InternalPaymentResultCallback { result ->
        when (result) {
            is InternalPaymentResult.Completed -> onPaymentResult(PaymentResult.Completed)
            is InternalPaymentResult.Failed -> onPaymentResult(PaymentResult.Failed(result.throwable))
            is InternalPaymentResult.Canceled -> onPaymentResult(PaymentResult.Canceled)
        }
    }
}```
river vine
#

You can fetch the payment method from the SetupIntent

thorn adder
#

Do you mean on the backend ?

river vine
#

Yes

thorn adder
#

So instead of sending the card token (pm_) to the backend, I will send them the secret for them to retrieve the card token ?

river vine
#

No what I meant, you confirm the setup intent

#

the way the activity I shared with you

#

and once the Setupintent is confirmed

#

you can get the pm_1234 from the SetupIntent object

thorn adder
#

So on the app, I need to make the validation, then make an API call to Stripe then an API call to my backend with the token?

#

Is there any reason why we don't have direct access to this token via your Android SDK while it is possible on iOS?

river vine
#

an API call to my backend with the token?
by the SetupIntent Id

#

Is there any reason why we don't have direct access to this token via your Android SDK while it is possible on iOS?
Let me check if there is a direct access from the mobile Android sdk....

river vine
#

Sorry for the late reply, was doing couple of tests

#

the callback response value PaymentResult doens't provide any way for accesing the payment method Id nor the SetupIntent details