mezielabs / adonis-stripe Goto Github PK
View Code? Open in Web Editor NEWThis package makes it seamless to work with Stripe in AdonisJS 5 applications.
License: MIT License
This package makes it seamless to work with Stripe in AdonisJS 5 applications.
License: MIT License
bug with stripe.webhooks.constructEvent
I need to use the webhook but it doesn't work in my opinion it's related to the body parser
try {
event = stripe.webhooks.constructEvent(request.body(), request.header('stripe-signature'), Env.get('STRIPE_WEBHOOK_SECRET'))
} catch (err) {
Logger.error(`⚠️ Webhook signature verification failed.`, err.message)
return response.badRequest()
}
1.0.5
Bug: Template stripe.ts
files are not copied when running node ace configure @mezielabs/adonis-stripe
adonis-stripe 1.0.4
Error stack trace:
node ace configure @mezielabs/adonis-stripe
...
UnhandledPromiseRejectionWarning: Error: Template file not found: <local-path>/node_modules/@mezielabs/adonis-stripe/build/templates/stripe.txt
Actual paths: ../templates/config/stripe.txt
& ../templates/contracts/stripe.txt
I think you might've forgot to update the file paths in the command script. Anyway, I've resolved the issue by manually copy-pasting the two files into my project. And now it works fine! Thank you for the package
Showing error at configuration time
/Users/abiliocoelho/www/dev/stripe/node_modules/@adonisjs/core/build/src/Ignitor/SignalsListener/index.js:50
this.application.logger.fatal(error, '"uncaughtException" detected. Process will shutdown');
^
TypeError: Cannot read properties of undefined (reading 'fatal')
at process. (/Users/abiliocoelho/www/dev/stripe/node_modules/@adonisjs/core/build/src/Ignitor/SignalsListener/index.js:50:37)
at Object.onceWrapper (node:events:514:26)
at process.emit (node:events:394:28)
at process.emit (/Users/abiliocoelho/www/dev/stripe/node_modules/source-map-support/source-map-support.js:516:21)
at process._fatalException (node:internal/process/execution:170:25)
at processPromiseRejections (node:internal/process/promises:246:11)
at processTicksAndRejections (node:internal/process/task_queues:97:32)
I'm using Adonis version 5, I've done all the steps for installation, but when setting up this error appears.
The package is working perfectly but I get this TypeScript error. What did I miss? (new to typescript) :)
Module '"@IOC:Mezielabs/Stripe"' has no exported member 'StripeConfig'. Did you mean to use 'import StripeConfig from "@IOC:Mezielabs/Stripe"' instead?ts(2614)
PS: Thanks a lot for this package.
Not a bug, but I recommend including stripe
as a peer-dependency, not as dependency. When I installed your package, the installed stripe package is at v8.222
, when the latest version currently is v10.7
at the time of writing.
Given that this is a wrapper package that provides a stripe singleton instance, I think this should be safe to implement.
adonis-stripe: 1.0.5
Adonis V6 got released on the 24th of january, it'd be great if you make this package compatible :)
There is a package migration guide
ERROR
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.