> For the complete documentation index, see [llms.txt](https://docs.facephi.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services.md).

# Biometric Services

Middleware API v2 facial biometrics services: a liveness check on a selfie, comparison of two faces, and verification that combines both checks in a single call.

All accept assets inline or by reference, except for detokenization, which operates on a token rather than an asset. The reference-based flow is described in [Common Flow](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/flujo-comun.md).

#### Available Services

* [**Face Liveness**](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services/face-liveness.md): Performs a liveness check on the user's selfie.
* [**Facial Matching**](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services/facial-matching.md): Compares two faces and returns the result with its confidence score.
* [**Face Verification**](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services/face-verification.md): Checks that the IAD capture is not an injection attack and compares the extracted face with the one in the document.
* [**Selfie Verification**](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services/selfie-verification.md): Performs a liveness check on the selfie and compares it with the face in the document.
* [**Detokenize Image**](https://docs.facephi.com/docs.facephi-en/rest-api/midapi-v2/biometric-services/detokenize-image.md): Returns the unwrapped image corresponding to a best-image token.
