#.jovanm_

1 messages · Page 1 of 1 (latest)

sterile cragBOT
#

Hello! We'll be with you shortly. 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.

plush tide
gritty shore
#

Should I disable this setting?

plush tide
#

those settings are for invoices, you want to disable receipts yeah?

gritty shore
#

Yes, I want the user to stop receiving this kind of email

plush tide
gritty shore
#

Okay thanks

#

This is another inquiry:

So, this is my payment element config:

  const paymentElement = elements.create('payment', {
    wallets,
    defaultValues: {
      billingDetails: {
        address: {
          country: 'US',
        }
      }
    },
    fields: {
      billingDetails: {
        address: {
          country: 'never'
        }
      }
    }
  });

Since I already put the country on defaultValues. Why I got this error?

Uncaught (in promise) IntegrationError: You specified "never" for fields.billing_details.address.country when creating the payment Element, but did not pass confirmParams.payment_method_data.billing_details.address.country when calling stripe.confirmPayment(). If you opt out of collecting data via the payment Element using the fields option, the data must be passed in when calling stripe.confirmPayment().
#

Do I need to do this?

  // Confirm the PaymentIntent using the details collected by the Payment Element
  const { paymentIntent, error } = await stripe.confirmPayment({
    elements,
    clientSecret,
    confirmParams: {
      payment_method_data: {
        billing_details: {
          address: {
            country: 'US'
          }
        }
      },
      return_url: window.location.href.split("?")[0] + 'successful-payment',
    },
  });
plush tide
#

defaultValues pre-fills the value in the form, since you're setting the field to never then its possible that the element ends up not passing the value

#

you'd need to pass it to confirmParams

#

when calling confirmPayment

gritty shore
#

Okay, thanks!

#

I just need to verify, since I disabled the Successful Payments here in Customer Emails, the customer shouldn't be able to receive the receipts in their email right?

plush tide
#

yes