v1

latestOpenAPI 3.0.0Apache 2.0 License2026-07-1465453454.1 KB

For a given input face ID, searches for matching faces in the collection the face belongs to. You get a face ID when you add a face to the collection using the IndexFaces operation. The operation compares the features of the input face with faces in the specified collection.

You can also search faces without indexing faces by using the SearchFacesByImage operation.

The operation response returns an array of faces that match, ordered by similarity score with the highest similarity first. More specifically, it is an array of metadata for each face match that is found. Along with the metadata, the response also includes a confidence value for each face match, indicating the confidence that the specific face matches the input face.

For an example, see Searching for a face using its face ID in the Amazon Rekognition Developer Guide.

This operation requires permissions to perform the rekognition:SearchFaces action.

post/#X-Amz-Target=RekognitionService.SearchFaces

Headers

X-Amz-Target'RekognitionService.SearchFaces' required

Request body

CollectionIdstring required

ID of the collection the face belongs to.

FaceIdstring required

ID of a face to find matches for in the collection.

MaxFacesinteger

Maximum number of faces to return. The operation returns the maximum number of faces with the highest confidence in the match.

FaceMatchThresholdnumber float

Optional value specifying the minimum confidence in the face match to return. For example, don't return any matches where confidence in matches is less than 70%. The default value is 80%.

Response

Success

SearchedFaceIdstring

ID of the face that was searched for matches in a collection.

FaceModelVersionstring

Version number of the face detection model associated with the input collection (<code>CollectionId</code>).

Example response

{
  "FaceMatches": [
    {
      "Face": {
        "BoundingBox": {
          "Height": 0.3259260058403015,
          "Left": 0.5144439935684204,
          "Top": 0.15111100673675537,
          "Width": 0.24444399774074554
        },
        "Confidence": 99.99949645996094,
        "FaceId": "8be04dba-4e58-520d-850e-9eae4af70eb2",
        "ImageId": "465f4e93-763e-51d0-b030-b9667a2d94b1"
      },
      "Similarity": 99.97222137451172
    },
    {
      "Face": {
        "BoundingBox": {
          "Height": 0.16555599868297577,
          "Left": 0.30963000655174255,
          "Top": 0.7066670060157776,
          "Width": 0.22074100375175476
        },
        "Confidence": 100,
        "FaceId": "29a75abe-397b-5101-ba4f-706783b2246c",
        "ImageId": "147fdf82-7a71-52cf-819b-e786c7b9746e"
      },
      "Similarity": 97.04154968261719
    },
    {
      "Face": {
        "BoundingBox": {
          "Height": 0.18888899683952332,
          "Left": 0.3783380091190338,
          "Top": 0.2355560064315796,
          "Width": 0.25222599506378174
        },
        "Confidence": 99.9999008178711,
        "FaceId": "908544ad-edc3-59df-8faf-6a87cc256cf5",
        "ImageId": "3c731605-d772-541a-a5e7-0375dbc68a07"
      },
      "Similarity": 95.94520568847656
    }
  ],
  "SearchedFaceId": "70008e50-75e4-55d0-8e80-363fb73b3a14"
}