braintree / braintree_ios

Braintree SDK for iOS
https://developer.paypal.com/braintree/docs/start/hello-client/ios/v5
MIT License
557 stars 291 forks source link

Added "Origami Checkout" to Web Checkout Flow #1298

Closed stechiu closed 2 months ago

stechiu commented 2 months ago

This ticket allows for QA team to test the Origami Checkout flow. We want to add the tokenization key “sandbox_rz48bqvw_jcyycfw6f9j4nj9c" to launch the PayPal checkout Origami experience. To launch this, PayPal intent type must be “Sale”

This tokenization key should only be used when specified in settings (not new default tokenization key).

Summary of changes

To Test

  1. Settings: Integration > PayPal - Web Checkout, Authorization Type > Origami Tokenization Key
  2. Buyer email (ex: jsdk@bt.com)
  3. Toggle Origami Checkout to on
  4. Tap "PayPal Checkout"

Known Error

When Authorization Type is set to Origami Tokenization Key, there's a known error where HTTP POST request fails. This appears when tapping on PayPalCheckout Button, regardless of whether Origami Checkout or PayLater is switched on or off. You need to enter a Buyer Email (ex: jsdk@bt.com) to before using any of the PayPal Checkout experiences.

This error doesn't occur when using the other Authorization Types.

simulator_screenshot_995BA9C5-B5B9-44EC-BBED-24DDFF82FA41

Checklist

Authors

List GitHub usernames for everyone who contributed to this pull request.

sarahkoop commented 2 months ago

Update on the known error - this is happening when we pass "" instead of an email address or nil for the userAuthenticationEmail param.

jaxdesmarais commented 2 months ago

Update on the known error - this is happening when we pass "" instead of an email address or nil for the userAuthenticationEmail param.

🤔 it's a bit odd to me that this new flow behaves differently than passing an empty string for MPE (I had asked about this on Android here). Do we know if this is a change in previous behavior or specific to this new flow?

sarahkoop commented 2 months ago

Update on the known error - this is happening when we pass "" instead of an email address or nil for the userAuthenticationEmail param.

🤔 it's a bit odd to me that this new flow behaves differently than passing an empty string for MPE (I had asked about this on Android here). Do we know if this is a change in previous behavior or specific to this new flow?

I'll follow up internally about this - agreed we should be able to pass empty string similar to the vault flow

stechiu commented 2 months ago

It looks like the Android PR used the term "New PayPal checkout experience" for this - should we consider aligning with the same naming since I believe "Oragami" is more of an internal name?

Good point. I changed the label text that users would see in the Demo app but kept Origami for when it's used internally. Thought process is that there will be new Checkout experiences in the future so we'd need a way to identify the different experiences. Unless we know for sure that Origami will be the new Checkout experiences and the current one will be fazed out in a couple months? @sarahkoop would love your input here

sarahkoop commented 2 months ago

It looks like the Android PR used the term "New PayPal checkout experience" for this - should we consider aligning with the same naming since I believe "Oragami" is more of an internal name?

Good point. I changed the label text that users would see in the Demo app but kept Origami for when it's used internally. Thought process is that there will be new Checkout experiences in the future so we'd need a way to identify the different experiences. Unless we know for sure that Origami will be the new Checkout experiences and the current one will be fazed out in a couple months? @sarahkoop would love your input here

I would agree we should probably avoid using internal naming for flows, but also agree "new PayPal checkout experience" is somewhat vague - is there another name we could use to indicate what this flow is?

jaxdesmarais commented 2 months ago

I would agree we should probably avoid using internal naming for flows, but also agree "new PayPal checkout experience" is somewhat vague - is there another name we could use to indicate what this flow is?

Do we know what we are calling this to merchants? Stephanie asked me this but I wasn't sure what the external facing name for the new UI was.