stripe-cli
stripe-cli copied to clipboard
NPM package for stripe-cli?
Problem
This cli requires to be installed beforehand and haven't a node-like way to be installed. I am only going to use the stripe-cli for webhooks in test env. Besides node, this is the only program that is required to be installed manually in my setup. I don't use Docker because it would cost me more time than it would save. Brew isn't available for windows and I don't really like it, only used it once in linux.
Feature
This could be a npm package for easier installation and usage flow. At first, for simplicity, the package could contain all the executables and it would decide which one to run at runtime via a simple .js script. Being a npm package, they would be located under node_modules. Not internet/disk optimized, but would work very easily. I can do this simple prototype in my free time if you want to.
Then, it would be possible to execute it via npx stripe
in the cli or directly under the scripts of package.json. New versions of stripe-cli would update the package version.
A better / smarter package version would detect the user user SO and CPU and download only the corresponding executable.
Unfortunately there is already a package using the stripe-cli name (https://www.npmjs.com/package/stripe-cli), but it could be called maybe @stripe/cli.
It would also be possible to install it globally with npm i -g @stripe/cli
with no further code.
Examples
It would be in my devDependencies in the package.json of my server, so when I npm install
or yarn install
the stripe-cli would be easily and automatically installed. In my server npm start
(for local testing), it would include the stripe command to init the webhook. It would also be very good for CI/CD.
How's this going? Any steps forward? Would also love to see the stripe cli available on npm :)
I'd ask for this as well. I am using Codespaces and its not available for install via NPM
Where we at on this?
...
+1 for this. Ideally devs wouldn't need to install any additional dependencies to run our application that uses the Stripe CLI to trigger checkout webhooks for local development. Without a node module for the CLI, I'm forced to have devs install the Stripe CLI or just deal with not having payments testable locally, which is not great.
2 years and still no answer or solution from them... C'mon this is a quite easy thing to implement and this is a billionaire company.
Why do I need to add a GPG key and another repository to install a cli tool that only bootstraps a language-specific project? It's not 2008. Can we please get first class support for the languages and platforms?