Skip to content

E-commerce App built in Swift / SwiftUI using Firebase (Authentication, Hosting, Firestore Database, Storage, Analytics, Remote Config) and Stripe with a server hosted on Render.

Notifications You must be signed in to change notification settings

DavidBeckhamdeveloper/eCommerceServer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

A backend for Stripe's integration into the eCommerce app

This project includes a Node.js server script hosting the backend logic for enabling integration of Stripe’s prebuilt payment UI on the client-side.

It defines 2 endpoints:

  • /customers: creates a Stripe Customer object and sends back the Customer's id to the client so that it can be retrieved later on.
  • /checkout: retrieves the Stripe Customer Object associated with the user, creates an Ephemeral Key for the Customer and creates a Payment Intent with the payment amount (in cents) and the currency.

The server then returns the Payment Intent’s client secret, the Ephemeral Key’s secret, the Customer’s id, and the Publishable Key to the app, enabling the client-side to complete the checkout process.

About

E-commerce App built in Swift / SwiftUI using Firebase (Authentication, Hosting, Firestore Database, Storage, Analytics, Remote Config) and Stripe with a server hosted on Render.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published