docs: add Clerk setup guide and improve auth error messages

- Create CLERK_SETUP.md with step-by-step instructions
- Improve error message to indicate Clerk configuration issue
- Remove debug logging from auth middleware
- Update error handling to be more helpful

The 401 error is caused by missing Clerk Secret Key in server/.env
This commit is contained in:
2025-11-16 19:23:37 +00:00
parent 18e1e03bfc
commit d80e787701
4 changed files with 83 additions and 2 deletions

View File

@@ -50,7 +50,7 @@ class ReportService {
if (!response.ok) {
if (response.status === 401) {
throw new Error('You must be signed in to upload photos. Please sign in and try again.');
throw new Error('Authentication failed. Please make sure the backend Clerk Secret Key is configured correctly.');
}
// Try to get error details from response