Return 404 JSON for oauth-protected-resource discovery probes.

Stop 302ing Claude well-known checks to /login without advertising OAuth.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Towsty
2026-11-02 22:30:26 -06:00
co-authored by Cursor
parent 7fd040ad62
commit ab1d6acb2d
4 changed files with 25 additions and 5 deletions
@@ -0,0 +1,7 @@
/** Claude discovery probe — no OAuth; never redirect to /login. */
export default defineEventHandler((event) => {
setResponseStatus(event, 404)
setResponseHeader(event, 'Content-Type', 'application/json')
setResponseHeader(event, 'Cache-Control', 'no-store')
return { error: 'not found' }
})