on 2023 Mar 27 2:40 PM
Hi,
We have a requirement to make an account.resetpassword API on reset password UI builder page. So can some one help how to make an API call in Javascript it would be helpful if get a sample code.
Thanks,
Help others by sharing your knowledge.
AnswerRequest clarification before answering.
maheswariiii
You can make an API call using the JavaScript Fetch API. Here is an example of how to call a resetpassword API using the Fetch API:
// Make a POST request to the resetpassword API
fetch('https://example.com/resetpassword', {
method: 'POST',
body: JSON.stringify({
username: 'exampleUsername'
}),
headers: {
'Content-type': 'application/json; charset=UTF-8'
}
})
.then(response => response.json())
.then(json => {
// This is where you can handle the response from the API
console.log(json);
});
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
do you have API endpoint ? or sample endpoint ?
User | Count |
---|---|
21 | |
16 | |
3 | |
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.