Skip to content

Demo for accepting payments with Link

License

Notifications You must be signed in to change notification settings

stripe-samples/link

Repository files navigation

Checkout faster with Link

An Express server implementation

Requirements

How to run

  1. Confirm .env configuration

Ensure the API keys are configured in .env in this directory. It should include the following keys:

# Stripe API keys - see https://stripe.com/docs/development/quickstart#api-keys
STRIPE_PUBLISHABLE_KEY=pk_test...
STRIPE_SECRET_KEY=sk_test...

# Required to verify signatures in the webhook handler.
# See README on how to use the Stripe CLI to test webhooks
STRIPE_WEBHOOK_SECRET=whsec_...

# Path to front-end implementation. Two versions are available, one in HTML and the other using crate-react-app
STATIC_DIR=../../client/html

# or

STATIC_DIR=../../client/react-cra
  1. Install dependencies
npm install
  1. Run the application
npm start
  1. Go to localhost:4242 to see the demo