Age Verification
Detect faces in a photo and estimate whether each belongs to a minor or an adult. Returns an estimated age, age range, and a clear verdict.
POST
/age/detectAuthentication
Bearer token in the Authorization header.
Request
Content-Type:
multipart/form-data| Field | Type | Required | Description |
|---|---|---|---|
| file | File | Required | Image file containing a face. Accepts PNG, JPEG, and WebP. |
Response
| Field | Type | Description |
|---|---|---|
| estimated_age | number | Estimated age in years (e.g. 24.5). |
| is_minor | boolean | Whether the estimated age is under 18. |
| age_range | string | Age bracket, e.g. "20-29", "10-19", "0-2". |
| verdict | string | Human-readable verdict: "likely_minor", "possibly_minor", "likely_adult", or "adult". |
Example
Request
curl -X POST https://api.cacuda.com/age/detect \ -H "Authorization: Bearer YOUR_API_KEY" \ -F "file=@portrait.jpg"
Response 200 OK
{
"estimated_age": 24.5,
"is_minor": false,
"age_range": "20-29",
"verdict": "likely_adult"
}Error Codes
| Code | Description |
|---|---|
| 400 | No file provided, unsupported format, or no face detected. |
| 401 | Missing or invalid API key. |
| 402 | Insufficient credits. |
| 503 | Age verification service unavailable. |
Notes
The service automatically detects and crops the most prominent face in the image.
If no face is detected, a 400 error is returned.
Try it in the scanner
Test this endpoint interactively with real data. No code required.
Open Scanner