revox 0.0.2

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.
Files changed (161) hide show
  1. checksums.yaml +7 -0
  2. data/.ignore +2 -0
  3. data/CHANGELOG.md +10 -0
  4. data/README.md +234 -0
  5. data/SECURITY.md +23 -0
  6. data/lib/revox/client.rb +86 -0
  7. data/lib/revox/errors.rb +228 -0
  8. data/lib/revox/file_part.rb +58 -0
  9. data/lib/revox/internal/transport/base_client.rb +570 -0
  10. data/lib/revox/internal/transport/pooled_net_requester.rb +210 -0
  11. data/lib/revox/internal/type/array_of.rb +168 -0
  12. data/lib/revox/internal/type/base_model.rb +529 -0
  13. data/lib/revox/internal/type/base_page.rb +55 -0
  14. data/lib/revox/internal/type/boolean.rb +77 -0
  15. data/lib/revox/internal/type/converter.rb +327 -0
  16. data/lib/revox/internal/type/enum.rb +131 -0
  17. data/lib/revox/internal/type/file_input.rb +110 -0
  18. data/lib/revox/internal/type/hash_of.rb +188 -0
  19. data/lib/revox/internal/type/request_parameters.rb +42 -0
  20. data/lib/revox/internal/type/union.rb +237 -0
  21. data/lib/revox/internal/type/unknown.rb +81 -0
  22. data/lib/revox/internal/util.rb +920 -0
  23. data/lib/revox/internal.rb +20 -0
  24. data/lib/revox/models/assistant_create_params.rb +467 -0
  25. data/lib/revox/models/assistant_create_response.rb +535 -0
  26. data/lib/revox/models/assistant_delete_params.rb +14 -0
  27. data/lib/revox/models/assistant_delete_response.rb +16 -0
  28. data/lib/revox/models/assistant_list_params.rb +14 -0
  29. data/lib/revox/models/assistant_list_response.rb +533 -0
  30. data/lib/revox/models/assistant_retrieve_params.rb +14 -0
  31. data/lib/revox/models/assistant_retrieve_response.rb +518 -0
  32. data/lib/revox/models/assistant_update_params.rb +467 -0
  33. data/lib/revox/models/assistant_update_response.rb +535 -0
  34. data/lib/revox/models/call_create_params.rb +592 -0
  35. data/lib/revox/models/call_create_response.rb +684 -0
  36. data/lib/revox/models/call_list_params.rb +29 -0
  37. data/lib/revox/models/call_list_response.rb +197 -0
  38. data/lib/revox/models/call_retrieve_params.rb +14 -0
  39. data/lib/revox/models/call_retrieve_response.rb +684 -0
  40. data/lib/revox/models/users/me_retrieve_params.rb +16 -0
  41. data/lib/revox/models/users/me_retrieve_response.rb +89 -0
  42. data/lib/revox/models/users/me_update_params.rb +22 -0
  43. data/lib/revox/models/users/me_update_response.rb +89 -0
  44. data/lib/revox/models/voice_list_params.rb +14 -0
  45. data/lib/revox/models/voice_list_response.rb +91 -0
  46. data/lib/revox/models/voice_preview_params.rb +49 -0
  47. data/lib/revox/models/voice_retrieve_params.rb +30 -0
  48. data/lib/revox/models/voice_retrieve_response.rb +39 -0
  49. data/lib/revox/models.rb +65 -0
  50. data/lib/revox/request_options.rb +77 -0
  51. data/lib/revox/resources/assistants.rb +180 -0
  52. data/lib/revox/resources/call.rb +100 -0
  53. data/lib/revox/resources/users/me.rb +55 -0
  54. data/lib/revox/resources/users.rb +18 -0
  55. data/lib/revox/resources/voices.rb +83 -0
  56. data/lib/revox/version.rb +5 -0
  57. data/lib/revox.rb +85 -0
  58. data/manifest.yaml +17 -0
  59. data/rbi/revox/client.rbi +58 -0
  60. data/rbi/revox/errors.rbi +205 -0
  61. data/rbi/revox/file_part.rbi +37 -0
  62. data/rbi/revox/internal/transport/base_client.rbi +297 -0
  63. data/rbi/revox/internal/transport/pooled_net_requester.rbi +82 -0
  64. data/rbi/revox/internal/type/array_of.rbi +104 -0
  65. data/rbi/revox/internal/type/base_model.rbi +299 -0
  66. data/rbi/revox/internal/type/base_page.rbi +42 -0
  67. data/rbi/revox/internal/type/boolean.rbi +58 -0
  68. data/rbi/revox/internal/type/converter.rbi +204 -0
  69. data/rbi/revox/internal/type/enum.rbi +82 -0
  70. data/rbi/revox/internal/type/file_input.rbi +58 -0
  71. data/rbi/revox/internal/type/hash_of.rbi +104 -0
  72. data/rbi/revox/internal/type/request_parameters.rbi +29 -0
  73. data/rbi/revox/internal/type/union.rbi +126 -0
  74. data/rbi/revox/internal/type/unknown.rbi +58 -0
  75. data/rbi/revox/internal/util.rbi +478 -0
  76. data/rbi/revox/internal.rbi +16 -0
  77. data/rbi/revox/models/assistant_create_params.rbi +929 -0
  78. data/rbi/revox/models/assistant_create_response.rbi +1089 -0
  79. data/rbi/revox/models/assistant_delete_params.rbi +27 -0
  80. data/rbi/revox/models/assistant_delete_response.rbi +26 -0
  81. data/rbi/revox/models/assistant_list_params.rbi +27 -0
  82. data/rbi/revox/models/assistant_list_response.rbi +1079 -0
  83. data/rbi/revox/models/assistant_retrieve_params.rbi +27 -0
  84. data/rbi/revox/models/assistant_retrieve_response.rbi +1024 -0
  85. data/rbi/revox/models/assistant_update_params.rbi +935 -0
  86. data/rbi/revox/models/assistant_update_response.rbi +1089 -0
  87. data/rbi/revox/models/call_create_params.rbi +1147 -0
  88. data/rbi/revox/models/call_create_response.rbi +1335 -0
  89. data/rbi/revox/models/call_list_params.rbi +47 -0
  90. data/rbi/revox/models/call_list_response.rbi +401 -0
  91. data/rbi/revox/models/call_retrieve_params.rbi +27 -0
  92. data/rbi/revox/models/call_retrieve_response.rbi +1346 -0
  93. data/rbi/revox/models/users/me_retrieve_params.rbi +29 -0
  94. data/rbi/revox/models/users/me_retrieve_response.rbi +139 -0
  95. data/rbi/revox/models/users/me_update_params.rbi +43 -0
  96. data/rbi/revox/models/users/me_update_response.rbi +139 -0
  97. data/rbi/revox/models/voice_list_params.rbi +25 -0
  98. data/rbi/revox/models/voice_list_response.rbi +204 -0
  99. data/rbi/revox/models/voice_preview_params.rbi +84 -0
  100. data/rbi/revox/models/voice_retrieve_params.rbi +59 -0
  101. data/rbi/revox/models/voice_retrieve_response.rbi +70 -0
  102. data/rbi/revox/models.rbi +27 -0
  103. data/rbi/revox/request_options.rbi +55 -0
  104. data/rbi/revox/resources/assistants.rbi +206 -0
  105. data/rbi/revox/resources/call.rbi +86 -0
  106. data/rbi/revox/resources/users/me.rbi +33 -0
  107. data/rbi/revox/resources/users.rbi +15 -0
  108. data/rbi/revox/resources/voices.rbi +58 -0
  109. data/rbi/revox/version.rbi +5 -0
  110. data/sig/revox/client.rbs +32 -0
  111. data/sig/revox/errors.rbs +117 -0
  112. data/sig/revox/file_part.rbs +21 -0
  113. data/sig/revox/internal/transport/base_client.rbs +133 -0
  114. data/sig/revox/internal/transport/pooled_net_requester.rbs +48 -0
  115. data/sig/revox/internal/type/array_of.rbs +48 -0
  116. data/sig/revox/internal/type/base_model.rbs +102 -0
  117. data/sig/revox/internal/type/base_page.rbs +24 -0
  118. data/sig/revox/internal/type/boolean.rbs +26 -0
  119. data/sig/revox/internal/type/converter.rbs +79 -0
  120. data/sig/revox/internal/type/enum.rbs +32 -0
  121. data/sig/revox/internal/type/file_input.rbs +25 -0
  122. data/sig/revox/internal/type/hash_of.rbs +48 -0
  123. data/sig/revox/internal/type/request_parameters.rbs +17 -0
  124. data/sig/revox/internal/type/union.rbs +52 -0
  125. data/sig/revox/internal/type/unknown.rbs +26 -0
  126. data/sig/revox/internal/util.rbs +185 -0
  127. data/sig/revox/internal.rbs +9 -0
  128. data/sig/revox/models/assistant_create_params.rbs +413 -0
  129. data/sig/revox/models/assistant_create_response.rbs +461 -0
  130. data/sig/revox/models/assistant_delete_params.rbs +15 -0
  131. data/sig/revox/models/assistant_delete_response.rbs +13 -0
  132. data/sig/revox/models/assistant_list_params.rbs +15 -0
  133. data/sig/revox/models/assistant_list_response.rbs +461 -0
  134. data/sig/revox/models/assistant_retrieve_params.rbs +15 -0
  135. data/sig/revox/models/assistant_retrieve_response.rbs +446 -0
  136. data/sig/revox/models/assistant_update_params.rbs +417 -0
  137. data/sig/revox/models/assistant_update_response.rbs +461 -0
  138. data/sig/revox/models/call_create_params.rbs +507 -0
  139. data/sig/revox/models/call_create_response.rbs +551 -0
  140. data/sig/revox/models/call_list_params.rbs +28 -0
  141. data/sig/revox/models/call_list_response.rbs +171 -0
  142. data/sig/revox/models/call_retrieve_params.rbs +14 -0
  143. data/sig/revox/models/call_retrieve_response.rbs +551 -0
  144. data/sig/revox/models/users/me_retrieve_params.rbs +16 -0
  145. data/sig/revox/models/users/me_retrieve_response.rbs +70 -0
  146. data/sig/revox/models/users/me_update_params.rbs +28 -0
  147. data/sig/revox/models/users/me_update_response.rbs +70 -0
  148. data/sig/revox/models/voice_list_params.rbs +14 -0
  149. data/sig/revox/models/voice_list_response.rbs +83 -0
  150. data/sig/revox/models/voice_preview_params.rbs +49 -0
  151. data/sig/revox/models/voice_retrieve_params.rbs +35 -0
  152. data/sig/revox/models/voice_retrieve_response.rbs +32 -0
  153. data/sig/revox/models.rbs +25 -0
  154. data/sig/revox/request_options.rbs +34 -0
  155. data/sig/revox/resources/assistants.rbs +66 -0
  156. data/sig/revox/resources/call.rbs +31 -0
  157. data/sig/revox/resources/users/me.rbs +18 -0
  158. data/sig/revox/resources/users.rbs +9 -0
  159. data/sig/revox/resources/voices.rbs +24 -0
  160. data/sig/revox/version.rbs +3 -0
  161. metadata +232 -0
@@ -0,0 +1,935 @@
1
+ # typed: strong
2
+
3
+ module Revox
4
+ module Models
5
+ class AssistantUpdateParams < Revox::Internal::Type::BaseModel
6
+ extend Revox::Internal::Type::RequestParameters::Converter
7
+ include Revox::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(Revox::AssistantUpdateParams, Revox::Internal::AnyHash)
12
+ end
13
+
14
+ # The background sound to play during the call. Useful to give the impression that
15
+ # your AI agent is in an office, in the street, or anywhere else you want.
16
+ sig do
17
+ returns(
18
+ T.nilable(Revox::AssistantUpdateParams::BackgroundSound::OrSymbol)
19
+ )
20
+ end
21
+ attr_accessor :background_sound
22
+
23
+ sig { returns(T.nilable(Revox::AssistantUpdateParams::Calendly)) }
24
+ attr_reader :calendly
25
+
26
+ sig do
27
+ params(
28
+ calendly: T.nilable(Revox::AssistantUpdateParams::Calendly::OrHash)
29
+ ).void
30
+ end
31
+ attr_writer :calendly
32
+
33
+ # Configuration for call retry behavior including time windows, delays, and max
34
+ # iterations. If not provided, defaults will be used.
35
+ sig { returns(T.nilable(Revox::AssistantUpdateParams::CallRetryConfig)) }
36
+ attr_reader :call_retry_config
37
+
38
+ sig do
39
+ params(
40
+ call_retry_config:
41
+ Revox::AssistantUpdateParams::CallRetryConfig::OrHash
42
+ ).void
43
+ end
44
+ attr_writer :call_retry_config
45
+
46
+ # Optional message to say when the agent decides to end the call.
47
+ sig { returns(T.nilable(String)) }
48
+ attr_reader :end_of_call_sentence
49
+
50
+ sig { params(end_of_call_sentence: String).void }
51
+ attr_writer :end_of_call_sentence
52
+
53
+ # FAQ items to associate with this assistant. When provided, replaces all existing
54
+ # FAQ items.
55
+ sig do
56
+ returns(T.nilable(T::Array[Revox::AssistantUpdateParams::FaqItem]))
57
+ end
58
+ attr_reader :faq_items
59
+
60
+ sig do
61
+ params(
62
+ faq_items: T::Array[Revox::AssistantUpdateParams::FaqItem::OrHash]
63
+ ).void
64
+ end
65
+ attr_writer :faq_items
66
+
67
+ # The first sentence to use for the call. This will be given to the LLM
68
+ sig { returns(T.nilable(String)) }
69
+ attr_reader :first_sentence
70
+
71
+ sig { params(first_sentence: String).void }
72
+ attr_writer :first_sentence
73
+
74
+ # Delay in milliseconds before speaking the first sentence. Default: 400.
75
+ sig { returns(T.nilable(Integer)) }
76
+ attr_reader :first_sentence_delay_ms
77
+
78
+ sig { params(first_sentence_delay_ms: Integer).void }
79
+ attr_writer :first_sentence_delay_ms
80
+
81
+ # How the first sentence should be handled. "generated" means the LLM will
82
+ # generate a response based on the first_sentence instruction. "static" means the
83
+ # first_sentence will be spoken exactly as provided. "none" means the agent will
84
+ # not speak first and will wait for the user.
85
+ sig do
86
+ returns(
87
+ T.nilable(Revox::AssistantUpdateParams::FirstSentenceMode::OrSymbol)
88
+ )
89
+ end
90
+ attr_reader :first_sentence_mode
91
+
92
+ sig do
93
+ params(
94
+ first_sentence_mode:
95
+ Revox::AssistantUpdateParams::FirstSentenceMode::OrSymbol
96
+ ).void
97
+ end
98
+ attr_writer :first_sentence_mode
99
+
100
+ # Enable IVR navigation tools. When enabled, the assistant can send DTMF tones and
101
+ # skip turns to navigate phone menus.
102
+ sig { returns(T.nilable(T::Boolean)) }
103
+ attr_reader :ivr_navigation_enabled
104
+
105
+ sig { params(ivr_navigation_enabled: T::Boolean).void }
106
+ attr_writer :ivr_navigation_enabled
107
+
108
+ sig do
109
+ returns(
110
+ T.nilable(
111
+ T.any(
112
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0,
113
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1
114
+ )
115
+ )
116
+ )
117
+ end
118
+ attr_reader :llm_model
119
+
120
+ sig do
121
+ params(
122
+ llm_model:
123
+ T.any(
124
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::OrHash,
125
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1::OrHash
126
+ )
127
+ ).void
128
+ end
129
+ attr_writer :llm_model
130
+
131
+ # The maximum duration of the call in seconds. This is the maximum time the call
132
+ # will be allowed to run.
133
+ sig { returns(T.nilable(Float)) }
134
+ attr_reader :max_call_duration_secs
135
+
136
+ sig { params(max_call_duration_secs: Float).void }
137
+ attr_writer :max_call_duration_secs
138
+
139
+ sig { returns(T.nilable(String)) }
140
+ attr_reader :name
141
+
142
+ sig { params(name: String).void }
143
+ attr_writer :name
144
+
145
+ # The prompt to use for the call. This will be given to the LLM (gpt-4.1)
146
+ sig { returns(T.nilable(String)) }
147
+ attr_reader :prompt
148
+
149
+ sig { params(prompt: String).void }
150
+ attr_writer :prompt
151
+
152
+ # The structured output config to use for the call. This is used to extract the
153
+ # data from the call (like email, name, company name, etc.).
154
+ sig do
155
+ returns(
156
+ T.nilable(
157
+ T::Array[Revox::AssistantUpdateParams::StructuredOutputConfig]
158
+ )
159
+ )
160
+ end
161
+ attr_reader :structured_output_config
162
+
163
+ sig do
164
+ params(
165
+ structured_output_config:
166
+ T::Array[
167
+ Revox::AssistantUpdateParams::StructuredOutputConfig::OrHash
168
+ ]
169
+ ).void
170
+ end
171
+ attr_writer :structured_output_config
172
+
173
+ # Phone number to transfer calls to when users request to speak to a human agent
174
+ # in E.164 format (e.g. +1234567890).
175
+ sig { returns(T.nilable(String)) }
176
+ attr_accessor :transfer_phone_number
177
+
178
+ # The voice to use for the call. You can get the list of voices using the /voices
179
+ # endpoint
180
+ sig { returns(T.nilable(Revox::AssistantUpdateParams::Voice)) }
181
+ attr_reader :voice
182
+
183
+ sig { params(voice: Revox::AssistantUpdateParams::Voice::OrHash).void }
184
+ attr_writer :voice
185
+
186
+ # If set, when voicemail is detected the agent will speak this message then hang
187
+ # up; if null, hang up immediately.
188
+ sig { returns(T.nilable(String)) }
189
+ attr_accessor :voicemail_message
190
+
191
+ # The webhook URL to call when the call is completed.
192
+ sig { returns(T.nilable(String)) }
193
+ attr_reader :webhook_url
194
+
195
+ sig { params(webhook_url: String).void }
196
+ attr_writer :webhook_url
197
+
198
+ sig do
199
+ params(
200
+ background_sound:
201
+ T.nilable(Revox::AssistantUpdateParams::BackgroundSound::OrSymbol),
202
+ calendly: T.nilable(Revox::AssistantUpdateParams::Calendly::OrHash),
203
+ call_retry_config:
204
+ Revox::AssistantUpdateParams::CallRetryConfig::OrHash,
205
+ end_of_call_sentence: String,
206
+ faq_items: T::Array[Revox::AssistantUpdateParams::FaqItem::OrHash],
207
+ first_sentence: String,
208
+ first_sentence_delay_ms: Integer,
209
+ first_sentence_mode:
210
+ Revox::AssistantUpdateParams::FirstSentenceMode::OrSymbol,
211
+ ivr_navigation_enabled: T::Boolean,
212
+ llm_model:
213
+ T.any(
214
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::OrHash,
215
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1::OrHash
216
+ ),
217
+ max_call_duration_secs: Float,
218
+ name: String,
219
+ prompt: String,
220
+ structured_output_config:
221
+ T::Array[
222
+ Revox::AssistantUpdateParams::StructuredOutputConfig::OrHash
223
+ ],
224
+ transfer_phone_number: T.nilable(String),
225
+ voice: Revox::AssistantUpdateParams::Voice::OrHash,
226
+ voicemail_message: T.nilable(String),
227
+ webhook_url: String,
228
+ request_options: Revox::RequestOptions::OrHash
229
+ ).returns(T.attached_class)
230
+ end
231
+ def self.new(
232
+ # The background sound to play during the call. Useful to give the impression that
233
+ # your AI agent is in an office, in the street, or anywhere else you want.
234
+ background_sound: nil,
235
+ calendly: nil,
236
+ # Configuration for call retry behavior including time windows, delays, and max
237
+ # iterations. If not provided, defaults will be used.
238
+ call_retry_config: nil,
239
+ # Optional message to say when the agent decides to end the call.
240
+ end_of_call_sentence: nil,
241
+ # FAQ items to associate with this assistant. When provided, replaces all existing
242
+ # FAQ items.
243
+ faq_items: nil,
244
+ # The first sentence to use for the call. This will be given to the LLM
245
+ first_sentence: nil,
246
+ # Delay in milliseconds before speaking the first sentence. Default: 400.
247
+ first_sentence_delay_ms: nil,
248
+ # How the first sentence should be handled. "generated" means the LLM will
249
+ # generate a response based on the first_sentence instruction. "static" means the
250
+ # first_sentence will be spoken exactly as provided. "none" means the agent will
251
+ # not speak first and will wait for the user.
252
+ first_sentence_mode: nil,
253
+ # Enable IVR navigation tools. When enabled, the assistant can send DTMF tones and
254
+ # skip turns to navigate phone menus.
255
+ ivr_navigation_enabled: nil,
256
+ llm_model: nil,
257
+ # The maximum duration of the call in seconds. This is the maximum time the call
258
+ # will be allowed to run.
259
+ max_call_duration_secs: nil,
260
+ name: nil,
261
+ # The prompt to use for the call. This will be given to the LLM (gpt-4.1)
262
+ prompt: nil,
263
+ # The structured output config to use for the call. This is used to extract the
264
+ # data from the call (like email, name, company name, etc.).
265
+ structured_output_config: nil,
266
+ # Phone number to transfer calls to when users request to speak to a human agent
267
+ # in E.164 format (e.g. +1234567890).
268
+ transfer_phone_number: nil,
269
+ # The voice to use for the call. You can get the list of voices using the /voices
270
+ # endpoint
271
+ voice: nil,
272
+ # If set, when voicemail is detected the agent will speak this message then hang
273
+ # up; if null, hang up immediately.
274
+ voicemail_message: nil,
275
+ # The webhook URL to call when the call is completed.
276
+ webhook_url: nil,
277
+ request_options: {}
278
+ )
279
+ end
280
+
281
+ sig do
282
+ override.returns(
283
+ {
284
+ background_sound:
285
+ T.nilable(
286
+ Revox::AssistantUpdateParams::BackgroundSound::OrSymbol
287
+ ),
288
+ calendly: T.nilable(Revox::AssistantUpdateParams::Calendly),
289
+ call_retry_config: Revox::AssistantUpdateParams::CallRetryConfig,
290
+ end_of_call_sentence: String,
291
+ faq_items: T::Array[Revox::AssistantUpdateParams::FaqItem],
292
+ first_sentence: String,
293
+ first_sentence_delay_ms: Integer,
294
+ first_sentence_mode:
295
+ Revox::AssistantUpdateParams::FirstSentenceMode::OrSymbol,
296
+ ivr_navigation_enabled: T::Boolean,
297
+ llm_model:
298
+ T.any(
299
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0,
300
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1
301
+ ),
302
+ max_call_duration_secs: Float,
303
+ name: String,
304
+ prompt: String,
305
+ structured_output_config:
306
+ T::Array[Revox::AssistantUpdateParams::StructuredOutputConfig],
307
+ transfer_phone_number: T.nilable(String),
308
+ voice: Revox::AssistantUpdateParams::Voice,
309
+ voicemail_message: T.nilable(String),
310
+ webhook_url: String,
311
+ request_options: Revox::RequestOptions
312
+ }
313
+ )
314
+ end
315
+ def to_hash
316
+ end
317
+
318
+ # The background sound to play during the call. Useful to give the impression that
319
+ # your AI agent is in an office, in the street, or anywhere else you want.
320
+ module BackgroundSound
321
+ extend Revox::Internal::Type::Enum
322
+
323
+ TaggedSymbol =
324
+ T.type_alias do
325
+ T.all(Symbol, Revox::AssistantUpdateParams::BackgroundSound)
326
+ end
327
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
328
+
329
+ AUDIO_OFFICE_OGG =
330
+ T.let(
331
+ :"audio/office.ogg",
332
+ Revox::AssistantUpdateParams::BackgroundSound::TaggedSymbol
333
+ )
334
+
335
+ sig do
336
+ override.returns(
337
+ T::Array[
338
+ Revox::AssistantUpdateParams::BackgroundSound::TaggedSymbol
339
+ ]
340
+ )
341
+ end
342
+ def self.values
343
+ end
344
+ end
345
+
346
+ class Calendly < Revox::Internal::Type::BaseModel
347
+ OrHash =
348
+ T.type_alias do
349
+ T.any(
350
+ Revox::AssistantUpdateParams::Calendly,
351
+ Revox::Internal::AnyHash
352
+ )
353
+ end
354
+
355
+ # The connection ID representing the link between your Calendly account and Revox.
356
+ sig { returns(String) }
357
+ attr_accessor :connection_id
358
+
359
+ # The event type ID representing the event type to schedule. (eg:
360
+ # https://api.calendly.com/event_types/b2330295-2a91-4a1d-bb73-99e7707663d5)
361
+ sig { returns(String) }
362
+ attr_accessor :event_type_id
363
+
364
+ sig do
365
+ params(connection_id: String, event_type_id: String).returns(
366
+ T.attached_class
367
+ )
368
+ end
369
+ def self.new(
370
+ # The connection ID representing the link between your Calendly account and Revox.
371
+ connection_id:,
372
+ # The event type ID representing the event type to schedule. (eg:
373
+ # https://api.calendly.com/event_types/b2330295-2a91-4a1d-bb73-99e7707663d5)
374
+ event_type_id:
375
+ )
376
+ end
377
+
378
+ sig do
379
+ override.returns({ connection_id: String, event_type_id: String })
380
+ end
381
+ def to_hash
382
+ end
383
+ end
384
+
385
+ class CallRetryConfig < Revox::Internal::Type::BaseModel
386
+ OrHash =
387
+ T.type_alias do
388
+ T.any(
389
+ Revox::AssistantUpdateParams::CallRetryConfig,
390
+ Revox::Internal::AnyHash
391
+ )
392
+ end
393
+
394
+ sig do
395
+ returns(
396
+ T::Array[
397
+ Revox::AssistantUpdateParams::CallRetryConfig::CallingWindow
398
+ ]
399
+ )
400
+ end
401
+ attr_accessor :calling_windows
402
+
403
+ # Maximum number of call retry attempts. Default: 3.
404
+ sig { returns(Integer) }
405
+ attr_accessor :max_retry_attempts
406
+
407
+ # Optional IANA timezone identifier to override the automatic timezone detection
408
+ # from phone number. If not provided, timezone is determined from the recipient's
409
+ # phone number country code. Examples: 'America/New_York', 'Europe/Paris'.
410
+ sig { returns(T.nilable(String)) }
411
+ attr_accessor :timezone
412
+
413
+ # Configuration for call retry behavior including time windows, delays, and max
414
+ # iterations. If not provided, defaults will be used.
415
+ sig do
416
+ params(
417
+ calling_windows:
418
+ T::Array[
419
+ Revox::AssistantUpdateParams::CallRetryConfig::CallingWindow::OrHash
420
+ ],
421
+ max_retry_attempts: Integer,
422
+ timezone: T.nilable(String)
423
+ ).returns(T.attached_class)
424
+ end
425
+ def self.new(
426
+ calling_windows:,
427
+ # Maximum number of call retry attempts. Default: 3.
428
+ max_retry_attempts:,
429
+ # Optional IANA timezone identifier to override the automatic timezone detection
430
+ # from phone number. If not provided, timezone is determined from the recipient's
431
+ # phone number country code. Examples: 'America/New_York', 'Europe/Paris'.
432
+ timezone: nil
433
+ )
434
+ end
435
+
436
+ sig do
437
+ override.returns(
438
+ {
439
+ calling_windows:
440
+ T::Array[
441
+ Revox::AssistantUpdateParams::CallRetryConfig::CallingWindow
442
+ ],
443
+ max_retry_attempts: Integer,
444
+ timezone: T.nilable(String)
445
+ }
446
+ )
447
+ end
448
+ def to_hash
449
+ end
450
+
451
+ class CallingWindow < Revox::Internal::Type::BaseModel
452
+ OrHash =
453
+ T.type_alias do
454
+ T.any(
455
+ Revox::AssistantUpdateParams::CallRetryConfig::CallingWindow,
456
+ Revox::Internal::AnyHash
457
+ )
458
+ end
459
+
460
+ # End time for the calling window in the recipient's timezone (or
461
+ # timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
462
+ # Examples: '17:00', '6pm'. Default: '18:00'.
463
+ sig { returns(String) }
464
+ attr_accessor :calling_window_end_time
465
+
466
+ # Start time for the calling window in the recipient's timezone (or
467
+ # timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
468
+ # Examples: '09:00', '10am'. Default: '10:00'.
469
+ sig { returns(String) }
470
+ attr_accessor :calling_window_start_time
471
+
472
+ # Delay between retry attempts in seconds. Default: 7200 (2 hours).
473
+ sig { returns(Integer) }
474
+ attr_accessor :retry_delay_seconds
475
+
476
+ sig do
477
+ params(
478
+ calling_window_end_time: String,
479
+ calling_window_start_time: String,
480
+ retry_delay_seconds: Integer
481
+ ).returns(T.attached_class)
482
+ end
483
+ def self.new(
484
+ # End time for the calling window in the recipient's timezone (or
485
+ # timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
486
+ # Examples: '17:00', '6pm'. Default: '18:00'.
487
+ calling_window_end_time:,
488
+ # Start time for the calling window in the recipient's timezone (or
489
+ # timezone_override if provided). Format: 'HH:mm' (24-hour) or 'H:mma' (12-hour).
490
+ # Examples: '09:00', '10am'. Default: '10:00'.
491
+ calling_window_start_time:,
492
+ # Delay between retry attempts in seconds. Default: 7200 (2 hours).
493
+ retry_delay_seconds:
494
+ )
495
+ end
496
+
497
+ sig do
498
+ override.returns(
499
+ {
500
+ calling_window_end_time: String,
501
+ calling_window_start_time: String,
502
+ retry_delay_seconds: Integer
503
+ }
504
+ )
505
+ end
506
+ def to_hash
507
+ end
508
+ end
509
+ end
510
+
511
+ class FaqItem < Revox::Internal::Type::BaseModel
512
+ OrHash =
513
+ T.type_alias do
514
+ T.any(
515
+ Revox::AssistantUpdateParams::FaqItem,
516
+ Revox::Internal::AnyHash
517
+ )
518
+ end
519
+
520
+ sig { returns(String) }
521
+ attr_accessor :answer
522
+
523
+ sig { returns(String) }
524
+ attr_accessor :question
525
+
526
+ sig do
527
+ params(answer: String, question: String).returns(T.attached_class)
528
+ end
529
+ def self.new(answer:, question:)
530
+ end
531
+
532
+ sig { override.returns({ answer: String, question: String }) }
533
+ def to_hash
534
+ end
535
+ end
536
+
537
+ # How the first sentence should be handled. "generated" means the LLM will
538
+ # generate a response based on the first_sentence instruction. "static" means the
539
+ # first_sentence will be spoken exactly as provided. "none" means the agent will
540
+ # not speak first and will wait for the user.
541
+ module FirstSentenceMode
542
+ extend Revox::Internal::Type::Enum
543
+
544
+ TaggedSymbol =
545
+ T.type_alias do
546
+ T.all(Symbol, Revox::AssistantUpdateParams::FirstSentenceMode)
547
+ end
548
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
549
+
550
+ GENERATED =
551
+ T.let(
552
+ :generated,
553
+ Revox::AssistantUpdateParams::FirstSentenceMode::TaggedSymbol
554
+ )
555
+ STATIC =
556
+ T.let(
557
+ :static,
558
+ Revox::AssistantUpdateParams::FirstSentenceMode::TaggedSymbol
559
+ )
560
+ NONE =
561
+ T.let(
562
+ :none,
563
+ Revox::AssistantUpdateParams::FirstSentenceMode::TaggedSymbol
564
+ )
565
+
566
+ sig do
567
+ override.returns(
568
+ T::Array[
569
+ Revox::AssistantUpdateParams::FirstSentenceMode::TaggedSymbol
570
+ ]
571
+ )
572
+ end
573
+ def self.values
574
+ end
575
+ end
576
+
577
+ module LlmModel
578
+ extend Revox::Internal::Type::Union
579
+
580
+ Variants =
581
+ T.type_alias do
582
+ T.any(
583
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0,
584
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1
585
+ )
586
+ end
587
+
588
+ class UnionMember0 < Revox::Internal::Type::BaseModel
589
+ OrHash =
590
+ T.type_alias do
591
+ T.any(
592
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0,
593
+ Revox::Internal::AnyHash
594
+ )
595
+ end
596
+
597
+ sig do
598
+ returns(
599
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::OrSymbol
600
+ )
601
+ end
602
+ attr_accessor :name
603
+
604
+ sig { returns(Symbol) }
605
+ attr_accessor :type
606
+
607
+ sig do
608
+ params(
609
+ name:
610
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::OrSymbol,
611
+ type: Symbol
612
+ ).returns(T.attached_class)
613
+ end
614
+ def self.new(name:, type: :"dedicated-instance")
615
+ end
616
+
617
+ sig do
618
+ override.returns(
619
+ {
620
+ name:
621
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::OrSymbol,
622
+ type: Symbol
623
+ }
624
+ )
625
+ end
626
+ def to_hash
627
+ end
628
+
629
+ module Name
630
+ extend Revox::Internal::Type::Enum
631
+
632
+ TaggedSymbol =
633
+ T.type_alias do
634
+ T.all(
635
+ Symbol,
636
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name
637
+ )
638
+ end
639
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
640
+
641
+ GPT_4_1 =
642
+ T.let(
643
+ :"gpt-4.1",
644
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::TaggedSymbol
645
+ )
646
+ MINISTRAL_3_8B_INSTRUCT =
647
+ T.let(
648
+ :"ministral-3-8b-instruct",
649
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::TaggedSymbol
650
+ )
651
+
652
+ sig do
653
+ override.returns(
654
+ T::Array[
655
+ Revox::AssistantUpdateParams::LlmModel::UnionMember0::Name::TaggedSymbol
656
+ ]
657
+ )
658
+ end
659
+ def self.values
660
+ end
661
+ end
662
+ end
663
+
664
+ class UnionMember1 < Revox::Internal::Type::BaseModel
665
+ OrHash =
666
+ T.type_alias do
667
+ T.any(
668
+ Revox::AssistantUpdateParams::LlmModel::UnionMember1,
669
+ Revox::Internal::AnyHash
670
+ )
671
+ end
672
+
673
+ # The model ID to use from OpenRouter. eg: openai/gpt-4.1
674
+ sig { returns(String) }
675
+ attr_accessor :openrouter_model_id
676
+
677
+ # The provider to use from OpenRouter. eg: nebius, openai, azure, etc.
678
+ sig { returns(String) }
679
+ attr_accessor :openrouter_provider
680
+
681
+ # Use a model from OpenRouter.
682
+ sig { returns(Symbol) }
683
+ attr_accessor :type
684
+
685
+ sig do
686
+ params(
687
+ openrouter_model_id: String,
688
+ openrouter_provider: String,
689
+ type: Symbol
690
+ ).returns(T.attached_class)
691
+ end
692
+ def self.new(
693
+ # The model ID to use from OpenRouter. eg: openai/gpt-4.1
694
+ openrouter_model_id:,
695
+ # The provider to use from OpenRouter. eg: nebius, openai, azure, etc.
696
+ openrouter_provider:,
697
+ # Use a model from OpenRouter.
698
+ type: :openrouter
699
+ )
700
+ end
701
+
702
+ sig do
703
+ override.returns(
704
+ {
705
+ openrouter_model_id: String,
706
+ openrouter_provider: String,
707
+ type: Symbol
708
+ }
709
+ )
710
+ end
711
+ def to_hash
712
+ end
713
+ end
714
+
715
+ sig do
716
+ override.returns(
717
+ T::Array[Revox::AssistantUpdateParams::LlmModel::Variants]
718
+ )
719
+ end
720
+ def self.variants
721
+ end
722
+ end
723
+
724
+ class StructuredOutputConfig < Revox::Internal::Type::BaseModel
725
+ OrHash =
726
+ T.type_alias do
727
+ T.any(
728
+ Revox::AssistantUpdateParams::StructuredOutputConfig,
729
+ Revox::Internal::AnyHash
730
+ )
731
+ end
732
+
733
+ sig { returns(String) }
734
+ attr_accessor :name
735
+
736
+ sig { returns(T::Boolean) }
737
+ attr_accessor :required
738
+
739
+ sig do
740
+ returns(
741
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::OrSymbol
742
+ )
743
+ end
744
+ attr_accessor :type
745
+
746
+ sig { returns(T.nilable(String)) }
747
+ attr_reader :description
748
+
749
+ sig { params(description: String).void }
750
+ attr_writer :description
751
+
752
+ sig { returns(T.nilable(T::Array[String])) }
753
+ attr_reader :enum_options
754
+
755
+ sig { params(enum_options: T::Array[String]).void }
756
+ attr_writer :enum_options
757
+
758
+ sig do
759
+ params(
760
+ name: String,
761
+ required: T::Boolean,
762
+ type:
763
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::OrSymbol,
764
+ description: String,
765
+ enum_options: T::Array[String]
766
+ ).returns(T.attached_class)
767
+ end
768
+ def self.new(
769
+ name:,
770
+ required:,
771
+ type:,
772
+ description: nil,
773
+ enum_options: nil
774
+ )
775
+ end
776
+
777
+ sig do
778
+ override.returns(
779
+ {
780
+ name: String,
781
+ required: T::Boolean,
782
+ type:
783
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::OrSymbol,
784
+ description: String,
785
+ enum_options: T::Array[String]
786
+ }
787
+ )
788
+ end
789
+ def to_hash
790
+ end
791
+
792
+ module Type
793
+ extend Revox::Internal::Type::Enum
794
+
795
+ TaggedSymbol =
796
+ T.type_alias do
797
+ T.all(
798
+ Symbol,
799
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type
800
+ )
801
+ end
802
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
803
+
804
+ STRING =
805
+ T.let(
806
+ :string,
807
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
808
+ )
809
+ NUMBER =
810
+ T.let(
811
+ :number,
812
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
813
+ )
814
+ BOOLEAN =
815
+ T.let(
816
+ :boolean,
817
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
818
+ )
819
+ ENUM =
820
+ T.let(
821
+ :enum,
822
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
823
+ )
824
+ DATE =
825
+ T.let(
826
+ :date,
827
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
828
+ )
829
+ DATETIME =
830
+ T.let(
831
+ :datetime,
832
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
833
+ )
834
+
835
+ sig do
836
+ override.returns(
837
+ T::Array[
838
+ Revox::AssistantUpdateParams::StructuredOutputConfig::Type::TaggedSymbol
839
+ ]
840
+ )
841
+ end
842
+ def self.values
843
+ end
844
+ end
845
+ end
846
+
847
+ class Voice < Revox::Internal::Type::BaseModel
848
+ OrHash =
849
+ T.type_alias do
850
+ T.any(Revox::AssistantUpdateParams::Voice, Revox::Internal::AnyHash)
851
+ end
852
+
853
+ # The ID of the voice.
854
+ sig { returns(String) }
855
+ attr_accessor :id
856
+
857
+ # The provider of the voice.
858
+ sig { returns(Revox::AssistantUpdateParams::Voice::Provider::OrSymbol) }
859
+ attr_accessor :provider
860
+
861
+ # The speed of the voice. Range depends on provider: Cartesia 0.6–1.5, ElevenLabs
862
+ # 0.7–1.2. Default is 1.0.
863
+ sig { returns(T.nilable(Float)) }
864
+ attr_reader :speed
865
+
866
+ sig { params(speed: Float).void }
867
+ attr_writer :speed
868
+
869
+ # The voice to use for the call. You can get the list of voices using the /voices
870
+ # endpoint
871
+ sig do
872
+ params(
873
+ id: String,
874
+ provider: Revox::AssistantUpdateParams::Voice::Provider::OrSymbol,
875
+ speed: Float
876
+ ).returns(T.attached_class)
877
+ end
878
+ def self.new(
879
+ # The ID of the voice.
880
+ id:,
881
+ # The provider of the voice.
882
+ provider:,
883
+ # The speed of the voice. Range depends on provider: Cartesia 0.6–1.5, ElevenLabs
884
+ # 0.7–1.2. Default is 1.0.
885
+ speed: nil
886
+ )
887
+ end
888
+
889
+ sig do
890
+ override.returns(
891
+ {
892
+ id: String,
893
+ provider: Revox::AssistantUpdateParams::Voice::Provider::OrSymbol,
894
+ speed: Float
895
+ }
896
+ )
897
+ end
898
+ def to_hash
899
+ end
900
+
901
+ # The provider of the voice.
902
+ module Provider
903
+ extend Revox::Internal::Type::Enum
904
+
905
+ TaggedSymbol =
906
+ T.type_alias do
907
+ T.all(Symbol, Revox::AssistantUpdateParams::Voice::Provider)
908
+ end
909
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
910
+
911
+ CARTESIA =
912
+ T.let(
913
+ :cartesia,
914
+ Revox::AssistantUpdateParams::Voice::Provider::TaggedSymbol
915
+ )
916
+ ELEVENLABS =
917
+ T.let(
918
+ :elevenlabs,
919
+ Revox::AssistantUpdateParams::Voice::Provider::TaggedSymbol
920
+ )
921
+
922
+ sig do
923
+ override.returns(
924
+ T::Array[
925
+ Revox::AssistantUpdateParams::Voice::Provider::TaggedSymbol
926
+ ]
927
+ )
928
+ end
929
+ def self.values
930
+ end
931
+ end
932
+ end
933
+ end
934
+ end
935
+ end