> You are reading the Docusign Developer Documentation. For clean Markdown of any page, append .md to the page URL.
>
> Documentation indexes by section:
> - APIs and SDKs: https://docusign.docs.buildwithfern.com/docs/llms.txt
> - Platform 101: https://docusign.docs.buildwithfern.com/platform/llms.txt
> - Extension Apps: https://docusign.docs.buildwithfern.com/extension-apps/llms.txt
> - Docusign CLI: https://docusign.docs.buildwithfern.com/docusign-cli/llms.txt
>
> Authentication (OAuth, JWT Grant, M2M): https://docusign.docs.buildwithfern.com/platform/auth
> Webhooks and Connect: https://docusign.docs.buildwithfern.com/platform/webhooks
>
> OpenAPI specifications: https://docusign.docs.buildwithfern.com/openapi.json
> MCP server: https://docusign.docs.buildwithfern.com/_mcp/server

# Data verification extension envelope test

> Learn how to test a data verification extension in an envelope.

This procedure explains how to set up and execute a [functional test](/extension-apps/build-an-extension-app/test/functional-tests) that invokes a data verification extension from an eSignature [envelope](/docs/esign-rest-api/esign101/concepts/envelopes). Although the example screens are for a bank account verification extension, this procedure can be used with any data verification [extension](/extension-apps/extension-apps-101/supported-extensions).

This test checks the functioning of *connected fields*, which are envelope fields that can be verified by data verification or connected field extensions defined in your account. To set up the test, you add connected fields to an [eSignature template](https://support.docusign.com/s/document-item?bundleId=xry1643227563338\&topicId=dqj1578456412286.html\&rsc_301), generate an envelope from the template, and access the envelope via an emailed link. While viewing the envelope, you supply values in the connected fields to confirm that your extension is successfully invoked.

> **Note**
>
> Instead of creating a template, you can add connected fields directly to an envelope. This test procedure specifies adding them to a template so that you can save and reuse it instead of adding connected fields to an envelope every time you want to test. Docusign also supports programmatically creating envelopes that include connected fields. See [Connected fields concepts](/docs/connected-fields-api/concepts) for details.

The high-level steps to create and run this test are:

* [Step 1. Add connected fields to a template](/extension-apps/build-an-extension-app/test/functional-tests/data-verification-envelope#step-1-add-connected-fields-to-a-template)
* [Step 2. Generate and send an envelope](/extension-apps/build-an-extension-app/test/functional-tests/data-verification-envelope#step-2-generate-and-send-an-envelope)
* [Step 3. Access the envelope and supply data to verify](/extension-apps/build-an-extension-app/test/functional-tests/data-verification-envelope#step-3-access-the-envelope-and-supply-data-to-verify)

> **Warning**
>
> Make sure that you’ve completed all the requirements listed for functional tests in [Test prerequisites](/extension-apps/build-an-extension-app/test#test-prerequisites).

**Walkthrough playlist** You can also see video overviews of the data verification extension envelope test using the [Data Verification Reference Implementation](https://github.com/docusign/extension-app-data-verification-reference-implementation) below:

## Step 1. Add connected fields to a template

To add connected fields to a template:

1. Log in to the [eSignature web application](https://account-d.docusign.com/) and select **Templates** from the top navigation.
2. Do one of the following:

   * Follow the procedure in [To edit a template](https://support.docusign.com/s/document-item?bundleId=xry1643227563338\&topicId=uvw1578456369720.html)﻿ if you want to add connected fields to an existing template.
   * Follow the procedure in [To create a template](https://support.docusign.com/s/document-item?bundleId=xry1643227563338\&topicId=lsg1578456368117.html) to create a new template for the test.
3. While creating or editing the template, select **Next** to display the [Add Fields view](https://support.docusign.com/s/document-item?bundleId=ulp1643236876813\&topicId=odn1578456409392.html).
4. In the left navigation, select the **Custom Fields** icon.

   ![Custom fields icon](/_fern-files/_img/eee08d503577430b491ac05787f6e883608c5a0cb74eff22cd419503ffbaaf15.webp)
5. Expand the **Verification** list to display a list of data verification extensions. See [Supported extensions](/extension-apps/extension-apps-101/supported-extensions) for a complete list.

   ![List of data verification fields](/_fern-files/_img/96b043c9794062d535e3b09f79b5a7e930949ed58de5d0b883657b105ca7fc78.webp)
6. Expand the extension you want to test. You'll see a list of connected fields that will appear in the envelope. For example, bank account verification requires an account number, account type, and routing number. These fields correspond to the required request properties for the extension's action contract.

   > **Note**
   >
   > You can access the action and capability contracts for each [extension](/extension-apps/extension-apps-101/supported-extensions) from the [Extension contracts](/extension-apps/extension-app-reference/extension-contracts) page.

   ![Bank account verification field list](/_fern-files/_img/41eb727a21765531823d5702dc49f92d87da5329d2688e0728eab02902d78065.webp)

   > **Warning**
   >
   > If the fields are not enabled, then no extension app with this extension is installed to your account. See [Run a connection test](/extension-apps/build-an-extension-app/test/integration-tests#run-a-connection-test) for instructions to install an extension app to your account.
7. Drag the connected field group to the document. You can then move the fields individually to position them as appropriate.

   ![Bank account verification fields on document](/_fern-files/_img/8de38ac1107f89abef98fa9e6745518bbd126b51af42668c8cb48fbe279c5994.webp)
8. In the properties list on the right, expand **Data Verification**.
9. Confirm that the correct value appears in the **Extension App** field. This is the **App name** you selected when you registered the extension app via the [form-based process](/extension-apps/build-an-extension-app/register/use-form), or the value from the [name](/extension-apps/extension-app-reference/app-manifest-reference) property in the app manifest if you registered the extension app by [uploading an app manifest file](/extension-apps/build-an-extension-app/register/use-manifest).
10. Select **Must verify to sign** if you want to require successful verification of the data supplied in the envelope in order to complete the signing process. If you leave this option unchecked, data verification will still occur.

    You are not required to add a **Signature** field or any other fields to the template in order to test a data verification extension.
11. Select **Save and Close** to save the template.

> **Note**
>
> Once you've saved the template, you can generate an envelope from it whenever you want to test your extension. For example, if you update your back-end API service code to fix an issue, you can test the fix by generating a new envelope. In the current release, if you [update the extension app registration](/extension-apps/build-an-extension-app/update-registration), you'll need to create a new template or envelope to test with. In a future release, registration changes will automatically be propagated to existing templates.

## Step 2. Generate and send an envelope

Follow the procedure in [Use a Template to Create an Envelope](https://support.docusign.com/s/document-item?bundleId=xry1643227563338\&topicId=nxv1578456289719.html)﻿ to generate an envelope and email a link to view the envelope. When completing this procedure, supply an address where you can receive email.

## Step 3. Access the envelope and supply data to verify

When you receive the email:

1. Open it and select **Review Document**.
2. Select **Continue** to display the envelope.
3. Enter values in all the connected fields. Each field has a tooltip that lists the type of value expected in the field.

   ![Bank account verification signing view](/_fern-files/_img/75ed4c2c3a544303fae4856dbcdcfccf0ceff8d8a5dbf38696b8388975fbf970.webp)
4. When all connected field values have been supplied, Docusign invokes your extension to verify them. A **Verifying data** message is displayed, followed by a message to indicate whether verification succeeded or failed. You should confirm that:

   * Supplying valid values results in successful verification.
   * Supplying invalid values results in failed verification.
   * For a postal address verification extension, supplying an address that results in a partial match returns a list of suggested addresses.
5. Changing any of the values causes the data verification operation to be triggered again.

> **Warning**
>
> If your extension is not invoked successfully, run the Developer Console [connection and extension tests](/extension-apps/build-an-extension-app/test/integration-tests) for the extension app to get detailed error messages and troubleshoot.

## Next steps

* Find out more about [functional tests](/extension-apps/build-an-extension-app/test/functional-tests).
* Learn how to run [integration tests](/extension-apps/build-an-extension-app/test/integration-tests).
* See how to use the [App Center preview](/extension-apps/build-an-extension-app/test/app-center-preview).