Who: As a developer
What: I want to be able to validates the user that makes api calls
Why: so that I can be sure only authenticated user can access user related data
Acceptance criteria
Only api request with a firebase token in the header are allowed
Implementation details.
Create getUserToken method for the Firebase provider
Save user Token in local storage
Add authorisation check middleware that decodes Token to all API calls
Add authorisation with user token in header to all fetch calls in pages
User story
Who: As a developer What: I want to be able to validates the user that makes api calls Why: so that I can be sure only authenticated user can access user related data
Acceptance criteria
Only api request with a firebase token in the header are allowed
Implementation details.