You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Certain backend routes (like triggering manual database syncs in the future) should only be accessible to authorized clients. We need a simple header check.
Requirements
Add an ADMIN_API_KEY to the .env file.
Create a middleware function verifyApiKey.
Check if req.headers['x-api-key'] matches the environment variable.