Skip to content

Natisk/stripe_subscriptions

Repository files navigation

Stripe Subscriptions

This is a brief guide to get you started with running the application locally.

Prerequisites

Before you begin, ensure you have the following installed on your machine:

  • docker

Installation

  1. Clone the repository to your local machine:

    git clone git@github.com:Natisk/stripe_subscriptions.git
    
  2. cd stripe_subscriptions

  3. Run docker compose build

  4. Create stripe account on stripe.com.

  5. Go to dashboard -> Developers -> API keys

  6. In the application root folder create .env file according to .env.example

  7. Add API key to .env file

  8. Run

    docker compose run --rm stripe
    
  9. Stripe CLI will provide you a link for authentication.

  10. Follow the link and confirm authentication on stripe web site.

  11. Run again

    docker compose run --rm stripe
    
  12. Now Stripe CLI will give you webhook secret, paste it to .env

  13. Stop that container and Run

    docker compose up
    
  14. Now you can create Subscriptions on Stripe web interface or open new terminal tab and run

    docker compose run --rm stripe trigger customer.subscription.created
    

    or

    docker compose run --rm stripe trigger customer.subscription.deleted
    
  15. Visit localhost:3000 to see newly created subscription

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors