#owerol
1 messages · Page 1 of 1 (latest)
Are you using test keys? We don't send receipt emails automatically in test mode
Yes im using test keys, im gonna try with live keys, thanks :))
We don't recommend testing in live mode
What specifically do you want to check on the emails?
When the checkout session is completed and the webhook triggers my function i send an email to the costumer and to myself. Then i want stripe to send a receipt so i added some code to my application:
stripe.PaymentIntent.create(
amount=session['amount_total'],
currency="huf",
payment_method_types=["card"],
receipt_email=session['customer_details']['email'],
description="3% of your purchase goes toward our ocean cleanup effort!",
)
I tested it and it has no error, i received the welcome emails but has not received the receipt from stripe
If you're using Checkout, then why do you need a separate Payment Intent too? Checkout sends payment receipts automatically
invoice_creation={"enabled":True}, if i add this to my checkout?
Well, that's somethign different entirely. Do you need an invoice or just a receipt?
invoice would be better
I tried in live mode, but has not received invoice from stripe. My code:
checkout_session = stripe.checkout.Session.create(
payment_method_types=['card'],
invoice_creation={"enabled":True},
line_items=[{
'price_data': {
'currency':'huf',
'product_data':{
'name':x[1],
},
'unit_amount':x[3]*100,
},
'quantity':1,
} for x in request.session['items']],
mode='payment',
success_url=f'https://capaiskola.com/success/',
cancel_url='https://capaiskola.com/cancel/',
billing_address_collection='required',
)
Does the stripe send invoice instantly?
Did you complete the session?
Yes, i can find it in stripe, i can download the invoice pdf but i didn't receive the email. Do you have any idea what can cause this?
What's the cs_xxx ID?
where can i find this?
👋 stepping in here as ynnoj needed to step away
If you can provide the Invoice ID or PaymentIntent ID associated that might be easier to grab
You should be able to find that based on the Invoice or payment in your Dashboard
Otherwise, you can grab the Checkout Session ID from the creation request in your logs from the "developers" tab
invoice ID: in_1NLmp8Lzf0Gptnh97p2kwZra
checkout session ID: evt_1NLmp9Lzf0Gptnh9Z615Sa0y
Everything works perfectly, i can download the automatic generated pdf but hasn't received the email witt it. Any idea what can be wrong?
Taking a look
Thanks
Looks like you don't have your email settings on. You turn that on at: https://dashboard.stripe.com/settings/emails
Oh i will look at it thank you for your feedback!