From 6f501382602662a5f83de05c4a2116d33566a964 Mon Sep 17 00:00:00 2001 From: Daniel Lo Nigro Date: Mon, 17 Nov 2025 04:23:51 -0800 Subject: [PATCH] Improve Stripe example (#851) --- .env.example | 12 +++++++++++- docker-compose.prod.yml | 7 +++++++ 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/.env.example b/.env.example index 30101827f..1cdc87e6c 100644 --- a/.env.example +++ b/.env.example @@ -98,8 +98,18 @@ POSTHOG_API_KEY= POSTHOG_HOST= # Stripe Payment +# Get the keys from the Stripe dashboard +# Starts with "sk_" STRIPE_PAYMENT_SECRET_KEY= +# Starts with "pk_" STRIPE_PAYMENT_PUBLISHABLE_KEY= +# Get the client ID from https://dashboard.stripe.com/settings/connect/onboarding-options/oauth +# Starts with "ca_" STRIPE_PAYMENT_CLIENT_ID= +# Configure the webhook here: https://dashboard.stripe.com/workbench/webhooks/ +# Endpoint URL is https://example.com/api/webhooks/stripe (replace "example.com" with the correct domain) +# Select the "checkout.session.completed" and "account.updated" events +# Starts with "whsec_" STRIPE_PAYMENT_WEBHOOKS_SECRET= -STRIPE_PAYMENT_REDIRECT_URL= \ No newline at end of file +# Replace example.com with the correct domain +STRIPE_PAYMENT_REDIRECT_URL=https://example.com/preferences/payment-methods/stripe/callback diff --git a/docker-compose.prod.yml b/docker-compose.prod.yml index c125f6224..a17276efd 100644 --- a/docker-compose.prod.yml +++ b/docker-compose.prod.yml @@ -122,6 +122,13 @@ services: - S3_SECRET_ACCESS_KEY=${S3_SECRET_ACCESS_KEY} - S3_ENDPOINT=${S3_ENDPOINT} - S3_BUCKET=${S3_BUCKET} + + # Stripe + - STRIPE_PAYMENT_SECRET_KEY=${STRIPE_PAYMENT_SECRET_KEY} + - STRIPE_PAYMENT_PUBLISHABLE_KEY=${STRIPE_PAYMENT_PUBLISHABLE_KEY} + - STRIPE_PAYMENT_CLIENT_ID=${STRIPE_PAYMENT_CLIENT_ID} + - STRIPE_PAYMENT_WEBHOOKS_SECRET=${STRIPE_PAYMENT_WEBHOOKS_SECRET} + - STRIPE_PAYMENT_REDIRECT_URL=${STRIPE_PAYMENT_REDIRECT_URL} database_migration: container_name: bigcapital-database-migration