Reset password
POST
/_torii/auth/reset-password
const url = 'https://your-app.torii.so/_torii/auth/reset-password';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"email":"hello@example.com","code":"example","newPassword":"example"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://your-app.torii.so/_torii/auth/reset-password \ --header 'Content-Type: application/json' \ --data '{ "email": "hello@example.com", "code": "example", "newPassword": "example" }'Resets the user’s password using the code received via email.
Parameters
Section titled “ Parameters ”Header Parameters
Section titled “Header Parameters ” Host
string
Request Body required
Section titled “Request Body required ” Media type application/json
Payload for resetting a password with the received code
object
email
required
string format: email
code
required
string
newPassword
required
string
Example generated
{ "email": "hello@example.com", "code": "example", "newPassword": "example"}Responses
Section titled “ Responses ”OK
Media type application/json
object
Example generated
{}