fix(astrolabe): Fix revoke access button HTTP method mismatch

The "Revoke Access" button in Astrolabe personal settings was failing
with "Unable to connect to server" error in multi-user basic auth mode.

Root cause: The JavaScript sends a POST request but the route was
configured to accept DELETE. Changed the route to:
- Use POST method (matching the JavaScript fetch call)
- Use /api/v1/background-sync/credentials/revoke path (avoiding
  conflict with storeAppPassword which uses POST on the base URL)

Added integration test that verifies the complete revoke flow:
enable background sync → click revoke → verify credentials deleted.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Chris Coutinho
2025-12-29 22:49:53 -06:00
co-authored by Claude Opus 4.5
parent 13dd709fc2
commit 48a4182ef9
3 changed files with 261 additions and 3 deletions
+2 -2
View File
@@ -47,8 +47,8 @@ return [
],
[
'name' => 'credentials#deleteCredentials',
'url' => '/api/v1/background-sync/credentials',
'verb' => 'DELETE',
'url' => '/api/v1/background-sync/credentials/revoke',
'verb' => 'POST',
],
[
'name' => 'credentials#getStatus',