Subject: POST /api/x returns 405 from nginx before reaching my Node app
Posted by user_c13215 in general.
Subject: POST /api/x returns 405 from nginx before reaching my Node app Server: bb9d465b Hi, My Node.js app on this server proxies requests to an external API. All GET requests work and other POST endpoints reach the app, but POST to /api/x is rejected with a 405 HTML page generated by nginx, so the request never reaches my application. Evidence (2026 12 02 17:00:53 GMT, CF RAY a63be3ee3b585906 WAW): POST https://tahcmils.wisp.uno/api/x 405 Method Not Allowed Content Type: text/html; charset=utf 8 body: <html <head <title 405 Not Allowed</title </head <body <center <h1 405 Not Allowed</h1 </center <hr <center nginx</center </body </html POST https://tahcmils.wisp.uno/api/auth/email/request code 400 (reaches app) GET https://tahcmils.wisp.uno/api/x 404 (reaches app) GET https://tahcmils.wisp.uno/ health 200 {"ok":true,...} The same request works when I run the identical server.js locally, so the block happens in front of the container. Earlier the same 405 appeared for other request shapes as well: POST /api/x?anonop=<value POST /api/x with header X Anon Op: <value Now it affects POST /api/x regardless of query/headers/body. I believe a WAF/security rule (ModSecurity/CRS, CrowdSec, or an nginx location/limit except) is matching these requests. Could you please: 1. check the nginx/WAF logs for this request (CF RAY a63be3ee3b585906 WAW) and tell me which rule returns 405; 2. remove the rule or whitelist POST /api/x for this server. This is a legitimate API proxy for a chat frontend hosted on GitHub Pages, not a scanner or abuse traffic. The endpoint only forwards JSON to an upstream API and requires CORS, which the Node app already handles. Thanks.