on 2022 Aug 15 8:21 PM
Unable to access response of gigya.accounts.otp.sendCode as it's internally triggered by gigya js plugin
We have integrated gigya js plugin in our application for implementing email verification flow. But after submitting user data 2 api's called.
accounts.register api (can access it's response)
accounts.otp.sendCode (can't access response)
May I know how response of send code can be accessed in front end ?
Request clarification before answering.
Hi Suman,
There are 2 ways you can access the response depends of the way you implement the flow.
1. if gigya screen manage the requests then the way to get the response is to set onAfterSubmit event listener when calling showScreenSet.
gigya.accounts.showScreenSet({
screenSet: "Default-RegistrationLogin",
onAfterSubmit: (event) => {"in the event data you can see the response"}
});
2. if you manage the flow and call manually our api then you can do the following
gigya.accounts.otp.sendCode(callback: (data) => {"in the event data you can see the response"})
Please let us know if this was helpfull.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Shem,
Thanks for looking into it.
But on Click of gigya-register-screen submit, am able to capture the response of accounts.register call alone in afterSubmit event.
but unable to capture the response of gigya.accounts.otp.sendCode.
screen id used: gigya-register-screen
form id used: gigya-register-form
On OTP view page which appears right after registration step.
I want to enter OTP and trigger accounts.otp.update call for which I need to pass vToken of accounts.otp.sendCode call as payload.
So want to know how I can access vToken of accounts.otp.sendCode response.
noticed Gigya plugin is not adding vToken by itself during accounts.otp.update call then how can we pass vToken to accounts.otp.update call ?
User | Count |
---|---|
19 | |
3 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.