AadharUID is an all-purpose scanner app1 for the national Indian Aadhar2 health card.
- AadharUID does no scanning itself, but can be used with any popular Android barcode scanner, such as QR Droid or Barcode.
- also spelled Aadhaar
AadharUID does not do much as an app by itself, but rather provides an interface through which other applications can call it. It was built for integration with CommCare, but any Android app can access it through the following callout interface.
Intent intent = new Intent("org.commcarehq.aadharuid.barcode.LAUNCH");
// optional: specify which field you want returned to you
// as `intent.getExtra("odk_intent_data")`.
// default value is "statusText"
intent.putExtra("odk_intent_data_field", "uid");intent.getBundleExtra("odk_intent_bundle")This bundle will contain the following fields:
- Special values:
statusCodeeither"0"(success) or"1"(parse error)statusTexteither"✓"(success) or"✗"(any failure)rawStringthe raw string represented by the QR Code or barcode
- Values straight from the Aadhar barcode
codistdobnormalized to YYYY-MM-DDdobGuessdob if provided or else yob-06-01gendernormalized toMorFhouselmlocnamepcpostatestreetsubdistuidvtcyob
Some Aadhar cards use a 2D barcode. On these cards,
only the uid is encoded; the rest of the values will be "".
intent.getStringExtra("odk_intent_data")This value will be set to whatever field was requested through
the odk_intent_data_field extra. For example, if odk_intent_data_field was set to "uid" in the request intent,
then the odk_intent_data extra will be set to the uid value.
By default it is set to statusText.