An identity input specialised for CRVS (Civil Registration and Vital Statistics) lookups, validating against the configured CRVS endpoint.
Read Form Rules before using this component — keys, labels, required fields, expressions, visibility, and validation all follow shared conventions.
Instead of customcrvsidinput, use… |
For… |
|---|---|
customidinput |
General-purpose NID / passport / refugee ID lookup |
customdoubleidinput |
Paired identity lookup (e.g. husband + wife in one record) |
customapplicationnumberinput |
Looking up an existing application by its application number |
The full prop surface mirrors customidinput (label, required, defaultRequired, url, endpointCode, useBaseUrl, populates, hideField) with the addition of CRVS-specific configuration. Verify exact prop names against the running UI library before shipping.
| Prop | Type | Required? | Description |
|---|---|---|---|
label |
string |
required | Visible label. |
required |
boolean |
required | Always false. The expression controls the runtime value. |
defaultRequired |
boolean |
required | true for required fields, false for optional ones. |
endpointCode |
string |
required | Integration endpoint code for the CRVS lookup. |
url |
string |
required | Integration endpoint path — typically /integration/v1/fetch/sync. |
useBaseUrl |
boolean |
optional | Prepend the API gateway base URL to url. Set true for production. |
populates |
array |
optional | { valueKey, targetKey } mappings to auto-fill downstream fields from the response. |
hideField |
boolean |
optional | Hides the field and excludes its value from submission. Toggle via expressions["props.hideField"]. |
{
"key": "BIRTH_CERTIFICATE",
"type": "customcrvsidinput",
"props": {
"label": "Birth Certificate Number",
"required": false,
"defaultRequired": true,
"url": "/integration/v1/fetch/sync",
"useBaseUrl": true,
"endpointCode": "FGETBIRTHRECORD"
},
"expressions": {
"props.required": "!(field?.props?.hideField || field?.hide) && field?.props?.defaultRequired"
},
"validation": {
"messages": {
"required": "Birth certificate number is required.",
"invalidId": "We could not verify this certificate. Please check the number and try again."
}
}
}
{
"key": "BIRTH_CERTIFICATE",
"type": "customcrvsidinput",
"props": {
"label": "Birth Certificate Number",
"required": false,
"defaultRequired": true,
"url": "/integration/v1/fetch/sync",
"useBaseUrl": true,
"endpointCode": "FGETBIRTHRECORD",
"populates": [
{ "valueKey": "firstName", "targetKey": "CHILD_FIRST_NAME" },
{ "valueKey": "surname", "targetKey": "CHILD_LAST_NAME" },
{ "valueKey": "dateOfBirth", "targetKey": "CHILD_DOB" },
{ "valueKey": "placeOfBirth", "targetKey": "CHILD_PLACE_OF_BIRTH" }
]
},
"expressions": {
"props.required": "!(field?.props?.hideField || field?.hide) && field?.props?.defaultRequired"
},
"validation": {
"messages": {
"required": "Birth certificate number is required.",
"invalidId": "We could not verify this certificate. Please check the number and try again."
}
}
}
The CRVS widget emits the generic identity error keys. See Cross-field Validators and the identity-validator section for the exhaustive list. The common ones:
required — field is emptyinvalidId — lookup API failed or returned no matchrequired: true directly — use the required: false + defaultRequired: true + expression pattern from Form Rules.endpointCode — the component cannot resolve a lookup endpoint and the fetch fails silently.useBaseUrl: true in production — the request is sent to a relative path with no host and fails.populates at fields that don't exist in the form — the response data is dropped.customidinput for general identity verification.key is UPPER_SNAKE_CASE and unique across the entire formprops.label is present, unique, and correctly casedsections > formly-group > block > customcrvsidinputrequired: false is set (never true)defaultRequired is set (true or false)expressions["props.required"] is present with the exact required expressionendpointCode matches a known CRVS integration endpointurl and useBaseUrl are configured per environmentpopulates is used, every targetKey corresponds to a declared fieldvalidation.messages.required and validation.messages.invalidId are both present