v0alpha1

Initialize Verification Flow for APIs, Services, Apps, ...

This endpoint initiates a verification flow for API clients such as mobile devices, smart TVs, and so on.

To fetch an existing verification flow call /self-service/verification/flows?flow=<flow_id>.

You MUST NOT use this endpoint in client-side (Single Page Apps, ReactJS, AngularJS) nor server-side (Java Server Pages, NodeJS, PHP, Golang, ...) browser applications. Using this endpoint in these applications will make you vulnerable to a variety of CSRF attacks.

This endpoint MUST ONLY be used in scenarios such as native mobile apps (React Native, Objective C, Swift, Java, ...).

More information can be found at Ory Kratos Email and Phone Verification Documentation.

get/self-service/verification/api

Response

selfServiceVerificationFlow

activestring

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

expires_atstring date-time

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

idstring uuid4 required
issued_atstring date-time

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

request_urlstring

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.

state'choose_method' | 'sent_email' | 'passed_challenge' required

The state represents the state of the verification flow.

choose_method: ask the user to choose a method (e.g. recover account via email) sent_email: the email has been sent to the user passed_challenge: the request was successful and the recovery challenge was passed.

typestring required

The flow type can either be api or browser.

Example response

{
  "expires_at": "2000-01-23T04:56:07.000+00:00",
  "ui": {
    "nodes": [
      {
        "meta": {
          "label": {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          }
        },
        "messages": [
          {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          },
          {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          }
        ],
        "type": "type",
        "group": "group"
      },
      {
        "meta": {
          "label": {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          }
        },
        "messages": [
          {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          },
          {
            "context": "{}",
            "id": 0,
            "text": "text",
            "type": "type"
          }
        ],
        "type": "type",
        "group": "group"
      }
    ],
    "method": "method",
    "action": "action",
    "messages": [
      {
        "context": "{}",
        "id": 0,
        "text": "text",
        "type": "type"
      },
      {
        "context": "{}",
        "id": 0,
        "text": "text",
        "type": "type"
      }
    ]
  },
  "active": "active",
  "id": "id",
  "type": "type",
  "issued_at": "2000-01-23T04:56:07.000+00:00",
  "request_url": "request_url"
}

Changes