revox 0.0.2 → 0.2.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.
Files changed (128) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +96 -0
  3. data/README.md +88 -22
  4. data/lib/revox/client.rb +19 -1
  5. data/lib/revox/internal/transport/base_client.rb +5 -0
  6. data/lib/revox/internal/type/base_model.rb +3 -3
  7. data/lib/revox/internal/util.rb +53 -7
  8. data/lib/revox/models/assistant_create_params.rb +1036 -11
  9. data/lib/revox/models/assistant_create_response.rb +1071 -11
  10. data/lib/revox/models/assistant_delete_params.rb +7 -1
  11. data/lib/revox/models/assistant_list_response.rb +1070 -11
  12. data/lib/revox/models/assistant_retrieve_params.rb +7 -1
  13. data/lib/revox/models/assistant_retrieve_response.rb +1066 -11
  14. data/lib/revox/models/assistant_update_params.rb +1043 -11
  15. data/lib/revox/models/assistant_update_response.rb +1097 -12
  16. data/lib/revox/models/call_create_params.rb +1063 -11
  17. data/lib/revox/models/call_create_response.rb +2507 -87
  18. data/lib/revox/models/call_retrieve_params.rb +7 -1
  19. data/lib/revox/models/call_retrieve_response.rb +2512 -87
  20. data/lib/revox/models/campaign_cancel_params.rb +20 -0
  21. data/lib/revox/models/campaign_cancel_response.rb +16 -0
  22. data/lib/revox/models/campaign_create_params.rb +239 -0
  23. data/lib/revox/models/campaign_create_response.rb +2030 -0
  24. data/lib/revox/models/campaign_delete_params.rb +20 -0
  25. data/lib/revox/models/campaign_delete_response.rb +16 -0
  26. data/lib/revox/models/campaign_export_rows_params.rb +20 -0
  27. data/lib/revox/models/campaign_export_rows_response.rb +22 -0
  28. data/lib/revox/models/campaign_get_rows_params.rb +20 -0
  29. data/lib/revox/models/campaign_get_rows_response.rb +3176 -0
  30. data/lib/revox/models/campaign_list_params.rb +14 -0
  31. data/lib/revox/models/campaign_list_response.rb +2024 -0
  32. data/lib/revox/models/campaign_retrieve_params.rb +20 -0
  33. data/lib/revox/models/campaign_retrieve_response.rb +2032 -0
  34. data/lib/revox/models/users/me_retrieve_response.rb +13 -1
  35. data/lib/revox/models/users/me_update_response.rb +13 -1
  36. data/lib/revox/models/voice_list_response.rb +55 -1
  37. data/lib/revox/models/voice_preview_params.rb +43 -3
  38. data/lib/revox/models/voice_retrieve_params.rb +7 -1
  39. data/lib/revox/models.rb +14 -2
  40. data/lib/revox/resources/assistants.rb +138 -6
  41. data/lib/revox/resources/call.rb +10 -27
  42. data/lib/revox/resources/campaigns.rb +176 -0
  43. data/lib/revox/resources/voices.rb +17 -7
  44. data/lib/revox/version.rb +1 -1
  45. data/lib/revox.rb +15 -2
  46. data/rbi/revox/client.rbi +3 -0
  47. data/rbi/revox/internal/util.rbi +28 -0
  48. data/rbi/revox/models/assistant_create_params.rbi +2135 -102
  49. data/rbi/revox/models/assistant_create_response.rbi +2454 -199
  50. data/rbi/revox/models/assistant_delete_params.rbi +11 -5
  51. data/rbi/revox/models/assistant_list_response.rbi +2448 -195
  52. data/rbi/revox/models/assistant_retrieve_params.rbi +11 -5
  53. data/rbi/revox/models/assistant_retrieve_response.rbi +2401 -210
  54. data/rbi/revox/models/assistant_update_params.rbi +2139 -100
  55. data/rbi/revox/models/assistant_update_response.rbi +2504 -198
  56. data/rbi/revox/models/call_create_params.rbi +2377 -222
  57. data/rbi/revox/models/call_create_response.rbi +5840 -594
  58. data/rbi/revox/models/call_retrieve_params.rbi +11 -5
  59. data/rbi/revox/models/call_retrieve_response.rbi +5872 -618
  60. data/rbi/revox/models/campaign_cancel_params.rbi +33 -0
  61. data/rbi/revox/models/campaign_cancel_response.rbi +23 -0
  62. data/rbi/revox/models/campaign_create_params.rbi +433 -0
  63. data/rbi/revox/models/campaign_create_response.rbi +4170 -0
  64. data/rbi/revox/models/campaign_delete_params.rbi +33 -0
  65. data/rbi/revox/models/campaign_delete_response.rbi +23 -0
  66. data/rbi/revox/models/campaign_export_rows_params.rbi +33 -0
  67. data/rbi/revox/models/campaign_export_rows_response.rbi +29 -0
  68. data/rbi/revox/models/campaign_get_rows_params.rbi +33 -0
  69. data/rbi/revox/models/campaign_get_rows_response.rbi +6706 -0
  70. data/rbi/revox/models/campaign_list_params.rbi +27 -0
  71. data/rbi/revox/models/campaign_list_response.rbi +4156 -0
  72. data/rbi/revox/models/campaign_retrieve_params.rbi +33 -0
  73. data/rbi/revox/models/campaign_retrieve_response.rbi +4175 -0
  74. data/rbi/revox/models/users/me_retrieve_response.rbi +13 -3
  75. data/rbi/revox/models/users/me_update_response.rbi +13 -3
  76. data/rbi/revox/models/voice_list_response.rbi +105 -3
  77. data/rbi/revox/models/voice_preview_params.rbi +60 -2
  78. data/rbi/revox/models/voice_retrieve_params.rbi +6 -1
  79. data/rbi/revox/models.rbi +14 -2
  80. data/rbi/revox/resources/assistants.rbi +301 -6
  81. data/rbi/revox/resources/call.rbi +10 -19
  82. data/rbi/revox/resources/campaigns.rbi +121 -0
  83. data/rbi/revox/resources/voices.rbi +15 -5
  84. data/sig/revox/client.rbs +2 -0
  85. data/sig/revox/internal/util.rbs +14 -0
  86. data/sig/revox/models/assistant_create_params.rbs +841 -4
  87. data/sig/revox/models/assistant_create_response.rbs +860 -3
  88. data/sig/revox/models/assistant_delete_params.rbs +8 -3
  89. data/sig/revox/models/assistant_list_response.rbs +860 -3
  90. data/sig/revox/models/assistant_retrieve_params.rbs +8 -3
  91. data/sig/revox/models/assistant_retrieve_response.rbs +859 -3
  92. data/sig/revox/models/assistant_update_params.rbs +846 -4
  93. data/sig/revox/models/assistant_update_response.rbs +886 -6
  94. data/sig/revox/models/call_create_params.rbs +844 -6
  95. data/sig/revox/models/call_create_response.rbs +2166 -79
  96. data/sig/revox/models/call_retrieve_params.rbs +9 -3
  97. data/sig/revox/models/call_retrieve_response.rbs +2166 -79
  98. data/sig/revox/models/campaign_cancel_params.rbs +20 -0
  99. data/sig/revox/models/campaign_cancel_response.rbs +13 -0
  100. data/sig/revox/models/campaign_create_params.rbs +203 -0
  101. data/sig/revox/models/campaign_create_response.rbs +1694 -0
  102. data/sig/revox/models/campaign_delete_params.rbs +20 -0
  103. data/sig/revox/models/campaign_delete_response.rbs +13 -0
  104. data/sig/revox/models/campaign_export_rows_params.rbs +20 -0
  105. data/sig/revox/models/campaign_export_rows_response.rbs +15 -0
  106. data/sig/revox/models/campaign_get_rows_params.rbs +20 -0
  107. data/sig/revox/models/campaign_get_rows_response.rbs +2688 -0
  108. data/sig/revox/models/campaign_list_params.rbs +14 -0
  109. data/sig/revox/models/campaign_list_response.rbs +1694 -0
  110. data/sig/revox/models/campaign_retrieve_params.rbs +20 -0
  111. data/sig/revox/models/campaign_retrieve_response.rbs +1694 -0
  112. data/sig/revox/models/users/me_retrieve_response.rbs +8 -3
  113. data/sig/revox/models/users/me_update_response.rbs +8 -3
  114. data/sig/revox/models/voice_list_response.rbs +45 -3
  115. data/sig/revox/models/voice_preview_params.rbs +35 -1
  116. data/sig/revox/models/voice_retrieve_params.rbs +5 -1
  117. data/sig/revox/models.rbs +14 -2
  118. data/sig/revox/resources/assistants.rbs +54 -0
  119. data/sig/revox/resources/call.rbs +0 -6
  120. data/sig/revox/resources/campaigns.rbs +49 -0
  121. data/sig/revox/resources/voices.rbs +3 -0
  122. metadata +47 -8
  123. data/lib/revox/models/call_list_params.rb +0 -29
  124. data/lib/revox/models/call_list_response.rb +0 -197
  125. data/rbi/revox/models/call_list_params.rbi +0 -47
  126. data/rbi/revox/models/call_list_response.rbi +0 -401
  127. data/sig/revox/models/call_list_params.rbs +0 -28
  128. data/sig/revox/models/call_list_response.rbs +0 -171
@@ -18,13 +18,35 @@ module Revox
18
18
  # @return [String]
19
19
  required :prompt, String
20
20
 
21
+ # @!attribute after_call_sms_outcomes
22
+ # Which call outcomes trigger the after-call SMS. When empty or null, no
23
+ # after-call SMS is sent. E.g. ["interested", "completed", "none"]. Use "none"
24
+ # when outcome is null.
25
+ #
26
+ # @return [Array<Symbol, Revox::Models::AssistantCreateParams::AfterCallSMSOutcome>, nil]
27
+ optional :after_call_sms_outcomes,
28
+ -> { Revox::Internal::Type::ArrayOf[enum: Revox::AssistantCreateParams::AfterCallSMSOutcome] },
29
+ nil?: true
30
+
31
+ # @!attribute after_call_sms_prompt
32
+ # Prompt / instructions for the after-call SMS. Supports {{variable}}
33
+ # placeholders. When null, no after-call SMS is sent.
34
+ #
35
+ # @return [String, nil]
36
+ optional :after_call_sms_prompt, String, nil?: true
37
+
21
38
  # @!attribute background_sound
22
- # The background sound to play during the call. Useful to give the impression that
23
- # your AI agent is in an office, in the street, or anywhere else you want.
39
+ # Ambient background sound to play during the call. null/omitted disables it.
24
40
  #
25
41
  # @return [Symbol, Revox::Models::AssistantCreateParams::BackgroundSound, nil]
26
42
  optional :background_sound, enum: -> { Revox::AssistantCreateParams::BackgroundSound }, nil?: true
27
43
 
44
+ # @!attribute background_sound_volume
45
+ # Volume of the ambient background sound (0 = silent, 1 = max).
46
+ #
47
+ # @return [Float, nil]
48
+ optional :background_sound_volume, Float
49
+
28
50
  # @!attribute calendly
29
51
  #
30
52
  # @return [Revox::Models::AssistantCreateParams::Calendly, nil]
@@ -37,6 +59,49 @@ module Revox
37
59
  # @return [Revox::Models::AssistantCreateParams::CallRetryConfig, nil]
38
60
  optional :call_retry_config, -> { Revox::AssistantCreateParams::CallRetryConfig }
39
61
 
62
+ # @!attribute cartesia_dictionary_pronunciation_id
63
+ # Optional Cartesia pronunciation dictionary ID to use for this assistant's calls.
64
+ # Set null to unlink it.
65
+ #
66
+ # @return [String, nil]
67
+ optional :cartesia_dictionary_pronunciation_id, String, nil?: true
68
+
69
+ # @!attribute custom_tools
70
+ # Custom API tools the assistant can call during conversations. Each tool defines
71
+ # an HTTP endpoint with variable substitution.
72
+ #
73
+ # @return [Array<Revox::Models::AssistantCreateParams::CustomTool>, nil]
74
+ optional :custom_tools,
75
+ -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::CustomTool] },
76
+ nil?: true
77
+
78
+ # @!attribute email_notification_address
79
+ # Email address(es) to receive notifications when a call ends with a matching
80
+ # outcome. Accepts a single email or a comma-separated list (e.g. "alice@x.com,
81
+ # bob@y.com").
82
+ #
83
+ # @return [String, nil]
84
+ optional :email_notification_address, String, nil?: true
85
+
86
+ # @!attribute email_notification_language
87
+ # The language used for the notification email content. One of "en" or "fr".
88
+ # Defaults to "en".
89
+ #
90
+ # @return [Symbol, Revox::Models::AssistantCreateParams::EmailNotificationLanguage, nil]
91
+ optional :email_notification_language,
92
+ enum: -> { Revox::AssistantCreateParams::EmailNotificationLanguage }
93
+
94
+ # @!attribute email_notification_outcomes
95
+ # Which call outcomes trigger an email notification. E.g. ["interested",
96
+ # "completed", "none"]. Use "none" when outcome is null.
97
+ #
98
+ # @return [Array<Symbol, Revox::Models::AssistantCreateParams::EmailNotificationOutcome>, nil]
99
+ optional :email_notification_outcomes,
100
+ -> {
101
+ Revox::Internal::Type::ArrayOf[enum: Revox::AssistantCreateParams::EmailNotificationOutcome]
102
+ },
103
+ nil?: true
104
+
40
105
  # @!attribute end_of_call_sentence
41
106
  # Optional message to say when the agent decides to end the call.
42
107
  #
@@ -71,6 +136,21 @@ module Revox
71
136
  # @return [Symbol, Revox::Models::AssistantCreateParams::FirstSentenceMode, nil]
72
137
  optional :first_sentence_mode, enum: -> { Revox::AssistantCreateParams::FirstSentenceMode }
73
138
 
139
+ # @!attribute from_phone_number
140
+ # Override the default outbound phone number for calls placed with this assistant.
141
+ # Must be a phone number owned by the organization in E.164 format (e.g.
142
+ # +1234567890). When null, the organization's default phone number is used.
143
+ #
144
+ # @return [String, nil]
145
+ optional :from_phone_number, String, nil?: true
146
+
147
+ # @!attribute human_transfer_mode
148
+ # When transfer_phone_number is set: "warm" (AI bridges) or "cold" (SIP REFER;
149
+ # trunk must allow REFER/PSTN). Omit or null when transfer is disabled.
150
+ #
151
+ # @return [Symbol, Revox::Models::AssistantCreateParams::HumanTransferMode, nil]
152
+ optional :human_transfer_mode, enum: -> { Revox::AssistantCreateParams::HumanTransferMode }, nil?: true
153
+
74
154
  # @!attribute ivr_navigation_enabled
75
155
  # Enable IVR navigation tools. When enabled, the assistant can send DTMF tones and
76
156
  # skip turns to navigate phone menus.
@@ -80,9 +160,16 @@ module Revox
80
160
 
81
161
  # @!attribute llm_model
82
162
  #
83
- # @return [Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1, nil]
163
+ # @return [Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1, Revox::Models::AssistantCreateParams::LlmModel::UnionMember2, Revox::Models::AssistantCreateParams::LlmModel::UnionMember3, nil]
84
164
  optional :llm_model, union: -> { Revox::AssistantCreateParams::LlmModel }
85
165
 
166
+ # @!attribute logo_url
167
+ # Public URL of the brand logo shown on the assistant's demo page. Upload a new
168
+ # logo via POST /assistants/:id/logo. Set explicitly to null to clear it.
169
+ #
170
+ # @return [String, nil]
171
+ optional :logo_url, String, nil?: true
172
+
86
173
  # @!attribute max_call_duration_secs
87
174
  # The maximum duration of the call in seconds. This is the maximum time the call
88
175
  # will be allowed to run.
@@ -90,6 +177,50 @@ module Revox
90
177
  # @return [Float, nil]
91
178
  optional :max_call_duration_secs, Float
92
179
 
180
+ # @!attribute max_duration_end_message
181
+ # Optional message the agent will say, without being interruptible, when the call
182
+ # reaches its max duration. Kept short so it fits inside the farewell buffer. If
183
+ # not set, the call ends silently.
184
+ #
185
+ # @return [String, nil]
186
+ optional :max_duration_end_message, String, nil?: true
187
+
188
+ # @!attribute position
189
+ # Canvas position of this assistant's node in its multi-step flow editor.
190
+ #
191
+ # @return [Revox::Models::AssistantCreateParams::Position, nil]
192
+ optional :position, -> { Revox::AssistantCreateParams::Position }, nil?: true
193
+
194
+ # @!attribute prompt_flow
195
+ # Visual prompt constructor data (nodes, edges, positions). Used by the UI to
196
+ # re-open the visual editor. Does not affect call behavior — the flattened prompt
197
+ # field is what the LLM receives.
198
+ #
199
+ # @return [Revox::Models::AssistantCreateParams::PromptFlow, nil]
200
+ optional :prompt_flow, -> { Revox::AssistantCreateParams::PromptFlow }, nil?: true
201
+
202
+ # @!attribute slack
203
+ # Slack notification config. When set, posts a message to the chosen channel after
204
+ # a call ends with one of the configured outcomes.
205
+ #
206
+ # @return [Revox::Models::AssistantCreateParams::Slack, nil]
207
+ optional :slack, -> { Revox::AssistantCreateParams::Slack }, nil?: true
208
+
209
+ # @!attribute sms_enabled
210
+ # Enable SMS tool during calls. When enabled, the agent can send SMS messages to
211
+ # the user on the call.
212
+ #
213
+ # @return [Boolean, nil]
214
+ optional :sms_enabled, Revox::Internal::Type::Boolean
215
+
216
+ # @!attribute sms_template
217
+ # Hardcoded SMS template to send during calls. When set, this exact text is sent
218
+ # instead of letting the agent generate the message. Supports {{variable}}
219
+ # placeholders.
220
+ #
221
+ # @return [String, nil]
222
+ optional :sms_template, String, nil?: true
223
+
93
224
  # @!attribute structured_output_config
94
225
  # The structured output config to use for the call. This is used to extract the
95
226
  # data from the call (like email, name, company name, etc.).
@@ -98,6 +229,49 @@ module Revox
98
229
  optional :structured_output_config,
99
230
  -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::StructuredOutputConfig] }
100
231
 
232
+ # @!attribute structured_output_prompt
233
+ # Custom prompt for structured data extraction. If not provided, a default prompt
234
+ # is used. Available variables: {{transcript}}, {{call_direction}},
235
+ # {{user_phone_number}}, {{agent_phone_number}}.
236
+ #
237
+ # @return [String, nil]
238
+ optional :structured_output_prompt, String, nil?: true
239
+
240
+ # @!attribute stt_context
241
+ # Assistant-level speech-to-text context: structured `general` key/value pairs
242
+ # plus a list of domain `terms`. Prompt-derived context is merged in without
243
+ # replacing existing entries.
244
+ #
245
+ # @return [Revox::Models::AssistantCreateParams::SttContext, nil]
246
+ optional :stt_context, -> { Revox::AssistantCreateParams::SttContext }, nil?: true
247
+
248
+ # @!attribute stt_model
249
+ # Transcriber (speech-to-text) model. Defaults to the newest Soniox realtime model
250
+ # when omitted.
251
+ #
252
+ # @return [Symbol, Revox::Models::AssistantCreateParams::SttModel, nil]
253
+ optional :stt_model, enum: -> { Revox::AssistantCreateParams::SttModel }
254
+
255
+ # @!attribute thinking_sound
256
+ # Audio clip to play while the agent is processing a response. One of the built-in
257
+ # LiveKit audio clips; null/omitted disables it.
258
+ #
259
+ # @return [Symbol, Revox::Models::AssistantCreateParams::ThinkingSound, nil]
260
+ optional :thinking_sound, enum: -> { Revox::AssistantCreateParams::ThinkingSound }, nil?: true
261
+
262
+ # @!attribute thinking_sound_probability
263
+ # Probability [0..1] that the thinking sound plays on any given turn; otherwise
264
+ # the agent is silent while thinking.
265
+ #
266
+ # @return [Float, nil]
267
+ optional :thinking_sound_probability, Float
268
+
269
+ # @!attribute thinking_sound_volume
270
+ # Volume of the thinking sound (0 = silent, 1 = max).
271
+ #
272
+ # @return [Float, nil]
273
+ optional :thinking_sound_volume, Float
274
+
101
275
  # @!attribute transfer_phone_number
102
276
  # Phone number to transfer calls to when users request to speak to a human agent
103
277
  # in E.164 format (e.g. +1234567890).
@@ -105,6 +279,15 @@ module Revox
105
279
  # @return [String, nil]
106
280
  optional :transfer_phone_number, String, nil?: true
107
281
 
282
+ # @!attribute type
283
+ # Assistant kind. 'standalone' (default) is a normal assistant, 'multi-step'
284
+ # orchestrates a flow of sub-assistants, 'sub-assistant' is a step inside a
285
+ # multi-step flow (hidden from the assistants list). Flow transitions are managed
286
+ # via the /assistants/:id/edges endpoints, not on the assistant itself.
287
+ #
288
+ # @return [Symbol, Revox::Models::AssistantCreateParams::Type, nil]
289
+ optional :type, enum: -> { Revox::AssistantCreateParams::Type }
290
+
108
291
  # @!attribute voice
109
292
  # The voice to use for the call. You can get the list of voices using the /voices
110
293
  # endpoint
@@ -119,13 +302,36 @@ module Revox
119
302
  # @return [String, nil]
120
303
  optional :voicemail_message, String, nil?: true
121
304
 
305
+ # @!attribute voicemail_sms_prompt
306
+ # SMS message to send when the call reaches voicemail. Supports {{variable}}
307
+ # placeholders. When null, no SMS is sent on voicemail.
308
+ #
309
+ # @return [String, nil]
310
+ optional :voicemail_sms_prompt, String, nil?: true
311
+
312
+ # @!attribute warm_transfer_summary_instructions
313
+ # When using warm transfer: extra instructions for the supervisor handoff summary.
314
+ # If null or empty, the API uses the product default briefing when the call is
315
+ # loaded for the agent.
316
+ #
317
+ # @return [String, nil]
318
+ optional :warm_transfer_summary_instructions, String, nil?: true
319
+
122
320
  # @!attribute webhook_url
123
321
  # The webhook URL to call when the call is completed.
124
322
  #
125
323
  # @return [String, nil]
126
324
  optional :webhook_url, String
127
325
 
128
- # @!method initialize(name:, prompt:, background_sound: nil, calendly: nil, call_retry_config: nil, end_of_call_sentence: nil, faq_items: nil, first_sentence: nil, first_sentence_delay_ms: nil, first_sentence_mode: nil, ivr_navigation_enabled: nil, llm_model: nil, max_call_duration_secs: nil, structured_output_config: nil, transfer_phone_number: nil, voice: nil, voicemail_message: nil, webhook_url: nil, request_options: {})
326
+ # @!attribute zoho
327
+ # Zoho CRM integration config. When set, upserts the prospect (keyed on phone)
328
+ # into the chosen module and attaches a Note with the call summary after a call
329
+ # ends with one of the configured outcomes.
330
+ #
331
+ # @return [Revox::Models::AssistantCreateParams::Zoho, nil]
332
+ optional :zoho, -> { Revox::AssistantCreateParams::Zoho }, nil?: true
333
+
334
+ # @!method initialize(name:, prompt:, after_call_sms_outcomes: nil, after_call_sms_prompt: nil, background_sound: nil, background_sound_volume: nil, calendly: nil, call_retry_config: nil, cartesia_dictionary_pronunciation_id: nil, custom_tools: nil, email_notification_address: nil, email_notification_language: nil, email_notification_outcomes: nil, end_of_call_sentence: nil, faq_items: nil, first_sentence: nil, first_sentence_delay_ms: nil, first_sentence_mode: nil, from_phone_number: nil, human_transfer_mode: nil, ivr_navigation_enabled: nil, llm_model: nil, logo_url: nil, max_call_duration_secs: nil, max_duration_end_message: nil, position: nil, prompt_flow: nil, slack: nil, sms_enabled: nil, sms_template: nil, structured_output_config: nil, structured_output_prompt: nil, stt_context: nil, stt_model: nil, thinking_sound: nil, thinking_sound_probability: nil, thinking_sound_volume: nil, transfer_phone_number: nil, type: nil, voice: nil, voicemail_message: nil, voicemail_sms_prompt: nil, warm_transfer_summary_instructions: nil, webhook_url: nil, zoho: nil, request_options: {})
129
335
  # Some parameter documentations has been truncated, see
130
336
  # {Revox::Models::AssistantCreateParams} for more details.
131
337
  #
@@ -133,12 +339,28 @@ module Revox
133
339
  #
134
340
  # @param prompt [String] The prompt to use for the call. This will be given to the LLM (gpt-4.1)
135
341
  #
136
- # @param background_sound [Symbol, Revox::Models::AssistantCreateParams::BackgroundSound, nil] The background sound to play during the call. Useful to give the impression that
342
+ # @param after_call_sms_outcomes [Array<Symbol, Revox::Models::AssistantCreateParams::AfterCallSMSOutcome>, nil] Which call outcomes trigger the after-call SMS. When empty or null, no after-cal
343
+ #
344
+ # @param after_call_sms_prompt [String, nil] Prompt / instructions for the after-call SMS. Supports {{variable}} placeholders
345
+ #
346
+ # @param background_sound [Symbol, Revox::Models::AssistantCreateParams::BackgroundSound, nil] Ambient background sound to play during the call. null/omitted disables it.
347
+ #
348
+ # @param background_sound_volume [Float] Volume of the ambient background sound (0 = silent, 1 = max).
137
349
  #
138
350
  # @param calendly [Revox::Models::AssistantCreateParams::Calendly, nil]
139
351
  #
140
352
  # @param call_retry_config [Revox::Models::AssistantCreateParams::CallRetryConfig] Configuration for call retry behavior including time windows, delays, and max it
141
353
  #
354
+ # @param cartesia_dictionary_pronunciation_id [String, nil] Optional Cartesia pronunciation dictionary ID to use for this assistant's calls.
355
+ #
356
+ # @param custom_tools [Array<Revox::Models::AssistantCreateParams::CustomTool>, nil] Custom API tools the assistant can call during conversations. Each tool defines
357
+ #
358
+ # @param email_notification_address [String, nil] Email address(es) to receive notifications when a call ends with a matching outc
359
+ #
360
+ # @param email_notification_language [Symbol, Revox::Models::AssistantCreateParams::EmailNotificationLanguage] The language used for the notification email content. One of "en" or "fr". Defau
361
+ #
362
+ # @param email_notification_outcomes [Array<Symbol, Revox::Models::AssistantCreateParams::EmailNotificationOutcome>, nil] Which call outcomes trigger an email notification. E.g. ["interested", "complete
363
+ #
142
364
  # @param end_of_call_sentence [String] Optional message to say when the agent decides to end the call.
143
365
  #
144
366
  # @param faq_items [Array<Revox::Models::AssistantCreateParams::FaqItem>] FAQ items to associate with this assistant. When provided, replaces all existing
@@ -149,26 +371,79 @@ module Revox
149
371
  #
150
372
  # @param first_sentence_mode [Symbol, Revox::Models::AssistantCreateParams::FirstSentenceMode] How the first sentence should be handled. "generated" means the LLM will generat
151
373
  #
374
+ # @param from_phone_number [String, nil] Override the default outbound phone number for calls placed with this assistant.
375
+ #
376
+ # @param human_transfer_mode [Symbol, Revox::Models::AssistantCreateParams::HumanTransferMode, nil] When transfer_phone_number is set: "warm" (AI bridges) or "cold" (SIP REFER; tru
377
+ #
152
378
  # @param ivr_navigation_enabled [Boolean] Enable IVR navigation tools. When enabled, the assistant can send DTMF tones and
153
379
  #
154
- # @param llm_model [Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1]
380
+ # @param llm_model [Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1, Revox::Models::AssistantCreateParams::LlmModel::UnionMember2, Revox::Models::AssistantCreateParams::LlmModel::UnionMember3]
381
+ #
382
+ # @param logo_url [String, nil] Public URL of the brand logo shown on the assistant's demo page. Upload a new lo
155
383
  #
156
384
  # @param max_call_duration_secs [Float] The maximum duration of the call in seconds. This is the maximum time the call w
157
385
  #
386
+ # @param max_duration_end_message [String, nil] Optional message the agent will say, without being interruptible, when the call
387
+ #
388
+ # @param position [Revox::Models::AssistantCreateParams::Position, nil] Canvas position of this assistant's node in its multi-step flow editor.
389
+ #
390
+ # @param prompt_flow [Revox::Models::AssistantCreateParams::PromptFlow, nil] Visual prompt constructor data (nodes, edges, positions). Used by the UI to re-o
391
+ #
392
+ # @param slack [Revox::Models::AssistantCreateParams::Slack, nil] Slack notification config. When set, posts a message to the chosen channel after
393
+ #
394
+ # @param sms_enabled [Boolean] Enable SMS tool during calls. When enabled, the agent can send SMS messages to t
395
+ #
396
+ # @param sms_template [String, nil] Hardcoded SMS template to send during calls. When set, this exact text is sent i
397
+ #
158
398
  # @param structured_output_config [Array<Revox::Models::AssistantCreateParams::StructuredOutputConfig>] The structured output config to use for the call. This is used to extract the da
159
399
  #
400
+ # @param structured_output_prompt [String, nil] Custom prompt for structured data extraction. If not provided, a default prompt
401
+ #
402
+ # @param stt_context [Revox::Models::AssistantCreateParams::SttContext, nil] Assistant-level speech-to-text context: structured `general` key/value pairs plu
403
+ #
404
+ # @param stt_model [Symbol, Revox::Models::AssistantCreateParams::SttModel] Transcriber (speech-to-text) model. Defaults to the newest Soniox realtime model
405
+ #
406
+ # @param thinking_sound [Symbol, Revox::Models::AssistantCreateParams::ThinkingSound, nil] Audio clip to play while the agent is processing a response. One of the built-in
407
+ #
408
+ # @param thinking_sound_probability [Float] Probability [0..1] that the thinking sound plays on any given turn; otherwise th
409
+ #
410
+ # @param thinking_sound_volume [Float] Volume of the thinking sound (0 = silent, 1 = max).
411
+ #
160
412
  # @param transfer_phone_number [String, nil] Phone number to transfer calls to when users request to speak to a human agent i
161
413
  #
414
+ # @param type [Symbol, Revox::Models::AssistantCreateParams::Type] Assistant kind. 'standalone' (default) is a normal assistant, 'multi-step' orche
415
+ #
162
416
  # @param voice [Revox::Models::AssistantCreateParams::Voice] The voice to use for the call. You can get the list of voices using the /voices
163
417
  #
164
418
  # @param voicemail_message [String, nil] If set, when voicemail is detected the agent will speak this message then hang u
165
419
  #
420
+ # @param voicemail_sms_prompt [String, nil] SMS message to send when the call reaches voicemail. Supports {{variable}} place
421
+ #
422
+ # @param warm_transfer_summary_instructions [String, nil] When using warm transfer: extra instructions for the supervisor handoff summary.
423
+ #
166
424
  # @param webhook_url [String] The webhook URL to call when the call is completed.
167
425
  #
426
+ # @param zoho [Revox::Models::AssistantCreateParams::Zoho, nil] Zoho CRM integration config. When set, upserts the prospect (keyed on phone) int
427
+ #
168
428
  # @param request_options [Revox::RequestOptions, Hash{Symbol=>Object}]
169
429
 
170
- # The background sound to play during the call. Useful to give the impression that
171
- # your AI agent is in an office, in the street, or anywhere else you want.
430
+ module AfterCallSMSOutcome
431
+ extend Revox::Internal::Type::Enum
432
+
433
+ NOT_INTERESTED = :not_interested
434
+ INTERESTED = :interested
435
+ COMPLETED = :completed
436
+ REQUESTED_CALLBACK_LATER = :requested_callback_later
437
+ REQUESTED_CALLBACK_NEW_NUMBER = :requested_callback_new_number
438
+ DO_NOT_CONTACT = :do_not_contact
439
+ AI_AVERSE = :ai_averse
440
+ NONE = :none
441
+
442
+ # @!method self.values
443
+ # @return [Array<Symbol>]
444
+ end
445
+
446
+ # Ambient background sound to play during the call. null/omitted disables it.
172
447
  module BackgroundSound
173
448
  extend Revox::Internal::Type::Enum
174
449
 
@@ -202,6 +477,23 @@ module Revox
202
477
  end
203
478
 
204
479
  class CallRetryConfig < Revox::Internal::Type::BaseModel
480
+ # @!attribute allowed_days
481
+ # Days of the week when calls are allowed, in the recipient's timezone. Default:
482
+ # Monday through Friday.
483
+ #
484
+ # @return [Array<Symbol, Revox::Models::AssistantCreateParams::CallRetryConfig::AllowedDay>]
485
+ required :allowed_days,
486
+ -> { Revox::Internal::Type::ArrayOf[enum: Revox::AssistantCreateParams::CallRetryConfig::AllowedDay] }
487
+
488
+ # @!attribute call_twice_in_a_row
489
+ # If true and max_retry_attempts >= 2, attempt #2 fires immediately (skipping
490
+ # retry_delay_seconds) when attempt #1 didn't reach a human.
491
+ # Calling-window/allowed-days checks still apply. Only affects the 1→2 transition.
492
+ # Default: false.
493
+ #
494
+ # @return [Boolean]
495
+ required :call_twice_in_a_row, Revox::Internal::Type::Boolean
496
+
205
497
  # @!attribute calling_windows
206
498
  #
207
499
  # @return [Array<Revox::Models::AssistantCreateParams::CallRetryConfig::CallingWindow>]
@@ -222,19 +514,38 @@ module Revox
222
514
  # @return [String, nil]
223
515
  optional :timezone, String, nil?: true
224
516
 
225
- # @!method initialize(calling_windows:, max_retry_attempts:, timezone: nil)
517
+ # @!method initialize(allowed_days:, call_twice_in_a_row:, calling_windows:, max_retry_attempts:, timezone: nil)
226
518
  # Some parameter documentations has been truncated, see
227
519
  # {Revox::Models::AssistantCreateParams::CallRetryConfig} for more details.
228
520
  #
229
521
  # Configuration for call retry behavior including time windows, delays, and max
230
522
  # iterations. If not provided, defaults will be used.
231
523
  #
524
+ # @param allowed_days [Array<Symbol, Revox::Models::AssistantCreateParams::CallRetryConfig::AllowedDay>] Days of the week when calls are allowed, in the recipient's timezone. Default: M
525
+ #
526
+ # @param call_twice_in_a_row [Boolean] If true and max_retry_attempts >= 2, attempt #2 fires immediately (skipping retr
527
+ #
232
528
  # @param calling_windows [Array<Revox::Models::AssistantCreateParams::CallRetryConfig::CallingWindow>]
233
529
  #
234
530
  # @param max_retry_attempts [Integer] Maximum number of call retry attempts. Default: 3.
235
531
  #
236
532
  # @param timezone [String, nil] Optional IANA timezone identifier to override the automatic timezone detection f
237
533
 
534
+ module AllowedDay
535
+ extend Revox::Internal::Type::Enum
536
+
537
+ MONDAY = :monday
538
+ TUESDAY = :tuesday
539
+ WEDNESDAY = :wednesday
540
+ THURSDAY = :thursday
541
+ FRIDAY = :friday
542
+ SATURDAY = :saturday
543
+ SUNDAY = :sunday
544
+
545
+ # @!method self.values
546
+ # @return [Array<Symbol>]
547
+ end
548
+
238
549
  class CallingWindow < Revox::Internal::Type::BaseModel
239
550
  # @!attribute calling_window_end_time
240
551
  # End time for the calling window in the recipient's timezone (or
@@ -271,6 +582,208 @@ module Revox
271
582
  end
272
583
  end
273
584
 
585
+ class CustomTool < Revox::Internal::Type::BaseModel
586
+ # @!attribute body_template
587
+ # JSON body template for the request. Use quoted {{variable}} placeholders (e.g.
588
+ # "{{name}}") for dynamic values
589
+ #
590
+ # @return [String, nil]
591
+ required :body_template, String, nil?: true
592
+
593
+ # @!attribute description
594
+ # Human-readable description of what the tool does, used by the LLM to decide when
595
+ # to call it
596
+ #
597
+ # @return [String]
598
+ required :description, String
599
+
600
+ # @!attribute headers
601
+ # HTTP headers to include in the request. Values support {{variable}} placeholders
602
+ #
603
+ # @return [Array<Revox::Models::AssistantCreateParams::CustomTool::Header>]
604
+ required :headers, -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::CustomTool::Header] }
605
+
606
+ # @!attribute input_schema
607
+ # Schema defining the parameters the LLM should extract from the conversation to
608
+ # pass to this tool
609
+ #
610
+ # @return [Array<Revox::Models::AssistantCreateParams::CustomTool::InputSchema>]
611
+ required :input_schema,
612
+ -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::CustomTool::InputSchema] }
613
+
614
+ # @!attribute method_
615
+ # HTTP method to use when calling the API endpoint
616
+ #
617
+ # @return [Symbol, Revox::Models::AssistantCreateParams::CustomTool::Method]
618
+ required :method_, enum: -> { Revox::AssistantCreateParams::CustomTool::Method }, api_name: :method
619
+
620
+ # @!attribute name
621
+ # Unique tool name in lowercase_snake_case (e.g. check_inventory)
622
+ #
623
+ # @return [String]
624
+ required :name, String
625
+
626
+ # @!attribute query_params
627
+ # Query string parameters appended to the URL. Values support {{variable}}
628
+ # placeholders
629
+ #
630
+ # @return [Array<Revox::Models::AssistantCreateParams::CustomTool::QueryParam>]
631
+ required :query_params,
632
+ -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::CustomTool::QueryParam] }
633
+
634
+ # @!attribute url
635
+ # Full URL of the API endpoint. Supports {{variable}} placeholders for dynamic
636
+ # values
637
+ #
638
+ # @return [String]
639
+ required :url, String
640
+
641
+ # @!method initialize(body_template:, description:, headers:, input_schema:, method_:, name:, query_params:, url:)
642
+ # Some parameter documentations has been truncated, see
643
+ # {Revox::Models::AssistantCreateParams::CustomTool} for more details.
644
+ #
645
+ # @param body_template [String, nil] JSON body template for the request. Use quoted {{variable}} placeholders (e.g. "
646
+ #
647
+ # @param description [String] Human-readable description of what the tool does, used by the LLM to decide when
648
+ #
649
+ # @param headers [Array<Revox::Models::AssistantCreateParams::CustomTool::Header>] HTTP headers to include in the request. Values support {{variable}} placeholders
650
+ #
651
+ # @param input_schema [Array<Revox::Models::AssistantCreateParams::CustomTool::InputSchema>] Schema defining the parameters the LLM should extract from the conversation to p
652
+ #
653
+ # @param method_ [Symbol, Revox::Models::AssistantCreateParams::CustomTool::Method] HTTP method to use when calling the API endpoint
654
+ #
655
+ # @param name [String] Unique tool name in lowercase_snake_case (e.g. check_inventory)
656
+ #
657
+ # @param query_params [Array<Revox::Models::AssistantCreateParams::CustomTool::QueryParam>] Query string parameters appended to the URL. Values support {{variable}} placeho
658
+ #
659
+ # @param url [String] Full URL of the API endpoint. Supports {{variable}} placeholders for dynamic val
660
+
661
+ class Header < Revox::Internal::Type::BaseModel
662
+ # @!attribute key
663
+ #
664
+ # @return [String]
665
+ required :key, String
666
+
667
+ # @!attribute value
668
+ #
669
+ # @return [String]
670
+ required :value, String
671
+
672
+ # @!method initialize(key:, value:)
673
+ # @param key [String]
674
+ # @param value [String]
675
+ end
676
+
677
+ class InputSchema < Revox::Internal::Type::BaseModel
678
+ # @!attribute name
679
+ #
680
+ # @return [String]
681
+ required :name, String
682
+
683
+ # @!attribute required
684
+ #
685
+ # @return [Boolean]
686
+ required :required, Revox::Internal::Type::Boolean
687
+
688
+ # @!attribute type
689
+ #
690
+ # @return [Symbol, Revox::Models::AssistantCreateParams::CustomTool::InputSchema::Type]
691
+ required :type, enum: -> { Revox::AssistantCreateParams::CustomTool::InputSchema::Type }
692
+
693
+ # @!attribute description
694
+ #
695
+ # @return [String, nil]
696
+ optional :description, String
697
+
698
+ # @!attribute enum_options
699
+ #
700
+ # @return [Array<String>, nil]
701
+ optional :enum_options, Revox::Internal::Type::ArrayOf[String]
702
+
703
+ # @!method initialize(name:, required:, type:, description: nil, enum_options: nil)
704
+ # @param name [String]
705
+ # @param required [Boolean]
706
+ # @param type [Symbol, Revox::Models::AssistantCreateParams::CustomTool::InputSchema::Type]
707
+ # @param description [String]
708
+ # @param enum_options [Array<String>]
709
+
710
+ # @see Revox::Models::AssistantCreateParams::CustomTool::InputSchema#type
711
+ module Type
712
+ extend Revox::Internal::Type::Enum
713
+
714
+ STRING = :string
715
+ NUMBER = :number
716
+ BOOLEAN = :boolean
717
+ ENUM = :enum
718
+ DATE = :date
719
+ DATETIME = :datetime
720
+
721
+ # @!method self.values
722
+ # @return [Array<Symbol>]
723
+ end
724
+ end
725
+
726
+ # HTTP method to use when calling the API endpoint
727
+ #
728
+ # @see Revox::Models::AssistantCreateParams::CustomTool#method_
729
+ module Method
730
+ extend Revox::Internal::Type::Enum
731
+
732
+ GET = :GET
733
+ POST = :POST
734
+ PUT = :PUT
735
+ PATCH = :PATCH
736
+ DELETE = :DELETE
737
+
738
+ # @!method self.values
739
+ # @return [Array<Symbol>]
740
+ end
741
+
742
+ class QueryParam < Revox::Internal::Type::BaseModel
743
+ # @!attribute key
744
+ #
745
+ # @return [String]
746
+ required :key, String
747
+
748
+ # @!attribute value
749
+ #
750
+ # @return [String]
751
+ required :value, String
752
+
753
+ # @!method initialize(key:, value:)
754
+ # @param key [String]
755
+ # @param value [String]
756
+ end
757
+ end
758
+
759
+ # The language used for the notification email content. One of "en" or "fr".
760
+ # Defaults to "en".
761
+ module EmailNotificationLanguage
762
+ extend Revox::Internal::Type::Enum
763
+
764
+ EN = :en
765
+ FR = :fr
766
+
767
+ # @!method self.values
768
+ # @return [Array<Symbol>]
769
+ end
770
+
771
+ module EmailNotificationOutcome
772
+ extend Revox::Internal::Type::Enum
773
+
774
+ NOT_INTERESTED = :not_interested
775
+ INTERESTED = :interested
776
+ COMPLETED = :completed
777
+ REQUESTED_CALLBACK_LATER = :requested_callback_later
778
+ REQUESTED_CALLBACK_NEW_NUMBER = :requested_callback_new_number
779
+ DO_NOT_CONTACT = :do_not_contact
780
+ AI_AVERSE = :ai_averse
781
+ NONE = :none
782
+
783
+ # @!method self.values
784
+ # @return [Array<Symbol>]
785
+ end
786
+
274
787
  class FaqItem < Revox::Internal::Type::BaseModel
275
788
  # @!attribute answer
276
789
  #
@@ -302,6 +815,18 @@ module Revox
302
815
  # @return [Array<Symbol>]
303
816
  end
304
817
 
818
+ # When transfer_phone_number is set: "warm" (AI bridges) or "cold" (SIP REFER;
819
+ # trunk must allow REFER/PSTN). Omit or null when transfer is disabled.
820
+ module HumanTransferMode
821
+ extend Revox::Internal::Type::Enum
822
+
823
+ WARM = :warm
824
+ COLD = :cold
825
+
826
+ # @!method self.values
827
+ # @return [Array<Symbol>]
828
+ end
829
+
305
830
  module LlmModel
306
831
  extend Revox::Internal::Type::Union
307
832
 
@@ -309,6 +834,10 @@ module Revox
309
834
 
310
835
  variant -> { Revox::AssistantCreateParams::LlmModel::UnionMember1 }
311
836
 
837
+ variant -> { Revox::AssistantCreateParams::LlmModel::UnionMember2 }
838
+
839
+ variant -> { Revox::AssistantCreateParams::LlmModel::UnionMember3 }
840
+
312
841
  class UnionMember0 < Revox::Internal::Type::BaseModel
313
842
  # @!attribute name
314
843
  #
@@ -363,8 +892,285 @@ module Revox
363
892
  # @param type [Symbol, :openrouter] Use a model from OpenRouter.
364
893
  end
365
894
 
895
+ class UnionMember2 < Revox::Internal::Type::BaseModel
896
+ # @!attribute api_key
897
+ # API key sent as Bearer token to the custom endpoint.
898
+ #
899
+ # @return [String]
900
+ required :api_key, String
901
+
902
+ # @!attribute api_url
903
+ # Base URL for the OpenAI-compatible API, e.g. https://api.together.xyz/v1
904
+ #
905
+ # @return [String]
906
+ required :api_url, String
907
+
908
+ # @!attribute model_name
909
+ # Model name as expected by the provider, e.g. meta-llama/llama-3-70b
910
+ #
911
+ # @return [String]
912
+ required :model_name, String
913
+
914
+ # @!attribute type
915
+ # OpenAI-compatible chat completions API (bring your own endpoint and key).
916
+ #
917
+ # @return [Symbol, :custom]
918
+ required :type, const: :custom
919
+
920
+ # @!method initialize(api_key:, api_url:, model_name:, type: :custom)
921
+ # @param api_key [String] API key sent as Bearer token to the custom endpoint.
922
+ #
923
+ # @param api_url [String] Base URL for the OpenAI-compatible API, e.g. https://api.together.xyz/v1
924
+ #
925
+ # @param model_name [String] Model name as expected by the provider, e.g. meta-llama/llama-3-70b
926
+ #
927
+ # @param type [Symbol, :custom] OpenAI-compatible chat completions API (bring your own endpoint and key).
928
+ end
929
+
930
+ class UnionMember3 < Revox::Internal::Type::BaseModel
931
+ # @!attribute provider
932
+ # The provider to use from Realtime. eg: openai, google.
933
+ #
934
+ # @return [Symbol, Revox::Models::AssistantCreateParams::LlmModel::UnionMember3::Provider]
935
+ required :provider, enum: -> { Revox::AssistantCreateParams::LlmModel::UnionMember3::Provider }
936
+
937
+ # @!attribute realtime_model_id
938
+ # The model ID to use from Realtime. eg: gpt-4.1
939
+ #
940
+ # @return [String]
941
+ required :realtime_model_id, String
942
+
943
+ # @!attribute type
944
+ # Use a model from Realtime.
945
+ #
946
+ # @return [Symbol, :realtime]
947
+ required :type, const: :realtime
948
+
949
+ # @!attribute realtime_voice_id
950
+ # Output voice for the realtime provider (e.g. OpenAI: marin; Gemini: Puck).
951
+ #
952
+ # @return [String, nil]
953
+ optional :realtime_voice_id, String
954
+
955
+ # @!method initialize(provider:, realtime_model_id:, realtime_voice_id: nil, type: :realtime)
956
+ # @param provider [Symbol, Revox::Models::AssistantCreateParams::LlmModel::UnionMember3::Provider] The provider to use from Realtime. eg: openai, google.
957
+ #
958
+ # @param realtime_model_id [String] The model ID to use from Realtime. eg: gpt-4.1
959
+ #
960
+ # @param realtime_voice_id [String] Output voice for the realtime provider (e.g. OpenAI: marin; Gemini: Puck).
961
+ #
962
+ # @param type [Symbol, :realtime] Use a model from Realtime.
963
+
964
+ # The provider to use from Realtime. eg: openai, google.
965
+ #
966
+ # @see Revox::Models::AssistantCreateParams::LlmModel::UnionMember3#provider
967
+ module Provider
968
+ extend Revox::Internal::Type::Enum
969
+
970
+ OPENAI = :openai
971
+ GOOGLE = :google
972
+
973
+ # @!method self.values
974
+ # @return [Array<Symbol>]
975
+ end
976
+ end
977
+
366
978
  # @!method self.variants
367
- # @return [Array(Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1)]
979
+ # @return [Array(Revox::Models::AssistantCreateParams::LlmModel::UnionMember0, Revox::Models::AssistantCreateParams::LlmModel::UnionMember1, Revox::Models::AssistantCreateParams::LlmModel::UnionMember2, Revox::Models::AssistantCreateParams::LlmModel::UnionMember3)]
980
+ end
981
+
982
+ class Position < Revox::Internal::Type::BaseModel
983
+ # @!attribute x
984
+ #
985
+ # @return [Float]
986
+ required :x, Float
987
+
988
+ # @!attribute y_
989
+ #
990
+ # @return [Float]
991
+ required :y_, Float, api_name: :y
992
+
993
+ # @!method initialize(x:, y_:)
994
+ # Canvas position of this assistant's node in its multi-step flow editor.
995
+ #
996
+ # @param x [Float]
997
+ # @param y_ [Float]
998
+ end
999
+
1000
+ class PromptFlow < Revox::Internal::Type::BaseModel
1001
+ # @!attribute edges
1002
+ #
1003
+ # @return [Array<Revox::Models::AssistantCreateParams::PromptFlow::Edge>]
1004
+ required :edges, -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::PromptFlow::Edge] }
1005
+
1006
+ # @!attribute nodes
1007
+ #
1008
+ # @return [Array<Revox::Models::AssistantCreateParams::PromptFlow::Node>]
1009
+ required :nodes, -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::PromptFlow::Node] }
1010
+
1011
+ # @!method initialize(edges:, nodes:)
1012
+ # Visual prompt constructor data (nodes, edges, positions). Used by the UI to
1013
+ # re-open the visual editor. Does not affect call behavior — the flattened prompt
1014
+ # field is what the LLM receives.
1015
+ #
1016
+ # @param edges [Array<Revox::Models::AssistantCreateParams::PromptFlow::Edge>]
1017
+ # @param nodes [Array<Revox::Models::AssistantCreateParams::PromptFlow::Node>]
1018
+
1019
+ class Edge < Revox::Internal::Type::BaseModel
1020
+ # @!attribute id
1021
+ #
1022
+ # @return [String]
1023
+ required :id, String
1024
+
1025
+ # @!attribute source
1026
+ #
1027
+ # @return [String]
1028
+ required :source, String
1029
+
1030
+ # @!attribute target
1031
+ #
1032
+ # @return [String]
1033
+ required :target, String
1034
+
1035
+ # @!method initialize(id:, source:, target:)
1036
+ # @param id [String]
1037
+ # @param source [String]
1038
+ # @param target [String]
1039
+ end
1040
+
1041
+ class Node < Revox::Internal::Type::BaseModel
1042
+ # @!attribute id
1043
+ #
1044
+ # @return [String]
1045
+ required :id, String
1046
+
1047
+ # @!attribute data
1048
+ #
1049
+ # @return [Revox::Models::AssistantCreateParams::PromptFlow::Node::Data]
1050
+ required :data, -> { Revox::AssistantCreateParams::PromptFlow::Node::Data }
1051
+
1052
+ # @!attribute position
1053
+ #
1054
+ # @return [Revox::Models::AssistantCreateParams::PromptFlow::Node::Position]
1055
+ required :position, -> { Revox::AssistantCreateParams::PromptFlow::Node::Position }
1056
+
1057
+ # @!attribute type
1058
+ #
1059
+ # @return [Symbol, :promptBlock]
1060
+ required :type, const: :promptBlock
1061
+
1062
+ # @!method initialize(id:, data:, position:, type: :promptBlock)
1063
+ # @param id [String]
1064
+ # @param data [Revox::Models::AssistantCreateParams::PromptFlow::Node::Data]
1065
+ # @param position [Revox::Models::AssistantCreateParams::PromptFlow::Node::Position]
1066
+ # @param type [Symbol, :promptBlock]
1067
+
1068
+ # @see Revox::Models::AssistantCreateParams::PromptFlow::Node#data
1069
+ class Data < Revox::Internal::Type::BaseModel
1070
+ # @!attribute body
1071
+ #
1072
+ # @return [String]
1073
+ required :body, String
1074
+
1075
+ # @!attribute title
1076
+ #
1077
+ # @return [String]
1078
+ required :title, String
1079
+
1080
+ # @!method initialize(body:, title:)
1081
+ # @param body [String]
1082
+ # @param title [String]
1083
+ end
1084
+
1085
+ # @see Revox::Models::AssistantCreateParams::PromptFlow::Node#position
1086
+ class Position < Revox::Internal::Type::BaseModel
1087
+ # @!attribute x
1088
+ #
1089
+ # @return [Float]
1090
+ required :x, Float
1091
+
1092
+ # @!attribute y_
1093
+ #
1094
+ # @return [Float]
1095
+ required :y_, Float, api_name: :y
1096
+
1097
+ # @!method initialize(x:, y_:)
1098
+ # @param x [Float]
1099
+ # @param y_ [Float]
1100
+ end
1101
+ end
1102
+ end
1103
+
1104
+ class Slack < Revox::Internal::Type::BaseModel
1105
+ # @!attribute channel_id
1106
+ # The Slack channel ID where the notification will be posted.
1107
+ #
1108
+ # @return [String]
1109
+ required :channel_id, String
1110
+
1111
+ # @!attribute connection_id
1112
+ # The Nango connection ID linking the org's Slack workspace to Revox.
1113
+ #
1114
+ # @return [String]
1115
+ required :connection_id, String
1116
+
1117
+ # @!attribute outcomes
1118
+ # Which call outcomes trigger a Slack notification (e.g. ['interested', 'none']).
1119
+ # Use 'none' to notify when outcome is null.
1120
+ #
1121
+ # @return [Array<Symbol, Revox::Models::AssistantCreateParams::Slack::Outcome>]
1122
+ required :outcomes,
1123
+ -> { Revox::Internal::Type::ArrayOf[enum: Revox::AssistantCreateParams::Slack::Outcome] }
1124
+
1125
+ # @!attribute channel_name
1126
+ # Human-readable Slack channel name, cached for display in the UI.
1127
+ #
1128
+ # @return [String, nil]
1129
+ optional :channel_name, String, nil?: true
1130
+
1131
+ # @!attribute template
1132
+ # Optional message template. Supports {{summary}}, {{outcome}}, {{phone}},
1133
+ # {{call_url}}, {{assistant_name}}, {{campaign_name}}, {{first_name}},
1134
+ # {{last_name}}, {{email}}, {{company}}, {{contact_name}}, {{contact_line}}, plus
1135
+ # prompt_variables and structured_output keys. When null/empty a default template
1136
+ # is used.
1137
+ #
1138
+ # @return [String, nil]
1139
+ optional :template, String, nil?: true
1140
+
1141
+ # @!method initialize(channel_id:, connection_id:, outcomes:, channel_name: nil, template: nil)
1142
+ # Some parameter documentations has been truncated, see
1143
+ # {Revox::Models::AssistantCreateParams::Slack} for more details.
1144
+ #
1145
+ # Slack notification config. When set, posts a message to the chosen channel after
1146
+ # a call ends with one of the configured outcomes.
1147
+ #
1148
+ # @param channel_id [String] The Slack channel ID where the notification will be posted.
1149
+ #
1150
+ # @param connection_id [String] The Nango connection ID linking the org's Slack workspace to Revox.
1151
+ #
1152
+ # @param outcomes [Array<Symbol, Revox::Models::AssistantCreateParams::Slack::Outcome>] Which call outcomes trigger a Slack notification (e.g. ['interested', 'none']).
1153
+ #
1154
+ # @param channel_name [String, nil] Human-readable Slack channel name, cached for display in the UI.
1155
+ #
1156
+ # @param template [String, nil] Optional message template. Supports {{summary}}, {{outcome}}, {{phone}},
1157
+ # {{call\_
1158
+
1159
+ module Outcome
1160
+ extend Revox::Internal::Type::Enum
1161
+
1162
+ NOT_INTERESTED = :not_interested
1163
+ INTERESTED = :interested
1164
+ COMPLETED = :completed
1165
+ REQUESTED_CALLBACK_LATER = :requested_callback_later
1166
+ REQUESTED_CALLBACK_NEW_NUMBER = :requested_callback_new_number
1167
+ DO_NOT_CONTACT = :do_not_contact
1168
+ AI_AVERSE = :ai_averse
1169
+ NONE = :none
1170
+
1171
+ # @!method self.values
1172
+ # @return [Array<Symbol>]
1173
+ end
368
1174
  end
369
1175
 
370
1176
  class StructuredOutputConfig < Revox::Internal::Type::BaseModel
@@ -416,6 +1222,87 @@ module Revox
416
1222
  end
417
1223
  end
418
1224
 
1225
+ class SttContext < Revox::Internal::Type::BaseModel
1226
+ # @!attribute general
1227
+ #
1228
+ # @return [Array<Revox::Models::AssistantCreateParams::SttContext::General>]
1229
+ required :general,
1230
+ -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::SttContext::General] }
1231
+
1232
+ # @!attribute terms
1233
+ #
1234
+ # @return [Array<String>]
1235
+ required :terms, Revox::Internal::Type::ArrayOf[String]
1236
+
1237
+ # @!method initialize(general:, terms:)
1238
+ # Assistant-level speech-to-text context: structured `general` key/value pairs
1239
+ # plus a list of domain `terms`. Prompt-derived context is merged in without
1240
+ # replacing existing entries.
1241
+ #
1242
+ # @param general [Array<Revox::Models::AssistantCreateParams::SttContext::General>]
1243
+ # @param terms [Array<String>]
1244
+
1245
+ class General < Revox::Internal::Type::BaseModel
1246
+ # @!attribute key
1247
+ #
1248
+ # @return [String]
1249
+ required :key, String
1250
+
1251
+ # @!attribute value
1252
+ #
1253
+ # @return [String]
1254
+ required :value, String
1255
+
1256
+ # @!method initialize(key:, value:)
1257
+ # @param key [String]
1258
+ # @param value [String]
1259
+ end
1260
+ end
1261
+
1262
+ # Transcriber (speech-to-text) model. Defaults to the newest Soniox realtime model
1263
+ # when omitted.
1264
+ module SttModel
1265
+ extend Revox::Internal::Type::Enum
1266
+
1267
+ STT_RT_V4 = :"stt-rt-v4"
1268
+ STT_RT_V5 = :"stt-rt-v5"
1269
+
1270
+ # @!method self.values
1271
+ # @return [Array<Symbol>]
1272
+ end
1273
+
1274
+ # Audio clip to play while the agent is processing a response. One of the built-in
1275
+ # LiveKit audio clips; null/omitted disables it.
1276
+ module ThinkingSound
1277
+ extend Revox::Internal::Type::Enum
1278
+
1279
+ CITY_AMBIENCE_OGG = :"city-ambience.ogg"
1280
+ FOREST_AMBIENCE_OGG = :"forest-ambience.ogg"
1281
+ OFFICE_AMBIENCE_OGG = :"office-ambience.ogg"
1282
+ CROWDED_ROOM_OGG = :"crowded-room.ogg"
1283
+ KEYBOARD_TYPING_OGG = :"keyboard-typing.ogg"
1284
+ KEYBOARD_TYPING2_OGG = :"keyboard-typing2.ogg"
1285
+ HOLD_MUSIC_OGG = :"hold_music.ogg"
1286
+
1287
+ # @!method self.values
1288
+ # @return [Array<Symbol>]
1289
+ end
1290
+
1291
+ # Assistant kind. 'standalone' (default) is a normal assistant, 'multi-step'
1292
+ # orchestrates a flow of sub-assistants, 'sub-assistant' is a step inside a
1293
+ # multi-step flow (hidden from the assistants list). Flow transitions are managed
1294
+ # via the /assistants/:id/edges endpoints, not on the assistant itself.
1295
+ module Type
1296
+ extend Revox::Internal::Type::Enum
1297
+
1298
+ STANDALONE = :standalone
1299
+ MULTI_STEP = :"multi-step"
1300
+ SUB_ASSISTANT = :"sub-assistant"
1301
+
1302
+ # @!method self.values
1303
+ # @return [Array<Symbol>]
1304
+ end
1305
+
419
1306
  class Voice < Revox::Internal::Type::BaseModel
420
1307
  # @!attribute id
421
1308
  # The ID of the voice.
@@ -429,6 +1316,13 @@ module Revox
429
1316
  # @return [Symbol, Revox::Models::AssistantCreateParams::Voice::Provider]
430
1317
  required :provider, enum: -> { Revox::AssistantCreateParams::Voice::Provider }
431
1318
 
1319
+ # @!attribute model
1320
+ # Cartesia TTS model (Cartesia only). Defaults to sonic-3 when omitted. Ignored
1321
+ # for other providers.
1322
+ #
1323
+ # @return [Symbol, Revox::Models::AssistantCreateParams::Voice::Model, nil]
1324
+ optional :model, enum: -> { Revox::AssistantCreateParams::Voice::Model }
1325
+
432
1326
  # @!attribute speed
433
1327
  # The speed of the voice. Range depends on provider: Cartesia 0.6–1.5, ElevenLabs
434
1328
  # 0.7–1.2. Default is 1.0.
@@ -436,7 +1330,14 @@ module Revox
436
1330
  # @return [Float, nil]
437
1331
  optional :speed, Float
438
1332
 
439
- # @!method initialize(id:, provider:, speed: nil)
1333
+ # @!attribute volume
1334
+ # Volume of the voice (Cartesia only). 0.5–2.0, default 1.0. Ignored for other
1335
+ # providers.
1336
+ #
1337
+ # @return [Float, nil]
1338
+ optional :volume, Float
1339
+
1340
+ # @!method initialize(id:, provider:, model: nil, speed: nil, volume: nil)
440
1341
  # Some parameter documentations has been truncated, see
441
1342
  # {Revox::Models::AssistantCreateParams::Voice} for more details.
442
1343
  #
@@ -447,7 +1348,11 @@ module Revox
447
1348
  #
448
1349
  # @param provider [Symbol, Revox::Models::AssistantCreateParams::Voice::Provider] The provider of the voice.
449
1350
  #
1351
+ # @param model [Symbol, Revox::Models::AssistantCreateParams::Voice::Model] Cartesia TTS model (Cartesia only). Defaults to sonic-3 when omitted. Ignored fo
1352
+ #
450
1353
  # @param speed [Float] The speed of the voice. Range depends on provider: Cartesia 0.6–1.5, ElevenLabs
1354
+ #
1355
+ # @param volume [Float] Volume of the voice (Cartesia only). 0.5–2.0, default 1.0. Ignored for other pro
451
1356
 
452
1357
  # The provider of the voice.
453
1358
  #
@@ -461,6 +1366,126 @@ module Revox
461
1366
  # @!method self.values
462
1367
  # @return [Array<Symbol>]
463
1368
  end
1369
+
1370
+ # Cartesia TTS model (Cartesia only). Defaults to sonic-3 when omitted. Ignored
1371
+ # for other providers.
1372
+ #
1373
+ # @see Revox::Models::AssistantCreateParams::Voice#model
1374
+ module Model
1375
+ extend Revox::Internal::Type::Enum
1376
+
1377
+ SONIC_3 = :"sonic-3"
1378
+ SONIC_3_5 = :"sonic-3.5"
1379
+
1380
+ # @!method self.values
1381
+ # @return [Array<Symbol>]
1382
+ end
1383
+ end
1384
+
1385
+ class Zoho < Revox::Internal::Type::BaseModel
1386
+ # @!attribute connection_id
1387
+ # The Nango connection ID linking the org's Zoho CRM account to Revox.
1388
+ #
1389
+ # @return [String]
1390
+ required :connection_id, String
1391
+
1392
+ # @!attribute field_mapping
1393
+ # Maps extracted call fields (structured_output / prompt variables) onto Zoho
1394
+ # field API names on the upserted record.
1395
+ #
1396
+ # @return [Array<Revox::Models::AssistantCreateParams::Zoho::FieldMapping>]
1397
+ required :field_mapping,
1398
+ -> { Revox::Internal::Type::ArrayOf[Revox::AssistantCreateParams::Zoho::FieldMapping] }
1399
+
1400
+ # @!attribute log_call_activity
1401
+ # When true, also log the call as a record in Zoho's Calls module (related to the
1402
+ # upserted prospect via Who_Id).
1403
+ #
1404
+ # @return [Boolean]
1405
+ required :log_call_activity, Revox::Internal::Type::Boolean
1406
+
1407
+ # @!attribute module_
1408
+ # Zoho module the prospect record is upserted into (e.g. 'Leads' or 'Contacts').
1409
+ #
1410
+ # @return [String]
1411
+ required :module_, String, api_name: :module
1412
+
1413
+ # @!attribute outcomes
1414
+ # Which call outcomes trigger the Zoho push (e.g. ['interested', 'none']). Use
1415
+ # 'none' to push when outcome is null.
1416
+ #
1417
+ # @return [Array<Symbol, Revox::Models::AssistantCreateParams::Zoho::Outcome>]
1418
+ required :outcomes,
1419
+ -> { Revox::Internal::Type::ArrayOf[enum: Revox::AssistantCreateParams::Zoho::Outcome] }
1420
+
1421
+ # @!attribute template
1422
+ # Optional Note body template. Supports {{summary}}, {{outcome}}, {{phone}},
1423
+ # {{call_url}}, {{assistant_name}}, {{campaign_name}}, {{transcript}}, plus
1424
+ # prompt_variables and structured_output keys. When null/empty a default note
1425
+ # (outcome + summary + auto-listed extracted fields) is used.
1426
+ #
1427
+ # @return [String, nil]
1428
+ optional :template, String, nil?: true
1429
+
1430
+ # @!method initialize(connection_id:, field_mapping:, log_call_activity:, module_:, outcomes:, template: nil)
1431
+ # Some parameter documentations has been truncated, see
1432
+ # {Revox::Models::AssistantCreateParams::Zoho} for more details.
1433
+ #
1434
+ # Zoho CRM integration config. When set, upserts the prospect (keyed on phone)
1435
+ # into the chosen module and attaches a Note with the call summary after a call
1436
+ # ends with one of the configured outcomes.
1437
+ #
1438
+ # @param connection_id [String] The Nango connection ID linking the org's Zoho CRM account to Revox.
1439
+ #
1440
+ # @param field_mapping [Array<Revox::Models::AssistantCreateParams::Zoho::FieldMapping>] Maps extracted call fields (structured_output / prompt variables) onto Zoho fiel
1441
+ #
1442
+ # @param log_call_activity [Boolean] When true, also log the call as a record in Zoho's Calls module (related to the
1443
+ #
1444
+ # @param module_ [String] Zoho module the prospect record is upserted into (e.g. 'Leads' or 'Contacts').
1445
+ #
1446
+ # @param outcomes [Array<Symbol, Revox::Models::AssistantCreateParams::Zoho::Outcome>] Which call outcomes trigger the Zoho push (e.g. ['interested', 'none']). Use 'no
1447
+ #
1448
+ # @param template [String, nil] Optional Note body template. Supports {{summary}}, {{outcome}}, {{phone}}, {{cal
1449
+
1450
+ class FieldMapping < Revox::Internal::Type::BaseModel
1451
+ # @!attribute source
1452
+ # Source key to read from the call: a structured_output field name, falling back
1453
+ # to a prompt variable of the same name.
1454
+ #
1455
+ # @return [String]
1456
+ required :source, String
1457
+
1458
+ # @!attribute zoho_field
1459
+ # Destination Zoho field API name on the upserted record (e.g. 'Email', 'Company',
1460
+ # or a custom 'Budget\_\_c').
1461
+ #
1462
+ # @return [String]
1463
+ required :zoho_field, String
1464
+
1465
+ # @!method initialize(source:, zoho_field:)
1466
+ # Some parameter documentations has been truncated, see
1467
+ # {Revox::Models::AssistantCreateParams::Zoho::FieldMapping} for more details.
1468
+ #
1469
+ # @param source [String] Source key to read from the call: a structured_output field name, falling back t
1470
+ #
1471
+ # @param zoho_field [String] Destination Zoho field API name on the upserted record (e.g. 'Email', 'Company',
1472
+ end
1473
+
1474
+ module Outcome
1475
+ extend Revox::Internal::Type::Enum
1476
+
1477
+ NOT_INTERESTED = :not_interested
1478
+ INTERESTED = :interested
1479
+ COMPLETED = :completed
1480
+ REQUESTED_CALLBACK_LATER = :requested_callback_later
1481
+ REQUESTED_CALLBACK_NEW_NUMBER = :requested_callback_new_number
1482
+ DO_NOT_CONTACT = :do_not_contact
1483
+ AI_AVERSE = :ai_averse
1484
+ NONE = :none
1485
+
1486
+ # @!method self.values
1487
+ # @return [Array<Symbol>]
1488
+ end
464
1489
  end
465
1490
  end
466
1491
  end