#Maxime-payment-ios

1 messages ยท Page 1 of 1 (latest)

hasty pagoda
#

Hello! Can you give me a bit more detail here? I'm not completely following your question

frigid viper
#

Sure

#

So, my server is creating a paymentintent

#

It uses confirmation_method=manual so that the server can confirm the PI when the mobile app has made the required actions

#

But I'm not quite sure what to use on iOS to clear the required actions without confirming the PI

#

Just to clarify the flow

  • Server: creates a PI with confirm=true & confirmation_ethod=manual
  • Server : if the payment fails because of requires_action, it returns the PI secret to the mobile app
  • Mobile App : Performs the required actions (not sure about the correct method to use as it's not possible to use the confirmation method of the SDK)
  • Server : Should handle the final confirmation of the PI
hasty pagoda
stone thunder
#

hey guys following up here, since i'm working with Maxime (iOS side):
We previously used the method :

        _ paymentParams: STPPaymentIntentParams,
        with authenticationContext: STPAuthenticationContext,
        completion: @escaping STPPaymentHandlerActionPaymentIntentCompletionBlock
    )``` 
but this was actually confirming the payment through the stripe API (which makes sense given the method name) and are now using :
```public func handleNextAction(
        forPayment paymentIntentClientSecret: String,
        with authenticationContext: STPAuthenticationContext,
        returnURL: String?,
        completion: @escaping STPPaymentHandlerActionPaymentIntentCompletionBlock
    )
#

ok we might have missed the doc ๐Ÿ˜‰

#

but in the hand it's exactly what we implemented

#

thanks @hasty pagoda you can close the thread

hasty pagoda
#

๐Ÿ‘ If you need any more clarification feel free to ask!

frigid viper
#

I need actually

#

What is the current payment state (from the customer or the bank point of view) between the time the PI has cleared all the required actions (on mobile) and before it has been confirmed by the backend

#

Same question in case the server never confirms the payment intent

#

Are the funds actually hold? or does this happen only when confirming?

hasty pagoda
#

After the next actions are handled client-side, the PI should go back to a requires_confirmation state.

frigid viper
#

Exactly, this is what we have ๐Ÿ™‚

hasty pagoda
#

The funds aren't held until the PI is actually confirmed, so if it never gets confirmed then the funds are not held

frigid viper
#

Not even an pre-autorization made to the bank for the transaction amount?

#

If not, perfect then! This synchronous flow is actually quite convenient for us. I don't really see the benefits of using the async approach with web hooks here (or maybe we missed something? ๐Ÿค”)

hasty pagoda
#

Correct there shouldn't be any funds held at all ๐Ÿ‘

#

One of the major downsides with the synchronous flow is that it isn't as flexible with handling additional payment method types (You would need to build out more code to handle a new payment method type other than card)

frigid viper
#

Only other method we would like to handle is apple pay, but we can use it synchronously, correct? ๐Ÿค”

hasty pagoda
#

Yes, I believe you should be able to handle that synchronously

frigid viper
#

Thanks a lot for these precious infos!

#

Have a nice evening/day

hasty pagoda
#

you too!