Copyright | (c) 2013-2018 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Gets face detection results for a Rekognition Video analysis started by .
Face detection with Rekognition Video is an asynchronous operation. You start face detection by calling which returns a job identifier (JobId
). When the face detection operation finishes, Rekognition Video publishes a completion status to the Amazon Simple Notification Service topic registered in the initial call to StartFaceDetection
. To get the results of the face detection operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED
. If so, call and pass the job identifier (JobId
) from the initial call to StartFaceDetection
.
GetFaceDetection
returns an array of detected faces (Faces
) sorted by the time the faces were detected.
Use MaxResults parameter to limit the number of labels returned. If there are more results than specified in MaxResults
, the value of NextToken
in the operation response contains a pagination token for getting the next set of results. To get the next page of results, call GetFaceDetection
and populate the NextToken
request parameter with the token value returned from the previous call to GetFaceDetection
.
Synopsis
- getFaceDetection :: Text -> GetFaceDetection
- data GetFaceDetection
- gfdNextToken :: Lens' GetFaceDetection (Maybe Text)
- gfdMaxResults :: Lens' GetFaceDetection (Maybe Natural)
- gfdJobId :: Lens' GetFaceDetection Text
- getFaceDetectionResponse :: Int -> GetFaceDetectionResponse
- data GetFaceDetectionResponse
- gfdrsNextToken :: Lens' GetFaceDetectionResponse (Maybe Text)
- gfdrsVideoMetadata :: Lens' GetFaceDetectionResponse (Maybe VideoMetadata)
- gfdrsStatusMessage :: Lens' GetFaceDetectionResponse (Maybe Text)
- gfdrsFaces :: Lens' GetFaceDetectionResponse [FaceDetection]
- gfdrsJobStatus :: Lens' GetFaceDetectionResponse (Maybe VideoJobStatus)
- gfdrsResponseStatus :: Lens' GetFaceDetectionResponse Int
Creating a Request
Creates a value of GetFaceDetection
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
gfdNextToken
- If the previous response was incomplete (because there are more faces to retrieve), Rekognition Video returns a pagination token in the response. You can use this pagination token to retrieve the next set of faces.gfdMaxResults
- Maximum number of results to return per paginated call. The largest value you can specify is 1000. If you specify a value greater than 1000, a maximum of 1000 results is returned. The default value is 1000.gfdJobId
- Unique identifier for the face detection job. TheJobId
is returned fromStartFaceDetection
.
data GetFaceDetection Source #
See: getFaceDetection
smart constructor.
Instances
Request Lenses
gfdNextToken :: Lens' GetFaceDetection (Maybe Text) Source #
If the previous response was incomplete (because there are more faces to retrieve), Rekognition Video returns a pagination token in the response. You can use this pagination token to retrieve the next set of faces.
gfdMaxResults :: Lens' GetFaceDetection (Maybe Natural) Source #
Maximum number of results to return per paginated call. The largest value you can specify is 1000. If you specify a value greater than 1000, a maximum of 1000 results is returned. The default value is 1000.
gfdJobId :: Lens' GetFaceDetection Text Source #
Unique identifier for the face detection job. The JobId
is returned from StartFaceDetection
.
Destructuring the Response
getFaceDetectionResponse Source #
Creates a value of GetFaceDetectionResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
gfdrsNextToken
- If the response is truncated, Amazon Rekognition returns this token that you can use in the subsequent request to retrieve the next set of faces.gfdrsVideoMetadata
- Information about a video that Rekognition Video analyzed.Videometadata
is returned in every page of paginated responses from a Amazon Rekognition video operation.gfdrsStatusMessage
- If the job fails,StatusMessage
provides a descriptive error message.gfdrsFaces
- An array of faces detected in the video. Each element contains a detected face's details and the time, in milliseconds from the start of the video, the face was detected.gfdrsJobStatus
- The current status of the face detection job.gfdrsResponseStatus
- -- | The response status code.
data GetFaceDetectionResponse Source #
See: getFaceDetectionResponse
smart constructor.
Instances
Response Lenses
gfdrsNextToken :: Lens' GetFaceDetectionResponse (Maybe Text) Source #
If the response is truncated, Amazon Rekognition returns this token that you can use in the subsequent request to retrieve the next set of faces.
gfdrsVideoMetadata :: Lens' GetFaceDetectionResponse (Maybe VideoMetadata) Source #
Information about a video that Rekognition Video analyzed. Videometadata
is returned in every page of paginated responses from a Amazon Rekognition video operation.
gfdrsStatusMessage :: Lens' GetFaceDetectionResponse (Maybe Text) Source #
If the job fails, StatusMessage
provides a descriptive error message.
gfdrsFaces :: Lens' GetFaceDetectionResponse [FaceDetection] Source #
An array of faces detected in the video. Each element contains a detected face's details and the time, in milliseconds from the start of the video, the face was detected.
gfdrsJobStatus :: Lens' GetFaceDetectionResponse (Maybe VideoJobStatus) Source #
The current status of the face detection job.
gfdrsResponseStatus :: Lens' GetFaceDetectionResponse Int Source #
- - | The response status code.