Skip to content

ojusxe/stripe-payment-intent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 

Repository files navigation

Stripe Payment Intent

This project is a demonstration of how to integrate Stripe Payment Intent API with a Go backend. The project includes a demo frontend with React to initiate the payments and send request to Go API. The purpose of this project is to provide a simple example of how to set up and use Stripe Payment Intent API in a full-stack application.

Backend Server Setup

  1. Clone the repository:
git clone https://github.com/ojuss/stripe-payment-intent.git
cd stripe-payment-intent/go-backend
  1. Create a .env file in the go-backend directory and add your Stripe secret key:
STRIPE_KEY=your_stripe_secret_key
PORT=4242
  1. Install dependencies:
go mod tidy
  1. Run the server:
go run server.go

The backend server will start on port 4242.

Frontend Client App Setup

  1. Navigate to the go-frontend directory:
cd ../go-frontend
  1. Install dependencies:
npm install
  1. Run the client app:
npm start

The frontend client app will start on port 3000. Go to http://localhost:3000/product to view it.

Contributing

If you would like to contribute to this project, please fork the repository and submit a pull request. I welcome all contributions, including bug fixes, new features, and documentation improvements.

About

Stripe payment integeration with Go backend

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published