#jemagnie_defered-pi-ios

1 messages ยท Page 1 of 1 (latest)

subtle sinewBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

๐Ÿ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1243116443034451978

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

stray glenBOT
signal iris
#

Firstly, Is there a particular reason for following that guide ?

polar solar
#

Hello,

Indeed at the beginning I followed the integration that you shared, unfortunately the backend did its job poorly and prevented me from using this integration, so I have to follow the other integration while the modifications are made by the backend to return to the first (which will not be done for a month)

signal iris
#

the backend did its job poorly
Can you share more details ?

subtle sinewBOT
polar solar
signal iris
#

If you could share more details about the issue, that could be benefical to assist you better, other wise it's not clear what is th issue you are facing, sorry

subtle sinewBOT
#

jemagnie_defered-pi-android

polar solar
#

I see that you renamed the show name to "...Android" but I am part of the iOS team and my question concerns help on iOS

#

Here is the link of the show with the android dev, this allows you to have more context on my situation

potent drift
#

oh sorry, I saw "Android" in your message while I was quickly catching up

subtle sinewBOT
#

jemagnie_defered-pi-ios

potent drift
#

can you please give me a moment to properly catch up on your question?

polar solar
#

No worries, and sorry if I express myself badly, I'm French ๐Ÿฅ–

potent drift
#

no worries

#

what issues are you facing?

#

just fyi, this statement is not really accurate

The backend I work with did not respect modern documentation

#

the deferred flow is newer than the accept-a-payment flow you shared

#

but each has a different use-case

#

so it's not about being modern or not

#

would you mind sharing more details about what you're facing exactly?

polar solar
#

My problem is to know what will be called by stripe after calling StripeAPI.handleURLCallback(with:url) in the SceneDelegate

Is it the completion of the function that will be directly called by stripe?

public func present(
from presentingViewController: UIViewController,
completion: @escaping (PaymentSheetResult) -> Void
)

tawny kindle
#

yes.

#

a pretty normal implementation of that is

 @objc
    func didTapCheckoutButton() {
      // MARK: Start the checkout process
      paymentSheet?.present(from: self) { paymentResult in
        // MARK: Handle the payment result
        switch paymentResult {
        case .completed:
          print("Your order is confirmed")
        case .canceled:
          print("Canceled!")
        case .failed(let error):
            print("Payment failed: \n\(error.localizedDescription)")
            let fullError = error as NSError
            print(fullError.code)
            print(fullError.description)
            dump(fullError.userInfo)
       }
      }
    }

the callback happens when the payment is finished, if it's a payment method that involves opening another app or a URL, then when the user comes back(via returnUrl + your AppDelegate invoking handleURLCallback) , the payment is finished and that callback happens.

polar solar
#

Thank you very much for the answer, is there a way to test this in a dev environment?
Because the card 4000 0025 0000 3155 which needs authentication does not take me out of the application

tawny kindle
#

Likely the best way is to pay with a payment method like iDEAL in the PaymentSheet.

subtle sinewBOT
polar solar
#

Ok thanks i would try this