sentdm 0.39.0 → 0.40.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 (140) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +9 -0
  3. data/README.md +1 -1
  4. data/lib/sentdm/internal/voice_agents_page.rb +115 -0
  5. data/lib/sentdm/models/call_event.rb +8 -6
  6. data/lib/sentdm/models/call_event_payload.rb +25 -6
  7. data/lib/sentdm/models/channels/voice_create_params.rb +23 -11
  8. data/lib/sentdm/models/channels/voice_number.rb +23 -1
  9. data/lib/sentdm/models/channels/voice_update_params.rb +12 -1
  10. data/lib/sentdm/models/voice/agent_create_params.rb +142 -0
  11. data/lib/sentdm/models/voice/agent_delete_params.rb +28 -0
  12. data/lib/sentdm/models/voice/agent_list_params.rb +38 -0
  13. data/lib/sentdm/models/voice/agent_retrieve_params.rb +28 -0
  14. data/lib/sentdm/models/voice/agent_rotate_secret_params.rb +34 -0
  15. data/lib/sentdm/models/voice/agent_update_params.rb +141 -0
  16. data/lib/sentdm/models/voice/api_response_of_voice_agent.rb +51 -0
  17. data/lib/sentdm/models/voice/api_response_of_voice_agent_secret.rb +45 -0
  18. data/lib/sentdm/models/voice/api_response_of_voice_agents_list.rb +48 -0
  19. data/lib/sentdm/models/voice/api_response_of_voice_catalogue.rb +49 -0
  20. data/lib/sentdm/models/voice/call.rb +97 -5
  21. data/lib/sentdm/models/voice/call_list_params.rb +19 -1
  22. data/lib/sentdm/models/voice/catalogue_list_params.rb +22 -0
  23. data/lib/sentdm/models/voice/voice_agent.rb +138 -0
  24. data/lib/sentdm/models/voice/voice_agent_audio.rb +19 -0
  25. data/lib/sentdm/models/voice/voice_agent_audio_spec.rb +20 -0
  26. data/lib/sentdm/models/voice/voice_agent_limits.rb +31 -0
  27. data/lib/sentdm/models/voice/voice_agent_limits_spec.rb +40 -0
  28. data/lib/sentdm/models/voice/voice_agent_party.rb +25 -0
  29. data/lib/sentdm/models/voice/voice_agent_party_spec.rb +28 -0
  30. data/lib/sentdm/models/voice/voice_agent_secret.rb +27 -0
  31. data/lib/sentdm/models/voice/voice_agent_speech.rb +31 -0
  32. data/lib/sentdm/models/voice/voice_agent_speech_spec.rb +40 -0
  33. data/lib/sentdm/models/voice/voice_agent_transcripts.rb +25 -0
  34. data/lib/sentdm/models/voice/voice_agent_transcripts_spec.rb +32 -0
  35. data/lib/sentdm/models/voice/voice_agents_list.rb +30 -0
  36. data/lib/sentdm/models/voice/voice_catalogue.rb +30 -0
  37. data/lib/sentdm/models/voice/voice_catalogue_voice.rb +43 -0
  38. data/lib/sentdm/models/webhook_create_params.rb +31 -5
  39. data/lib/sentdm/models/webhook_response.rb +66 -4
  40. data/lib/sentdm/models/webhook_update_params.rb +15 -3
  41. data/lib/sentdm/resources/channels/voice.rb +38 -15
  42. data/lib/sentdm/resources/profiles/campaigns.rb +3 -2
  43. data/lib/sentdm/resources/voice/agents.rb +319 -0
  44. data/lib/sentdm/resources/voice/calls/participants.rb +11 -0
  45. data/lib/sentdm/resources/voice/calls.rb +44 -13
  46. data/lib/sentdm/resources/voice/catalogue.rb +71 -0
  47. data/lib/sentdm/resources/voice/tokens.rb +11 -0
  48. data/lib/sentdm/resources/voice.rb +86 -0
  49. data/lib/sentdm/resources/webhooks.rb +43 -15
  50. data/lib/sentdm/version.rb +1 -1
  51. data/lib/sentdm.rb +29 -0
  52. data/rbi/sentdm/internal/voice_agents_page.rbi +71 -0
  53. data/rbi/sentdm/models/call_event.rbi +14 -10
  54. data/rbi/sentdm/models/call_event_payload.rbi +28 -5
  55. data/rbi/sentdm/models/channels/voice_create_params.rbi +33 -17
  56. data/rbi/sentdm/models/channels/voice_number.rbi +31 -0
  57. data/rbi/sentdm/models/channels/voice_update_params.rbi +14 -0
  58. data/rbi/sentdm/models/voice/agent_create_params.rbi +215 -0
  59. data/rbi/sentdm/models/voice/agent_delete_params.rbi +48 -0
  60. data/rbi/sentdm/models/voice/agent_list_params.rbi +66 -0
  61. data/rbi/sentdm/models/voice/agent_retrieve_params.rbi +48 -0
  62. data/rbi/sentdm/models/voice/agent_rotate_secret_params.rbi +64 -0
  63. data/rbi/sentdm/models/voice/agent_update_params.rbi +211 -0
  64. data/rbi/sentdm/models/voice/api_response_of_voice_agent.rbi +85 -0
  65. data/rbi/sentdm/models/voice/api_response_of_voice_agent_secret.rbi +81 -0
  66. data/rbi/sentdm/models/voice/api_response_of_voice_agents_list.rbi +83 -0
  67. data/rbi/sentdm/models/voice/api_response_of_voice_catalogue.rbi +83 -0
  68. data/rbi/sentdm/models/voice/call.rbi +141 -8
  69. data/rbi/sentdm/models/voice/call_list_params.rbi +20 -0
  70. data/rbi/sentdm/models/voice/catalogue_list_params.rbi +40 -0
  71. data/rbi/sentdm/models/voice/voice_agent.rbi +196 -0
  72. data/rbi/sentdm/models/voice/voice_agent_audio.rbi +30 -0
  73. data/rbi/sentdm/models/voice/voice_agent_audio_spec.rbi +33 -0
  74. data/rbi/sentdm/models/voice/voice_agent_limits.rbi +57 -0
  75. data/rbi/sentdm/models/voice/voice_agent_limits_spec.rbi +62 -0
  76. data/rbi/sentdm/models/voice/voice_agent_party.rbi +36 -0
  77. data/rbi/sentdm/models/voice/voice_agent_party_spec.rbi +45 -0
  78. data/rbi/sentdm/models/voice/voice_agent_secret.rbi +37 -0
  79. data/rbi/sentdm/models/voice/voice_agent_speech.rbi +48 -0
  80. data/rbi/sentdm/models/voice/voice_agent_speech_spec.rbi +62 -0
  81. data/rbi/sentdm/models/voice/voice_agent_transcripts.rbi +43 -0
  82. data/rbi/sentdm/models/voice/voice_agent_transcripts_spec.rbi +51 -0
  83. data/rbi/sentdm/models/voice/voice_agents_list.rbi +55 -0
  84. data/rbi/sentdm/models/voice/voice_catalogue.rbi +59 -0
  85. data/rbi/sentdm/models/voice/voice_catalogue_voice.rbi +75 -0
  86. data/rbi/sentdm/models/webhook_create_params.rbi +41 -3
  87. data/rbi/sentdm/models/webhook_response.rbi +112 -3
  88. data/rbi/sentdm/models/webhook_update_params.rbi +18 -3
  89. data/rbi/sentdm/resources/channels/voice.rbi +52 -19
  90. data/rbi/sentdm/resources/profiles/campaigns.rbi +3 -2
  91. data/rbi/sentdm/resources/voice/agents.rbi +316 -0
  92. data/rbi/sentdm/resources/voice/calls/participants.rbi +11 -0
  93. data/rbi/sentdm/resources/voice/calls.rbi +46 -11
  94. data/rbi/sentdm/resources/voice/catalogue.rbi +59 -0
  95. data/rbi/sentdm/resources/voice/tokens.rbi +11 -0
  96. data/rbi/sentdm/resources/voice.rbi +84 -0
  97. data/rbi/sentdm/resources/webhooks.rbi +56 -16
  98. data/sig/sentdm/internal/voice_agents_page.rbs +41 -0
  99. data/sig/sentdm/models/call_event_payload.rbs +12 -0
  100. data/sig/sentdm/models/channels/voice_create_params.rbs +9 -4
  101. data/sig/sentdm/models/channels/voice_number.rbs +12 -0
  102. data/sig/sentdm/models/channels/voice_update_params.rbs +5 -0
  103. data/sig/sentdm/models/voice/agent_create_params.rbs +99 -0
  104. data/sig/sentdm/models/voice/agent_delete_params.rbs +34 -0
  105. data/sig/sentdm/models/voice/agent_list_params.rbs +40 -0
  106. data/sig/sentdm/models/voice/agent_retrieve_params.rbs +32 -0
  107. data/sig/sentdm/models/voice/agent_rotate_secret_params.rbs +40 -0
  108. data/sig/sentdm/models/voice/agent_update_params.rbs +108 -0
  109. data/sig/sentdm/models/voice/api_response_of_voice_agent.rbs +41 -0
  110. data/sig/sentdm/models/voice/api_response_of_voice_agent_secret.rbs +41 -0
  111. data/sig/sentdm/models/voice/api_response_of_voice_agents_list.rbs +41 -0
  112. data/sig/sentdm/models/voice/api_response_of_voice_catalogue.rbs +41 -0
  113. data/sig/sentdm/models/voice/call.rbs +65 -0
  114. data/sig/sentdm/models/voice/call_list_params.rbs +10 -0
  115. data/sig/sentdm/models/voice/catalogue_list_params.rbs +27 -0
  116. data/sig/sentdm/models/voice/voice_agent.rbs +116 -0
  117. data/sig/sentdm/models/voice/voice_agent_audio.rbs +19 -0
  118. data/sig/sentdm/models/voice/voice_agent_audio_spec.rbs +17 -0
  119. data/sig/sentdm/models/voice/voice_agent_limits.rbs +38 -0
  120. data/sig/sentdm/models/voice/voice_agent_limits_spec.rbs +34 -0
  121. data/sig/sentdm/models/voice/voice_agent_party.rbs +23 -0
  122. data/sig/sentdm/models/voice/voice_agent_party_spec.rbs +19 -0
  123. data/sig/sentdm/models/voice/voice_agent_secret.rbs +19 -0
  124. data/sig/sentdm/models/voice/voice_agent_speech.rbs +32 -0
  125. data/sig/sentdm/models/voice/voice_agent_speech_spec.rbs +26 -0
  126. data/sig/sentdm/models/voice/voice_agent_transcripts.rbs +23 -0
  127. data/sig/sentdm/models/voice/voice_agent_transcripts_spec.rbs +20 -0
  128. data/sig/sentdm/models/voice/voice_agents_list.rbs +35 -0
  129. data/sig/sentdm/models/voice/voice_catalogue.rbs +35 -0
  130. data/sig/sentdm/models/voice/voice_catalogue_voice.rbs +42 -0
  131. data/sig/sentdm/models/webhook_create_params.rbs +12 -0
  132. data/sig/sentdm/models/webhook_response.rbs +46 -3
  133. data/sig/sentdm/models/webhook_update_params.rbs +5 -0
  134. data/sig/sentdm/resources/channels/voice.rbs +3 -1
  135. data/sig/sentdm/resources/voice/agents.rbs +74 -0
  136. data/sig/sentdm/resources/voice/calls.rbs +2 -0
  137. data/sig/sentdm/resources/voice/catalogue.rbs +14 -0
  138. data/sig/sentdm/resources/voice.rbs +4 -0
  139. data/sig/sentdm/resources/webhooks.rbs +3 -0
  140. metadata +89 -2
@@ -0,0 +1,64 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class AgentRotateSecretParams < Sentdm::Models::MutationRequest
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(
13
+ Sentdm::Voice::AgentRotateSecretParams,
14
+ Sentdm::Internal::AnyHash
15
+ )
16
+ end
17
+
18
+ sig { returns(String) }
19
+ attr_accessor :id
20
+
21
+ sig { returns(T.nilable(String)) }
22
+ attr_reader :idempotency_key
23
+
24
+ sig { params(idempotency_key: String).void }
25
+ attr_writer :idempotency_key
26
+
27
+ sig { returns(T.nilable(String)) }
28
+ attr_reader :x_profile_id
29
+
30
+ sig { params(x_profile_id: String).void }
31
+ attr_writer :x_profile_id
32
+
33
+ sig do
34
+ params(
35
+ id: String,
36
+ idempotency_key: String,
37
+ x_profile_id: String,
38
+ request_options: Sentdm::RequestOptions::OrHash
39
+ ).returns(T.attached_class)
40
+ end
41
+ def self.new(
42
+ id:,
43
+ idempotency_key: nil,
44
+ x_profile_id: nil,
45
+ request_options: {}
46
+ )
47
+ end
48
+
49
+ sig do
50
+ override.returns(
51
+ {
52
+ id: String,
53
+ idempotency_key: String,
54
+ x_profile_id: String,
55
+ request_options: Sentdm::RequestOptions
56
+ }
57
+ )
58
+ end
59
+ def to_hash
60
+ end
61
+ end
62
+ end
63
+ end
64
+ end
@@ -0,0 +1,211 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class AgentUpdateParams < Sentdm::Internal::Type::BaseModel
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(Sentdm::Voice::AgentUpdateParams, Sentdm::Internal::AnyHash)
13
+ end
14
+
15
+ sig { returns(String) }
16
+ attr_accessor :id
17
+
18
+ # Audio sessions: { sample_rate }; null restores the default.
19
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentAudioSpec)) }
20
+ attr_reader :audio
21
+
22
+ sig do
23
+ params(
24
+ audio: T.nilable(Sentdm::Voice::VoiceAgentAudioSpec::OrHash)
25
+ ).void
26
+ end
27
+ attr_writer :audio
28
+
29
+ # A new fallback party, or null for none.
30
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentPartySpec)) }
31
+ attr_reader :fallback
32
+
33
+ sig do
34
+ params(
35
+ fallback: T.nilable(Sentdm::Voice::VoiceAgentPartySpec::OrHash)
36
+ ).void
37
+ end
38
+ attr_writer :fallback
39
+
40
+ # A new greeting, or null for none.
41
+ sig { returns(T.nilable(String)) }
42
+ attr_accessor :greeting
43
+
44
+ # The whole limits object; null restores the defaults.
45
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentLimitsSpec)) }
46
+ attr_reader :limits
47
+
48
+ sig do
49
+ params(
50
+ limits: T.nilable(Sentdm::Voice::VoiceAgentLimitsSpec::OrHash)
51
+ ).void
52
+ end
53
+ attr_writer :limits
54
+
55
+ # A new name, 1 to 100 characters.
56
+ sig { returns(T.nilable(String)) }
57
+ attr_reader :name
58
+
59
+ sig { params(name: String).void }
60
+ attr_writer :name
61
+
62
+ # Sandbox flag - when true, the operation is simulated without side effects Useful
63
+ # for testing integrations without actual execution
64
+ sig { returns(T.nilable(T::Boolean)) }
65
+ attr_reader :sandbox
66
+
67
+ sig { params(sandbox: T::Boolean).void }
68
+ attr_writer :sandbox
69
+
70
+ # text or audio. Changing it drops the settings the other type cannot have
71
+ # (speech, audio, greeting) unless the body sends them.
72
+ sig { returns(T.nilable(String)) }
73
+ attr_reader :session_type
74
+
75
+ sig { params(session_type: String).void }
76
+ attr_writer :session_type
77
+
78
+ # Text sessions: { setting, voice, language }, replaced whole; null restores the
79
+ # defaults.
80
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentSpeechSpec)) }
81
+ attr_reader :speech
82
+
83
+ sig do
84
+ params(
85
+ speech: T.nilable(Sentdm::Voice::VoiceAgentSpeechSpec::OrHash)
86
+ ).void
87
+ end
88
+ attr_writer :speech
89
+
90
+ # The whole list of tools; null restores the default.
91
+ sig { returns(T.nilable(T::Array[String])) }
92
+ attr_accessor :tools
93
+
94
+ # The whole transcripts object; null restores the defaults.
95
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentTranscriptsSpec)) }
96
+ attr_reader :transcripts
97
+
98
+ sig do
99
+ params(
100
+ transcripts:
101
+ T.nilable(Sentdm::Voice::VoiceAgentTranscriptsSpec::OrHash)
102
+ ).void
103
+ end
104
+ attr_writer :transcripts
105
+
106
+ # The whole list of parties; null clears it.
107
+ sig { returns(T.nilable(T::Array[Sentdm::Voice::VoiceAgentPartySpec])) }
108
+ attr_accessor :transfer_targets
109
+
110
+ # A new wss:// URL, or null for an agent that dials in.
111
+ sig { returns(T.nilable(String)) }
112
+ attr_accessor :websocket_url
113
+
114
+ sig { returns(T.nilable(String)) }
115
+ attr_reader :idempotency_key
116
+
117
+ sig { params(idempotency_key: String).void }
118
+ attr_writer :idempotency_key
119
+
120
+ sig { returns(T.nilable(String)) }
121
+ attr_reader :x_profile_id
122
+
123
+ sig { params(x_profile_id: String).void }
124
+ attr_writer :x_profile_id
125
+
126
+ sig do
127
+ params(
128
+ id: String,
129
+ audio: T.nilable(Sentdm::Voice::VoiceAgentAudioSpec::OrHash),
130
+ fallback: T.nilable(Sentdm::Voice::VoiceAgentPartySpec::OrHash),
131
+ greeting: T.nilable(String),
132
+ limits: T.nilable(Sentdm::Voice::VoiceAgentLimitsSpec::OrHash),
133
+ name: String,
134
+ sandbox: T::Boolean,
135
+ session_type: String,
136
+ speech: T.nilable(Sentdm::Voice::VoiceAgentSpeechSpec::OrHash),
137
+ tools: T.nilable(T::Array[String]),
138
+ transcripts:
139
+ T.nilable(Sentdm::Voice::VoiceAgentTranscriptsSpec::OrHash),
140
+ transfer_targets:
141
+ T.nilable(T::Array[Sentdm::Voice::VoiceAgentPartySpec::OrHash]),
142
+ websocket_url: T.nilable(String),
143
+ idempotency_key: String,
144
+ x_profile_id: String,
145
+ request_options: Sentdm::RequestOptions::OrHash
146
+ ).returns(T.attached_class)
147
+ end
148
+ def self.new(
149
+ id:,
150
+ # Audio sessions: { sample_rate }; null restores the default.
151
+ audio: nil,
152
+ # A new fallback party, or null for none.
153
+ fallback: nil,
154
+ # A new greeting, or null for none.
155
+ greeting: nil,
156
+ # The whole limits object; null restores the defaults.
157
+ limits: nil,
158
+ # A new name, 1 to 100 characters.
159
+ name: nil,
160
+ # Sandbox flag - when true, the operation is simulated without side effects Useful
161
+ # for testing integrations without actual execution
162
+ sandbox: nil,
163
+ # text or audio. Changing it drops the settings the other type cannot have
164
+ # (speech, audio, greeting) unless the body sends them.
165
+ session_type: nil,
166
+ # Text sessions: { setting, voice, language }, replaced whole; null restores the
167
+ # defaults.
168
+ speech: nil,
169
+ # The whole list of tools; null restores the default.
170
+ tools: nil,
171
+ # The whole transcripts object; null restores the defaults.
172
+ transcripts: nil,
173
+ # The whole list of parties; null clears it.
174
+ transfer_targets: nil,
175
+ # A new wss:// URL, or null for an agent that dials in.
176
+ websocket_url: nil,
177
+ idempotency_key: nil,
178
+ x_profile_id: nil,
179
+ request_options: {}
180
+ )
181
+ end
182
+
183
+ sig do
184
+ override.returns(
185
+ {
186
+ id: String,
187
+ audio: T.nilable(Sentdm::Voice::VoiceAgentAudioSpec),
188
+ fallback: T.nilable(Sentdm::Voice::VoiceAgentPartySpec),
189
+ greeting: T.nilable(String),
190
+ limits: T.nilable(Sentdm::Voice::VoiceAgentLimitsSpec),
191
+ name: String,
192
+ sandbox: T::Boolean,
193
+ session_type: String,
194
+ speech: T.nilable(Sentdm::Voice::VoiceAgentSpeechSpec),
195
+ tools: T.nilable(T::Array[String]),
196
+ transcripts: T.nilable(Sentdm::Voice::VoiceAgentTranscriptsSpec),
197
+ transfer_targets:
198
+ T.nilable(T::Array[Sentdm::Voice::VoiceAgentPartySpec]),
199
+ websocket_url: T.nilable(String),
200
+ idempotency_key: String,
201
+ x_profile_id: String,
202
+ request_options: Sentdm::RequestOptions
203
+ }
204
+ )
205
+ end
206
+ def to_hash
207
+ end
208
+ end
209
+ end
210
+ end
211
+ end
@@ -0,0 +1,85 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class APIResponseOfVoiceAgent < Sentdm::Internal::Type::BaseModel
7
+ OrHash =
8
+ T.type_alias do
9
+ T.any(
10
+ Sentdm::Voice::APIResponseOfVoiceAgent,
11
+ Sentdm::Internal::AnyHash
12
+ )
13
+ end
14
+
15
+ # A voice agent as stored: what was written with every default filled in, plus the
16
+ # signing secret the one time it is shown (on create, and on rotate). The one
17
+ # shape every read of an agent answers with, on /v3/voice/agents and on the admin
18
+ # API the dashboard uses, so the two cannot drift.
19
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgent)) }
20
+ attr_reader :data
21
+
22
+ sig { params(data: T.nilable(Sentdm::Voice::VoiceAgent::OrHash)).void }
23
+ attr_writer :data
24
+
25
+ # Error information
26
+ sig { returns(T.nilable(Sentdm::ErrorDetail)) }
27
+ attr_reader :error
28
+
29
+ sig { params(error: T.nilable(Sentdm::ErrorDetail::OrHash)).void }
30
+ attr_writer :error
31
+
32
+ # Request and response metadata
33
+ sig { returns(T.nilable(Sentdm::APIMeta)) }
34
+ attr_reader :meta
35
+
36
+ sig { params(meta: Sentdm::APIMeta::OrHash).void }
37
+ attr_writer :meta
38
+
39
+ # Indicates whether the request was successful
40
+ sig { returns(T.nilable(T::Boolean)) }
41
+ attr_reader :success
42
+
43
+ sig { params(success: T::Boolean).void }
44
+ attr_writer :success
45
+
46
+ # Standard API response envelope for all v3 endpoints
47
+ sig do
48
+ params(
49
+ data: T.nilable(Sentdm::Voice::VoiceAgent::OrHash),
50
+ error: T.nilable(Sentdm::ErrorDetail::OrHash),
51
+ meta: Sentdm::APIMeta::OrHash,
52
+ success: T::Boolean
53
+ ).returns(T.attached_class)
54
+ end
55
+ def self.new(
56
+ # A voice agent as stored: what was written with every default filled in, plus the
57
+ # signing secret the one time it is shown (on create, and on rotate). The one
58
+ # shape every read of an agent answers with, on /v3/voice/agents and on the admin
59
+ # API the dashboard uses, so the two cannot drift.
60
+ data: nil,
61
+ # Error information
62
+ error: nil,
63
+ # Request and response metadata
64
+ meta: nil,
65
+ # Indicates whether the request was successful
66
+ success: nil
67
+ )
68
+ end
69
+
70
+ sig do
71
+ override.returns(
72
+ {
73
+ data: T.nilable(Sentdm::Voice::VoiceAgent),
74
+ error: T.nilable(Sentdm::ErrorDetail),
75
+ meta: Sentdm::APIMeta,
76
+ success: T::Boolean
77
+ }
78
+ )
79
+ end
80
+ def to_hash
81
+ end
82
+ end
83
+ end
84
+ end
85
+ end
@@ -0,0 +1,81 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class APIResponseOfVoiceAgentSecret < Sentdm::Internal::Type::BaseModel
7
+ OrHash =
8
+ T.type_alias do
9
+ T.any(
10
+ Sentdm::Voice::APIResponseOfVoiceAgentSecret,
11
+ Sentdm::Internal::AnyHash
12
+ )
13
+ end
14
+
15
+ # A freshly rotated signing secret.
16
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentSecret)) }
17
+ attr_reader :data
18
+
19
+ sig do
20
+ params(data: T.nilable(Sentdm::Voice::VoiceAgentSecret::OrHash)).void
21
+ end
22
+ attr_writer :data
23
+
24
+ # Error information
25
+ sig { returns(T.nilable(Sentdm::ErrorDetail)) }
26
+ attr_reader :error
27
+
28
+ sig { params(error: T.nilable(Sentdm::ErrorDetail::OrHash)).void }
29
+ attr_writer :error
30
+
31
+ # Request and response metadata
32
+ sig { returns(T.nilable(Sentdm::APIMeta)) }
33
+ attr_reader :meta
34
+
35
+ sig { params(meta: Sentdm::APIMeta::OrHash).void }
36
+ attr_writer :meta
37
+
38
+ # Indicates whether the request was successful
39
+ sig { returns(T.nilable(T::Boolean)) }
40
+ attr_reader :success
41
+
42
+ sig { params(success: T::Boolean).void }
43
+ attr_writer :success
44
+
45
+ # Standard API response envelope for all v3 endpoints
46
+ sig do
47
+ params(
48
+ data: T.nilable(Sentdm::Voice::VoiceAgentSecret::OrHash),
49
+ error: T.nilable(Sentdm::ErrorDetail::OrHash),
50
+ meta: Sentdm::APIMeta::OrHash,
51
+ success: T::Boolean
52
+ ).returns(T.attached_class)
53
+ end
54
+ def self.new(
55
+ # A freshly rotated signing secret.
56
+ data: nil,
57
+ # Error information
58
+ error: nil,
59
+ # Request and response metadata
60
+ meta: nil,
61
+ # Indicates whether the request was successful
62
+ success: nil
63
+ )
64
+ end
65
+
66
+ sig do
67
+ override.returns(
68
+ {
69
+ data: T.nilable(Sentdm::Voice::VoiceAgentSecret),
70
+ error: T.nilable(Sentdm::ErrorDetail),
71
+ meta: Sentdm::APIMeta,
72
+ success: T::Boolean
73
+ }
74
+ )
75
+ end
76
+ def to_hash
77
+ end
78
+ end
79
+ end
80
+ end
81
+ end
@@ -0,0 +1,83 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class APIResponseOfVoiceAgentsList < Sentdm::Internal::Type::BaseModel
7
+ OrHash =
8
+ T.type_alias do
9
+ T.any(
10
+ Sentdm::Voice::APIResponseOfVoiceAgentsList,
11
+ Sentdm::Internal::AnyHash
12
+ )
13
+ end
14
+
15
+ # A page of the account's agents. The agent itself is VoiceAgentResponse, shared
16
+ # with the admin API.
17
+ sig { returns(T.nilable(Sentdm::Voice::VoiceAgentsList)) }
18
+ attr_reader :data
19
+
20
+ sig do
21
+ params(data: T.nilable(Sentdm::Voice::VoiceAgentsList::OrHash)).void
22
+ end
23
+ attr_writer :data
24
+
25
+ # Error information
26
+ sig { returns(T.nilable(Sentdm::ErrorDetail)) }
27
+ attr_reader :error
28
+
29
+ sig { params(error: T.nilable(Sentdm::ErrorDetail::OrHash)).void }
30
+ attr_writer :error
31
+
32
+ # Request and response metadata
33
+ sig { returns(T.nilable(Sentdm::APIMeta)) }
34
+ attr_reader :meta
35
+
36
+ sig { params(meta: Sentdm::APIMeta::OrHash).void }
37
+ attr_writer :meta
38
+
39
+ # Indicates whether the request was successful
40
+ sig { returns(T.nilable(T::Boolean)) }
41
+ attr_reader :success
42
+
43
+ sig { params(success: T::Boolean).void }
44
+ attr_writer :success
45
+
46
+ # Standard API response envelope for all v3 endpoints
47
+ sig do
48
+ params(
49
+ data: T.nilable(Sentdm::Voice::VoiceAgentsList::OrHash),
50
+ error: T.nilable(Sentdm::ErrorDetail::OrHash),
51
+ meta: Sentdm::APIMeta::OrHash,
52
+ success: T::Boolean
53
+ ).returns(T.attached_class)
54
+ end
55
+ def self.new(
56
+ # A page of the account's agents. The agent itself is VoiceAgentResponse, shared
57
+ # with the admin API.
58
+ data: nil,
59
+ # Error information
60
+ error: nil,
61
+ # Request and response metadata
62
+ meta: nil,
63
+ # Indicates whether the request was successful
64
+ success: nil
65
+ )
66
+ end
67
+
68
+ sig do
69
+ override.returns(
70
+ {
71
+ data: T.nilable(Sentdm::Voice::VoiceAgentsList),
72
+ error: T.nilable(Sentdm::ErrorDetail),
73
+ meta: Sentdm::APIMeta,
74
+ success: T::Boolean
75
+ }
76
+ )
77
+ end
78
+ def to_hash
79
+ end
80
+ end
81
+ end
82
+ end
83
+ end
@@ -0,0 +1,83 @@
1
+ # typed: strong
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Voice
6
+ class APIResponseOfVoiceCatalogue < Sentdm::Internal::Type::BaseModel
7
+ OrHash =
8
+ T.type_alias do
9
+ T.any(
10
+ Sentdm::Voice::APIResponseOfVoiceCatalogue,
11
+ Sentdm::Internal::AnyHash
12
+ )
13
+ end
14
+
15
+ # The voices and languages a text-session agent may name in its speech settings:
16
+ # what GET /v3/voice/voices and the admin GET /voice/voices answer, in one shape.
17
+ sig { returns(T.nilable(Sentdm::Voice::VoiceCatalogue)) }
18
+ attr_reader :data
19
+
20
+ sig do
21
+ params(data: T.nilable(Sentdm::Voice::VoiceCatalogue::OrHash)).void
22
+ end
23
+ attr_writer :data
24
+
25
+ # Error information
26
+ sig { returns(T.nilable(Sentdm::ErrorDetail)) }
27
+ attr_reader :error
28
+
29
+ sig { params(error: T.nilable(Sentdm::ErrorDetail::OrHash)).void }
30
+ attr_writer :error
31
+
32
+ # Request and response metadata
33
+ sig { returns(T.nilable(Sentdm::APIMeta)) }
34
+ attr_reader :meta
35
+
36
+ sig { params(meta: Sentdm::APIMeta::OrHash).void }
37
+ attr_writer :meta
38
+
39
+ # Indicates whether the request was successful
40
+ sig { returns(T.nilable(T::Boolean)) }
41
+ attr_reader :success
42
+
43
+ sig { params(success: T::Boolean).void }
44
+ attr_writer :success
45
+
46
+ # Standard API response envelope for all v3 endpoints
47
+ sig do
48
+ params(
49
+ data: T.nilable(Sentdm::Voice::VoiceCatalogue::OrHash),
50
+ error: T.nilable(Sentdm::ErrorDetail::OrHash),
51
+ meta: Sentdm::APIMeta::OrHash,
52
+ success: T::Boolean
53
+ ).returns(T.attached_class)
54
+ end
55
+ def self.new(
56
+ # The voices and languages a text-session agent may name in its speech settings:
57
+ # what GET /v3/voice/voices and the admin GET /voice/voices answer, in one shape.
58
+ data: nil,
59
+ # Error information
60
+ error: nil,
61
+ # Request and response metadata
62
+ meta: nil,
63
+ # Indicates whether the request was successful
64
+ success: nil
65
+ )
66
+ end
67
+
68
+ sig do
69
+ override.returns(
70
+ {
71
+ data: T.nilable(Sentdm::Voice::VoiceCatalogue),
72
+ error: T.nilable(Sentdm::ErrorDetail),
73
+ meta: Sentdm::APIMeta,
74
+ success: T::Boolean
75
+ }
76
+ )
77
+ end
78
+ def to_hash
79
+ end
80
+ end
81
+ end
82
+ end
83
+ end