telnyx 5.82.0 → 5.83.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +1 -1
- data/lib/telnyx/models/text_to_speech_generate_params.rb +96 -1
- data/lib/telnyx/models/text_to_speech_list_voices_params.rb +1 -0
- data/lib/telnyx/resources/text_to_speech.rb +4 -2
- data/lib/telnyx/version.rb +1 -1
- data/rbi/telnyx/models/text_to_speech_generate_params.rbi +269 -0
- data/rbi/telnyx/models/text_to_speech_list_voices_params.rbi +5 -0
- data/rbi/telnyx/resources/text_to_speech.rbi +4 -1
- data/sig/telnyx/models/text_to_speech_generate_params.rbs +104 -2
- data/sig/telnyx/models/text_to_speech_list_voices_params.rbs +9 -1
- data/sig/telnyx/resources/text_to_speech.rbs +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: af69a9c52a7872be1f265596088ca3ab802c9e45f5ae9089b207751da44b3811
|
|
4
|
+
data.tar.gz: '021387f579faa6177f78c0e368784c5e8b0605da69f2919cb2531d94cbfa6bbf'
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cb75c492caa4661b3e4ef80c0f9ecaa5929130c439a9a20261155498013216ed41f44623c5e768a634b34dd881f3ffbbc815c07c3e51e8ae7dd8e90790739eb7
|
|
7
|
+
data.tar.gz: 16bdcf9b6771e0a5cbcd833d7ce88a0e0c702de3f47977ae1cd10b740e8be686a8bb52b08de9c4b63be234843c1581c61f52d531a4fa8b6ea69d95116f403ef5
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 5.83.0 (2026-04-23)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v5.82.0...v5.83.0](https://github.com/team-telnyx/telnyx-ruby/compare/v5.82.0...v5.83.0)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* Add xAI provider to standalone STT and TTS specs ([f46ab80](https://github.com/team-telnyx/telnyx-ruby/commit/f46ab80c6f17a19e1c7aa4120b7690e671d6bb77))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Chores
|
|
13
|
+
|
|
14
|
+
* **internal:** more robust bootstrap script ([9f0d291](https://github.com/team-telnyx/telnyx-ruby/commit/9f0d291b8ef718abf05007a0c36402540a320fcd))
|
|
15
|
+
|
|
3
16
|
## 5.82.0 (2026-04-22)
|
|
4
17
|
|
|
5
18
|
Full Changelog: [v5.81.0...v5.82.0](https://github.com/team-telnyx/telnyx-ruby/compare/v5.81.0...v5.82.0)
|
data/README.md
CHANGED
|
@@ -106,7 +106,13 @@ module Telnyx
|
|
|
106
106
|
# @return [Hash{Symbol=>Object}, nil]
|
|
107
107
|
optional :voice_settings, ::Telnyx::Internal::Type::HashOf[::Telnyx::Internal::Type::Unknown]
|
|
108
108
|
|
|
109
|
-
# @!
|
|
109
|
+
# @!attribute xai
|
|
110
|
+
# xAI provider-specific parameters.
|
|
111
|
+
#
|
|
112
|
+
# @return [::Telnyx::Models::TextToSpeechGenerateParams::Xai, nil]
|
|
113
|
+
optional :xai, -> { ::Telnyx::TextToSpeechGenerateParams::Xai }
|
|
114
|
+
|
|
115
|
+
# @!method initialize(aws: nil, azure: nil, disable_cache: nil, elevenlabs: nil, language: nil, minimax: nil, output_type: nil, provider: nil, resemble: nil, rime: nil, telnyx: nil, text: nil, text_type: nil, voice: nil, voice_settings: nil, xai: nil, request_options: {})
|
|
110
116
|
# Some parameter documentations has been truncated, see
|
|
111
117
|
# {::Telnyx::Models::TextToSpeechGenerateParams} for more details.
|
|
112
118
|
#
|
|
@@ -140,6 +146,8 @@ module Telnyx
|
|
|
140
146
|
#
|
|
141
147
|
# @param voice_settings [Hash{Symbol=>Object}] Provider-specific voice settings. Contents vary by provider — see provider-speci
|
|
142
148
|
#
|
|
149
|
+
# @param xai [::Telnyx::Models::TextToSpeechGenerateParams::Xai] xAI provider-specific parameters.
|
|
150
|
+
#
|
|
143
151
|
# @param request_options [::Telnyx::RequestOptions, Hash{Symbol=>Object}]
|
|
144
152
|
|
|
145
153
|
class Aws < ::Telnyx::Internal::Type::BaseModel
|
|
@@ -379,6 +387,7 @@ module Telnyx
|
|
|
379
387
|
MINIMAX = :minimax
|
|
380
388
|
RIME = :rime
|
|
381
389
|
RESEMBLE = :resemble
|
|
390
|
+
XAI = :xai
|
|
382
391
|
|
|
383
392
|
# @!method self.values
|
|
384
393
|
# @return [Array<Symbol>]
|
|
@@ -538,6 +547,92 @@ module Telnyx
|
|
|
538
547
|
# @!method self.values
|
|
539
548
|
# @return [Array<Symbol>]
|
|
540
549
|
end
|
|
550
|
+
|
|
551
|
+
class Xai < ::Telnyx::Internal::Type::BaseModel
|
|
552
|
+
# @!attribute voice_id
|
|
553
|
+
# xAI voice identifier.
|
|
554
|
+
#
|
|
555
|
+
# @return [Symbol, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::VoiceID]
|
|
556
|
+
required :voice_id, enum: -> { ::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID }
|
|
557
|
+
|
|
558
|
+
# @!attribute language
|
|
559
|
+
# Language code, or `auto` to detect.
|
|
560
|
+
#
|
|
561
|
+
# @return [String, nil]
|
|
562
|
+
optional :language, String
|
|
563
|
+
|
|
564
|
+
# @!attribute output_format
|
|
565
|
+
# Audio output format.
|
|
566
|
+
#
|
|
567
|
+
# @return [Symbol, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::OutputFormat, nil]
|
|
568
|
+
optional :output_format, enum: -> { ::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat }
|
|
569
|
+
|
|
570
|
+
# @!attribute sample_rate
|
|
571
|
+
# Audio sample rate in Hz.
|
|
572
|
+
#
|
|
573
|
+
# @return [Integer, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::SampleRate, nil]
|
|
574
|
+
optional :sample_rate, enum: -> { ::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate }
|
|
575
|
+
|
|
576
|
+
# @!method initialize(voice_id:, language: nil, output_format: nil, sample_rate: nil)
|
|
577
|
+
# xAI provider-specific parameters.
|
|
578
|
+
#
|
|
579
|
+
# @param voice_id [Symbol, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::VoiceID] xAI voice identifier.
|
|
580
|
+
#
|
|
581
|
+
# @param language [String] Language code, or `auto` to detect.
|
|
582
|
+
#
|
|
583
|
+
# @param output_format [Symbol, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::OutputFormat] Audio output format.
|
|
584
|
+
#
|
|
585
|
+
# @param sample_rate [Integer, ::Telnyx::Models::TextToSpeechGenerateParams::Xai::SampleRate] Audio sample rate in Hz.
|
|
586
|
+
|
|
587
|
+
# xAI voice identifier.
|
|
588
|
+
#
|
|
589
|
+
# @see Telnyx::Models::TextToSpeechGenerateParams::Xai#voice_id
|
|
590
|
+
module VoiceID
|
|
591
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
592
|
+
|
|
593
|
+
EVE = :eve
|
|
594
|
+
ARA = :ara
|
|
595
|
+
REX = :rex
|
|
596
|
+
SAL = :sal
|
|
597
|
+
LEO = :leo
|
|
598
|
+
|
|
599
|
+
# @!method self.values
|
|
600
|
+
# @return [Array<Symbol>]
|
|
601
|
+
end
|
|
602
|
+
|
|
603
|
+
# Audio output format.
|
|
604
|
+
#
|
|
605
|
+
# @see Telnyx::Models::TextToSpeechGenerateParams::Xai#output_format
|
|
606
|
+
module OutputFormat
|
|
607
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
608
|
+
|
|
609
|
+
MP3 = :mp3
|
|
610
|
+
WAV = :wav
|
|
611
|
+
PCM = :pcm
|
|
612
|
+
MULAW = :mulaw
|
|
613
|
+
ALAW = :alaw
|
|
614
|
+
|
|
615
|
+
# @!method self.values
|
|
616
|
+
# @return [Array<Symbol>]
|
|
617
|
+
end
|
|
618
|
+
|
|
619
|
+
# Audio sample rate in Hz.
|
|
620
|
+
#
|
|
621
|
+
# @see Telnyx::Models::TextToSpeechGenerateParams::Xai#sample_rate
|
|
622
|
+
module SampleRate
|
|
623
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
624
|
+
|
|
625
|
+
SAMPLE_RATE_8000 = 8000
|
|
626
|
+
SAMPLE_RATE_16000 = 16_000
|
|
627
|
+
SAMPLE_RATE_22050 = 22_050
|
|
628
|
+
SAMPLE_RATE_24000 = 24_000
|
|
629
|
+
SAMPLE_RATE_44100 = 44_100
|
|
630
|
+
SAMPLE_RATE_48000 = 48_000
|
|
631
|
+
|
|
632
|
+
# @!method self.values
|
|
633
|
+
# @return [Array<Integer>]
|
|
634
|
+
end
|
|
635
|
+
end
|
|
541
636
|
end
|
|
542
637
|
end
|
|
543
638
|
end
|
|
@@ -20,13 +20,13 @@ module Telnyx
|
|
|
20
20
|
# with provider-specific parameters.
|
|
21
21
|
#
|
|
22
22
|
# Supported providers: `aws`, `telnyx`, `azure`, `elevenlabs`, `minimax`, `rime`,
|
|
23
|
-
# `resemble`.
|
|
23
|
+
# `resemble`, `xai`.
|
|
24
24
|
#
|
|
25
25
|
# The Telnyx `Ultra` model supports 44 languages with emotion control, speed
|
|
26
26
|
# adjustment, and volume control. Use the `telnyx` provider-specific parameters to
|
|
27
27
|
# configure these features.
|
|
28
28
|
#
|
|
29
|
-
# @overload generate(aws: nil, azure: nil, disable_cache: nil, elevenlabs: nil, language: nil, minimax: nil, output_type: nil, provider: nil, resemble: nil, rime: nil, telnyx: nil, text: nil, text_type: nil, voice: nil, voice_settings: nil, request_options: {})
|
|
29
|
+
# @overload generate(aws: nil, azure: nil, disable_cache: nil, elevenlabs: nil, language: nil, minimax: nil, output_type: nil, provider: nil, resemble: nil, rime: nil, telnyx: nil, text: nil, text_type: nil, voice: nil, voice_settings: nil, xai: nil, request_options: {})
|
|
30
30
|
#
|
|
31
31
|
# @param aws [::Telnyx::Models::TextToSpeechGenerateParams::Aws] AWS Polly provider-specific parameters.
|
|
32
32
|
#
|
|
@@ -58,6 +58,8 @@ module Telnyx
|
|
|
58
58
|
#
|
|
59
59
|
# @param voice_settings [Hash{Symbol=>Object}] Provider-specific voice settings. Contents vary by provider — see provider-speci
|
|
60
60
|
#
|
|
61
|
+
# @param xai [::Telnyx::Models::TextToSpeechGenerateParams::Xai] xAI provider-specific parameters.
|
|
62
|
+
#
|
|
61
63
|
# @param request_options [Telnyx::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
62
64
|
#
|
|
63
65
|
# @return [Telnyx::Models::TextToSpeechGenerateResponse]
|
data/lib/telnyx/version.rb
CHANGED
|
@@ -177,6 +177,15 @@ module Telnyx
|
|
|
177
177
|
sig { params(voice_settings: T::Hash[Symbol, T.anything]).void }
|
|
178
178
|
attr_writer :voice_settings
|
|
179
179
|
|
|
180
|
+
# xAI provider-specific parameters.
|
|
181
|
+
sig { returns(T.nilable(::Telnyx::TextToSpeechGenerateParams::Xai)) }
|
|
182
|
+
attr_reader :xai
|
|
183
|
+
|
|
184
|
+
sig do
|
|
185
|
+
params(xai: ::Telnyx::TextToSpeechGenerateParams::Xai::OrHash).void
|
|
186
|
+
end
|
|
187
|
+
attr_writer :xai
|
|
188
|
+
|
|
180
189
|
sig do
|
|
181
190
|
params(
|
|
182
191
|
aws: ::Telnyx::TextToSpeechGenerateParams::Aws::OrHash,
|
|
@@ -195,6 +204,7 @@ module Telnyx
|
|
|
195
204
|
text_type: ::Telnyx::TextToSpeechGenerateParams::TextType::OrSymbol,
|
|
196
205
|
voice: String,
|
|
197
206
|
voice_settings: T::Hash[Symbol, T.anything],
|
|
207
|
+
xai: ::Telnyx::TextToSpeechGenerateParams::Xai::OrHash,
|
|
198
208
|
request_options: ::Telnyx::RequestOptions::OrHash
|
|
199
209
|
).returns(T.attached_class)
|
|
200
210
|
end
|
|
@@ -238,6 +248,8 @@ module Telnyx
|
|
|
238
248
|
# Provider-specific voice settings. Contents vary by provider — see
|
|
239
249
|
# provider-specific parameter objects below.
|
|
240
250
|
voice_settings: nil,
|
|
251
|
+
# xAI provider-specific parameters.
|
|
252
|
+
xai: nil,
|
|
241
253
|
request_options: {}
|
|
242
254
|
)
|
|
243
255
|
end
|
|
@@ -261,6 +273,7 @@ module Telnyx
|
|
|
261
273
|
text_type: ::Telnyx::TextToSpeechGenerateParams::TextType::OrSymbol,
|
|
262
274
|
voice: String,
|
|
263
275
|
voice_settings: T::Hash[Symbol, T.anything],
|
|
276
|
+
xai: ::Telnyx::TextToSpeechGenerateParams::Xai,
|
|
264
277
|
request_options: ::Telnyx::RequestOptions
|
|
265
278
|
}
|
|
266
279
|
)
|
|
@@ -782,6 +795,11 @@ module Telnyx
|
|
|
782
795
|
:resemble,
|
|
783
796
|
::Telnyx::TextToSpeechGenerateParams::Provider::TaggedSymbol
|
|
784
797
|
)
|
|
798
|
+
XAI =
|
|
799
|
+
T.let(
|
|
800
|
+
:xai,
|
|
801
|
+
::Telnyx::TextToSpeechGenerateParams::Provider::TaggedSymbol
|
|
802
|
+
)
|
|
785
803
|
|
|
786
804
|
sig do
|
|
787
805
|
override.returns(
|
|
@@ -1130,6 +1148,257 @@ module Telnyx
|
|
|
1130
1148
|
def self.values
|
|
1131
1149
|
end
|
|
1132
1150
|
end
|
|
1151
|
+
|
|
1152
|
+
class Xai < ::Telnyx::Internal::Type::BaseModel
|
|
1153
|
+
OrHash =
|
|
1154
|
+
T.type_alias do
|
|
1155
|
+
T.any(
|
|
1156
|
+
::Telnyx::TextToSpeechGenerateParams::Xai,
|
|
1157
|
+
::Telnyx::Internal::AnyHash
|
|
1158
|
+
)
|
|
1159
|
+
end
|
|
1160
|
+
|
|
1161
|
+
# xAI voice identifier.
|
|
1162
|
+
sig do
|
|
1163
|
+
returns(::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::OrSymbol)
|
|
1164
|
+
end
|
|
1165
|
+
attr_accessor :voice_id
|
|
1166
|
+
|
|
1167
|
+
# Language code, or `auto` to detect.
|
|
1168
|
+
sig { returns(T.nilable(String)) }
|
|
1169
|
+
attr_reader :language
|
|
1170
|
+
|
|
1171
|
+
sig { params(language: String).void }
|
|
1172
|
+
attr_writer :language
|
|
1173
|
+
|
|
1174
|
+
# Audio output format.
|
|
1175
|
+
sig do
|
|
1176
|
+
returns(
|
|
1177
|
+
T.nilable(
|
|
1178
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::OrSymbol
|
|
1179
|
+
)
|
|
1180
|
+
)
|
|
1181
|
+
end
|
|
1182
|
+
attr_reader :output_format
|
|
1183
|
+
|
|
1184
|
+
sig do
|
|
1185
|
+
params(
|
|
1186
|
+
output_format:
|
|
1187
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::OrSymbol
|
|
1188
|
+
).void
|
|
1189
|
+
end
|
|
1190
|
+
attr_writer :output_format
|
|
1191
|
+
|
|
1192
|
+
# Audio sample rate in Hz.
|
|
1193
|
+
sig do
|
|
1194
|
+
returns(
|
|
1195
|
+
T.nilable(
|
|
1196
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::OrInteger
|
|
1197
|
+
)
|
|
1198
|
+
)
|
|
1199
|
+
end
|
|
1200
|
+
attr_reader :sample_rate
|
|
1201
|
+
|
|
1202
|
+
sig do
|
|
1203
|
+
params(
|
|
1204
|
+
sample_rate:
|
|
1205
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::OrInteger
|
|
1206
|
+
).void
|
|
1207
|
+
end
|
|
1208
|
+
attr_writer :sample_rate
|
|
1209
|
+
|
|
1210
|
+
# xAI provider-specific parameters.
|
|
1211
|
+
sig do
|
|
1212
|
+
params(
|
|
1213
|
+
voice_id:
|
|
1214
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::OrSymbol,
|
|
1215
|
+
language: String,
|
|
1216
|
+
output_format:
|
|
1217
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::OrSymbol,
|
|
1218
|
+
sample_rate:
|
|
1219
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::OrInteger
|
|
1220
|
+
).returns(T.attached_class)
|
|
1221
|
+
end
|
|
1222
|
+
def self.new(
|
|
1223
|
+
# xAI voice identifier.
|
|
1224
|
+
voice_id:,
|
|
1225
|
+
# Language code, or `auto` to detect.
|
|
1226
|
+
language: nil,
|
|
1227
|
+
# Audio output format.
|
|
1228
|
+
output_format: nil,
|
|
1229
|
+
# Audio sample rate in Hz.
|
|
1230
|
+
sample_rate: nil
|
|
1231
|
+
)
|
|
1232
|
+
end
|
|
1233
|
+
|
|
1234
|
+
sig do
|
|
1235
|
+
override.returns(
|
|
1236
|
+
{
|
|
1237
|
+
voice_id:
|
|
1238
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::OrSymbol,
|
|
1239
|
+
language: String,
|
|
1240
|
+
output_format:
|
|
1241
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::OrSymbol,
|
|
1242
|
+
sample_rate:
|
|
1243
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::OrInteger
|
|
1244
|
+
}
|
|
1245
|
+
)
|
|
1246
|
+
end
|
|
1247
|
+
def to_hash
|
|
1248
|
+
end
|
|
1249
|
+
|
|
1250
|
+
# xAI voice identifier.
|
|
1251
|
+
module VoiceID
|
|
1252
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
1253
|
+
|
|
1254
|
+
TaggedSymbol =
|
|
1255
|
+
T.type_alias do
|
|
1256
|
+
T.all(Symbol, ::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID)
|
|
1257
|
+
end
|
|
1258
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1259
|
+
|
|
1260
|
+
EVE =
|
|
1261
|
+
T.let(
|
|
1262
|
+
:eve,
|
|
1263
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1264
|
+
)
|
|
1265
|
+
ARA =
|
|
1266
|
+
T.let(
|
|
1267
|
+
:ara,
|
|
1268
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1269
|
+
)
|
|
1270
|
+
REX =
|
|
1271
|
+
T.let(
|
|
1272
|
+
:rex,
|
|
1273
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1274
|
+
)
|
|
1275
|
+
SAL =
|
|
1276
|
+
T.let(
|
|
1277
|
+
:sal,
|
|
1278
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1279
|
+
)
|
|
1280
|
+
LEO =
|
|
1281
|
+
T.let(
|
|
1282
|
+
:leo,
|
|
1283
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1284
|
+
)
|
|
1285
|
+
|
|
1286
|
+
sig do
|
|
1287
|
+
override.returns(
|
|
1288
|
+
T::Array[
|
|
1289
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::VoiceID::TaggedSymbol
|
|
1290
|
+
]
|
|
1291
|
+
)
|
|
1292
|
+
end
|
|
1293
|
+
def self.values
|
|
1294
|
+
end
|
|
1295
|
+
end
|
|
1296
|
+
|
|
1297
|
+
# Audio output format.
|
|
1298
|
+
module OutputFormat
|
|
1299
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
1300
|
+
|
|
1301
|
+
TaggedSymbol =
|
|
1302
|
+
T.type_alias do
|
|
1303
|
+
T.all(
|
|
1304
|
+
Symbol,
|
|
1305
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat
|
|
1306
|
+
)
|
|
1307
|
+
end
|
|
1308
|
+
OrSymbol = T.type_alias { T.any(Symbol, String) }
|
|
1309
|
+
|
|
1310
|
+
MP3 =
|
|
1311
|
+
T.let(
|
|
1312
|
+
:mp3,
|
|
1313
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1314
|
+
)
|
|
1315
|
+
WAV =
|
|
1316
|
+
T.let(
|
|
1317
|
+
:wav,
|
|
1318
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1319
|
+
)
|
|
1320
|
+
PCM =
|
|
1321
|
+
T.let(
|
|
1322
|
+
:pcm,
|
|
1323
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1324
|
+
)
|
|
1325
|
+
MULAW =
|
|
1326
|
+
T.let(
|
|
1327
|
+
:mulaw,
|
|
1328
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1329
|
+
)
|
|
1330
|
+
ALAW =
|
|
1331
|
+
T.let(
|
|
1332
|
+
:alaw,
|
|
1333
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1334
|
+
)
|
|
1335
|
+
|
|
1336
|
+
sig do
|
|
1337
|
+
override.returns(
|
|
1338
|
+
T::Array[
|
|
1339
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::OutputFormat::TaggedSymbol
|
|
1340
|
+
]
|
|
1341
|
+
)
|
|
1342
|
+
end
|
|
1343
|
+
def self.values
|
|
1344
|
+
end
|
|
1345
|
+
end
|
|
1346
|
+
|
|
1347
|
+
# Audio sample rate in Hz.
|
|
1348
|
+
module SampleRate
|
|
1349
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
1350
|
+
|
|
1351
|
+
TaggedInteger =
|
|
1352
|
+
T.type_alias do
|
|
1353
|
+
T.all(
|
|
1354
|
+
Integer,
|
|
1355
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate
|
|
1356
|
+
)
|
|
1357
|
+
end
|
|
1358
|
+
OrInteger = T.type_alias { Integer }
|
|
1359
|
+
|
|
1360
|
+
SAMPLE_RATE_8000 =
|
|
1361
|
+
T.let(
|
|
1362
|
+
8000,
|
|
1363
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1364
|
+
)
|
|
1365
|
+
SAMPLE_RATE_16000 =
|
|
1366
|
+
T.let(
|
|
1367
|
+
16_000,
|
|
1368
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1369
|
+
)
|
|
1370
|
+
SAMPLE_RATE_22050 =
|
|
1371
|
+
T.let(
|
|
1372
|
+
22_050,
|
|
1373
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1374
|
+
)
|
|
1375
|
+
SAMPLE_RATE_24000 =
|
|
1376
|
+
T.let(
|
|
1377
|
+
24_000,
|
|
1378
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1379
|
+
)
|
|
1380
|
+
SAMPLE_RATE_44100 =
|
|
1381
|
+
T.let(
|
|
1382
|
+
44_100,
|
|
1383
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1384
|
+
)
|
|
1385
|
+
SAMPLE_RATE_48000 =
|
|
1386
|
+
T.let(
|
|
1387
|
+
48_000,
|
|
1388
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1389
|
+
)
|
|
1390
|
+
|
|
1391
|
+
sig do
|
|
1392
|
+
override.returns(
|
|
1393
|
+
T::Array[
|
|
1394
|
+
::Telnyx::TextToSpeechGenerateParams::Xai::SampleRate::TaggedInteger
|
|
1395
|
+
]
|
|
1396
|
+
)
|
|
1397
|
+
end
|
|
1398
|
+
def self.values
|
|
1399
|
+
end
|
|
1400
|
+
end
|
|
1401
|
+
end
|
|
1133
1402
|
end
|
|
1134
1403
|
end
|
|
1135
1404
|
end
|
|
@@ -17,7 +17,7 @@ module Telnyx
|
|
|
17
17
|
# with provider-specific parameters.
|
|
18
18
|
#
|
|
19
19
|
# Supported providers: `aws`, `telnyx`, `azure`, `elevenlabs`, `minimax`, `rime`,
|
|
20
|
-
# `resemble`.
|
|
20
|
+
# `resemble`, `xai`.
|
|
21
21
|
#
|
|
22
22
|
# The Telnyx `Ultra` model supports 44 languages with emotion control, speed
|
|
23
23
|
# adjustment, and volume control. Use the `telnyx` provider-specific parameters to
|
|
@@ -40,6 +40,7 @@ module Telnyx
|
|
|
40
40
|
text_type: ::Telnyx::TextToSpeechGenerateParams::TextType::OrSymbol,
|
|
41
41
|
voice: String,
|
|
42
42
|
voice_settings: T::Hash[Symbol, T.anything],
|
|
43
|
+
xai: ::Telnyx::TextToSpeechGenerateParams::Xai::OrHash,
|
|
43
44
|
request_options: Telnyx::RequestOptions::OrHash
|
|
44
45
|
).returns(Telnyx::Models::TextToSpeechGenerateResponse)
|
|
45
46
|
end
|
|
@@ -83,6 +84,8 @@ module Telnyx
|
|
|
83
84
|
# Provider-specific voice settings. Contents vary by provider — see
|
|
84
85
|
# provider-specific parameter objects below.
|
|
85
86
|
voice_settings: nil,
|
|
87
|
+
# xAI provider-specific parameters.
|
|
88
|
+
xai: nil,
|
|
86
89
|
request_options: {}
|
|
87
90
|
)
|
|
88
91
|
end
|
|
@@ -16,7 +16,8 @@ module Telnyx
|
|
|
16
16
|
text: String,
|
|
17
17
|
text_type: ::Telnyx::Models::TextToSpeechGenerateParams::text_type,
|
|
18
18
|
voice: String,
|
|
19
|
-
voice_settings: ::Hash[Symbol, top]
|
|
19
|
+
voice_settings: ::Hash[Symbol, top],
|
|
20
|
+
xai: ::Telnyx::TextToSpeechGenerateParams::Xai
|
|
20
21
|
}
|
|
21
22
|
& ::Telnyx::Internal::Type::request_parameters
|
|
22
23
|
|
|
@@ -104,6 +105,12 @@ module Telnyx
|
|
|
104
105
|
|
|
105
106
|
def voice_settings=: (::Hash[Symbol, top]) -> ::Hash[Symbol, top]
|
|
106
107
|
|
|
108
|
+
attr_reader xai: ::Telnyx::TextToSpeechGenerateParams::Xai?
|
|
109
|
+
|
|
110
|
+
def xai=: (
|
|
111
|
+
::Telnyx::TextToSpeechGenerateParams::Xai
|
|
112
|
+
) -> ::Telnyx::TextToSpeechGenerateParams::Xai
|
|
113
|
+
|
|
107
114
|
def initialize: (
|
|
108
115
|
?aws: ::Telnyx::TextToSpeechGenerateParams::Aws,
|
|
109
116
|
?azure: ::Telnyx::TextToSpeechGenerateParams::Azure,
|
|
@@ -120,6 +127,7 @@ module Telnyx
|
|
|
120
127
|
?text_type: ::Telnyx::Models::TextToSpeechGenerateParams::text_type,
|
|
121
128
|
?voice: String,
|
|
122
129
|
?voice_settings: ::Hash[Symbol, top],
|
|
130
|
+
?xai: ::Telnyx::TextToSpeechGenerateParams::Xai,
|
|
123
131
|
?request_options: ::Telnyx::request_opts
|
|
124
132
|
) -> void
|
|
125
133
|
|
|
@@ -139,6 +147,7 @@ module Telnyx
|
|
|
139
147
|
text_type: ::Telnyx::Models::TextToSpeechGenerateParams::text_type,
|
|
140
148
|
voice: String,
|
|
141
149
|
voice_settings: ::Hash[Symbol, top],
|
|
150
|
+
xai: ::Telnyx::TextToSpeechGenerateParams::Xai,
|
|
142
151
|
request_options: ::Telnyx::RequestOptions
|
|
143
152
|
}
|
|
144
153
|
|
|
@@ -375,7 +384,14 @@ module Telnyx
|
|
|
375
384
|
end
|
|
376
385
|
|
|
377
386
|
type provider =
|
|
378
|
-
:aws
|
|
387
|
+
:aws
|
|
388
|
+
| :telnyx
|
|
389
|
+
| :azure
|
|
390
|
+
| :elevenlabs
|
|
391
|
+
| :minimax
|
|
392
|
+
| :rime
|
|
393
|
+
| :resemble
|
|
394
|
+
| :xai
|
|
379
395
|
|
|
380
396
|
module Provider
|
|
381
397
|
extend ::Telnyx::Internal::Type::Enum
|
|
@@ -387,6 +403,7 @@ module Telnyx
|
|
|
387
403
|
MINIMAX: :minimax
|
|
388
404
|
RIME: :rime
|
|
389
405
|
RESEMBLE: :resemble
|
|
406
|
+
XAI: :xai
|
|
390
407
|
|
|
391
408
|
def self?.values: -> ::Array[::Telnyx::Models::TextToSpeechGenerateParams::provider]
|
|
392
409
|
end
|
|
@@ -543,6 +560,91 @@ module Telnyx
|
|
|
543
560
|
|
|
544
561
|
def self?.values: -> ::Array[::Telnyx::Models::TextToSpeechGenerateParams::text_type]
|
|
545
562
|
end
|
|
563
|
+
|
|
564
|
+
type xai =
|
|
565
|
+
{
|
|
566
|
+
voice_id: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::voice_id,
|
|
567
|
+
language: String,
|
|
568
|
+
output_format: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format,
|
|
569
|
+
sample_rate: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate
|
|
570
|
+
}
|
|
571
|
+
|
|
572
|
+
class Xai < ::Telnyx::Internal::Type::BaseModel
|
|
573
|
+
attr_accessor voice_id: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::voice_id
|
|
574
|
+
|
|
575
|
+
attr_reader language: String?
|
|
576
|
+
|
|
577
|
+
def language=: (String) -> String
|
|
578
|
+
|
|
579
|
+
attr_reader output_format: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format?
|
|
580
|
+
|
|
581
|
+
def output_format=: (
|
|
582
|
+
::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format
|
|
583
|
+
) -> ::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format
|
|
584
|
+
|
|
585
|
+
attr_reader sample_rate: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate?
|
|
586
|
+
|
|
587
|
+
def sample_rate=: (
|
|
588
|
+
::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate
|
|
589
|
+
) -> ::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate
|
|
590
|
+
|
|
591
|
+
def initialize: (
|
|
592
|
+
voice_id: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::voice_id,
|
|
593
|
+
?language: String,
|
|
594
|
+
?output_format: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format,
|
|
595
|
+
?sample_rate: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate
|
|
596
|
+
) -> void
|
|
597
|
+
|
|
598
|
+
def to_hash: -> {
|
|
599
|
+
voice_id: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::voice_id,
|
|
600
|
+
language: String,
|
|
601
|
+
output_format: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format,
|
|
602
|
+
sample_rate: ::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate
|
|
603
|
+
}
|
|
604
|
+
|
|
605
|
+
type voice_id = :eve | :ara | :rex | :sal | :leo
|
|
606
|
+
|
|
607
|
+
module VoiceID
|
|
608
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
609
|
+
|
|
610
|
+
EVE: :eve
|
|
611
|
+
ARA: :ara
|
|
612
|
+
REX: :rex
|
|
613
|
+
SAL: :sal
|
|
614
|
+
LEO: :leo
|
|
615
|
+
|
|
616
|
+
def self?.values: -> ::Array[::Telnyx::Models::TextToSpeechGenerateParams::Xai::voice_id]
|
|
617
|
+
end
|
|
618
|
+
|
|
619
|
+
type output_format = :mp3 | :wav | :pcm | :mulaw | :alaw
|
|
620
|
+
|
|
621
|
+
module OutputFormat
|
|
622
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
623
|
+
|
|
624
|
+
MP3: :mp3
|
|
625
|
+
WAV: :wav
|
|
626
|
+
PCM: :pcm
|
|
627
|
+
MULAW: :mulaw
|
|
628
|
+
ALAW: :alaw
|
|
629
|
+
|
|
630
|
+
def self?.values: -> ::Array[::Telnyx::Models::TextToSpeechGenerateParams::Xai::output_format]
|
|
631
|
+
end
|
|
632
|
+
|
|
633
|
+
type sample_rate = 8000 | 16000 | 22050 | 24000 | 44100 | 48000
|
|
634
|
+
|
|
635
|
+
module SampleRate
|
|
636
|
+
extend ::Telnyx::Internal::Type::Enum
|
|
637
|
+
|
|
638
|
+
SAMPLE_RATE_8000: 8000
|
|
639
|
+
SAMPLE_RATE_16000: 16000
|
|
640
|
+
SAMPLE_RATE_22050: 22050
|
|
641
|
+
SAMPLE_RATE_24000: 24000
|
|
642
|
+
SAMPLE_RATE_44100: 44100
|
|
643
|
+
SAMPLE_RATE_48000: 48000
|
|
644
|
+
|
|
645
|
+
def self?.values: -> ::Array[::Telnyx::Models::TextToSpeechGenerateParams::Xai::sample_rate]
|
|
646
|
+
end
|
|
647
|
+
end
|
|
546
648
|
end
|
|
547
649
|
end
|
|
548
650
|
end
|
|
@@ -34,7 +34,14 @@ module Telnyx
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
type provider =
|
|
37
|
-
:aws
|
|
37
|
+
:aws
|
|
38
|
+
| :telnyx
|
|
39
|
+
| :azure
|
|
40
|
+
| :elevenlabs
|
|
41
|
+
| :minimax
|
|
42
|
+
| :rime
|
|
43
|
+
| :resemble
|
|
44
|
+
| :xai
|
|
38
45
|
|
|
39
46
|
module Provider
|
|
40
47
|
extend Telnyx::Internal::Type::Enum
|
|
@@ -46,6 +53,7 @@ module Telnyx
|
|
|
46
53
|
MINIMAX: :minimax
|
|
47
54
|
RIME: :rime
|
|
48
55
|
RESEMBLE: :resemble
|
|
56
|
+
XAI: :xai
|
|
49
57
|
|
|
50
58
|
def self?.values: -> ::Array[Telnyx::Models::TextToSpeechListVoicesParams::provider]
|
|
51
59
|
end
|
|
@@ -17,6 +17,7 @@ module Telnyx
|
|
|
17
17
|
?text_type: ::Telnyx::Models::TextToSpeechGenerateParams::text_type,
|
|
18
18
|
?voice: String,
|
|
19
19
|
?voice_settings: ::Hash[Symbol, top],
|
|
20
|
+
?xai: ::Telnyx::TextToSpeechGenerateParams::Xai,
|
|
20
21
|
?request_options: Telnyx::request_opts
|
|
21
22
|
) -> Telnyx::Models::TextToSpeechGenerateResponse
|
|
22
23
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: telnyx
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 5.
|
|
4
|
+
version: 5.83.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Telnyx
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-04-
|
|
11
|
+
date: 2026-04-23 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: cgi
|