Reset a forgotten password
POST
/account/reset-password
const url = 'https://acme.mykreezalid.com/front_api/v1/account/reset-password';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"email":"jane@example.com","password":"example","token":"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://acme.mykreezalid.com/front_api/v1/account/reset-password \ --header 'Content-Type: application/json' \ --data '{ "email": "jane@example.com", "password": "example", "token": "example" }'Sets a new password with the token from the reset link emailed by POST /account/forgot-password. A token works once. It only works for a visitor who is not signed in: a request that already carries a valid token or session is refused with 403 and no body schema.
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
email
required
string format: email
Example
jane@example.compassword
required
The new password.
string format: password
token
required
Token from the reset link.
string
Responses
Section titled “Responses”The password is reset.
Media typeapplication/json
object
code
integer
status
string
message
string
Example
{ "code": 200, "status": "success", "message": "Password has successfully been reset"}No account uses this email address.
Media typeapplication/json
object
code
integer
success
boolean
message
string
Example
{ "code": 401, "success": false, "message": "user not found"}Wrong Token Provided when the token is wrong, expired or already used; You cannot access this resource when the new password is refused. Also returned, without this body, when the request already identifies a signed-in member.
Media typeapplication/json
Error body returned by the Front API when it refuses a request.
object
code
HTTP status code, repeated in the body.
integer
status
string
message
Human-readable reason.
string
Example
{ "code": 403, "status": "error", "message": "Token not found in request"}