Copyright | (c) 2015-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
Synopsis
- textToSpeechService :: ServiceConfig
- cloudPlatformScope :: Proxy '["https://www.googleapis.com/auth/cloud-platform"]
- data AudioConfig
- audioConfig :: AudioConfig
- acVolumeGainDB :: Lens' AudioConfig (Maybe Double)
- acSampleRateHertz :: Lens' AudioConfig (Maybe Int32)
- acAudioEncoding :: Lens' AudioConfig (Maybe AudioConfigAudioEncoding)
- acSpeakingRate :: Lens' AudioConfig (Maybe Double)
- acPitch :: Lens' AudioConfig (Maybe Double)
- data VoiceSelectionParams
- voiceSelectionParams :: VoiceSelectionParams
- vspLanguageCode :: Lens' VoiceSelectionParams (Maybe Text)
- vspSsmlGender :: Lens' VoiceSelectionParams (Maybe VoiceSelectionParamsSsmlGender)
- vspName :: Lens' VoiceSelectionParams (Maybe Text)
- data SynthesizeSpeechRequest
- synthesizeSpeechRequest :: SynthesizeSpeechRequest
- ssrAudioConfig :: Lens' SynthesizeSpeechRequest (Maybe AudioConfig)
- ssrInput :: Lens' SynthesizeSpeechRequest (Maybe SynthesisInput)
- ssrVoice :: Lens' SynthesizeSpeechRequest (Maybe VoiceSelectionParams)
- data ListVoicesResponse
- listVoicesResponse :: ListVoicesResponse
- lvrVoices :: Lens' ListVoicesResponse [Voice]
- data VoiceSelectionParamsSsmlGender
- data SynthesisInput
- synthesisInput :: SynthesisInput
- siText :: Lens' SynthesisInput (Maybe Text)
- siSsml :: Lens' SynthesisInput (Maybe Text)
- data Xgafv
- data VoiceSsmlGender
- data SynthesizeSpeechResponse
- synthesizeSpeechResponse :: SynthesizeSpeechResponse
- ssrAudioContent :: Lens' SynthesizeSpeechResponse (Maybe ByteString)
- data Voice
- voice :: Voice
- vLanguageCodes :: Lens' Voice [Text]
- vNATuralSampleRateHertz :: Lens' Voice (Maybe Int32)
- vSsmlGender :: Lens' Voice (Maybe VoiceSsmlGender)
- vName :: Lens' Voice (Maybe Text)
- data AudioConfigAudioEncoding
Service Configuration
textToSpeechService :: ServiceConfig Source #
Default request referring to version v1
of the Cloud Text-to-Speech API. This contains the host and root path used as a starting point for constructing service requests.
OAuth Scopes
cloudPlatformScope :: Proxy '["https://www.googleapis.com/auth/cloud-platform"] Source #
View and manage your data across Google Cloud Platform services
AudioConfig
data AudioConfig Source #
Description of audio data to be synthesized.
See: audioConfig
smart constructor.
Instances
audioConfig :: AudioConfig Source #
Creates a value of AudioConfig
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
acVolumeGainDB :: Lens' AudioConfig (Maybe Double) Source #
Optional volume gain (in dB) of the normal native volume supported by the specific voice, in the range [-96.0, 16.0]. If unset, or set to a value of 0.0 (dB), will play at normal native signal amplitude. A value of -6.0 (dB) will play at approximately half the amplitude of the normal native signal amplitude. A value of +6.0 (dB) will play at approximately twice the amplitude of the normal native signal amplitude. Strongly recommend not to exceed +10 (dB) as there's usually no effective increase in loudness for any value greater than that.
acSampleRateHertz :: Lens' AudioConfig (Maybe Int32) Source #
The synthesis sample rate (in hertz) for this audio. Optional. If this is different from the voice's natural sample rate, then the synthesizer will honor this request by converting to the desired sample rate (which might result in worse audio quality), unless the specified sample rate is not supported for the encoding chosen, in which case it will fail the request and return google.rpc.Code.INVALID_ARGUMENT.
acAudioEncoding :: Lens' AudioConfig (Maybe AudioConfigAudioEncoding) Source #
Required. The format of the requested audio byte stream.
acSpeakingRate :: Lens' AudioConfig (Maybe Double) Source #
Optional speaking rate/speed, in the range [0.25, 4.0]. 1.0 is the normal native speed supported by the specific voice. 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0), defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0 will return an error.
acPitch :: Lens' AudioConfig (Maybe Double) Source #
Optional speaking pitch, in the range [-20.0, 20.0]. 20 means increase 20 semitones from the original pitch. -20 means decrease 20 semitones from the original pitch.
VoiceSelectionParams
data VoiceSelectionParams Source #
Description of which voice to use for a synthesis request.
See: voiceSelectionParams
smart constructor.
Instances
voiceSelectionParams :: VoiceSelectionParams Source #
Creates a value of VoiceSelectionParams
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
vspLanguageCode :: Lens' VoiceSelectionParams (Maybe Text) Source #
The language (and optionally also the region) of the voice expressed as a BCP-47 language tag, e.g. "en-US". Required. This should not include a script tag (e.g. use "cmn-cn" rather than "cmn-Hant-cn"), because the script will be inferred from the input provided in the SynthesisInput. The TTS service will use this parameter to help choose an appropriate voice. Note that the TTS service may choose a voice with a slightly different language code than the one selected; it may substitute a different region (e.g. using en-US rather than en-CA if there isn't a Canadian voice available), or even a different language, e.g. using "nb" (Norwegian Bokmal) instead of "no" (Norwegian)".
vspSsmlGender :: Lens' VoiceSelectionParams (Maybe VoiceSelectionParamsSsmlGender) Source #
The preferred gender of the voice. Optional; if not set, the service will choose a voice based on the other parameters such as language_code and name. Note that this is only a preference, not requirement; if a voice of the appropriate gender is not available, the synthesizer should substitute a voice with a different gender rather than failing the request.
vspName :: Lens' VoiceSelectionParams (Maybe Text) Source #
The name of the voice. Optional; if not set, the service will choose a voice based on the other parameters such as language_code and gender.
SynthesizeSpeechRequest
data SynthesizeSpeechRequest Source #
The top-level message sent by the client for the `SynthesizeSpeech` method.
See: synthesizeSpeechRequest
smart constructor.
Instances
synthesizeSpeechRequest :: SynthesizeSpeechRequest Source #
Creates a value of SynthesizeSpeechRequest
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
ssrAudioConfig :: Lens' SynthesizeSpeechRequest (Maybe AudioConfig) Source #
Required. The configuration of the synthesized audio.
ssrInput :: Lens' SynthesizeSpeechRequest (Maybe SynthesisInput) Source #
Required. The Synthesizer requires either plain text or SSML as input.
ssrVoice :: Lens' SynthesizeSpeechRequest (Maybe VoiceSelectionParams) Source #
Required. The desired voice of the synthesized audio.
ListVoicesResponse
data ListVoicesResponse Source #
The message returned to the client by the `ListVoices` method.
See: listVoicesResponse
smart constructor.
Instances
listVoicesResponse :: ListVoicesResponse Source #
Creates a value of ListVoicesResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
VoiceSelectionParamsSsmlGender
data VoiceSelectionParamsSsmlGender Source #
The preferred gender of the voice. Optional; if not set, the service will choose a voice based on the other parameters such as language_code and name. Note that this is only a preference, not requirement; if a voice of the appropriate gender is not available, the synthesizer should substitute a voice with a different gender rather than failing the request.
SsmlVoiceGenderUnspecified |
|
Male |
|
Female |
|
Neutral |
|
Instances
SynthesisInput
data SynthesisInput Source #
Contains text input to be synthesized. Either `text` or `ssml` must be supplied. Supplying both or neither returns google.rpc.Code.INVALID_ARGUMENT. The input size is limited to 5000 characters.
See: synthesisInput
smart constructor.
Instances
synthesisInput :: SynthesisInput Source #
Creates a value of SynthesisInput
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
siSsml :: Lens' SynthesisInput (Maybe Text) Source #
The SSML document to be synthesized. The SSML document must be valid and well-formed. Otherwise the RPC will fail and return google.rpc.Code.INVALID_ARGUMENT. For more information, see SSML.
Xgafv
V1 error format.
Instances
VoiceSsmlGender
data VoiceSsmlGender Source #
The gender of this voice.
VSGSsmlVoiceGenderUnspecified |
|
VSGMale |
|
VSGFemale |
|
VSGNeutral |
|
Instances
SynthesizeSpeechResponse
data SynthesizeSpeechResponse Source #
The message returned to the client by the `SynthesizeSpeech` method.
See: synthesizeSpeechResponse
smart constructor.
Instances
synthesizeSpeechResponse :: SynthesizeSpeechResponse Source #
Creates a value of SynthesizeSpeechResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
ssrAudioContent :: Lens' SynthesizeSpeechResponse (Maybe ByteString) Source #
The audio data bytes encoded as specified in the request, including the header (For LINEAR16 audio, we include the WAV header). Note: as with all bytes fields, protobuffers use a pure binary representation, whereas JSON representations use base64.
Voice
Description of a voice supported by the TTS service.
See: voice
smart constructor.
Instances
Eq Voice Source # | |
Data Voice Source # | |
Defined in Network.Google.TextToSpeech.Types.Product gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Voice -> c Voice # gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Voice # dataTypeOf :: Voice -> DataType # dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Voice) # dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Voice) # gmapT :: (forall b. Data b => b -> b) -> Voice -> Voice # gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Voice -> r # gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Voice -> r # gmapQ :: (forall d. Data d => d -> u) -> Voice -> [u] # gmapQi :: Int -> (forall d. Data d => d -> u) -> Voice -> u # gmapM :: Monad m => (forall d. Data d => d -> m d) -> Voice -> m Voice # gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Voice -> m Voice # gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Voice -> m Voice # | |
Show Voice Source # | |
Generic Voice Source # | |
ToJSON Voice Source # | |
Defined in Network.Google.TextToSpeech.Types.Product | |
FromJSON Voice Source # | |
type Rep Voice Source # | |
Defined in Network.Google.TextToSpeech.Types.Product type Rep Voice = D1 (MetaData "Voice" "Network.Google.TextToSpeech.Types.Product" "gogol-texttospeech-0.4.0-1tOSifr1Iss9wmHJGn31FK" False) (C1 (MetaCons "Voice'" PrefixI True) ((S1 (MetaSel (Just "_vLanguageCodes") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [Text])) :*: S1 (MetaSel (Just "_vNATuralSampleRateHertz") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe (Textual Int32)))) :*: (S1 (MetaSel (Just "_vSsmlGender") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe VoiceSsmlGender)) :*: S1 (MetaSel (Just "_vName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))))) |
Creates a value of Voice
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
vLanguageCodes :: Lens' Voice [Text] Source #
The languages that this voice supports, expressed as BCP-47 language tags (e.g. "en-US", "es-419", "cmn-tw").
vNATuralSampleRateHertz :: Lens' Voice (Maybe Int32) Source #
The natural sample rate (in hertz) for this voice.
vSsmlGender :: Lens' Voice (Maybe VoiceSsmlGender) Source #
The gender of this voice.
vName :: Lens' Voice (Maybe Text) Source #
The name of this voice. Each distinct voice has a unique name.
AudioConfigAudioEncoding
data AudioConfigAudioEncoding Source #
Required. The format of the requested audio byte stream.
AudioEncodingUnspecified |
|
LINEAR16 |
|
MP3 |
|
OggOpus |
|