1.0.3 • Published 2 years ago

strapi-plugin-stripe-payment-gateway-basic v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

Strapi plugin stripe-payment-gateway-basic

This is a sample template on how to integrate Stripe with Strapi

Prerequisite:

Create Stripe dev account

Get Stripe API Credentials

  • Publishable Key
  • Signing Secret
  • Secret Key

Frontend code

Follow the codes from Homepage

Backend code

Follow the routes, controllers, and services codes Set environment variables SIGNING_SECRET and SECRET_KEY in .env in the root Strapi folder. Also the STRIPE_SUCCESS_REDIRECT_URL and STRIPE_CANCEL_REDIRECT_URL.

Note

koa-body/unparsed.js must be enabled under Strapi's config/middleware file

settings: {
  parser: {
    enabled:  true,
    multipart:  true,
    includeUnparsed:  true,
  },
},

koa-body/unparsed.js must also be installed to parse the Stripes raw payload.

Then run yarn strapi build then yarn develop. Make this plugin's createsession and webhook API to be public in Strapi Settings -> Users and Permissions -> Roles -> Public

That's it. Just click the

Pay

button to try! Happy coding :)

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago