| CORS blocked |
Browser request fails before reaching the API |
Missing `Access-Control-Allow-Origin` or bad preflight config |
Return the correct CORS headers and handle `OPTIONS` requests |
| 401 Unauthorized |
Token or API key is invalid, missing, or expired |
Client sent wrong auth header or stale token |
Refresh token, check scopes, and verify header name |
| 404 Not Found |
Wrong endpoint path or missing record id |
Route mismatch or bad URL construction |
Check route naming and confirm the resource exists |
| 409 Conflict |
Two updates clash or a duplicate key already exists |
Concurrent writes or unique constraint violation |
Re-fetch latest state and retry safely |
| 429 Too Many Requests |
The API is protecting itself from too many calls |
Client loop, burst traffic, or missing backoff |
Respect rate-limit headers and add retry delay |
| 500 Internal Server Error |
The server failed while processing |
Unhandled exception, SQL issue, or null data path |
Inspect logs, request id, stack trace, and database errors |
| Invalid JSON |
Body cannot be parsed |
Broken commas, quotes, or content type mismatch |
Validate body before sending and set `Content-Type: application/json` |
| Stale data on page |
The UI shows old values after save |
Cache layer, no re-fetch, or race condition |
Invalidate cache and reload the relevant data source |
| Slow response |
Users wait too long for data |
Heavy SQL, no index, or large payload |
Add indexes, reduce fields, paginate, and cache safe reads |
| Duplicate events |
Same webhook or POST is processed twice |
Client retry without idempotency |
Use idempotency keys and dedupe on event id |
| BOLA / object access issue |
A user can access another user record by changing the ID |
Object-level authorization is missing |
Check ownership or scope on every object lookup |
| CORS too open |
Any origin can call the API in unsafe ways |
Allow-all policy was left enabled |
Restrict origins, methods, and credential behavior deliberately |