---
title: Healthcare - Progressive Verification during Authentication - Verify Email - Subflow
description: Learn about the Healthcare - Progressive Verification during Authentication - Verify Email - Subflow flow, including its purpose, structure, inputs, outputs, and variables.
component: pingone-solutions
page_id: pingone-solutions:healthcare:flow-reference/healthcare-authentication-verify-email-subflow
canonical_url: https://docs.pingidentity.com/pingone-solutions/healthcare/flow-reference/healthcare-authentication-verify-email-subflow.html
revdate: January 1, 2025
section_ids:
  purpose: Purpose
  structure: Structure
  input-schema: Input schema
  output-schema: Output schema
  variables: Variables
---

# Healthcare - Progressive Verification during Authentication - Verify Email - Subflow

The Healthcare - Progressive Verification during Authentication - Verify Email - Subflow lets a user verify their email address using a one-time passcode (OTP) *(tooltip: \<div class="paragraph">
\<p>A passcode valid for only one sign-on or transaction on a computer system or other digital device. Also known as a one-time password, one-time PIN, or dynamic password.\</p>
\</div>)* sent by the PingOne Single Sign-on connector.

## Purpose

The **Healthcare - Progressive Verification during Authentication - Verify Email - Subflow** sends a verification code, then displays an HTML page giving users the option to enter a verification code sent to their email or resend the code. If the user enters the code, a PingOne node verifies the code. If the user requests that the code be resent, a PingOne node resends the code, then the user is returned to the beginning of the flow.

## Structure

This flow is divided into sections using teleport nodes:

* **Prompt for OTP**

  Uses a flow instance variable to track the number of verification attempts. Uses a PingOne node to send a verification code, then presents the user with an HTML page on which they can enter the verification code or request that the code be resent. If the user submits a verification code, the flow progresses to the **Validate OTP** section. If the user requests a new code, the flow progresses to the **Resend verification code** section.

* **Validate OTP**

  Increments the number of validation attempts. If the number of attempts has not reached the maximum, a PingOne node validates the verification code. If the validation succeeds, a JSON success message is sent. If the validation fails, an error message is displayed.

* **Resend OTP**

  Increments the number of resend attempts. If the number of attempts has not reached the maximum, a PingOne node sends a new verification code and a confirmation message indicates that the new verification code has been resent.

* **Return Error**

  Sends a JSON error message.

## Input schema

This flow has the following inputs:

| Input name          | Required | Description                                                                   |
| ------------------- | -------- | ----------------------------------------------------------------------------- |
| `p1UserID`          | Yes      | The user ID of the current user.                                              |
| `companyLogo`       | No       | The company logo.Used only when the main flow was launched using a redirect.  |
| `verificationLimit` | Yes      | The maximum number of times a user can attempt to verify their email.         |
| `resendOtpLimit`    | Yes      | The maximum number of times a user can attempt to resend a verification code. |

## Output schema

This flow has the following outputs.

| Output name     | Description                                          |
| --------------- | ---------------------------------------------------- |
| `errorMessage`  | The error message to display in the parent flow.     |
| `errorDetails`  | The details of the error that occurred in this flow. |
| `subflowResult` | The result status of the flow.                       |

## Variables

This flow uses the following variables.

| Variable name                    | Description                                                    |
| -------------------------------- | -------------------------------------------------------------- |
| `resendOtpAttempts`              | The number of times the user has resent an OTP.                |
| `verificationValidationAttempts` | The number of times the user has attempted email verification. |
