amazonka-rekognition-1.6.0: Amazon Rekognition SDK.

Copyright(c) 2013-2018 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.Rekognition.GetContentModeration

Contents

Description

Gets the content moderation analysis results for a Rekognition Video analysis started by .

Content moderation analysis of a video is an asynchronous operation. You start analysis by calling . which returns a job identifier (JobId ). When analysis finishes, Rekognition Video publishes a completion status to the Amazon Simple Notification Service topic registered in the initial call to StartContentModeration . To get the results of the content moderation analysis, first check that the status value published to the Amazon SNS topic is SUCCEEDED . If so, call GetCelebrityDetection and pass the job identifier (JobId ) from the initial call to StartCelebrityDetection . For more information, see video .

GetContentModeration returns detected content moderation labels, and the time they are detected, in an array, ModerationLabels , of objects.

By default, the moderated labels are returned sorted by time, in milliseconds from the start of the video. You can also sort them by moderated label by specifying NAME for the SortBy input parameter.

Since video analysis can return a large number of results, use the MaxResults parameter to limit the number of labels returned in a single call to GetContentModeration . 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 GetContentModeration and populate the NextToken request parameter with the value of NextToken returned from the previous call to GetContentModeration .

For more information, see moderation .

Synopsis

Creating a Request

getContentModeration Source #

Creates a value of GetContentModeration with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • gcmNextToken - If the previous response was incomplete (because there is more data to retrieve), Amazon Rekognition returns a pagination token in the response. You can use this pagination token to retrieve the next set of content moderation labels.
  • gcmMaxResults - 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.
  • gcmSortBy - Sort to use for elements in the ModerationLabelDetections array. Use TIMESTAMP to sort array elements by the time labels are detected. Use NAME to alphabetically group elements for a label together. Within each label group, the array element are sorted by detection confidence. The default sort is by TIMESTAMP .
  • gcmJobId - The identifier for the content moderation job. Use JobId to identify the job in a subsequent call to GetContentModeration .

data GetContentModeration Source #

See: getContentModeration smart constructor.

Instances

Eq GetContentModeration Source # 
Data GetContentModeration Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GetContentModeration -> c GetContentModeration #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GetContentModeration #

toConstr :: GetContentModeration -> Constr #

dataTypeOf :: GetContentModeration -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c GetContentModeration) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GetContentModeration) #

gmapT :: (forall b. Data b => b -> b) -> GetContentModeration -> GetContentModeration #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GetContentModeration -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GetContentModeration -> r #

gmapQ :: (forall d. Data d => d -> u) -> GetContentModeration -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GetContentModeration -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GetContentModeration -> m GetContentModeration #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GetContentModeration -> m GetContentModeration #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GetContentModeration -> m GetContentModeration #

Read GetContentModeration Source # 
Show GetContentModeration Source # 
Generic GetContentModeration Source # 
Hashable GetContentModeration Source # 
ToJSON GetContentModeration Source # 
NFData GetContentModeration Source # 

Methods

rnf :: GetContentModeration -> () #

AWSRequest GetContentModeration Source # 
ToHeaders GetContentModeration Source # 
ToPath GetContentModeration Source # 
ToQuery GetContentModeration Source # 
type Rep GetContentModeration Source # 
type Rep GetContentModeration = D1 * (MetaData "GetContentModeration" "Network.AWS.Rekognition.GetContentModeration" "amazonka-rekognition-1.6.0-3jgXZy5HWud2mYhTRx5OTT" False) (C1 * (MetaCons "GetContentModeration'" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmNextToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))) (S1 * (MetaSel (Just Symbol "_gcmMaxResults") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Nat)))) ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmSortBy") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe ContentModerationSortBy))) (S1 * (MetaSel (Just Symbol "_gcmJobId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)))))
type Rs GetContentModeration Source # 

Request Lenses

gcmNextToken :: Lens' GetContentModeration (Maybe Text) Source #

If the previous response was incomplete (because there is more data to retrieve), Amazon Rekognition returns a pagination token in the response. You can use this pagination token to retrieve the next set of content moderation labels.

gcmMaxResults :: Lens' GetContentModeration (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.

gcmSortBy :: Lens' GetContentModeration (Maybe ContentModerationSortBy) Source #

Sort to use for elements in the ModerationLabelDetections array. Use TIMESTAMP to sort array elements by the time labels are detected. Use NAME to alphabetically group elements for a label together. Within each label group, the array element are sorted by detection confidence. The default sort is by TIMESTAMP .

gcmJobId :: Lens' GetContentModeration Text Source #

The identifier for the content moderation job. Use JobId to identify the job in a subsequent call to GetContentModeration .

Destructuring the Response

getContentModerationResponse Source #

Creates a value of GetContentModerationResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • gcmrsNextToken - If the response is truncated, Rekognition Video returns this token that you can use in the subsequent request to retrieve the next set of moderation labels.
  • gcmrsVideoMetadata - Information about a video that Amazon Rekognition analyzed. Videometadata is returned in every page of paginated responses from GetContentModeration .
  • gcmrsStatusMessage - If the job fails, StatusMessage provides a descriptive error message.
  • gcmrsJobStatus - The current status of the content moderation job.
  • gcmrsModerationLabels - The detected moderation labels and the time(s) they were detected.
  • gcmrsResponseStatus - -- | The response status code.

data GetContentModerationResponse Source #

See: getContentModerationResponse smart constructor.

Instances

Eq GetContentModerationResponse Source # 
Data GetContentModerationResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> GetContentModerationResponse -> c GetContentModerationResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c GetContentModerationResponse #

toConstr :: GetContentModerationResponse -> Constr #

dataTypeOf :: GetContentModerationResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c GetContentModerationResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c GetContentModerationResponse) #

gmapT :: (forall b. Data b => b -> b) -> GetContentModerationResponse -> GetContentModerationResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> GetContentModerationResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> GetContentModerationResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> GetContentModerationResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> GetContentModerationResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> GetContentModerationResponse -> m GetContentModerationResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> GetContentModerationResponse -> m GetContentModerationResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> GetContentModerationResponse -> m GetContentModerationResponse #

Read GetContentModerationResponse Source # 
Show GetContentModerationResponse Source # 
Generic GetContentModerationResponse Source # 
NFData GetContentModerationResponse Source # 
type Rep GetContentModerationResponse Source # 
type Rep GetContentModerationResponse = D1 * (MetaData "GetContentModerationResponse" "Network.AWS.Rekognition.GetContentModeration" "amazonka-rekognition-1.6.0-3jgXZy5HWud2mYhTRx5OTT" False) (C1 * (MetaCons "GetContentModerationResponse'" PrefixI True) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmrsNextToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmrsVideoMetadata") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe VideoMetadata))) (S1 * (MetaSel (Just Symbol "_gcmrsStatusMessage") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))))) ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmrsJobStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe VideoJobStatus))) ((:*:) * (S1 * (MetaSel (Just Symbol "_gcmrsModerationLabels") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe [ContentModerationDetection]))) (S1 * (MetaSel (Just Symbol "_gcmrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Int))))))

Response Lenses

gcmrsNextToken :: Lens' GetContentModerationResponse (Maybe Text) Source #

If the response is truncated, Rekognition Video returns this token that you can use in the subsequent request to retrieve the next set of moderation labels.

gcmrsVideoMetadata :: Lens' GetContentModerationResponse (Maybe VideoMetadata) Source #

Information about a video that Amazon Rekognition analyzed. Videometadata is returned in every page of paginated responses from GetContentModeration .

gcmrsStatusMessage :: Lens' GetContentModerationResponse (Maybe Text) Source #

If the job fails, StatusMessage provides a descriptive error message.

gcmrsJobStatus :: Lens' GetContentModerationResponse (Maybe VideoJobStatus) Source #

The current status of the content moderation job.

gcmrsModerationLabels :: Lens' GetContentModerationResponse [ContentModerationDetection] Source #

The detected moderation labels and the time(s) they were detected.