#tienbt_api
1 messages ยท Page 1 of 1 (latest)
๐ 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/1218100548998266971
๐ Have more to share? Add more details, code, screenshots, videos, etc. below.
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.
- tienbt_api, 22 hours ago, 18 messages
- tienbt_api, 1 day ago, 13 messages
- tienbt_api, 1 day ago, 36 messages
- tienbt_api, 1 day ago, 68 messages
- tienbt_api, 2 days ago, 144 messages
- tienbt_api, 2 days ago, 51 messages
hello! how can I help?
Hi
My name is Chau
I am integrating apple pay to my website
I have made it to this step
Please check for me, what should I do next?
are you running into any specific issues or have any specific questions? I don't know what are your requirements or how your application should work so I can't really advise unless you provide more details
how do i listen for event after selecting any card of apple pay
I am coding by vuejs
what do you want to do with the event? What do you want to be informed of?
Yes, Thank you.
you need to let me know what do you want to do with the event and what you want to be informed of before I can help further
rguments: TypeError: 'arguments', 'callee', and 'caller' cannot be accessed in this context.
caller: TypeError: 'arguments', 'callee', and 'caller' cannot be accessed in this context.
Please help me check this error. Thank.
which line of code is this error coming from?
expressCheckoutElement.on('confirm', async (event) => {
...
const {error: submitError} = await elements.submit();
this.expressCheckoutElement.on('confirm', async (event) => {
console.log("๐ this.expressCheckoutElement.on event:222222222222", event) })
It is error when console.log(event)
What are you logging the event for?
alright, but creating a PaymentMethod doesn't require you to log the event right? What's the issue/problem that you're actually trying to solve here?
We skip the above.
Can you guide me how to test apple pay with failed cases? Thanks
When using Google/Apple Pay in test mode, Stripe will automatically replace whatever card you have in your wallet by the 42..42 test card for Apple Pay and 4111..11 test card for Google Pay. This means that all Apple/Google Pay test payments will succeed.
If you want to simulate a failed payment with Apple/Google Pay, you can try two workarounds :
Use Radar
You can use Radar to block some transactions according to some rules. In order to block Google/Apple Pay payments, you can rely on the Block rule with the digital_wallet attribute:
Apple Pay: Block if :digital_wallet: = 'apple_pay'
Google Pay: Block if :digital_wallet: = 'android_pay'
**Stubbing the result PaymentMethod with a decline token:
**
Another option is to stub the resulting PaymentMethod from Apple/Google pay with one of the decline PaymentMethods (e.g. pm_card_visa_chargeDeclined) in order to simulate a failure payment attempt. This applies when you are collecting a PaymentMethod and then confirming the Payment.
Example
...
const {paymentIntent, error: confirmError} = await stripe.confirmPayment(
clientSecret,
{payment_method: 'pm_card_visa_chargeDeclined'
},
);
...