#lucasribeiro_

1 messages ยท Page 1 of 1 (latest)

dull gateBOT
winter thistle
#

Hello! What debugging have you done so far? Are you seeing any errors? Do you have an example event ID I can take a look at?

pulsar imp
#

I'm not sure how to provide more details, but I'm using Next.js with TypeScript. This is the ID of my webhook: 'we_1OCq16EJpdNLS1lTUJQYiapo'.

#

"evt_1OCsZtEJpdNLS1lTrJePVlD6". Event ID

winter thistle
#

Hmmm... does your webhook handler have logic to raise a 405 error?

pulsar imp
#

in my file I handle GET and POST, after: return res.status(405).json({ error: 'Method Not Allowed' });

#

Thanks for the quick responses, by the way. ^^

#

I can send you the entire code if you wish

winter thistle
#

I don't htink I need your code quite yet

#

Have you been able to successfully curl your own server in production? Just to make sure you're not getting 405 errors there

pulsar imp
#

yes, in using CLI on localhost it works

winter thistle
#

Not localhost - are you able to curl/call your production server, separately?

dull gateBOT
pulsar imp
#

No, I can't do that...

#

I actually don't know how I could do it

burnt lintel
#

You can research on how to curl, or how to use Postman ๐Ÿ™‚

pulsar imp
#

Im searching about Postman

#

I managed to do a test send with Postman, but still with the 405 (method not allowed)

burnt lintel
#

What method you sent in?

pulsar imp
#

POST

#

when I try with GET I get ok but not in POST

burnt lintel
#

So you endpoint is not accepting POST. You would want to review your framework setting

pulsar imp
#

but if I wasn't accepting POST, on localhost I wouldn't be able to, but it's working.

burnt lintel
#

It could be different setting when you deployed to your hosting provider. Have no idea. That's something you would want to play around and it's really before thinking of any interaction with Stripe ๐Ÿ™‚

#

Simply about how to accept POST request from the internet