#ManuX
1 messages · Page 1 of 1 (latest)
Hi there! If you are creating a PaymentIntent before displaying the PaymentElement, could you share the PaymentIntent ID?
The ID should look like pi_...
Here's the entire log
200 OK
ID
req_aTGJTrusrR6Aam
Time
09/06/2023, 19:17:06
IP address
34.244.89.223
API Version
2020-03-02
Source
Stripe/v1 PythonBindings/2.43.0
Idempotency
Key – 9b7d64c0-7383-408d-8a0f-3decf6d9d97e
Response body
{
"id": "pi_3NH8vuKPF1lmFQxD0RQm0sAB",
"object": "payment_intent",
"amount": 54376,
"amount_capturable": 0,
"amount_details": {
"tip": {
}
},
"amount_received": 0,
"application": null,
"application_fee_amount": null,
"automatic_payment_methods": null,
"canceled_at": null,
"cancellation_reason": null,
"capture_method": "manual",
"charges": {
"object": "list",
"data": [
],
"has_more": false,
"total_count": 0,
"url": "/v1/charges?payment_intent=pi_3NH8vuKPF1lmFQxD0RQm0sAB"
},
"client_secret": "pi_3N**********************_******_*********************zWDO",
"confirmation_method": "automatic",
"created": 1686331026,
"currency": "eur",
"customer": null,
"description": "Payment from direct booking (2023-06-14 - 2023-06-16, property ID: 68669)",
"invoice": null,
"last_payment_error": null,
"latest_charge": null,
"livemode": false,
"metadata": {
},
"next_action": null,
"on_behalf_of": null,
"payment_method": null,
"payment_method_options": {
"card": {
"installments": null,
"mandate_options": null,
"network": null,
"request_three_d_secure": "automatic"
}
},
"payment_method_types": [
"card"
],
"processing": null,
"receipt_email": null,
"review": null,
"setup_future_usage": null,
"shipping": null,
"source": null,
"statement_descriptor": null,
"statement_descriptor_suffix": null,
"status": "requires_payment_method",
"transfer_data": null,
"transfer_group": null
}
Request POST body
{
"description": "Payment from direct booking (2023-06-14 - 2023-06-16, property ID: 68669)",
"capture_method": "manual",
"amount": "54376",
"currency": "EUR"
}
Google pay and apple pay are activated in my dashboard and I'm logged into Google with an account that has a valid wallet, should Gpay show up at least?
Let's see
I'm honestly most interested in making these two show up for now
(i'm on https by the way)
Yes, GPay should show up as long as you have a valid wallet. GPay and Apple Pay should show up if you create a PI that accepts card
Do you see any possible reason why it isn't showing?
This PaymentIntent was created without including payment_method_types: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_types
If both this parameter and automatic_payment_methods are omitted in the PI creation request, the PI defaults to accepting card only
hmmm interesting
If you visit this page in Chrome where you're logged into a Google account with a valid card, do you see the "GPay" button above the "HTML+JS" tab? https://stripe.com/docs/stripe-js/elements/payment-request-button
like this:
I get this
Either your browser does not support the Payment Request API, or you do not have a saved payment method. To try out the Payment Request Button live demo, switch to one of the supported browsers below, and make sure you have a saved payment method.```
Got it, okay. That means a card hasn't been added to Chrome/Gpay
I'm interested in this though
If both this parameter and automatic_payment_methods are omitted in the PI creation request, the PI defaults to accepting card only
When you say accepting card only, does that mean gpay and apple pay will not display?
Ah no, let me clarify. ApplePay and GooglePay will show up as options for card payments as well, so long as you're using a supported browser
understood
So, only Safari will display ApplePay as long as you've added a card to your Apple Wallet
And only Chrome will display GooglePay as long as you've added a card to your GooglePay account or saved a card in Chrome
ok, so I'm not seeing gpay on my end right now because I haven't added a card? but I do have cards in my gpay I just checked
hmmm
ok
This is good to know
Because I think my superiors expected those options to always be there
I will explain them this
but all in all, with the payment intent logs you've seen, if the user has apple pay or gpay correctly setup, they should show up
Yep, that's correct. Do you have a link to a staging environment that I can try to access on my end?
Can I PM you?
Ah, no
Well no worries, I will try to set up my google pay
do you happen to know what should i do?
I'm already logged in and my gpay has a saved card
I'm using brave by the way
Ah, that's gotta be it! Gpay will only show up in Chrome
ahhh
ok I will try that
Yep it's showing in chrome. So gpay only in Chrome and apple pay only in Safari, right?
Yep, that's correct
by the way, should I be able to test this with the test api key?
Back to automatic_payment_methods: if you want PaymentIntents to be created and reflect the payment methods you've turned on/off in the dashboard, you should use automatic_payment_methods: enabled
Ok cool, I will tell my backend dev that
You should be able to, yes
nothing's really happening
no other screen opened or anything
oh wait
this should show up after I confirm the payment I'm guessing
Nice it worked like a charm 🥳
Thanks so much roadrunner
Happy to help!
One more thing before you close this
what about paypal?
is there any similar particularity to make it show?
Like browser specific or needing to have some account linked?
Ah, not exactly. As a merchant, you'll need to link your Stripe merchant account to your Paypal account first. I recommend starting here:
https://stripe.com/docs/payments/paypal
https://stripe.com/docs/payments/paypal/connect-your-paypal-account
https://stripe.com/docs/payments/paypal/accept-a-payment