#danilkinkin_code

1 messages ยท Page 1 of 1 (latest)

subtle ruinBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can 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/1255517242561531955

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

wicked fractalBOT
#

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.

snow ibex
#

Hello
Give me a moment to take a look

open stump
#

First image, I logged with account with bonded card, second without.

Why PaymentRequest don't show if account doesn't have payment data?

snow ibex
#

What do you mean by bonded card? Is that some sort of gift card?

open stump
#

No, payment card added in google account

snow ibex
#

Ah I see. My understanding is that Express Checkout Element and PaymentRequestButton use different underlying APIs..

The PaymentRequestButton only renders the button if
1/ You're logged into a google account with wallet
2/ Wallet has a valid payment method

Express Checkout Elements shows you a login modal if you're not logged in.

open stump
#

Yep, but in this case, PaymentRequest is not usable for me.

A have my own payment system switcher, and it's so strange if I switch a payment system and don't see a button. Also, maybe If even user don't have an added card now, he is ready to make it right now during payment

#

So it's not a problem in my code, it's a strange stripe logic?

snow ibex
#

Like I mentioned earlier the PaymentRequestButton works differently compared to Express Checkout Element. Its not even Stripe logic, I think its just how Pay.js works with Google Pay (which is used by PaymentRequestButton)

open stump
#

Interesting that event this buttons display different payment direction. First ExpressCheckout, second PayemntRequest

#

First image from account without card, second with it

subtle ruinBOT
snow ibex
#

I think I misunderstood your ask ๐Ÿ˜… I assumed your ask was in comparison to Express Checkout Element

Circling back to your usecase though, we do recommend using Express Checkout Element over PaymentRequestButton anyway as it offers more flexibility and features

Can you share more about what your concerns are with Express Checkout Element? Just to be on the same page

open stump
#

First reason, I have other types of payment method, like a pay with bonus, and I have to display this method with other in one list.

My user story looks like that: Choose payment method -> Fill customer data -> Tap pay button.
So I have to render only one payment system button per page. In theory, i can limit payment method until one via wallets property

#

Second reason, my product is can be embedded in other sites (iframe widget for selling tickets). I discuss this problem yesterday there: #1255517242561531955 message

Apple Pay works only if top domain is verified, but not all sellers make it, so I have to check possibility Apple Pay method before render payment button, for hide this method from list

tough rover
open stump
#

Yeah, but still exist problem with check is verified top level (parent) domain. Method ApplePaySession.canMakePayments() return true for these cases, but in real I can't use Apple Pay.

Maybe do you have an API for check real possibility of use Apple Pay, without render ExpressCheckout and read data in onready?

tough rover
#

And that is interesting, so if neither of the wallets are available, do we still render something the size of those buttons? I would have thought that the ECE would be basically invisible at that point

open stump
#

Yes, if cards not added, ExpressCheckout anyway render button, and after click system ask add card first.

It's more correct behavior, I think

#

Problem of canMakePayment that this method return false if cards not added. But in really I can make a payment

tough rover
#

So if apple pay isn't registered, what shows up on your page that you don't like?

open stump
#

No, if my domain registered but in my Apple Pay account not added card, in this case canMakePayment return false

#

I need next behavior, my domain (and all other in chain) is registered and in my Apple Pay account not added card, in this case canMakePayment should return true

#

I mean canMakePayment should not check for availability added payment card in account. If user want, he added card during payment

#

ExpressCheckout already work in this scheme

#

So I need to detect only one case:

  1. Parent (top level) domain, where embedded our iframe not registered in Apple Pay
  2. User have added card in payment account or not, it's not important

ExpressCheckout can't check first point before use, but work perfect with second point
canMakePayment check added cards in payment account and it's not correct

tough rover
#

Unfortunately our SDK does not work that way. You can write in to our support to ask for a method similar to canMakePayment that does that, but right now we do not have a method that can do what you want.

open stump
#

It's so sad

#

Can you create topic for developer team and check why ExpressCheckout and PayemntRequest work different with account that don't have added card?

#

I think anyway it's wrong behavior

#

As for the main question, then we maybe will have to manually enable Apple Pay for users, well, what can I say.

Thanks for trying to help