sumup / sumup-ios-sdk

Other
46 stars 24 forks source link

Tap To Pay: deactivate #146

Closed wbison closed 2 months ago

wbison commented 2 months ago

We use

presentTapToPayActivationFromViewController

to activate Tap To Pay but how we deactivate Tap To Pay within our app? The SumUp app has a switch to activate or deactivate TapToPay but the SDK doesn't seem to support deactivation.

jadeburton-sumup commented 2 months ago

@wbison can I ask what the use case would be for deactivating Tap? It wasn't added to the SDK because we didn't think it would be needed, but I would be interested to know what we might have missed here.

wbison commented 2 months ago

The scenario would be a merchant who is currently using a terminal, tries out Tap To Pay and for some reason is not happy with it and wants to switch back. We would have to tell him to deactivate it using the SumUp app (which he might not have installed).

Just so you know: I'm very happy about the way SumUp supports Tap To Pay (within the library as opposed to app-to-app) and I think our iPhone users will be very happy too!

jadeburton-sumup commented 2 months ago

Can you confirm that passing SMPPaymentMethodCardReader as the payment method type does not show the user a menu with buttons for both the Card Reader and Tap to Pay?

It is meant to always go directly to the Card Reader screen and not ask the user to choose a payment method, however we did have some issues with this in the past, where it showed multiple payment methods and the user had to choose one.

If that's not the issue, would it be feasible to save the "enabled" payment method(s) in your app's user defaults instead?

wbison commented 2 months ago

If TapToPay is activated we set request.paymentMethod = SMPPaymentMethodTapToPay; otherwise we do nothing.

I prefer not to keep or own 'TapToPayActivated' setting. I can live with referring to the SumUp app in the rare case TapToPay should not be used.

jadeburton-sumup commented 2 months ago

Ok, thanks for the feedback.

Some more context/history on this:

The SDK used to show a menu with the available payment methods (including Payment Links), but we decided to move towards a more programmatic and UI-less approach so that integrators could customize the user experience more.

So the decision of which payment method(s) to show to the user should now be made by the hosting app itself, taking into consideration what payment methods are available ("activated") and what the merchant's preference is. We also want to decouple these enabled/disabled states from the SumUp app entirely in the future.

jadeburton-sumup commented 2 months ago

@wbison I will close this issue but keep an eye on demand for this feature