Mask a card
Content type multipart/form-data
Masks the Aadhaar and VID numbers on one card. Send exactly one file — a second file is refused with a 400. The call is synchronous: you get back the finished run, already charged, with the masked image in mask_applied_image. A card the service can't read comes back as a 400 and is not charged.
Request
curl -X POST "https://studioapi.kriyam.ai/models/mask/aadhaar/v1" \ -H "X-API-Key: $KRIYAM_API_KEY" \ -F "file=@aadhaar.jpg" \ -F "cached=False"
Response
Authentication
Send your key in the X-API-Key header. See Authentication.
Request
Body
| Name | Type | Required | Description |
|---|---|---|---|
file | file | Required | The Aadhaar card: a PNG or JPEG image, or a PDF (only its first page is masked). Exactly one file. |
cached | boolean | Optional | Return the result of an identical file checked by you or your team in the last 30 days by the same version, free, instead of running again. The response then has Default |
Response
200 OK
Returns the run envelope. The fields below are what this tool puts inside it.
| Field | Type | Description |
|---|---|---|
cached | boolean | True when this is the free copy of an identical file checked by you or your team in the last 30 days (you sent |
request_id | string | This request's id. Quote it if you contact support about a result. |
pipeline | string | The version of this endpoint that answered. Always |
mask_applied_image | string | The masked image as base64-encoded PNG — this is what you came for. |
Errors
Every keyed call can also get401402403404429— see Errors.
