telnyx 5.119.0 → 5.121.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 (49) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/README.md +1 -1
  4. data/lib/telnyx/client.rb +6 -0
  5. data/lib/telnyx/models/call_dial_params.rb +551 -1
  6. data/lib/telnyx/models/calls/action_answer_params.rb +556 -1
  7. data/lib/telnyx/models/calls/action_gather_using_speak_params.rb +2 -2
  8. data/lib/telnyx/models/calls/action_speak_params.rb +2 -2
  9. data/lib/telnyx/models/calls/action_start_conversation_relay_params.rb +411 -84
  10. data/lib/telnyx/models/conferences/action_speak_params.rb +2 -2
  11. data/lib/telnyx/models/voice_sdk_call_report_list_params.rb +56 -0
  12. data/lib/telnyx/models/voice_sdk_call_report_list_response.rb +385 -0
  13. data/lib/telnyx/models/voice_sdk_call_report_retrieve_params.rb +20 -0
  14. data/lib/telnyx/models/voice_sdk_call_report_retrieve_response.rb +390 -0
  15. data/lib/telnyx/models.rb +4 -0
  16. data/lib/telnyx/resources/calls/actions.rb +26 -8
  17. data/lib/telnyx/resources/calls.rb +3 -1
  18. data/lib/telnyx/resources/voice_sdk_call_reports.rb +71 -0
  19. data/lib/telnyx/version.rb +1 -1
  20. data/lib/telnyx.rb +5 -0
  21. data/rbi/telnyx/client.rbi +5 -0
  22. data/rbi/telnyx/models/call_dial_params.rbi +1273 -0
  23. data/rbi/telnyx/models/calls/action_answer_params.rbi +1279 -0
  24. data/rbi/telnyx/models/calls/action_gather_using_speak_params.rbi +4 -4
  25. data/rbi/telnyx/models/calls/action_speak_params.rbi +4 -4
  26. data/rbi/telnyx/models/calls/action_start_conversation_relay_params.rbi +928 -133
  27. data/rbi/telnyx/models/conferences/action_speak_params.rbi +4 -4
  28. data/rbi/telnyx/models/voice_sdk_call_report_list_params.rbi +108 -0
  29. data/rbi/telnyx/models/voice_sdk_call_report_list_response.rbi +774 -0
  30. data/rbi/telnyx/models/voice_sdk_call_report_retrieve_params.rbi +38 -0
  31. data/rbi/telnyx/models/voice_sdk_call_report_retrieve_response.rbi +782 -0
  32. data/rbi/telnyx/models.rbi +5 -0
  33. data/rbi/telnyx/resources/calls/actions.rbi +73 -24
  34. data/rbi/telnyx/resources/calls.rbi +9 -0
  35. data/rbi/telnyx/resources/conferences/actions.rbi +2 -2
  36. data/rbi/telnyx/resources/voice_sdk_call_reports.rbi +58 -0
  37. data/sig/telnyx/client.rbs +2 -0
  38. data/sig/telnyx/models/call_dial_params.rbs +440 -0
  39. data/sig/telnyx/models/calls/action_answer_params.rbs +440 -0
  40. data/sig/telnyx/models/calls/action_start_conversation_relay_params.rbs +317 -51
  41. data/sig/telnyx/models/voice_sdk_call_report_list_params.rbs +57 -0
  42. data/sig/telnyx/models/voice_sdk_call_report_list_response.rbs +340 -0
  43. data/sig/telnyx/models/voice_sdk_call_report_retrieve_params.rbs +23 -0
  44. data/sig/telnyx/models/voice_sdk_call_report_retrieve_response.rbs +345 -0
  45. data/sig/telnyx/models.rbs +4 -0
  46. data/sig/telnyx/resources/calls/actions.rbs +12 -3
  47. data/sig/telnyx/resources/calls.rbs +1 -0
  48. data/sig/telnyx/resources/voice_sdk_call_reports.rbs +19 -0
  49. metadata +17 -2
@@ -0,0 +1,774 @@
1
+ # typed: strong
2
+
3
+ module Telnyx
4
+ module Models
5
+ class VoiceSDKCallReportListResponse < Telnyx::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ Telnyx::Models::VoiceSDKCallReportListResponse,
10
+ Telnyx::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ # Unique call identifier.
15
+ sig { returns(T.nilable(String)) }
16
+ attr_reader :call_id
17
+
18
+ sig { params(call_id: String).void }
19
+ attr_writer :call_id
20
+
21
+ # User-scoped storage grouping identifier derived from the authenticated user.
22
+ # This is not a unique per-call report identifier and may be shared by multiple
23
+ # calls for the same user.
24
+ sig { returns(T.nilable(String)) }
25
+ attr_reader :call_report_id
26
+
27
+ sig { params(call_report_id: String).void }
28
+ attr_writer :call_report_id
29
+
30
+ # Creation timestamp when present.
31
+ sig { returns(T.nilable(Time)) }
32
+ attr_reader :created_at
33
+
34
+ sig { params(created_at: Time).void }
35
+ attr_writer :created_at
36
+
37
+ # Reason the SDK flushed this stats report segment, for example an intermediate
38
+ # socket-close flush.
39
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
40
+ attr_reader :flush_reason
41
+
42
+ sig { params(flush_reason: T::Hash[Symbol, T.anything]).void }
43
+ attr_writer :flush_reason
44
+
45
+ # Raw logs payload emitted by the Voice SDK and stored without normalization. Live
46
+ # responses commonly return an array of log entries, but object-shaped log
47
+ # payloads are also allowed for compatibility.
48
+ sig do
49
+ returns(
50
+ T.nilable(
51
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Variants
52
+ )
53
+ )
54
+ end
55
+ attr_reader :logs
56
+
57
+ sig do
58
+ params(
59
+ logs:
60
+ T.any(
61
+ T::Array[
62
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::OrHash
63
+ ],
64
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::OrHash
65
+ )
66
+ ).void
67
+ end
68
+ attr_writer :logs
69
+
70
+ # Organization associated with the stored call report when provided by the Voice
71
+ # SDK reporting path.
72
+ sig { returns(T.nilable(String)) }
73
+ attr_reader :organization_id
74
+
75
+ sig { params(organization_id: String).void }
76
+ attr_writer :organization_id
77
+
78
+ # Zero-based stats segment index when the SDK sends segmented or intermediate
79
+ # reports.
80
+ sig { returns(T.nilable(Integer)) }
81
+ attr_reader :segment
82
+
83
+ sig { params(segment: Integer).void }
84
+ attr_writer :segment
85
+
86
+ # Raw stats payload emitted by the Voice SDK and stored without normalization. The
87
+ # exact shape can vary by SDK platform and version. Live responses commonly return
88
+ # an array of interval snapshots, but object-shaped stats payloads are also
89
+ # allowed for compatibility.
90
+ sig do
91
+ returns(
92
+ T.nilable(
93
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::Variants
94
+ )
95
+ )
96
+ end
97
+ attr_reader :stats
98
+
99
+ sig do
100
+ params(
101
+ stats:
102
+ T.any(
103
+ T::Array[T::Hash[Symbol, T.anything]],
104
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::UnionMember1::OrHash
105
+ )
106
+ ).void
107
+ end
108
+ attr_writer :stats
109
+
110
+ # Time when the call report was stored.
111
+ sig { returns(T.nilable(Time)) }
112
+ attr_reader :stored_at
113
+
114
+ sig { params(stored_at: Time).void }
115
+ attr_writer :stored_at
116
+
117
+ # High-level call metadata.
118
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
119
+ attr_reader :summary
120
+
121
+ sig { params(summary: T::Hash[Symbol, T.anything]).void }
122
+ attr_writer :summary
123
+
124
+ # Telnyx call leg identifier for correlating the report with call-control, SIP,
125
+ # and media troubleshooting data.
126
+ sig { returns(T.nilable(String)) }
127
+ attr_reader :telnyx_leg_id
128
+
129
+ sig { params(telnyx_leg_id: String).void }
130
+ attr_writer :telnyx_leg_id
131
+
132
+ # Telnyx RTC session identifier for correlating the report with Voice SDK
133
+ # signaling and media-session logs.
134
+ sig { returns(T.nilable(String)) }
135
+ attr_reader :telnyx_session_id
136
+
137
+ sig { params(telnyx_session_id: String).void }
138
+ attr_writer :telnyx_session_id
139
+
140
+ # Voice SDK user agent string reported by the client. This is the preferred
141
+ # SDK/platform/version dimension when present.
142
+ sig { returns(T.nilable(String)) }
143
+ attr_reader :user_agent
144
+
145
+ sig { params(user_agent: String).void }
146
+ attr_writer :user_agent
147
+
148
+ # Authenticated user that owns the call report.
149
+ sig { returns(T.nilable(String)) }
150
+ attr_reader :user_id
151
+
152
+ sig { params(user_id: String).void }
153
+ attr_writer :user_id
154
+
155
+ # Legacy SDK version value when the client reports one separately from the user
156
+ # agent.
157
+ sig { returns(T.nilable(String)) }
158
+ attr_reader :version
159
+
160
+ sig { params(version: String).void }
161
+ attr_writer :version
162
+
163
+ # Voice SDK instance identifier.
164
+ sig { returns(T.nilable(String)) }
165
+ attr_reader :voice_sdk_id
166
+
167
+ sig { params(voice_sdk_id: String).void }
168
+ attr_writer :voice_sdk_id
169
+
170
+ # Decoded Voice SDK identifier metadata emitted by voice-sdk-proxy when available.
171
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
172
+ attr_reader :voice_sdk_id_decoded
173
+
174
+ sig { params(voice_sdk_id_decoded: T::Hash[Symbol, T.anything]).void }
175
+ attr_writer :voice_sdk_id_decoded
176
+
177
+ # Voice SDK session correlation identifier used to group stats segments for the
178
+ # same SDK session.
179
+ sig { returns(T.nilable(String)) }
180
+ attr_reader :voice_sdk_session_id
181
+
182
+ sig { params(voice_sdk_session_id: String).void }
183
+ attr_writer :voice_sdk_session_id
184
+
185
+ # A raw call report stats JSON payload. The schema is intentionally permissive
186
+ # because Voice SDK clients can add fields over time.
187
+ sig do
188
+ params(
189
+ call_id: String,
190
+ call_report_id: String,
191
+ created_at: Time,
192
+ flush_reason: T::Hash[Symbol, T.anything],
193
+ logs:
194
+ T.any(
195
+ T::Array[
196
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::OrHash
197
+ ],
198
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::OrHash
199
+ ),
200
+ organization_id: String,
201
+ segment: Integer,
202
+ stats:
203
+ T.any(
204
+ T::Array[T::Hash[Symbol, T.anything]],
205
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::UnionMember1::OrHash
206
+ ),
207
+ stored_at: Time,
208
+ summary: T::Hash[Symbol, T.anything],
209
+ telnyx_leg_id: String,
210
+ telnyx_session_id: String,
211
+ user_agent: String,
212
+ user_id: String,
213
+ version: String,
214
+ voice_sdk_id: String,
215
+ voice_sdk_id_decoded: T::Hash[Symbol, T.anything],
216
+ voice_sdk_session_id: String
217
+ ).returns(T.attached_class)
218
+ end
219
+ def self.new(
220
+ # Unique call identifier.
221
+ call_id: nil,
222
+ # User-scoped storage grouping identifier derived from the authenticated user.
223
+ # This is not a unique per-call report identifier and may be shared by multiple
224
+ # calls for the same user.
225
+ call_report_id: nil,
226
+ # Creation timestamp when present.
227
+ created_at: nil,
228
+ # Reason the SDK flushed this stats report segment, for example an intermediate
229
+ # socket-close flush.
230
+ flush_reason: nil,
231
+ # Raw logs payload emitted by the Voice SDK and stored without normalization. Live
232
+ # responses commonly return an array of log entries, but object-shaped log
233
+ # payloads are also allowed for compatibility.
234
+ logs: nil,
235
+ # Organization associated with the stored call report when provided by the Voice
236
+ # SDK reporting path.
237
+ organization_id: nil,
238
+ # Zero-based stats segment index when the SDK sends segmented or intermediate
239
+ # reports.
240
+ segment: nil,
241
+ # Raw stats payload emitted by the Voice SDK and stored without normalization. The
242
+ # exact shape can vary by SDK platform and version. Live responses commonly return
243
+ # an array of interval snapshots, but object-shaped stats payloads are also
244
+ # allowed for compatibility.
245
+ stats: nil,
246
+ # Time when the call report was stored.
247
+ stored_at: nil,
248
+ # High-level call metadata.
249
+ summary: nil,
250
+ # Telnyx call leg identifier for correlating the report with call-control, SIP,
251
+ # and media troubleshooting data.
252
+ telnyx_leg_id: nil,
253
+ # Telnyx RTC session identifier for correlating the report with Voice SDK
254
+ # signaling and media-session logs.
255
+ telnyx_session_id: nil,
256
+ # Voice SDK user agent string reported by the client. This is the preferred
257
+ # SDK/platform/version dimension when present.
258
+ user_agent: nil,
259
+ # Authenticated user that owns the call report.
260
+ user_id: nil,
261
+ # Legacy SDK version value when the client reports one separately from the user
262
+ # agent.
263
+ version: nil,
264
+ # Voice SDK instance identifier.
265
+ voice_sdk_id: nil,
266
+ # Decoded Voice SDK identifier metadata emitted by voice-sdk-proxy when available.
267
+ voice_sdk_id_decoded: nil,
268
+ # Voice SDK session correlation identifier used to group stats segments for the
269
+ # same SDK session.
270
+ voice_sdk_session_id: nil
271
+ )
272
+ end
273
+
274
+ sig do
275
+ override.returns(
276
+ {
277
+ call_id: String,
278
+ call_report_id: String,
279
+ created_at: Time,
280
+ flush_reason: T::Hash[Symbol, T.anything],
281
+ logs:
282
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Variants,
283
+ organization_id: String,
284
+ segment: Integer,
285
+ stats:
286
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::Variants,
287
+ stored_at: Time,
288
+ summary: T::Hash[Symbol, T.anything],
289
+ telnyx_leg_id: String,
290
+ telnyx_session_id: String,
291
+ user_agent: String,
292
+ user_id: String,
293
+ version: String,
294
+ voice_sdk_id: String,
295
+ voice_sdk_id_decoded: T::Hash[Symbol, T.anything],
296
+ voice_sdk_session_id: String
297
+ }
298
+ )
299
+ end
300
+ def to_hash
301
+ end
302
+
303
+ # Raw logs payload emitted by the Voice SDK and stored without normalization. Live
304
+ # responses commonly return an array of log entries, but object-shaped log
305
+ # payloads are also allowed for compatibility.
306
+ module Logs
307
+ extend Telnyx::Internal::Type::Union
308
+
309
+ Variants =
310
+ T.type_alias do
311
+ T.any(
312
+ T::Array[
313
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0
314
+ ],
315
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries
316
+ )
317
+ end
318
+
319
+ class UnionMember0 < Telnyx::Internal::Type::BaseModel
320
+ OrHash =
321
+ T.type_alias do
322
+ T.any(
323
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0,
324
+ Telnyx::Internal::AnyHash
325
+ )
326
+ end
327
+
328
+ # Raw structured context attached to the log entry.
329
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
330
+ attr_reader :context
331
+
332
+ sig { params(context: T::Hash[Symbol, T.anything]).void }
333
+ attr_writer :context
334
+
335
+ # Log level emitted by the SDK.
336
+ sig do
337
+ returns(
338
+ T.nilable(
339
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
340
+ )
341
+ )
342
+ end
343
+ attr_reader :level
344
+
345
+ sig do
346
+ params(
347
+ level:
348
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::OrSymbol
349
+ ).void
350
+ end
351
+ attr_writer :level
352
+
353
+ # Log message.
354
+ sig { returns(T.nilable(String)) }
355
+ attr_reader :message
356
+
357
+ sig { params(message: String).void }
358
+ attr_writer :message
359
+
360
+ # Time when the log entry was emitted.
361
+ sig { returns(T.nilable(Time)) }
362
+ attr_reader :timestamp
363
+
364
+ sig { params(timestamp: Time).void }
365
+ attr_writer :timestamp
366
+
367
+ # A raw Voice SDK log entry. Additional SDK-specific fields may be present.
368
+ sig do
369
+ params(
370
+ context: T::Hash[Symbol, T.anything],
371
+ level:
372
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::OrSymbol,
373
+ message: String,
374
+ timestamp: Time
375
+ ).returns(T.attached_class)
376
+ end
377
+ def self.new(
378
+ # Raw structured context attached to the log entry.
379
+ context: nil,
380
+ # Log level emitted by the SDK.
381
+ level: nil,
382
+ # Log message.
383
+ message: nil,
384
+ # Time when the log entry was emitted.
385
+ timestamp: nil
386
+ )
387
+ end
388
+
389
+ sig do
390
+ override.returns(
391
+ {
392
+ context: T::Hash[Symbol, T.anything],
393
+ level:
394
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol,
395
+ message: String,
396
+ timestamp: Time
397
+ }
398
+ )
399
+ end
400
+ def to_hash
401
+ end
402
+
403
+ # Log level emitted by the SDK.
404
+ module Level
405
+ extend Telnyx::Internal::Type::Enum
406
+
407
+ TaggedSymbol =
408
+ T.type_alias do
409
+ T.all(
410
+ Symbol,
411
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level
412
+ )
413
+ end
414
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
415
+
416
+ DEBUG =
417
+ T.let(
418
+ :debug,
419
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
420
+ )
421
+ INFO =
422
+ T.let(
423
+ :info,
424
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
425
+ )
426
+ WARN =
427
+ T.let(
428
+ :warn,
429
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
430
+ )
431
+ ERROR =
432
+ T.let(
433
+ :error,
434
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
435
+ )
436
+
437
+ sig do
438
+ override.returns(
439
+ T::Array[
440
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0::Level::TaggedSymbol
441
+ ]
442
+ )
443
+ end
444
+ def self.values
445
+ end
446
+ end
447
+ end
448
+
449
+ class Entries < Telnyx::Internal::Type::BaseModel
450
+ OrHash =
451
+ T.type_alias do
452
+ T.any(
453
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries,
454
+ Telnyx::Internal::AnyHash
455
+ )
456
+ end
457
+
458
+ # Raw log entries when the SDK groups logs under an entries field.
459
+ sig do
460
+ returns(
461
+ T.nilable(
462
+ T::Array[
463
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry
464
+ ]
465
+ )
466
+ )
467
+ end
468
+ attr_reader :entries
469
+
470
+ sig do
471
+ params(
472
+ entries:
473
+ T::Array[
474
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::OrHash
475
+ ]
476
+ ).void
477
+ end
478
+ attr_writer :entries
479
+
480
+ # Raw logs object emitted by the Voice SDK when logs are grouped under an entries
481
+ # field.
482
+ sig do
483
+ params(
484
+ entries:
485
+ T::Array[
486
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::OrHash
487
+ ]
488
+ ).returns(T.attached_class)
489
+ end
490
+ def self.new(
491
+ # Raw log entries when the SDK groups logs under an entries field.
492
+ entries: nil
493
+ )
494
+ end
495
+
496
+ sig do
497
+ override.returns(
498
+ {
499
+ entries:
500
+ T::Array[
501
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry
502
+ ]
503
+ }
504
+ )
505
+ end
506
+ def to_hash
507
+ end
508
+
509
+ class Entry < Telnyx::Internal::Type::BaseModel
510
+ OrHash =
511
+ T.type_alias do
512
+ T.any(
513
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry,
514
+ Telnyx::Internal::AnyHash
515
+ )
516
+ end
517
+
518
+ # Raw structured context attached to the log entry.
519
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
520
+ attr_reader :context
521
+
522
+ sig { params(context: T::Hash[Symbol, T.anything]).void }
523
+ attr_writer :context
524
+
525
+ # Log level emitted by the SDK.
526
+ sig do
527
+ returns(
528
+ T.nilable(
529
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
530
+ )
531
+ )
532
+ end
533
+ attr_reader :level
534
+
535
+ sig do
536
+ params(
537
+ level:
538
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::OrSymbol
539
+ ).void
540
+ end
541
+ attr_writer :level
542
+
543
+ # Log message.
544
+ sig { returns(T.nilable(String)) }
545
+ attr_reader :message
546
+
547
+ sig { params(message: String).void }
548
+ attr_writer :message
549
+
550
+ # Time when the log entry was emitted.
551
+ sig { returns(T.nilable(Time)) }
552
+ attr_reader :timestamp
553
+
554
+ sig { params(timestamp: Time).void }
555
+ attr_writer :timestamp
556
+
557
+ # A raw Voice SDK log entry. Additional SDK-specific fields may be present.
558
+ sig do
559
+ params(
560
+ context: T::Hash[Symbol, T.anything],
561
+ level:
562
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::OrSymbol,
563
+ message: String,
564
+ timestamp: Time
565
+ ).returns(T.attached_class)
566
+ end
567
+ def self.new(
568
+ # Raw structured context attached to the log entry.
569
+ context: nil,
570
+ # Log level emitted by the SDK.
571
+ level: nil,
572
+ # Log message.
573
+ message: nil,
574
+ # Time when the log entry was emitted.
575
+ timestamp: nil
576
+ )
577
+ end
578
+
579
+ sig do
580
+ override.returns(
581
+ {
582
+ context: T::Hash[Symbol, T.anything],
583
+ level:
584
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol,
585
+ message: String,
586
+ timestamp: Time
587
+ }
588
+ )
589
+ end
590
+ def to_hash
591
+ end
592
+
593
+ # Log level emitted by the SDK.
594
+ module Level
595
+ extend Telnyx::Internal::Type::Enum
596
+
597
+ TaggedSymbol =
598
+ T.type_alias do
599
+ T.all(
600
+ Symbol,
601
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level
602
+ )
603
+ end
604
+ OrSymbol = T.type_alias { T.any(Symbol, String) }
605
+
606
+ DEBUG =
607
+ T.let(
608
+ :debug,
609
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
610
+ )
611
+ INFO =
612
+ T.let(
613
+ :info,
614
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
615
+ )
616
+ WARN =
617
+ T.let(
618
+ :warn,
619
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
620
+ )
621
+ ERROR =
622
+ T.let(
623
+ :error,
624
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
625
+ )
626
+
627
+ sig do
628
+ override.returns(
629
+ T::Array[
630
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Entries::Entry::Level::TaggedSymbol
631
+ ]
632
+ )
633
+ end
634
+ def self.values
635
+ end
636
+ end
637
+ end
638
+ end
639
+
640
+ sig do
641
+ override.returns(
642
+ T::Array[
643
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::Variants
644
+ ]
645
+ )
646
+ end
647
+ def self.variants
648
+ end
649
+
650
+ UnionMember0Array =
651
+ T.let(
652
+ Telnyx::Internal::Type::ArrayOf[
653
+ Telnyx::Models::VoiceSDKCallReportListResponse::Logs::UnionMember0
654
+ ],
655
+ Telnyx::Internal::Type::Converter
656
+ )
657
+ end
658
+
659
+ # Raw stats payload emitted by the Voice SDK and stored without normalization. The
660
+ # exact shape can vary by SDK platform and version. Live responses commonly return
661
+ # an array of interval snapshots, but object-shaped stats payloads are also
662
+ # allowed for compatibility.
663
+ module Stats
664
+ extend Telnyx::Internal::Type::Union
665
+
666
+ Variants =
667
+ T.type_alias do
668
+ T.any(
669
+ T::Array[T::Hash[Symbol, T.anything]],
670
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::UnionMember1
671
+ )
672
+ end
673
+
674
+ class UnionMember1 < Telnyx::Internal::Type::BaseModel
675
+ OrHash =
676
+ T.type_alias do
677
+ T.any(
678
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::UnionMember1,
679
+ Telnyx::Internal::AnyHash
680
+ )
681
+ end
682
+
683
+ # Raw audio stats such as inbound/outbound packet, byte, jitter, packet-loss,
684
+ # bitrate, and audio-level metrics.
685
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
686
+ attr_reader :audio
687
+
688
+ sig { params(audio: T::Hash[Symbol, T.anything]).void }
689
+ attr_writer :audio
690
+
691
+ # Raw connection stats such as round-trip time, packets, and bytes sent or
692
+ # received.
693
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
694
+ attr_reader :connection
695
+
696
+ sig { params(connection: T::Hash[Symbol, T.anything]).void }
697
+ attr_writer :connection
698
+
699
+ # Raw ICE candidate-pair information, including selected pair, local/remote
700
+ # candidates, state, and nomination data when provided by the SDK.
701
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
702
+ attr_reader :ice
703
+
704
+ sig { params(ice: T::Hash[Symbol, T.anything]).void }
705
+ attr_writer :ice
706
+
707
+ # Raw transport stats such as ICE state, DTLS state, SRTP cipher, TLS version, and
708
+ # selected-candidate-pair changes.
709
+ sig { returns(T.nilable(T::Hash[Symbol, T.anything])) }
710
+ attr_reader :transport
711
+
712
+ sig { params(transport: T::Hash[Symbol, T.anything]).void }
713
+ attr_writer :transport
714
+
715
+ # Raw stats object emitted by the Voice SDK.
716
+ sig do
717
+ params(
718
+ audio: T::Hash[Symbol, T.anything],
719
+ connection: T::Hash[Symbol, T.anything],
720
+ ice: T::Hash[Symbol, T.anything],
721
+ transport: T::Hash[Symbol, T.anything]
722
+ ).returns(T.attached_class)
723
+ end
724
+ def self.new(
725
+ # Raw audio stats such as inbound/outbound packet, byte, jitter, packet-loss,
726
+ # bitrate, and audio-level metrics.
727
+ audio: nil,
728
+ # Raw connection stats such as round-trip time, packets, and bytes sent or
729
+ # received.
730
+ connection: nil,
731
+ # Raw ICE candidate-pair information, including selected pair, local/remote
732
+ # candidates, state, and nomination data when provided by the SDK.
733
+ ice: nil,
734
+ # Raw transport stats such as ICE state, DTLS state, SRTP cipher, TLS version, and
735
+ # selected-candidate-pair changes.
736
+ transport: nil
737
+ )
738
+ end
739
+
740
+ sig do
741
+ override.returns(
742
+ {
743
+ audio: T::Hash[Symbol, T.anything],
744
+ connection: T::Hash[Symbol, T.anything],
745
+ ice: T::Hash[Symbol, T.anything],
746
+ transport: T::Hash[Symbol, T.anything]
747
+ }
748
+ )
749
+ end
750
+ def to_hash
751
+ end
752
+ end
753
+
754
+ sig do
755
+ override.returns(
756
+ T::Array[
757
+ Telnyx::Models::VoiceSDKCallReportListResponse::Stats::Variants
758
+ ]
759
+ )
760
+ end
761
+ def self.variants
762
+ end
763
+
764
+ UnionMember0Array =
765
+ T.let(
766
+ Telnyx::Internal::Type::ArrayOf[
767
+ Telnyx::Internal::Type::HashOf[Telnyx::Internal::Type::Unknown]
768
+ ],
769
+ Telnyx::Internal::Type::Converter
770
+ )
771
+ end
772
+ end
773
+ end
774
+ end