Get Verification Flow
GET {{baseUrl}}/self-service/verification/flows?id=<string>
This endpoint returns a verification flow's context with, for example, error details and other information.
Browser flows expect the anti-CSRF cookie to be included in the request's HTTP Cookie Header. For AJAX requests you must ensure that cookies are included in the request or requests will fail.
If you use the browser-flow for server-side apps, the services need to run on a common top-level-domain and you need to forward the incoming HTTP Cookie header to this endpoint:
pseudo-code example
router.get('/recovery', async function (req, res) {
const flow = await client.getVerificationFlow(req.header('cookie'), req.query['flow'])
res.render('verification', flow)
})
More information can be found at Ory Kratos Email and Phone Verification Documentation.
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
id | string | (Required) The Flow ID |
The value for this parameter comes from request
URL Query parameter sent to your
application (e.g. /verification?flow=abcde
). |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
cookie | string | HTTP Cookies |
When using the SDK on the server side you must include the HTTP Cookie Header
originally sent to your HTTP handler here. |
| Accept
| string | | |
RESPONSES
status: OK
{"id":"\u003cuuid\u003e","type":"\u003cstring\u003e","ui":{"action":"\u003cstring\u003e","method":"\u003cstring\u003e","nodes":[{"type":"a","group":"passkey","attributes":{"name":"\u003cstring\u003e","type":"url","disabled":"\u003cboolean\u003e","node_type":"input","autocomplete":"email","label":{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"success","context":{}},"onclick":"\u003cstring\u003e","onload":"\u003cstring\u003e","pattern":"\u003cstring\u003e","required":"\u003cboolean\u003e","value":{"description":"The input's value.","nullable":true}},"messages":[{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"error","context":{}},{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"info","context":{}}],"meta":{"label":{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"info","context":{}}}},{"type":"input","group":"totp","attributes":{"name":"\u003cstring\u003e","type":"hidden","disabled":"\u003cboolean\u003e","node_type":"a","autocomplete":"email","label":{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"error","context":{}},"onclick":"\u003cstring\u003e","onload":"\u003cstring\u003e","pattern":"\u003cstring\u003e","required":"\u003cboolean\u003e","value":{"description":"The input's value.","nullable":true}},"messages":[{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"error","context":{}},{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"error","context":{}}],"meta":{"label":{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"info","context":{}}}}],"messages":[{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"success","context":{}},{"id":"\u003clong\u003e","text":"\u003cstring\u003e","type":"success","context":{}}]},"state":{"description":"State represents the state of this request:\n\nchoose_method: ask the user to choose a method (e.g. verify your email)\nsent_email: the email has been sent to the user\npassed_challenge: the request was successful and the verification challenge was passed."},"active":"\u003cstring\u003e","expires_at":"\u003cdateTime\u003e","issued_at":"\u003cdateTime\u003e","request_url":"\u003cstring\u003e","return_to":"\u003cstring\u003e","transient_payload":{}}