#teamie

1 messages · Page 1 of 1 (latest)

zenith grailBOT
dawn mantle
#
  1. Can you provide the request ID for the request where you attempted to to add a receipt_email?
  2. You can't
undone turret
#

I was setting this up on my react frontend application

#

also i tried setting this up on my server but it didn't work

#

perhaps cause i made the requests with test keys?

dawn mantle
#

The request ID would be helpful in figuring out what isn't work

#

Test keys do not matter here

undone turret
#
const paymentIntent = await stripe.paymentIntents.create({
    amount: total,
    currency: 'php',
    description: 'Lux Woodwork Store',
    payment_method: 'pm_card_visa',
    payment_method_types: ['card'],
    receipt_email: userEmail,
  });
undone turret
dawn mantle
undone turret
#

req_vbcb6TmulrjQAH

#

There

dawn mantle
#
  1. There was no receipt email passed when confirming this request.
  2. There was a receipt email on the Payment Intent already
undone turret
dawn mantle
#

Okay so what I need to see is the request where you try to include the receipt_email parameter in the confirmParams and the API returns an error. That will be helpful.

undone turret
#

okay

#

req_dbxh6GiBLdf1QV

dawn mantle
#

Oh that's easy. It's nested too far. the confirmParams are not another key but the whole object after the client_secrect.

#

So copying your code snippet above it would be:

const paylaod = await stripe.confirmCardPayment(clientSecret, {
   payment_method: {
     card: elements.getElement(CardElement),
   },
   receipt_email: 'test@example.com'
 });
undone turret
#

ohhh

#

no more errors

#

but there's no email

#

so that's because of the test env?

dawn mantle
#

You mean you don't receive an email?

undone turret
#

yes

#

req_DrNtdbCOYzqUXM

dawn mantle
#

That is correct, we don't send emails in Test mode.

undone turret
#

okayy

#

thank you