mrbbot / slshx

⚔️ Strongly-typed Discord commands on Cloudflare Workers
MIT License
212 stars 9 forks source link

Method Not Allowed (CORS) #10

Closed CraigglesO closed 2 years ago

CraigglesO commented 2 years ago

Uploading this template to cloudflare and accessing the site I get Method Not Allowed. I am convinced it is a cors issue, but not sure how to make changes since slshx handles everything.

CraigglesO commented 2 years ago

Looking at the source code, it returns Method Not Allowed for any requests that are not POST. I figured you could access the "Add to server" page after you setup the worker but this is not the case. You need to use dev mode + tunnel/localhost to add the application BEFORE you try to use it online.

Lencof commented 2 years ago

hmm.... this project worked?

CraigglesO commented 2 years ago

Yeah, I should close this issue. Using the tutorials in the README got me to a usable API online.