How to set a 5% application fee in Stripe for Cal self-hosted ? #18510
Replies: 2 comments
-
To set a 5% application fee in Stripe for Cal.com self-hosted, you need to configure the
Here's a code snippet that demonstrates this setup: const paymentFee = Math.round(payment.amount * 0.05); // 5% application fee
const params = {
amount: payment.amount,
currency: payment.currency,
application_fee_amount: paymentFee,
customer: setupIntent.customer as string,
payment_method: setupIntent.payment_method as string,
off_session: true,
confirm: true,
};
const paymentIntent = await this.stripe.paymentIntents.create(params, {
stripeAccount: this.credentials.stripe_user_id,
}); This configuration ensures that the platform retains 5% of the payment as an application fee, and the remaining amount (after Stripe processing fees) is transferred to the service provider [1]. To continue talking to Dosu, mention @dosu. Help Dosu learn! Give it feedback: Great Response | Irrelevant Answer | Incorrect Sources | Too Verbose | Hallucination | Other |
Beta Was this translation helpful? Give feedback.
-
any help ? any idea ? |
Beta Was this translation helpful? Give feedback.
-
Hi everyone, 👋
I'm self-hosting Cal.com and using Stripe to process payments for bookings. I want to charge a 5% platform fee when a user books a session. The goal is:
It looks like this is possible using the following environment variables:
PAYMENT_FEE_PERCENTAGE and PAYMENT_FEE_FIXED
but it didn't work.
Any suggestions
Thanks
Beta Was this translation helpful? Give feedback.
All reactions