* fix: improve error handling in Stripe collectCard method - Add CollectCardFailure error code for better error categorization - Replace generic error with ErrorWithCode for consistent error handling - Add error mappings for common Stripe errors (customer not found, invalid API key, rate limit, etc.) - Include Stripe error message when available for better debugging - Follow the same pattern used in chargeCard method Co-Authored-By: benny@cal.com <sldisek783@gmail.com> * fix: add CollectCardFailure to getHttpStatusCode mapping This ensures the error returns 400 instead of 500 when collectCard fails. Co-Authored-By: benny@cal.com <sldisek783@gmail.com> * docs: add comments explaining ChargeCardFailure vs CollectCardFailure Co-Authored-By: benny@cal.com <sldisek783@gmail.com> * refactor: simplify collectCard error handling Remove complex error mapping logic per code review feedback. Co-Authored-By: benny@cal.com <sldisek783@gmail.com> * test: add CollectCardFailure to HTTP status code tests Co-Authored-By: benny@cal.com <sldisek783@gmail.com> --------- Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
Enterprise Edition
Welcome to the Enterprise Edition ("/ee") of Cal.com.
The /ee subfolder is the place for all the Pro features from our hosted plan and enterprise-grade features such as SSO, SAML, ADFS, OIDC, SCIM, SIEM, HRIS and much more.
❗ WARNING: This package is copyrighted (unlike our main repo). You are not allowed to use this code to host your own version of app.cal.com without obtaining a proper license first❗
Setting up Stripe
- Create a stripe account or use an existing one. For testing, you should use all stripe dashboard functions with the Test-Mode toggle in the top right activated.
- Open Stripe ApiKeys save the token starting with
pk_...toNEXT_PUBLIC_STRIPE_PUBLIC_KEYandsk_...toSTRIPE_PRIVATE_KEYin the .env file. - Open Stripe Connect Settings and activate OAuth for Standard Accounts
- Add
<CALENDSO URL>/api/integrations/stripepayment/callbackas redirect URL. - Copy your client*id (
ca*...) toSTRIPE_CLIENT_IDin the .env file. - Open Stripe Webhooks and add
<CALENDSO URL>/api/integrations/stripepayment/webhookas webhook for connected applications. - Select all
payment_intentevents for the webhook. - Copy the webhook secret (
whsec_...) toSTRIPE_WEBHOOK_SECRETin the .env file.