QES integration guide

Start using QES Verification and seamlessly onboard customers in Europe with a single solution.

This article provides a complete guide on how to integrate QES Verification into your verification flows.

Step 1: Set up implementation

Check prerequisites

Before you start, make sure that QES Verification is enabled for your account. To enable it or to get a Sandbox or Trial key for QES Verification, contact your Customer Success Manager.

Important

If you opt out of the QES Data Retention service, which covers the processing and retention of the personal data required to issue the Qualified Signature, you will need a separate client key for QES Verification.

Configure API and SDK

To get started with Qualified Electronic Signature (QES) Verification:

  1. Generate an app token to start using the Sumsub API.
  2. Set up webhooks to get verification results. To manage QES verification results, you will need to configure and use the applicantReviewed webhook.
  3. Get started with the SDK implementation, as described in the web SDK integration article and the mobile SDK integration article.
📘

Note

To view and manage your available and active QES Verification products, refer to this article.

Step 2: Select your setup

Agree on the following options with your Customer Success Manager. Sumsub pre-configures your QES levels accordingly.

Note

If needed, you can also request optional checks or features, such as AML Screening, Address verification, or the QES Validation Report.

Choose the signing flow

QES Verification supports two signature flows:

  • Single-level flow — the applicant signs the documents in the same session, before the identity verification is approved.
  • Two-level flow — the applicant signs the documents only after the identity verification is approved.

For more information about the flows, see How QES Verification works.

Single-level flow (Pre-verification)

For the Single-level flow, Sumsub sets up one QES Verification level with the following steps:

  1. Identity document in the Seamless live capture mode
  2. Selfie
  3. One of the following, depending on the selected option:
    1. Phone verification and Email verification
    2. Applicant data with the Email and Phone fields
    3. None, if you provide the verified phone number and email address via API
  4. (Optional) Non-Doc with Penny Drop Verification
  5. E-Sign

Use this level to create applicants, generate SDK access tokens, and upload documents for signing.

Two-level flow (Post-verification)

For the Two-level flow, Sumsub sets up the following:

  1. The first level with the following steps:
    1. Identity document in the Seamless live capture mode
    2. Selfie
    3. One of the following, depending on the selected option:
      1. Phone verification and Email verification
      2. Applicant data with the Email and Phone fields
      3. None, if you provide the verified phone number and email address via API
    4. (Optional) Non-Doc with Penny Drop Verification
  2. The second level with the same steps and the E-Sign step. Applicants do not need to complete the identification steps again.
  3. A workflow that moves applicants from the first level to the second level once they are approved.

Add Penny Drop Verification (Optional)

By default, QES Verification follows the General QES Verification flow. To comply with Germany’s BaFin regulations, you can add Penny Drop Verification to QES Verification. In this case, the Non-Doc step with Penny Drop Verification is added to your QES levels. The integration steps remain the same.

Note

This step is optional. Agree with your Customer Success Manager on whether to add it to your QES Verification flow.

Collect phone number and email

Document signing requires the applicant’s phone number and email data to be collected. Depending on the option agreed with your Customer Success Manager, your QES levels are configured in one of the following ways:

  1. Verification by Sumsub: the levels contain the Phone verification and Email verification steps, and applicants verify their phone number and email with a one-time password. See Email and phone verification.
  2. Collection by Sumsub: the levels contain the Applicant data step, and applicants enter their phone number and email without verification.
  3. Verification on your side: you verify the applicant’s phone number and email during your own registration and pass them to Sumsub when creating an applicant. In this case, the levels do not contain these steps.
curl -X POST \
  'https://api.sumsub.com/resources/applicants?levelName={levelName}' \
  -H 'Content-Type: application/json' \
  -d '{
          "externalUserId": "someUniqueUserId",
          "email": "[email protected]",
          "phone": "+4912389032156"
      }'

Note

These steps are optional. Agree with your Customer Success Manager on whether to add them to your QES Verification flow.

If you verify the applicant’s phone number and email on your side and pass them via the API, you do not need these steps.

Step 3: Upload documents for signing

Upload the documents that applicants will sign with a Qualified Electronic Signature, such as contracts or terms and conditions. You can upload documents and configure the visibility of signatures in two ways:

  • Via Dashboard. With this method, the documents uploaded on the level will be displayed to all applicants for signing.
  • Via API. This method allows you to upload unique documents for each applicant to be signed.

Note

  • The pre-configured E-Sign step may contain a sample document or the documents you provided to your Customer Success Manager. Replace or add documents if needed.
  • Documents uploaded for an applicant via the API override the documents configured on the level.

Upload documents via Dashboard

To upload documents for signing in the Dashboard:

  1. Go to Configurations → Applicant verification → Individual levels and open the level that contains the E-Sign step:
    1. Single-level flow: the QES Verification level.
    2. Two-level flow: the second level, which applicants reach after their identity verification is approved.
  2. In the E-Sign step, click Add document.
  3. In the Enter the document name for applicants field, enter the document name that will be displayed to applicants. If you leave the field empty, the file name is used.
  4. Click Click to upload or drag and drop and upload a PDF file of up to 5 MB.
  5. Choose whether to display the signature on the document:
    1. Hide signature — the document is signed, but the signature is not displayed.
    2. Display signature — the signature is displayed on the document. Click Configure signature and specify the following:
      1. Page — the page on which the signature is displayed.
      2. Location — the X and Y axes of the signature position on the page.
      3. Dimensions — the width and height of the signature.
      4. To display the signature on another page, click Add page and specify the settings for that page. Click Apply to save the settings.
  6. To add more documents, repeat steps 2–5.
  7. Save the level.

Important

Do not change the capture mode or add other document types to the Identity document step.

By default, each signature displayed within the client document(s) will contain the following information:

  • Name of the signer
  • Legal basis for Qualified Signature creation
  • Date of the Qualified Signature creation

Note

The signature location and dimensions are specified in PDF units. For example, the A4 page size of 210mm x 297mm = 595 x 842 PDF units.

Upload documents via API

To upload unique documents for each applicant:

  1. Create an applicant. Use the level where the applicant starts the onboarding:
    1. Single-level flow: the QES Verification level.
    2. Two-level flow: the first level.
curl -X POST \
  'https://api.sumsub.com/resources/applicants?levelName={levelName}' \
  -H 'Content-Type: application/json' \
  -d '{
          "externalUserId": "someUniqueUserId"
      }'
  1. Upload the documents for signing using the Upload document for signing API method. Upload the documents before the applicant reaches the E-Sign step. In the request, provide:
    1. content — the PDF file to be signed.
    2. metadata — the document name (imageFileName) and the signature placement (signatures). For each page with a signature, specify the page number, the x and y axes of the signature position, and its width and height in PDF units.
curl -X POST \
  "https://api.sumsub.com/resources/applicants/{applicantId}/esign/resources/uploadDoc"  \
  -H 'Content-Type: multipart/form-data' \
  -F 'content=@/path/to/your/file.pdf'  \
  -F 'metadata={
        "imageFileName": "Displayed File Name",
        "signatures": [{
          "pages": [
            {
              "page": 1,
              "x": 400,
              "y": 45,
              "width": 150,
              "height": 45
            },
            {
              "page": 2,
              "x": 400,
              "y": 45,
              "width": 150,
              "height": 45
            }
          ]}
        ]}'

Note

If you reset the applicant or the E-Sign step, the documents uploaded via the API are deleted. Upload them again before the applicant reaches the E-Sign step.

Step 4: Launch verification for applicants

Use our WebSDK and MobileSDK frameworks to conduct QES Verification code-free.

Important

QES Verification is supported only in WebSDK 2.0 and MobileSDK 1.43 or higher.

  1. Generate an access token associated with the userId (externalUserId) and levelName. Use the level where the applicant starts the onboarding:
    1. Single-level flow: the QES Verification level.
    2. Two-level flow: the first level. Once the applicant is approved, the workflow moves them to the second level automatically.
  2. Launch the SDK and conduct identity verification.
  3. Receive and handle verification results.

Note

  • The applicant can leave the verification while their data is being processed and resume it later. Once the applicant’s status changes, you will receive a webhook that can be used to notify the applicant:
    • Single-level flow: applicantReviewed with the verification result.
    • Two-level flow: applicantLevelChanged when the applicant passes the identity verification and moves to the document signing level, or applicantReviewed when the applicant is rejected.
  • The document signing steps are available in English, French, German, Spanish, Dutch, Italian, and Polish. Other languages are displayed in English within the document signing steps.

Step 5: Listen to webhooks

Once verification is complete, the results are automatically delivered with the applicantReviewed webhook.

This webhook contains the reviewResult object that includes the reviewAnswer field, indicating the verification status. If it is GREEN, it means QES Verification was successfully completed, and you can get QES Verification results. If it is RED, the applicant has not passed verification; the reviewRejectType is set to RETRY or FINAL:

  • FINAL — indicates a final applicant rejection.
  • RETRY — applicants are allowed to resubmit their documents and repeat verification.

Step 6: Get verification results

You can get QES Verification results in either of the following ways:

Get verification results via Dashboard

To view the results of QES Verification in the Dashboard:

  1. Navigate to the Applicants page and open the profile that you need.
  2. Scroll down to the Qualified Electronic Signature section and review the results. The section contains the following information:
    1. Personal Information — the applicant data used to issue the Qualified Signature.
    2. Signed Documents — the signed documents with the signing date. You can download them.
    3. Validation Reports — the QES Validation Reports, if the report is enabled for your account.

Get verification results via API

To retrieve the results via the Sumsub API, use the Get E-Sign method according to the request example provided below.

Request

curl -X GET \
  'https://api.sumsub.com/resources/checks/latest?type=E_SIGN&applicantId={applicantId}'

Response

The response will include detailed personal information that was verified to issue a Qualified Signature and basic details about the signed documents. Depending on the applicant data, inputDoc can also include the issuedDate, countryOfBirth, and additionalNumber fields.

{
  "checks": [
    {
      "answer": "GREEN",
      "checkType": "E_SIGN",
      "createdAt": "2024-11-12 10:28:06",
      "id": "1cdf9711-4d50-4659-b82a-a12c330dc797",
      "inputDoc": {
        "idDocType": "PASSPORT",
        "country": "DEU",
        "firstName": "ERIKA",
        "lastName": "MUSTERMANN",
        "validUntil": "2027-02-28",
        "number": "C01XYCCG9",
        "dob": "1964-08-12",
        "email": "[email protected]",
        "phone": "+4912389032156"
      },
      "esignCheckInfo": {
        "unsignedDocuments": [
          {
            "id": "1672018978",
            "imageId": 1672018978,
            "name": "Terms And Conditions.pdf"
          }
        ],
        "signedDocuments": [
          {
            "id": "1672018978",
            "imageId": 1919960264,  // Use this ID to receive signed document
            "name": "Terms And Conditions.pdf",
            "signedAt": "2024-11-12 10:28:37"
          }
        ]
      }
    }
  ]
}

The complete scope of possible applicant output data as a result of successful verification includes:

  • Signed document(s)
  • First name
  • Date of birth
  • Last name
  • Nationality (if available)
  • Gender (if available)
  • Place of birth
  • Document type
  • Document number
  • Document issue date
  • Document expiration date
  • Phone number
  • Email attributes

Handle QES Verification failures

If the E-Sign step fails, the applicant is rejected with the ESIGN_FAILED label and the RETRY reject type, so they can sign the documents again. You receive the applicantReviewed webhook with the RED review answer.

The rejection reason is returned in the clientComment field of the reviewResult object and identified by the value in the buttonIds field. The answer of the E_SIGN check depends on the reason:

ReasonbuttonIDE_SIGN check answerclientComment
Data mismatcheSignDataMismatchRED, with violationsThe data provided during the flow does not match the data returned after KYC verification.
Signing failedeSignFailedERRORThe verification failed after the document was signed. Applicant will be asked to re-submit the missing details and repeat the document signing.
Invalid level configuration

Signing has not started, so the check is not completed.
eSignInvalidLevelYELLOWCheck that the e-signature level is configured correctly.

Note

  • For the list of violations returned with the RED answer, see Get E-Sign (QES) verification results.
  • In the clientComment, KYC verification refers to the verification steps of QES Verification, such as identity document, selfie, phone, and email verification. The data used for signing (name, date of birth, document dates and country, and email) is compared with the data verified in these steps.

Step 7: Receive signed documents

After receiving the QES Verification results, you can obtain the signed documents in either of the following ways:

  • Via Dashboard: download them in the Qualified Electronic Signature section of the applicant profile.
  • Via API: retrieve them as described below.

To retrieve the signed documents via the Sumsub API:

  1. In the verification results you received via the API, find the signedDocuments array. It includes the following information about each signed document:
    1. id — unique identifier of the signed document in the Sumsub system.
    2. imageId — unique identifier that is used to obtain the signed document.
    3. name — document title that was specified during the document upload.
    4. signedAt — date and time when the document was signed.
  2. Submit the imageId of each signed document to the Get signed document API method.

The response will contain binary content representing the signed document. The Content-Type response header precisely describes the response mime-type:

HTTP/1.1 200 OK
Date: Wed, 13 Nov 2024 10:44:38 GMT
Content-Type: application/pdf
Content-Length: 239371
Connection: keep-alive
x-correlation-id: 85e3033ee12d196b8400322e03e47b36
Content-Encoding: identity
content-disposition: attachment; filename=Terms+And+Conditions.pdf

<Binary content representing the signed document>

Test in Sandbox

Before going live, test QES Verification in the Sandbox environment. To get a Sandbox key for QES Verification, contact your Customer Success Manager.

We recommend creating a duplicate level for testing in the Sandbox environment. This ensures that the Production version of the level and its configuration are not affected.

Note

  • Make sure that the Seamless live capture mode is still enabled in the Identity document step on your test level.
  • The automated end-to-end flow cannot be completed via API only in the Sandbox environment. Go through all the steps manually in WebSDK or MobileSDK.

To test QES Verification:

  1. Switch to the Sandbox environment and run your test level.
  2. In the Identity document step, capture any physical test document or card.
  3. Complete the Liveness check in the Selfie step.
  4. Provide the phone number and email address in the SDK, or via API when creating the applicant.

Note

If your test flow includes the Phone verification and Email verification steps, use the test OTP code 111111 to pass them in the Sandbox environment.

  1. Complete document signing. To confirm the signing, enter the 11110123 test OTP.

Did this page help you?