/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include namespace Aws { namespace Rekognition { namespace Model { /** */ class IndexFacesRequest : public RekognitionRequest { public: AWS_REKOGNITION_API IndexFacesRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "IndexFaces"; } AWS_REKOGNITION_API Aws::String SerializePayload() const override; AWS_REKOGNITION_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline const Aws::String& GetCollectionId() const{ return m_collectionId; } /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline bool CollectionIdHasBeenSet() const { return m_collectionIdHasBeenSet; } /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline void SetCollectionId(const Aws::String& value) { m_collectionIdHasBeenSet = true; m_collectionId = value; } /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline void SetCollectionId(Aws::String&& value) { m_collectionIdHasBeenSet = true; m_collectionId = std::move(value); } /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline void SetCollectionId(const char* value) { m_collectionIdHasBeenSet = true; m_collectionId.assign(value); } /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline IndexFacesRequest& WithCollectionId(const Aws::String& value) { SetCollectionId(value); return *this;} /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline IndexFacesRequest& WithCollectionId(Aws::String&& value) { SetCollectionId(std::move(value)); return *this;} /** *

The ID of an existing collection to which you want to add the faces that are * detected in the input images.

*/ inline IndexFacesRequest& WithCollectionId(const char* value) { SetCollectionId(value); return *this;} /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline const Image& GetImage() const{ return m_image; } /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline bool ImageHasBeenSet() const { return m_imageHasBeenSet; } /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline void SetImage(const Image& value) { m_imageHasBeenSet = true; m_image = value; } /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline void SetImage(Image&& value) { m_imageHasBeenSet = true; m_image = std::move(value); } /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline IndexFacesRequest& WithImage(const Image& value) { SetImage(value); return *this;} /** *

The input image as base64-encoded bytes or an S3 object. If you use the AWS * CLI to call Amazon Rekognition operations, passing base64-encoded image bytes * isn't supported.

If you are using an AWS SDK to call Amazon Rekognition, * you might not need to base64-encode image bytes passed using the * Bytes field. For more information, see Images in the Amazon * Rekognition developer guide.

*/ inline IndexFacesRequest& WithImage(Image&& value) { SetImage(std::move(value)); return *this;} /** *

The ID you want to assign to all the faces detected in the image.

*/ inline const Aws::String& GetExternalImageId() const{ return m_externalImageId; } /** *

The ID you want to assign to all the faces detected in the image.

*/ inline bool ExternalImageIdHasBeenSet() const { return m_externalImageIdHasBeenSet; } /** *

The ID you want to assign to all the faces detected in the image.

*/ inline void SetExternalImageId(const Aws::String& value) { m_externalImageIdHasBeenSet = true; m_externalImageId = value; } /** *

The ID you want to assign to all the faces detected in the image.

*/ inline void SetExternalImageId(Aws::String&& value) { m_externalImageIdHasBeenSet = true; m_externalImageId = std::move(value); } /** *

The ID you want to assign to all the faces detected in the image.

*/ inline void SetExternalImageId(const char* value) { m_externalImageIdHasBeenSet = true; m_externalImageId.assign(value); } /** *

The ID you want to assign to all the faces detected in the image.

*/ inline IndexFacesRequest& WithExternalImageId(const Aws::String& value) { SetExternalImageId(value); return *this;} /** *

The ID you want to assign to all the faces detected in the image.

*/ inline IndexFacesRequest& WithExternalImageId(Aws::String&& value) { SetExternalImageId(std::move(value)); return *this;} /** *

The ID you want to assign to all the faces detected in the image.

*/ inline IndexFacesRequest& WithExternalImageId(const char* value) { SetExternalImageId(value); return *this;} /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline const Aws::Vector& GetDetectionAttributes() const{ return m_detectionAttributes; } /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline bool DetectionAttributesHasBeenSet() const { return m_detectionAttributesHasBeenSet; } /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline void SetDetectionAttributes(const Aws::Vector& value) { m_detectionAttributesHasBeenSet = true; m_detectionAttributes = value; } /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline void SetDetectionAttributes(Aws::Vector&& value) { m_detectionAttributesHasBeenSet = true; m_detectionAttributes = std::move(value); } /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline IndexFacesRequest& WithDetectionAttributes(const Aws::Vector& value) { SetDetectionAttributes(value); return *this;} /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline IndexFacesRequest& WithDetectionAttributes(Aws::Vector&& value) { SetDetectionAttributes(std::move(value)); return *this;} /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline IndexFacesRequest& AddDetectionAttributes(const Attribute& value) { m_detectionAttributesHasBeenSet = true; m_detectionAttributes.push_back(value); return *this; } /** *

An array of facial attributes you want to be returned. A DEFAULT * subset of facial attributes - BoundingBox, Confidence, * Pose, Quality, and Landmarks - will * always be returned. You can request for specific facial attributes (in addition * to the default list) - by using ["DEFAULT", "FACE_OCCLUDED"] or * just ["FACE_OCCLUDED"]. You can request for all facial attributes * by using ["ALL"]. Requesting more attributes may increase response * time.

If you provide both, ["ALL", "DEFAULT"], the service * uses a logical AND operator to determine which attributes to return (in this * case, all attributes).

*/ inline IndexFacesRequest& AddDetectionAttributes(Attribute&& value) { m_detectionAttributesHasBeenSet = true; m_detectionAttributes.push_back(std::move(value)); return *this; } /** *

The maximum number of faces to index. The value of MaxFaces must * be greater than or equal to 1. IndexFaces returns no more than 100 * detected faces in an image, even if you specify a larger value for * MaxFaces.

If IndexFaces detects more faces than * the value of MaxFaces, the faces with the lowest quality are * filtered out first. If there are still more faces than the value of * MaxFaces, the faces with the smallest bounding boxes are filtered * out (up to the number that's needed to satisfy the value of * MaxFaces). Information about the unindexed faces is available in * the UnindexedFaces array.

The faces that are returned by * IndexFaces are sorted by the largest face bounding box size to the * smallest size, in descending order.

MaxFaces can be used * with a collection associated with any version of the face model.

*/ inline int GetMaxFaces() const{ return m_maxFaces; } /** *

The maximum number of faces to index. The value of MaxFaces must * be greater than or equal to 1. IndexFaces returns no more than 100 * detected faces in an image, even if you specify a larger value for * MaxFaces.

If IndexFaces detects more faces than * the value of MaxFaces, the faces with the lowest quality are * filtered out first. If there are still more faces than the value of * MaxFaces, the faces with the smallest bounding boxes are filtered * out (up to the number that's needed to satisfy the value of * MaxFaces). Information about the unindexed faces is available in * the UnindexedFaces array.

The faces that are returned by * IndexFaces are sorted by the largest face bounding box size to the * smallest size, in descending order.

MaxFaces can be used * with a collection associated with any version of the face model.

*/ inline bool MaxFacesHasBeenSet() const { return m_maxFacesHasBeenSet; } /** *

The maximum number of faces to index. The value of MaxFaces must * be greater than or equal to 1. IndexFaces returns no more than 100 * detected faces in an image, even if you specify a larger value for * MaxFaces.

If IndexFaces detects more faces than * the value of MaxFaces, the faces with the lowest quality are * filtered out first. If there are still more faces than the value of * MaxFaces, the faces with the smallest bounding boxes are filtered * out (up to the number that's needed to satisfy the value of * MaxFaces). Information about the unindexed faces is available in * the UnindexedFaces array.

The faces that are returned by * IndexFaces are sorted by the largest face bounding box size to the * smallest size, in descending order.

MaxFaces can be used * with a collection associated with any version of the face model.

*/ inline void SetMaxFaces(int value) { m_maxFacesHasBeenSet = true; m_maxFaces = value; } /** *

The maximum number of faces to index. The value of MaxFaces must * be greater than or equal to 1. IndexFaces returns no more than 100 * detected faces in an image, even if you specify a larger value for * MaxFaces.

If IndexFaces detects more faces than * the value of MaxFaces, the faces with the lowest quality are * filtered out first. If there are still more faces than the value of * MaxFaces, the faces with the smallest bounding boxes are filtered * out (up to the number that's needed to satisfy the value of * MaxFaces). Information about the unindexed faces is available in * the UnindexedFaces array.

The faces that are returned by * IndexFaces are sorted by the largest face bounding box size to the * smallest size, in descending order.

MaxFaces can be used * with a collection associated with any version of the face model.

*/ inline IndexFacesRequest& WithMaxFaces(int value) { SetMaxFaces(value); return *this;} /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline const QualityFilter& GetQualityFilter() const{ return m_qualityFilter; } /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline bool QualityFilterHasBeenSet() const { return m_qualityFilterHasBeenSet; } /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline void SetQualityFilter(const QualityFilter& value) { m_qualityFilterHasBeenSet = true; m_qualityFilter = value; } /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline void SetQualityFilter(QualityFilter&& value) { m_qualityFilterHasBeenSet = true; m_qualityFilter = std::move(value); } /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline IndexFacesRequest& WithQualityFilter(const QualityFilter& value) { SetQualityFilter(value); return *this;} /** *

A filter that specifies a quality bar for how much filtering is done to * identify faces. Filtered faces aren't indexed. If you specify AUTO, * Amazon Rekognition chooses the quality bar. If you specify LOW, * MEDIUM, or HIGH, filtering removes all faces that * don’t meet the chosen quality bar. The default value is AUTO. The * quality bar is based on a variety of common use cases. Low-quality detections * can occur for a number of reasons. Some examples are an object that's * misidentified as a face, a face that's too blurry, or a face with a pose that's * too extreme to use. If you specify NONE, no filtering is performed. *

To use quality filtering, the collection you are using must be * associated with version 3 of the face model or higher.

*/ inline IndexFacesRequest& WithQualityFilter(QualityFilter&& value) { SetQualityFilter(std::move(value)); return *this;} private: Aws::String m_collectionId; bool m_collectionIdHasBeenSet = false; Image m_image; bool m_imageHasBeenSet = false; Aws::String m_externalImageId; bool m_externalImageIdHasBeenSet = false; Aws::Vector m_detectionAttributes; bool m_detectionAttributesHasBeenSet = false; int m_maxFaces; bool m_maxFacesHasBeenSet = false; QualityFilter m_qualityFilter; bool m_qualityFilterHasBeenSet = false; }; } // namespace Model } // namespace Rekognition } // namespace Aws