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

Amazonka.Polly.StartSpeechSynthesisTask

Description

Allows the creation of an asynchronous synthesis task, by starting a new SpeechSynthesisTask. This operation requires all the standard information needed for speech synthesis, plus the name of an Amazon S3 bucket for the service to store the output of the synthesis task and two optional parameters (OutputS3KeyPrefix and SnsTopicArn). Once the synthesis task is created, this operation will return a SpeechSynthesisTask object, which will include an identifier of this task as well as the current status. The SpeechSynthesisTask object is available for 72 hours after starting the asynchronous synthesis task.

Synopsis

Creating a Request

data StartSpeechSynthesisTask Source #

See: newStartSpeechSynthesisTask smart constructor.

Constructors

StartSpeechSynthesisTask' 

Fields

  • languageCode :: Maybe LanguageCode

    Optional language code for the Speech Synthesis request. This is only necessary if using a bilingual voice, such as Aditi, which can be used for either Indian English (en-IN) or Hindi (hi-IN).

    If a bilingual voice is used and no language code is specified, Amazon Polly uses the default language of the bilingual voice. The default language for any voice is the one returned by the DescribeVoices operation for the LanguageCode parameter. For example, if no language code is specified, Aditi will use Indian English rather than Hindi.

  • snsTopicArn :: Maybe Text

    ARN for the SNS topic optionally used for providing status notification for a speech synthesis task.

  • outputS3KeyPrefix :: Maybe Text

    The Amazon S3 key prefix for the output speech file.

  • engine :: Maybe Engine

    Specifies the engine (standard or neural) for Amazon Polly to use when processing input text for speech synthesis. Using a voice that is not supported for the engine selected will result in an error.

  • speechMarkTypes :: Maybe [SpeechMarkType]

    The type of speech marks returned for the input text.

  • sampleRate :: Maybe Text

    The audio frequency specified in Hz.

    The valid values for mp3 and ogg_vorbis are "8000", "16000", "22050", and "24000". The default value for standard voices is "22050". The default value for neural voices is "24000".

    Valid values for pcm are "8000" and "16000" The default value is "16000".

  • textType :: Maybe TextType

    Specifies whether the input text is plain text or SSML. The default value is plain text.

  • lexiconNames :: Maybe [Text]

    List of one or more pronunciation lexicon names you want the service to apply during synthesis. Lexicons are applied only if the language of the lexicon is the same as the language of the voice.

  • outputFormat :: OutputFormat

    The format in which the returned output will be encoded. For audio stream, this will be mp3, ogg_vorbis, or pcm. For speech marks, this will be json.

  • outputS3BucketName :: Text

    Amazon S3 bucket name to which the output file will be saved.

  • text :: Text

    The input text to synthesize. If you specify ssml as the TextType, follow the SSML format for the input text.

  • voiceId :: VoiceId

    Voice ID to use for the synthesis.

Instances

Instances details
Eq StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Read StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Show StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Generic StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Associated Types

type Rep StartSpeechSynthesisTask :: Type -> Type #

NFData StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Hashable StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

ToJSON StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

AWSRequest StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

ToHeaders StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

ToPath StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

ToQuery StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

type Rep StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

type Rep StartSpeechSynthesisTask = D1 ('MetaData "StartSpeechSynthesisTask" "Amazonka.Polly.StartSpeechSynthesisTask" "libZSservicesZSamazonka-pollyZSamazonka-polly" 'False) (C1 ('MetaCons "StartSpeechSynthesisTask'" 'PrefixI 'True) (((S1 ('MetaSel ('Just "languageCode") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe LanguageCode)) :*: (S1 ('MetaSel ('Just "snsTopicArn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "outputS3KeyPrefix") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)))) :*: (S1 ('MetaSel ('Just "engine") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Engine)) :*: (S1 ('MetaSel ('Just "speechMarkTypes") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [SpeechMarkType])) :*: S1 ('MetaSel ('Just "sampleRate") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))))) :*: ((S1 ('MetaSel ('Just "textType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe TextType)) :*: (S1 ('MetaSel ('Just "lexiconNames") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Text])) :*: S1 ('MetaSel ('Just "outputFormat") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 OutputFormat))) :*: (S1 ('MetaSel ('Just "outputS3BucketName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: (S1 ('MetaSel ('Just "text") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "voiceId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 VoiceId))))))
type AWSResponse StartSpeechSynthesisTask Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

newStartSpeechSynthesisTask Source #

Create a value of StartSpeechSynthesisTask with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:languageCode:StartSpeechSynthesisTask', startSpeechSynthesisTask_languageCode - Optional language code for the Speech Synthesis request. This is only necessary if using a bilingual voice, such as Aditi, which can be used for either Indian English (en-IN) or Hindi (hi-IN).

If a bilingual voice is used and no language code is specified, Amazon Polly uses the default language of the bilingual voice. The default language for any voice is the one returned by the DescribeVoices operation for the LanguageCode parameter. For example, if no language code is specified, Aditi will use Indian English rather than Hindi.

$sel:snsTopicArn:StartSpeechSynthesisTask', startSpeechSynthesisTask_snsTopicArn - ARN for the SNS topic optionally used for providing status notification for a speech synthesis task.

$sel:outputS3KeyPrefix:StartSpeechSynthesisTask', startSpeechSynthesisTask_outputS3KeyPrefix - The Amazon S3 key prefix for the output speech file.

$sel:engine:StartSpeechSynthesisTask', startSpeechSynthesisTask_engine - Specifies the engine (standard or neural) for Amazon Polly to use when processing input text for speech synthesis. Using a voice that is not supported for the engine selected will result in an error.

$sel:speechMarkTypes:StartSpeechSynthesisTask', startSpeechSynthesisTask_speechMarkTypes - The type of speech marks returned for the input text.

$sel:sampleRate:StartSpeechSynthesisTask', startSpeechSynthesisTask_sampleRate - The audio frequency specified in Hz.

The valid values for mp3 and ogg_vorbis are "8000", "16000", "22050", and "24000". The default value for standard voices is "22050". The default value for neural voices is "24000".

Valid values for pcm are "8000" and "16000" The default value is "16000".

$sel:textType:StartSpeechSynthesisTask', startSpeechSynthesisTask_textType - Specifies whether the input text is plain text or SSML. The default value is plain text.

$sel:lexiconNames:StartSpeechSynthesisTask', startSpeechSynthesisTask_lexiconNames - List of one or more pronunciation lexicon names you want the service to apply during synthesis. Lexicons are applied only if the language of the lexicon is the same as the language of the voice.

$sel:outputFormat:StartSpeechSynthesisTask', startSpeechSynthesisTask_outputFormat - The format in which the returned output will be encoded. For audio stream, this will be mp3, ogg_vorbis, or pcm. For speech marks, this will be json.

$sel:outputS3BucketName:StartSpeechSynthesisTask', startSpeechSynthesisTask_outputS3BucketName - Amazon S3 bucket name to which the output file will be saved.

$sel:text:StartSpeechSynthesisTask', startSpeechSynthesisTask_text - The input text to synthesize. If you specify ssml as the TextType, follow the SSML format for the input text.

$sel:voiceId:StartSpeechSynthesisTask', startSpeechSynthesisTask_voiceId - Voice ID to use for the synthesis.

Request Lenses

startSpeechSynthesisTask_languageCode :: Lens' StartSpeechSynthesisTask (Maybe LanguageCode) Source #

Optional language code for the Speech Synthesis request. This is only necessary if using a bilingual voice, such as Aditi, which can be used for either Indian English (en-IN) or Hindi (hi-IN).

If a bilingual voice is used and no language code is specified, Amazon Polly uses the default language of the bilingual voice. The default language for any voice is the one returned by the DescribeVoices operation for the LanguageCode parameter. For example, if no language code is specified, Aditi will use Indian English rather than Hindi.

startSpeechSynthesisTask_snsTopicArn :: Lens' StartSpeechSynthesisTask (Maybe Text) Source #

ARN for the SNS topic optionally used for providing status notification for a speech synthesis task.

startSpeechSynthesisTask_outputS3KeyPrefix :: Lens' StartSpeechSynthesisTask (Maybe Text) Source #

The Amazon S3 key prefix for the output speech file.

startSpeechSynthesisTask_engine :: Lens' StartSpeechSynthesisTask (Maybe Engine) Source #

Specifies the engine (standard or neural) for Amazon Polly to use when processing input text for speech synthesis. Using a voice that is not supported for the engine selected will result in an error.

startSpeechSynthesisTask_speechMarkTypes :: Lens' StartSpeechSynthesisTask (Maybe [SpeechMarkType]) Source #

The type of speech marks returned for the input text.

startSpeechSynthesisTask_sampleRate :: Lens' StartSpeechSynthesisTask (Maybe Text) Source #

The audio frequency specified in Hz.

The valid values for mp3 and ogg_vorbis are "8000", "16000", "22050", and "24000". The default value for standard voices is "22050". The default value for neural voices is "24000".

Valid values for pcm are "8000" and "16000" The default value is "16000".

startSpeechSynthesisTask_textType :: Lens' StartSpeechSynthesisTask (Maybe TextType) Source #

Specifies whether the input text is plain text or SSML. The default value is plain text.

startSpeechSynthesisTask_lexiconNames :: Lens' StartSpeechSynthesisTask (Maybe [Text]) Source #

List of one or more pronunciation lexicon names you want the service to apply during synthesis. Lexicons are applied only if the language of the lexicon is the same as the language of the voice.

startSpeechSynthesisTask_outputFormat :: Lens' StartSpeechSynthesisTask OutputFormat Source #

The format in which the returned output will be encoded. For audio stream, this will be mp3, ogg_vorbis, or pcm. For speech marks, this will be json.

startSpeechSynthesisTask_outputS3BucketName :: Lens' StartSpeechSynthesisTask Text Source #

Amazon S3 bucket name to which the output file will be saved.

startSpeechSynthesisTask_text :: Lens' StartSpeechSynthesisTask Text Source #

The input text to synthesize. If you specify ssml as the TextType, follow the SSML format for the input text.

Destructuring the Response

data StartSpeechSynthesisTaskResponse Source #

See: newStartSpeechSynthesisTaskResponse smart constructor.

Constructors

StartSpeechSynthesisTaskResponse' 

Fields

Instances

Instances details
Eq StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Read StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Show StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Generic StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

Associated Types

type Rep StartSpeechSynthesisTaskResponse :: Type -> Type #

NFData StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

type Rep StartSpeechSynthesisTaskResponse Source # 
Instance details

Defined in Amazonka.Polly.StartSpeechSynthesisTask

type Rep StartSpeechSynthesisTaskResponse = D1 ('MetaData "StartSpeechSynthesisTaskResponse" "Amazonka.Polly.StartSpeechSynthesisTask" "libZSservicesZSamazonka-pollyZSamazonka-polly" 'False) (C1 ('MetaCons "StartSpeechSynthesisTaskResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "synthesisTask") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe SynthesisTask)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newStartSpeechSynthesisTaskResponse Source #

Create a value of StartSpeechSynthesisTaskResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:synthesisTask:StartSpeechSynthesisTaskResponse', startSpeechSynthesisTaskResponse_synthesisTask - SynthesisTask object that provides information and attributes about a newly submitted speech synthesis task.

$sel:httpStatus:StartSpeechSynthesisTaskResponse', startSpeechSynthesisTaskResponse_httpStatus - The response's http status code.

Response Lenses

startSpeechSynthesisTaskResponse_synthesisTask :: Lens' StartSpeechSynthesisTaskResponse (Maybe SynthesisTask) Source #

SynthesisTask object that provides information and attributes about a newly submitted speech synthesis task.