Skip to content

Latest commit

 

History

History
40 lines (26 loc) · 704 Bytes

recovery.md

File metadata and controls

40 lines (26 loc) · 704 Bytes

# Account recovery


## Initialize Recovery Flow

Get a recovery flow ID to start the process:

final result = await client.getRecoveryFlow();

Send Recovery Email

Initiate email-based recovery:

final result = await client.sendEmailRecoveryFlow(flowId: result.flowId, email: userEmail,);

Submit Recovery Code

Send recovery code using flowId from previous step:

final result = await client.sendCodeRecoveryFlow(
  flowId: flowId, 
  code: code
);

Update Password

Finally, submit the new password using flowID from Submit Recovery Code step:

final result = await client.updatePassword(flowId: flowId, newPassword: newPassword,);

``