...
Zenuml sequence macro lite |
---|
uuid | 6b1e5f66-1cf0-42a2-b0fc-0b8fb97ceebd |
---|
customContentId | 4808409158 |
---|
updatedAt | 2024-06-18T16:36:01Z |
---|
|
|
Braze
Proposal
Solution 1 - Add isBlocked field in User DynamoDB item
Workflow:
Support agent blocks the user
Zenuml sequence macro lite |
---|
uuid | b71e9351-b423-4ec1-ba13-9349ce24c6aa |
---|
customContentId | 4810997767 |
---|
updatedAt | 2024-0607-19T0101T13:5624:16Z18Z |
---|
|
|
Blocked user attempts login
Zenuml sequence macro lite |
---|
uuid | 9e561ae4-39d8-4c19-81ba-99e914394741 |
---|
customContentId | 4810997776 |
---|
updatedAt | 2024-06-19T02:01:46Z |
---|
|
|
User is blocked while logged in WL → Add getMe query when user goes to cart page
Zenuml sequence macro lite |
---|
uuid | 5495a0ee-0cbb-4042-8755-8a716fa406f1 |
---|
customContentId | 4810965031 |
---|
updatedAt | 2024-06-19T02:08:58Z |
---|
|
|
User is blocked while logged in WL → Validate blocked user on gateway
Zenuml sequence macro lite |
---|
uuid | ee40a82d-c05d-4041-a5ed-e235ab9900cd |
---|
customContentId | 4836786181 |
---|
updatedAt | 2024-07-08T04:37:55Z |
---|
|
|
Task breakdown
Changes in intl-whitelabel-cms
Expand |
---|
|
Create email template for blocked user notification Templates should use the Liquid syntax
Create email template for unblocked user notification Templates should use the Liquid syntax
|
Changes in intl-notifications-service
Expand |
---|
|
Create send block notification endpoint POST /api/v1/email/send-block Create block TemplateType Receive SendEmailRequestDto as payload
Create send unblock notification endpoint POST /api/v1/email/send-unblock Create unblock TemplateType Receive SendEmailRequestDto as payload
|
Changes in intl-users-service
Expand |
---|
|
Create block user endpoint Endpoint: POST /api/v1/users/block-user/{cognitoId} Add isBlocked field to user details base interface The field should be returned in GET user endpoint
Use UpdateService to set is blocked to true user notification-service to send email remove user from braze campaings
Create unblock user endpoint Endpoint: POST /api/v1/users/unblock-user/{cognitoId} Use UpdateService to set is blocked to false user notification-service to send email return user to braze campaings
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
Expand |
---|
title | 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
Expand |
---|
title | intl-whitelable-graphql |
---|
|
Add isBlocked to userDetails type
|
Changes in intl-admin-app
Expand |
---|
|
Create block status card on customer page Update users package Add isBlocked to user details type in graphql Add isBlocked to customer query in frontend Create card to display user status
Create mutation to block the user Use blockUser exposed in the user package (instantiated insider the user provider) Create auditLog for the customer blocking Create new audit action block-user Example of audit log
Create block customer permission Permission: “RBI.supportActions.customer.block” Add “RBI.supportActions.customer.*” to rolePermissionMapping in agent role for BK,PLK,TH and FHS
Implement block user in front end Create confirmation modal Check if agent has permission to change customer status TBD: which permission is needed
Trigger block mutation on confirmation
Create mutation to unblock the user Use unblockUser exposed in the user package (instantiated insider the user provider) Create auditLog for the customer unblocking Create new audit action unblock-user Example of audit log
Check if the agent has permission to unblock Permission: “RBI.supportActions.customer.block”
Implement unblock user in front end Create confirmation modal Check if agent has permission to change customer status TBD: which permission is needed
Trigger unblock mutation on confirmation
|
Changes in intl-whitelable-app
Expand |
---|
|
Create blocked account modal Handle UserBlockedError in signIn Option 1 Create onError handler for signIn mutations If UserBlockedError: sign out user display blocked account modal
Add onError parameter to the following signIn mutations signInWithOtp signInWithJwt signInSocialLogin
Option 2 Monitor error value of all the mutations listed above with useEffect If UserBlockedError: sign out user display blocked account modal
Validate if user is blocked before proceeding to cart use getMe query to check user status if isBlocked sign out user display blocked account modal
|
Solution 2 - Disable user in cognito