Skip to main content

Check Image Reference

checkImageReference tells you whether a face image you previously enrolled under a caller-supplied photoReferenceId is already in the system. It is the safe-retry companion to faceEnroll: check before re-sending so a retried enrollment doesn't duplicate a face.

API Endpoint​

  • HTTP Method: GET
  • Endpoint: /api/v1/faces/checkImageReference/{referenceId}
  • Base URL (Cloud): https://customername.econnectcloud.com/identities
  • Base URL (On-prem): https://<server-host-or-ip>:5009

Authentication​

Requires a JWT bearer token in the Authorization header. See Authentication.

Minimum Permission​

The permission name and category below are what you'll see in the Identities web app under System → System settings → Roles.

PermissionCategory
Face DetectionFacial Recognition Services

Path Parameters​

ParameterTypeDescription
referenceIdstringThe photoReferenceId you passed to faceEnroll.

Code Examples​

Bash
API_URL="https://customername.econnectcloud.com/identities"
TOKEN="your_jwt" # from POST /api/v1/authenticate

# Check whether a photoReferenceId has already been enrolled.
# referenceId is the same value you passed as photoReferenceId to faceEnroll.
curl -sk -X GET "$API_URL/api/v1/faces/checkImageReference/ext-123" \
-H "Authorization: Bearer $TOKEN" | jq

# Typical retry flow: if exists=false, call faceEnroll with that photoReferenceId;
# if exists=true, the face is already enrolled - skip the enrollment.

Raw Sample​

Request​

HTTP
GET https://customername.econnectcloud.com/identities/api/v1/faces/checkImageReference/ext-123
Authorization: Bearer <your_jwt_token>

Response​

200 OK — an ImageReferenceCheckResult:

JSON
{
"exists": true,
"faceId": "5f9c2b7a-3e41-4d8a-9b6c-1a2b3c4d5e6f",
"detectId": "c1d2e3f4-a5b6-7c8d-9e0f-1a2b3c4d5e6f"
}

When the reference has not been enrolled, exists is false and faceId / detectId are null:

JSON
{ "exists": false, "faceId": null, "detectId": null }

Response Fields​

FieldTypeDescription
existsbooltrue when a face has been enrolled under this referenceId.
faceIdstringThe enrolled face's identifier. null when exists is false.
detectIdstringThe detection identifier for that enrollment. null when exists is false.

Response Codes​

CodeMeaning
200 OKThe check ran; exists reports the result.
401 UnauthorizedMissing or invalid JWT.
403 ForbiddenThe user lacks the Face Detection permission.
500 Internal Server ErrorA server-side error occurred.

Notes​

  • A missing reference is not a 404 — it returns 200 OK with exists: false.
  • Use the same referenceId you supplied as photoReferenceId on faceEnroll.
  • Typical flow: checkImageReference → if exists: false, call faceEnroll with that photoReferenceId; if exists: true, skip the enrollment.