dawidl022 / ECS506-flat-finder-app

FDM Flat Finder application for ECS506U - Software Engineering group project at Queen Mary University of London
1 stars 1 forks source link

Return custom JWT with user id and email after logging in #111

Closed dawidl022 closed 1 year ago

dawidl022 commented 1 year ago

Example JWT:

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiJjNTg5ZTM2Mi04Y2M4LTRmZTktODQ5Mi1mMjVmYmE1MTllOTYiLCJlbWFpbCI6ImRvbWRhdzdAZ21haWwuY29tIn0.n8LJOTiRh1V0VFC27cS4XG-X8uRH8BkiHShEmKI55UM

The payload is as follows for this token:

{
  "sub": "c589e362-8cc8-4fe9-8492-f25fba519e96",
  "email": "domdaw7@gmail.com"
}

Where sub is the user id.