You are viewing an old version of this page. View the current version.
Compare with Current
View Page History
« Previous
Version 8
Next »
Architecture AS-IS
OTP Sign In
Proposal
Solution 1 - Add isBlocked field in User DynamoDB item
Workflow:
Support agent blocks the user
Blocked user attempts login
User is blocked while logged in WL
Task breakdown
Changes in intl-notifications-service
Changes in intl-users-service
intl-users-service
Create block user endpoint
Endpoint: POST /api/v1/users/block-user/{cognitoId}
Add isBlocked field to user details base interface
Use UpdateService to set is blocked to true
Create unblock user endpoint
Endpoint: POST /api/v1/users/unblock-user/{cognitoId}
Use UpdateService to set is blocked to false
Prevent blocked users from signing in
Create UserBlockedError apollo error
Add isBlocked validation in the listed resolvers:
createOTP
createLoginOTP
signInJWT
socialLogin
User not found validation for reference
Changes in intl-packages
intl-packates/packages/user
Add isBlocked to userDetails type
Create method to block user
Should use axios to trigger a request to user service
Create method to unblock user
Should use axios to trigger a request to user service
Changes in intl-whitelable-graphql
Changes in intl-whitelable-app
Solution 2 - Disable user in cognito
Add Comment