- ✅ Receives a request of type POST on route /api/login
- ✅ Validates required email and password data
- ✅ Validates that the email field is a valid email
- ✅ Searches the user with the email and password provided
- ✅ Generates an access token from the user ID
- ✅ Updates user data with the generated access token
- ✅ Returns 200 with the access token and user name
- ✅ Returns error 404 if the API does not exist
- ✅ Returns error 400 if email or password is not supplied by the client
- ✅ Returns error 400 if the email field is an invalid email address
- ✅ Returns error 401 if it does not find a user with the given data
- ✅ Returns error 500 if an error occurs when trying to generate the access token
- ✅ Returns error 500 if an error occurs when trying to update the user with the generated access token