#cute_lynx_31904
1 messages · Page 1 of 1 (latest)
hi @snow fern i have included the customer_email but not sure if it is used to trigger a receipt. Here is my checkout.session.create object:
const checkoutSession = await stripe.checkout.sessions.create(
{
mode: cart.cartType === 'standard' ? 'payment' : 'subscription',
line_items: lineItems,
success_url: `${config.web.baseUrl}/checkout-confirmation?checkout=${cartId}`,
cancel_url: `${config.web.baseUrl}/${cart.username}?cart=true`,
...(cart.cartType === 'subscription'
? {
subscription_data: {
application_fee_percent: FEE_PERCENTAGE * 100,
},
}
: {
payment_intent_data: {
application_fee_amount: cart.fee,
receipt_email: customerEmail,
},
}),
customer_email: customerEmail,
client_reference_id: localCheckoutSession.id,
metadata: {
cartType: cart.cartType,
},
},
{
stripeAccount: connectedAccountId,
},
);
Ok. it looks good to me. Please note that no emails are sent in test mode.
yes ive tested in live mode and no reciepts are being sent 😦
what's the checkout session ID?
cs_live_a1PNKeomyEeufyM5Cma9QqxtPeRO6pJpKkp7rJroBeZFEaV7wN9cm2dqVY
The receipt was sent on Nov 7th 2023 7:12:56 am
and the title of the email is Your receipt from Prezz #2455-8702
yes i had manually sent it
through the dashboard
is it possibly to automatically send it like with payment_intent_data: { receipt_email: ... }
https://dashboard.stripe.com/settings/emails did you enable email for Successful payments in this page?
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
yep its all enabled
No it's not enabled in the connected account.
Since it's a direct charge, it should be enabled in the connected account.
ohh let me see. how would i enable it for the connected account?
The account need to log into their Dashboard to enable it
Hmm, wait, it
it's a express account. You shouldn't use direct charges on a express account.
You should use destination charge instead.
can you provide some documentation on this?
is this the reason for no email or does it still have to be enabled on the express account
i'm not usre if express dashboard has a settings for email.
The main reason that you shouldn't use direct charges for express account is that they don't have full dashboard access and they can't manage disputes
hm ok but the current way is still valid and receipt emails should still work?
with subscription mode on the checkout session you cannot use payment_intent_data anyways
if the " Successful payments" settings is switched on in the connected account's dashboard, then yes.
Im not sure where this setting is? I go to their account, then "View dashboard as ..."
it makes no sense to do this for Express really, this is why Direct Charges on Express is not recommened
that is not a 'real' dashboard that the user themselves have access to, and as you see, you can't access all parts or all settings, so it's just not possible to do this. Generally you'd use Destination charges and manage everything in your platform instead.
ok i see
there is an issue with not being able to create a customer portal for customer's existing on connected account until i manually go in and save the customer portal settings in the connect account. is this right?
hmm not sure, kind of rings of bell with needing to enable something
did you get an error when calling the API to try create a portal? https://stripe.com/docs/api/customer_portal
yes it says to save the settings first
but again overall this is not what Express accounts are designed for; if the customer is being charged directly by the connected account and managed by them you'd use Standard + Direct
I'd say that's just a limitation of using Express + Direct again then, as I said we don't recommend that integration path
ok i might have to revisit that then