Prerequisites
Sequence Diagram
To update the user's email and mobile number in both Haventec Connect and Authenticate, the request must be initiated from the Java SDK.
This sequence diagram describes the interactions between your external service (as Client), IAM and Java SDK, to the update user's email and mobile. The flow from Java SDK to Authenticate is also been showcased in the diagram below for your reference.
Java SDK method to update user's email and mobile number
Please use below method from Java SDK to update user's email and mobile number:
GenericResponse updateUser(String haventecUsername, String email, String mobileNumber, String requestorToken, String requestorUsername) throws HaventecException {}
Method Name | Parameter List | Return |
---|---|---|
updateUser |
String haventecUsername, String email, String mobileNumber, String requestorToken, String requestorUsername |
GenericResponse { ResponseStatus {String status; String message; String code; } } |
Parameter List
-
- haventecUsername : It's a user's Haventec username. e.g. 934bcc1f-e4b9-4d9e-a617-483700816b4d
-
To get the user's haventecUsername. Log in to Haventec IAM, select the digital Realm where users are registered. e.g. Digital Realm and click ' Users ' on the left menu and then click on the user's ' ID ' on the right-side table with the user's list for which the details need to be fetched.
-
Then click on the ' Identity Provider Links ' tab
-
Copy value in the column ' Provider Username '. This can be passed as a haventecUsername in the Java SDK method mentioned above.
- requestorToken : It is the ' access_token ' in the response received after running the curl command in step 3. The user sends a HTTP request to the IAM to log in and get a JWT in Configure Haventec IAM with the client and users.
- requestorUsername : It is the ' username ' passed in the HTTP request in step 3. The user sends a HTTP request to the IAM to log in and get a JWT in Configure Haventec IAM with the client and users.
Java SDK error code
Error Code |
Message Thrown |
Scenarios |
Recommended Action |
LP-REQ-1026 |
Invalid Haventec Username format |
Passed the wrong haventecUsername in the parameter |
Pass the correct haventecUsername in the parameter |
LP-REQ-1026 |
Invalid Haventec Username format |
Passed the wrong requestorUsername in the parameter |
Pass the correct requestorUsername in the parameter |
LP-EMAIL-1002 |
Email is not valid |
Passed the wrong format email id in the parameter |
Pass a valid email id in the parameter |
LP-REQ-1010 |
Invalid mobile number format |
Passed the wrong format mobile number in the parameter |
Pass a valid mobile number in the parameter |
LP-REQ-1039 |
Invalid iamUserJwt format |
Passed the wrong requestorToken in the parameter |
Pass the correct requestorToken as mentioned above. |
AN-OIAM-1001 |
Application does not have IAM properties enabled
|
The application is not configured with proper IAM properties. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure IAM Introspect properties correctly. |
AN-OIAM-1002 |
IAM client_id not configured |
The client_id is not configured properly. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure client_id correctly. |
AN-OIAM-1003 |
IAM client_secret not configured |
The client_secret is not configured properly. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure client_secret correctly. |
AN-OIAM-1004 |
IAM introspect url not configured |
The Introspect url is not configured properly. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure IAM Introspect url correctly. |
AN-OIAM-1005 |
IAM role not configured |
The Allowed role is not configured properly. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure the Allowed role correctly. |
AN-OIAM-1006 |
IAM role path not configured |
The Role JSON path is not configured properly. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure Role JSON path correctly. |
AN-OIAM-1007 |
Role path format |
The Role JSON path format is invalid. |
Please follow this link Configure Haventec Connect Application to enable Introspect IAM API to configure Role JSON path correctly. |
AN-OIAM-1008 |
IAM user denied access |
The externally authenticated user e.g. CRM user is not active. |
Please follow this link Configure Haventec IAM with the client and users step 3. The user sends a HTTP request to the IAM to log in and get a JWT to check if the access_token generated is active or not. If not. Generate a new access_token and use it as requestorToken in the request body. |
LP-USR-1033
|
Invalid Update User By Introspection request
|
The haventecUsername passed does belong to Organisation Admin or haventecUsername does belong to the given application. |
Pass the correct haventecUsername of the user who is not an Organisation Admin and belongs to the given application |
The haventecUsername passed is wrong and there is no user in Authenticate with the given haventecUsername. |
Pass the correct haventecUsername as explained in the above steps. |
Comments
0 comments
Please sign in to leave a comment.