v1

latestSwagger 2.02026-07-1760185352.5 KB
frontend

Create Recovery Flow for Browsers

This endpoint initializes a browser-based account recovery flow. Once initialized, the browser will be redirected to selfservice.flows.recovery.ui_url with the flow ID set as the query parameter ?flow=. If a valid user session exists, the browser is returned to the configured return URL.

If this endpoint is called via an AJAX request, the response contains the recovery flow without any redirects or a 400 bad request error if the user is already authenticated.

This endpoint is NOT INTENDED for clients that do not have a browser (Chrome, Firefox, ...) as cookies are needed.

More information can be found at Ory Kratos Account Recovery Documentation.

get/self-service/recovery/browser

Query parameters

return_tostring

The URL to return the browser to after the flow was completed.

skip_settingsstring

Skip redirection to the settings UI after the recovery flow was completed. Instead, the user will be redirected to the URL specified in return_to query parameter or the default return URL if return_to is not set.

Response

recoveryFlow

activestring

Active, if set, contains the recovery method that is being used. It is initially not set.

continue_withContinueWith[]

Contains possible actions that could follow this flow

expires_atstring date-time required

ExpiresAt is the time (UTC) when the request expires. If the user still wishes to update the setting, a new request has to be initiated.

idstring uuid required

ID represents the request's unique ID. When performing the recovery flow, this represents the id in the recovery ui's query parameter: http://<selfservice.flows.recovery.ui_url>?request=<id>

issued_atstring date-time required

IssuedAt is the time (UTC) when the request occurred.

request_urlstring required

RequestURL is the initial URL that was requested from Ory Kratos. It can be used to forward information contained in the URL's path or query for example.

return_tostring

ReturnTo contains the requested return_to URL.

{"stackTrail":"components:schemas:recoveryFlow:properties:state","oasType":"schema","type":"unknown","description":"State represents the state of this request:\n\nchoose_method: ask the user to choose a method (e.g. recover account via email)\nsent_email: the email has been sent to the user\npassed_challenge: the request was successful and the recovery challenge was passed."}
transient_payloadobject

TransientPayload is used to pass data from the recovery flow to hooks and email templates

typestring required

The flow type can either be api or browser.