Also had the same problem and I just changed my browser and it worked!!! (Do not use google chrome or brave, use firefox or some other browser)


Please use const stripeClient = require('stripe')('sk_test*************')


I had a similar issue with the same error message.

What I tried to do is to use the key from process.env variables, but it didn't work.

const Stripe = require('stripe');
const stripe = Stripe('sk_test_...');

This worked for me.

Related Query

More Query from same tag