Auth0 Home Blog Docs

requestChangePasswordEmail returns empty response in case of success and error, I can no differentiate these cases

authClient.requestChangePasswordEmail({
email,
connection: .connection,
})

this sends reset email to the appropriate email but I get empty response {}, in case of error too, And does it return an error when I tru to send email which does not exist ??? and in which case it returns an error ?

Hi @radik.harutyunyan,

Welcome to the Auth0 Community Forum!

I am not sure what library you are referring to by just seeing the code, but I would assume this method utilizes the dbconnections/change-password endpoint:

This endpoint will give a successful response to any email, regardless of whether or not the email exists in your user database. This is a security mechanism that prevents a third party from being able to test emails against the endpoint and receive confirmation that an email exists in your DB.

The endpoint will give errors on other requests that are not formatted or have incorrect connections or client ids.

If you are experiencing something else, that may be abnormal. Please provide more information if this is the case.

Hope this helps!

Thanks,
Dan

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.