#nyxi_automatic-payment-methods
1 messages ยท Page 1 of 1 (latest)
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.
- nyxi_docs, 3 days ago, 11 messages
- nyxi_pi-autopms, 4 days ago, 62 messages
- nyxi_invoice-return-url, 4 days ago, 79 messages
๐ 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/1244994481288249407
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
Hi there ๐ we automatically show all Payment Method types that match the criteria of the intent being used. It looks like the intent you created used a presentment currency of dkk, which isn't supported by most of the Payment Method types you mentioned. The only one mentioned that seems to match the currency is MobilePay.
nyxi_automatic-payment-methods
Yes, so why no MobilePay?
I'm still looking into that
ok
Checking with teammates where the perfect tool for looking into this got moved to
Alright
maybe I need to provide return_url when creating the intent to make the elements support redirect-based payment methods?
(Which MobilePay is)
But docs say "only when confirm=true" which we dont
This looks like a charge for one of your Connected Accounts, and MobilePay seems to off by default for your Connected Accounts.
https://dashboard.stripe.com/test/settings/payment_methods/connected_accounts
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
aha, ok
And that Connected Accounts seems to be inheriting defaults.
Ok I'll enable it now
I had enabled it on the connected account itself
It works now, but for Google Pay and MobilePay: Is there are way to remove this huge block of "You will be redirected" text? Would prefer it just checked the row and didn't expand at all.
(coloring/styling is WIP here)
No, but I'll capture your feedback that this is something you'd be interested in having more control over in the future.
Yes please, I think this looks fairly bad to be honest
We had a custom payment selector before which was basically this, but with no row expansion if you don't need to provide info (like card)
Do you know how to change the color of the white block in the screenshot above? We're having a bit of trouble targeting it with the styling guide.
Hm, not offhand. I know the Appearance API is the right approach if that is adjustable, but I'm not sure what the exact variable within it for those are.
Brute force then I guess
Something you could consider creating was a "config creator" where you can select each item and pick the color/whatever for it, then generate a config object. Would be very helpful.
I guess the inspect tool does 90% of that. We'll try.
That's exactly what I was firing up to look for clues
The inner-most object here is classed as Block
but it ignores anything we give it and overrides it with a var() that contains a stripe elements variable
Tried with color as well to change text color, no dice
Looking at the samples at the top of the page (https://docs.stripe.com/elements/appearance-api) and how they render, I do think .Block is the right path to go down.
What do you have right now for your appearance options?
I think we solved it by applying the variables first (step 2, after theme). We may not need to go into the rules at all.
It seems it applies colorBackground to the block
I think my guy just skipped a step ๐
Glad you were able to get it sorted!
Hmm yea it's still playing games with us. Like it will color all input fields correctly (using .Input), but the email input for link login remains white
and looking at the inspector, it has .Input as its class
but it also has p-EmailField
You're now talking about the section that appears when you click on the "something 1-click something" line that brings up Link?
yes
All other input fields are dark as expected
but email field is white. We can change it by styling the private selector, but the guide says that's a nono
Hm, my suspicion is that one is broken.
That's unfortunate
Sorry, I'm trying to test it out and confirm, but it's slow going.
Yeah no problem. Another thing. Since we're now moving to completely async handling (confirm on frontend, wait for webhook), is there a good way to provide an email that does not trigger the receipt email from Stripe?
Need to send an actual receipt for the product to the customer, but with this approach and in this case, we don't have any endpoints for data collection
Its like a single page with "prepay for your reservation" where the amount, product etc. is already set up
I can of course just make an endpoint for it, but would be nice to just do it all in one go
metadata is what comes to mind
https://docs.stripe.com/metadata
though it feels a little odd to store an email address there. Are you creating and using Customer objects as part of your flow?
No customer, no
I think metadata is the best fit then.
I can update the metadata on the client using the intent secret?
I don't believe so.
Frontend collects the email
So I guess there's no way to do that then
We'll solve it with a dedicted endpoint then
I have some more questions though:
- If the payment intent is paid for after its amount was changed from another source, what happens? Does the client secret change and make it not work?
- How do we return the payment intent to "requires_payment_method" without actually giving it a payment method? but without canceling the intent
2 being if the webhook comes in and the amount was wrong because of 1. above
Webhook does capture, so it would just not capture it if the amount was wrong
The only other place I can think of, but I'm not certain if it triggers automatic emails, is to provide it in payment_method_data.billing_details.email
https://docs.stripe.com/js/payment_intents/confirm_payment#confirm_payment_intent-options-confirmParams-payment_method_data-billing_details
Good call, will try
What do you mean, like chanigng the amount of the intent after it has succeeded? Did you try in your testing, where I'd expect the request to error?
From what state?
I did not try yet, no. But imagine:
- Amount is set
- Customer loads payment page and fetches the intent
- Amount is changed from different source
- Customer completes/confirms the payment intent
from requires_capture
Hard to say without more context about how you built your integration. A deferred intents flow will throw an error at confirmation, I believe, due to the amount mismatch.
So I basically will never have to worry about the amount on a requires_capture intent being wrong, because it won't be possible to confirm it with the wrong amount?
Depends on your flow, try it out
Assuming you update the amount from a different source; if the modification goes through, the payment cannot be confirmed later with the wrong amount.
I guess I'll try
If you're using an intent-first flow, I don't think that same protection is in place, because the intent is the source of truth.
Yes, so:
- Create PI, set amount (set SoT, backend)
- Load payment intent from Stripe (load SoT, frontend)
- Modify payment intent (new SoT, backend)
- Attempt to confirm out-dated payment amount (frontend)
They're all looking at the intent
I shall confirm
Yeah, I think that will let the payment be confirmed offhand.
I think it will throw https://docs.stripe.com/error-codes#payment-intent-amount-reconfirmation-required
but let's see
Possibly when trying to do the capture