I'm trying to let the user recover their account u...
# general
r
I'm trying to let the user recover their account using a username which isn't an email address, but getting a code by email to the user's recovery address. Is this possible, and if so how? I initially thought that I needed to add the
"recovery":{"via":"email"}
config to each trait with credentials and then any of those could be used to submit/update the flow, and the email with code would go to the user's recovery address. However, looking at the API docs, the body of a POST to self-service/recovery expects to be given the email address of the account to recover. All I can think of at the moment is making a back end call to the Kratos admin API to check for the email address of the account with the given username. Is there a better way?