> For the complete documentation index, see [llms.txt](https://simprints.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://simprints.gitbook.io/docs/development/simprints-for-developers/other-intergrations/commcare-integration/commcare-enrolment.md).

# CommCare: Enrolment

During enrolment, a beneficiary’s fingerprints will be registered and linked to their record on CommCare.

You can customise your Simprints enrolment integration to:

* Link a beneficiary's biometrics record to a particular user ID or module ID.
* Check that a frontline worker has completed a Simprints session before moving forward in their workflow
* Collect and store data on why a beneficiary declined Simprints

To customise your Simprints integration, follow the steps below.

### Customise Simprints enrolment <a href="#h.p_lnhnqdxy-1yq_l" id="h.p_lnhnqdxy-1yq_l"></a>

Before customising Simprints, you should have already completed the [Quick Start](/docs/development/simprints-for-developers/other-intergrations/commcare-integration.md) integration. Follow the instructions below to customise your enrolment form.

**Step 1:** Click "Enroll new person"

You should see "Scan Fingerprints" in the list of questions.

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FwFv6hMLCM0G8dZ2wkd2V%2FScreen%20Shot%202021-01-14%20at%206.09.32%20PM.png?alt=media&amp;token=4f85c1dc-7c46-4861-bb74-31542f07921b" alt=""><figcaption></figcaption></figure>

**Step 2:** Create a question list group by: +Add Question > Groups > Question List

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FDs0BzUuaR5tAHGlI7s3h%2FEmbeddedImage%20(4).png?alt=media&amp;token=8e7cb7c3-26e9-42c6-a2cf-2a65e9555186" alt=""><figcaption></figcaption></figure>

Name this question list the following:

* Display text: Capture fingerprints
* Question ID: simprintsData

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FMisFHCgeLBlMedwjqkze%2FScreen%20Shot%202021-01-14%20at%206.07.13%20PM.png?alt=media&amp;token=1163c1a7-6fac-4487-94a8-dac89a782a11" alt=""><figcaption></figcaption></figure>

**Step 3:** Add the "Scan Fingerprints" question and the hidden values (simprintsId, rightIndex, rightThumb, leftIndex, leftThumb) as sub-questions of the newly created "Capture Fingerprints" Question List. You do this by highlighting them and dragging underneath Capture Fingerprints. You can then delete rightIndex, rightThumb, leftIndex, leftThumb hidden values. They are not needed.

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2Fi37HQVTlyUmoqa8PvGBH%2Fcapture.png?alt=media&amp;token=56d0e78d-d7db-428c-9bb9-fad88c45e13d" alt=""><figcaption></figcaption></figure>

**Step 4:** Update the "External App" field within the "Scan Fingerprints" question:

* Click Custom in the dropdown list
* Update the value to: **com.simprints.commcare.REGISTER**

**Uncheck the Required button too!**

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FPcyO50yHWDdLKCMX1485%2Fscan%20fingerprints.png?alt=media&amp;token=eb6aa3d0-e038-423c-b379-f8a728065a35" alt=""><figcaption></figcaption></figure>

To customise the user ID and module ID linked to a beneficiary's biometrics record, follow the following steps. To find out more about what user ID and module ID is, click [here](/docs/development/simprints-for-developers.md)

**Step 5:** Update the "Extra" field within the "Scan Fingerprints" question as highlighted

* Link userId to the user logged into your CommCare application: **instance('commcaresession')/session/context/userid**
* Link moduleId to the module related question earlier in the form: **/data/REFQUESTION\***

\*REFQUESTION should be the question id related to the appropriate question

These steps will enable each beneficiary's biometrics record to be associated with a user ID and module ID.

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FpACqAowdkfAS3NniseYc%2Fextra.png?alt=media&amp;token=ff74f2c9-f4ed-4f9d-ae7d-c09d31aceca0" alt=""><figcaption></figcaption></figure>

**Step 6**: Update the "Response" field within the "Scan Fingerprints" question:

* the value for guid to: **/data/simprintsData/simprintsId**

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FfBZWWG1I2dlPTBNiUgZ8%2Fguid.png?alt=media&amp;token=112f4b7c-b044-4234-b4d6-f1705ee2b3e1" alt=""><figcaption></figcaption></figure>

In your CommCare form, you can check if a user has completed a Simprints session. A completed Simprints session could either be a successful enrolment or a beneficiary declining Simprints. Find out more about Biometrics Complete Check [here](/docs/development/simprints-for-developers/integrating-with-simprints/confidence-score-bands.md).

If a frontline worker has not completed a Simprints session, you may add logic in your form to prevent them from continuing with their workflow.

To enable this check in your CommCare form, follow the steps below:

**Step 7:** Add the following keys and values under the "Response" field in the "Scan Fingerprints" question as highlighted:

* To check whether a user has completed a Simprints session, in your form add - Key: **biometricsComplete;** Value: **/data/simprintsData/biometricsComplete**

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FJjb4XgJKK0DrqNADrd78%2Fbiometrics.png?alt=media&amp;token=5c8476ff-5602-4912-b86c-0d113e98be26" alt=""><figcaption></figcaption></figure>

**Step 8:** Save the changes made to the "Scan Fingerprints" question

**Step 9:** Click +Add Question to add a Hidden Value question under the "Capture Fingerprints" question list:

* Fill out the Question ID field with **biometricsComplete**

**Step 10:** Save the changes made to the "biometricsComplete" Hidden Value question

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FFxLTFJdZClC7WCJ2saLa%2Fhidden%20value.png?alt=media&amp;token=300a552e-f617-41f0-8cb9-4ddb7189efe0" alt=""><figcaption></figcaption></figure>

**Step 11:** Click +Add Question to add a label under the "Capture Fingerprints" question list:

* Fill out the Display Text with **Please click the 'Get Fingerprints' button**

**Step 12:** Include the following logic (by clicking on the 3 horizontal lines in top right corner):

* Display Condition: **/data/simprintsData/biometricsComplete != 'true'**
* Validation Condition: **1=2**
* Validation Message: **Please click the 'Get Fingerprints' button**

**Step 13:** Save the changes made

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2Fr9L2O1edFxTCo1zyJVLO%2Fbiometricscomplete.png?alt=media&amp;token=9eb409c0-9a38-46fd-907a-bbacb03ad441" alt=""><figcaption></figcaption></figure>

In your CommCare form, you can record reasons why a user left the Simprints application form without collecting a beneficiary's biometrics. To enable this check in your CommCare form, follow the steps below:

**Step 14:** Click the "Scan Fingerprints" question

**Step 15:** Add the following keys and values under the Response field in the "Scan Fingerprints" question as highlighted:

* To collect reasons for a user exiting Simprints without collecting a beneficiary's biometrics, in your form add - Key: **exitReason;** Value: **/data/simprintsData/exitReason**
* To collect additional information for why a user left the Simprints app, in your form add Key: **exitExtra;** Value: **/data/simprintsData/exitExtra**

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FhsPTTxbjbs7LcEFJiQF1%2Fexit.png?alt=media&amp;token=28128860-07c0-45ad-b097-2eed6a30b335" alt=""><figcaption></figcaption></figure>

**Step 16:** Click +Add Question to add a Hidden Value question:

* Fill out the Question ID field with **exitReason**

**Step 17:** Save the changes made to the "exitReason" Hidden Value question

**Step 18:** Click +Add Question to add a Hidden Value question:

* Fill out the Question ID field with **exitExtra**

**Step 19:** Save the changes made to the "exitExtra" Hidden Value question

**Step 20:** Click the ⚙️ on the "Enroll New Person" form.

**Step 21:** Under "Save Questions to Case Properties", update the Case Property simprintsId to reference the correct question

* This should be the question referencing the hidden value for simprintsId

<figure><img src="https://2829653571-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fe3eCeQ95EVZnUB1IR9zM%2Fuploads%2FA4wZnQwDKPZRRRLAeRre%2FEmbeddedImage%20(5).png?alt=media&amp;token=82ef2029-114e-4069-8ed3-c204af237c57" alt=""><figcaption></figcaption></figure>

Congratulations! You have now customised your CommCare Simprints integration in your registration form.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://simprints.gitbook.io/docs/development/simprints-for-developers/other-intergrations/commcare-integration/commcare-enrolment.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
