Extract Aadhaar Data with Zapier and Cryvis
Upload Aadhaar (1–2 multipart file parts) to Cryvis, write Google Sheets rows, and handle is_masked PII safely.
Aadhaar shows up as KYC uploads with one or two JPEG/PDF sides. This Zap sends them to Cryvis POST /v1/documents/aadhaar and writes structured fields to Google Sheets — with explicit handling for is_masked and PII hygiene.
Passport twin (two differently named parts): Extract passport data. Multipart reference: Send multipart form data. Hub: Zapier + Cryvis.
Why masking matters
Cryvis returns whatever is printed: full UID or masked (e.g. XXXX XXXX 9012) plus is_masked: true|false. Treat that flag as a control for storage and Slack notifications — not an afterthought.
Architecture
Source
Drive New File OR Forms file upload(s)
|
v
Filter: 1–2 supported images/PDFs
|
v
Webhooks by Zapier: Custom Request
POST https://api.cryvis.com/v1/documents/aadhaar
multipart: file [, file]
Authorization: Bearer <API_KEY>
|
v
Filter: success is true
|
v
Google Sheets: Create Spreadsheet Row
+ is_masked column
+ restricted access on the SheetPrerequisites
- Cryvis API key — Aadhaar API
- Zapier + Google Sheets (and Drive or Forms for intake)
- Sample Aadhaar front (and optionally back) image/PDF
Credits: 1 per PDF page or image — Credits.
Multipart: both parts named file
Cryvis accepts 1–2 files, same part name file. Do not use front / back (those are for Indian vehicle RC) or first_page / last_page (passport).
# One side
part: file = aadhaar-front.jpg
# Front + back
part: file = aadhaar-front.jpg
part: file = aadhaar-back.jpgcURL equivalent:
curl -X POST https://api.cryvis.com/v1/documents/aadhaar \
-H "Authorization: Bearer YOUR_API_KEY" \
-F "file=@aadhaar-front.jpg" \
-F "file=@aadhaar-back.jpg"Create the Zap
- Google Drive — New File or Forms — New Submission with file field(s)
- Filter — MIME / extension
- Webhooks by Zapier — Custom Request
- Filter —
successis true - Google Sheets — Create Spreadsheet Row
- Optional Paths:
is_maskedtrue vs false → different Slack channels or Sheet tabs
Instruct uploaders: front only, back only, or front+back. Cap at two images; ignore extras.
Cryvis HTTP
| Piece | Value |
|---|---|
| Method | POST |
| URL | https://api.cryvis.com/v1/documents/aadhaar |
| Header | Authorization: Bearer <API_KEY> |
| Body | multipart/form-data |
| Parts | one or two parts named file |
Docs: extractAadhaar.
Example response
{
"success": true,
"data": {
"aadhaar_number": "XXXX XXXX 9012",
"full_name": "RAHUL SHARMA",
"date_of_birth": "1992-08-14",
"gender": "Male",
"address": "12 MG Road, Bengaluru, Karnataka 560001",
"pincode": "560001",
"is_masked": true
},
"meta": {}
}| Field | Notes |
|---|---|
aadhaar_number | Full or masked string as printed |
full_name | Printed name |
date_of_birth | May be null on YOB-only cards |
gender | As printed |
address / pincode | Often stronger when back image is included |
is_masked | Boolean — drive storage policy |
Sheets mapping
Prefer a Sheet with restricted sharing (KYC ops only). Headers:
Aadhaar Number | Full Name | DOB | Gender | Address | Pincode | Is Masked | Source File | Processed At
| Column | Source |
|---|---|
| Aadhaar Number | data.aadhaar_number |
| Full Name | data.full_name |
| DOB | data.date_of_birth |
| Gender | data.gender |
| Address | data.address |
| Pincode | data.pincode |
| Is Masked | data.is_masked |
| Source File | Drive/Forms filename |
| Processed At | current timestamp |
Paths (optional):
Path A: is_masked is true
→ write row; Slack “masked UID OK for storage policy”
Path B: is_masked is false
→ write row to a higher-restriction tab; alert complianceYour policy decides whether unmasked UIDs are allowed in Sheets at all. Cryvis does not mask for you — it reports what the document shows.
Errors and testing
| Case | Action |
|---|---|
| 401 | Fix API key |
| 400 / missing file | Part not named file, or zero files |
| Blank address | Back side missing — send second file part |
| Full UID in Sheet against policy | Reject Path B or redact with Formatter before write |
Testing checklist
- One clear front JPEG →
success: true, name populated. - Front + back → address/pincode more complete when printed on back.
- Masked card →
is_masked: true, number looks likeXXXX …. - Wrong part names (
front/back) → failure — rename tofile.
Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
| Missing file | Used passport/RC part names | Both parts must be file |
| Empty Sheets row | Mapped outside data | Use data.full_name, etc. |
| Duplicate rows | Drive re-trigger | Move/archive after success |
| Two credits unexpectedly | Two images | Expected — Credits |
Production notes
- Restrict Sheet access; Aadhaar is sensitive PII.
- Prefer masked documents when your process allows it.
- Do not post full UIDs to public Slack channels — map
is_maskedand name only in notifications. - Archive source files after success; do not leave unmasked scans in a shared Drive inbox.