I am trying to reset password
from forgot password
action using REST API:
http://domain/index.php/rest/V1/customers/password?
email=myemail@gmail.com&
template=email_reset&
websiteId=1
and I receive an email successfully to set new password as follow:
When click the button Set a New Password, I got this error
Your password reset link has expired
as follow :
when enter my email again in the last screen, I got another email to reset a new password as the first image, then click reset password and I can receive the proper screen and reset password function working fine as follow :
Best Answer
First of all thanks @Shireen your comments help me to debug. I have kind of similar issue and it resolved not in the best way.
@Jsparo30
when you request reset password link via API, Magento creates DirectLink(Link with the query string, has 2 params) which are as follows.
please check this file
/vendor/magento/module-customer/Controller/Account/CreatePassword.php
and when you click the button on reset password email Magento try to access those query string params and get Failed
due to they accessing the wrong param.
I know this is not the solution, but you can at least start with this.