sentdm 0.34.0 → 0.35.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 (165) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +8 -0
  3. data/README.md +11 -9
  4. data/lib/sentdm/client.rb +25 -0
  5. data/lib/sentdm/internal/calls_page.rb +115 -0
  6. data/lib/sentdm/models/api_response_of_call.rb +43 -0
  7. data/lib/sentdm/models/api_response_of_call_recordings.rb +43 -0
  8. data/lib/sentdm/models/api_response_of_calls_list.rb +42 -0
  9. data/lib/sentdm/models/call.rb +133 -0
  10. data/lib/sentdm/models/call_event.rb +72 -0
  11. data/lib/sentdm/models/call_event_payload.rb +102 -0
  12. data/lib/sentdm/models/call_hangup_params.rb +32 -0
  13. data/lib/sentdm/models/call_list_params.rb +83 -0
  14. data/lib/sentdm/models/call_list_recordings_params.rb +26 -0
  15. data/lib/sentdm/models/call_party.rb +31 -0
  16. data/lib/sentdm/models/call_record_params.rb +55 -0
  17. data/lib/sentdm/models/call_recording.rb +38 -0
  18. data/lib/sentdm/models/call_recordings.rb +24 -0
  19. data/lib/sentdm/models/call_retrieve_params.rb +26 -0
  20. data/lib/sentdm/models/call_timeline_entry.rb +26 -0
  21. data/lib/sentdm/models/calls/api_response_of_list_of_call_participant.rb +45 -0
  22. data/lib/sentdm/models/calls/call_participant.rb +60 -0
  23. data/lib/sentdm/models/calls/call_participant_target.rb +30 -0
  24. data/lib/sentdm/models/calls/participant_add_params.rb +66 -0
  25. data/lib/sentdm/models/calls/participant_list_params.rb +28 -0
  26. data/lib/sentdm/models/calls/participant_remove_all_params.rb +28 -0
  27. data/lib/sentdm/models/calls/participant_remove_params.rb +34 -0
  28. data/lib/sentdm/models/calls/participant_update_params.rb +64 -0
  29. data/lib/sentdm/models/calls_list.rb +26 -0
  30. data/lib/sentdm/models/channels/api_response_of_list_of_voice_number.rb +45 -0
  31. data/lib/sentdm/models/channels/api_response_of_voice_callback_test.rb +45 -0
  32. data/lib/sentdm/models/channels/api_response_of_voice_number.rb +45 -0
  33. data/lib/sentdm/models/channels/api_response_of_voice_number_created.rb +45 -0
  34. data/lib/sentdm/models/channels/api_response_of_voice_secret.rb +45 -0
  35. data/lib/sentdm/models/channels/api_response_of_voice_token.rb +45 -0
  36. data/lib/sentdm/models/channels/voice_callback_test.rb +65 -0
  37. data/lib/sentdm/models/channels/voice_callback_test_error_info.rb +41 -0
  38. data/lib/sentdm/models/channels/voice_callback_test_request_info.rb +40 -0
  39. data/lib/sentdm/models/channels/voice_callback_test_response_info.rb +28 -0
  40. data/lib/sentdm/models/channels/voice_create_params.rb +86 -0
  41. data/lib/sentdm/models/channels/voice_create_token_params.rb +69 -0
  42. data/lib/sentdm/models/channels/voice_list_params.rb +22 -0
  43. data/lib/sentdm/models/channels/voice_number.rb +68 -0
  44. data/lib/sentdm/models/channels/voice_number_created.rb +26 -0
  45. data/lib/sentdm/models/channels/voice_retrieve_params.rb +28 -0
  46. data/lib/sentdm/models/channels/voice_rotate_secret_params.rb +34 -0
  47. data/lib/sentdm/models/channels/voice_secret.rb +25 -0
  48. data/lib/sentdm/models/channels/voice_test_params.rb +34 -0
  49. data/lib/sentdm/models/channels/voice_token.rb +44 -0
  50. data/lib/sentdm/models/channels/voice_update_params.rb +95 -0
  51. data/lib/sentdm/models/webhook_list_events_response.rb +4 -173
  52. data/lib/sentdm/models.rb +36 -0
  53. data/lib/sentdm/resources/calls/participants.rb +231 -0
  54. data/lib/sentdm/resources/calls.rb +235 -0
  55. data/lib/sentdm/resources/channels/voice.rb +381 -0
  56. data/lib/sentdm/resources/channels.rb +45 -0
  57. data/lib/sentdm/version.rb +1 -1
  58. data/lib/sentdm.rb +50 -0
  59. data/rbi/sentdm/client.rbi +23 -0
  60. data/rbi/sentdm/internal/calls_page.rbi +71 -0
  61. data/rbi/sentdm/models/api_response_of_call.rbi +74 -0
  62. data/rbi/sentdm/models/api_response_of_call_recordings.rbi +74 -0
  63. data/rbi/sentdm/models/api_response_of_calls_list.rbi +74 -0
  64. data/rbi/sentdm/models/call.rbi +177 -0
  65. data/rbi/sentdm/models/call_event.rbi +114 -0
  66. data/rbi/sentdm/models/call_event_payload.rbi +135 -0
  67. data/rbi/sentdm/models/call_hangup_params.rbi +59 -0
  68. data/rbi/sentdm/models/call_list_params.rbi +112 -0
  69. data/rbi/sentdm/models/call_list_recordings_params.rbi +46 -0
  70. data/rbi/sentdm/models/call_party.rbi +41 -0
  71. data/rbi/sentdm/models/call_record_params.rbi +83 -0
  72. data/rbi/sentdm/models/call_recording.rbi +59 -0
  73. data/rbi/sentdm/models/call_recordings.rbi +39 -0
  74. data/rbi/sentdm/models/call_retrieve_params.rbi +46 -0
  75. data/rbi/sentdm/models/call_timeline_entry.rbi +40 -0
  76. data/rbi/sentdm/models/calls/api_response_of_list_of_call_participant.rbi +76 -0
  77. data/rbi/sentdm/models/calls/call_participant.rbi +92 -0
  78. data/rbi/sentdm/models/calls/call_participant_target.rbi +47 -0
  79. data/rbi/sentdm/models/calls/participant_add_params.rbi +98 -0
  80. data/rbi/sentdm/models/calls/participant_list_params.rbi +51 -0
  81. data/rbi/sentdm/models/calls/participant_remove_all_params.rbi +51 -0
  82. data/rbi/sentdm/models/calls/participant_remove_params.rbi +61 -0
  83. data/rbi/sentdm/models/calls/participant_update_params.rbi +94 -0
  84. data/rbi/sentdm/models/calls_list.rbi +47 -0
  85. data/rbi/sentdm/models/channels/api_response_of_list_of_voice_number.rbi +76 -0
  86. data/rbi/sentdm/models/channels/api_response_of_voice_callback_test.rbi +83 -0
  87. data/rbi/sentdm/models/channels/api_response_of_voice_number.rbi +81 -0
  88. data/rbi/sentdm/models/channels/api_response_of_voice_number_created.rbi +83 -0
  89. data/rbi/sentdm/models/channels/api_response_of_voice_secret.rbi +81 -0
  90. data/rbi/sentdm/models/channels/api_response_of_voice_token.rbi +81 -0
  91. data/rbi/sentdm/models/channels/voice_callback_test.rbi +126 -0
  92. data/rbi/sentdm/models/channels/voice_callback_test_error_info.rbi +65 -0
  93. data/rbi/sentdm/models/channels/voice_callback_test_request_info.rbi +66 -0
  94. data/rbi/sentdm/models/channels/voice_callback_test_response_info.rbi +48 -0
  95. data/rbi/sentdm/models/channels/voice_create_params.rbi +127 -0
  96. data/rbi/sentdm/models/channels/voice_create_token_params.rbi +104 -0
  97. data/rbi/sentdm/models/channels/voice_list_params.rbi +40 -0
  98. data/rbi/sentdm/models/channels/voice_number.rbi +105 -0
  99. data/rbi/sentdm/models/channels/voice_number_created.rbi +42 -0
  100. data/rbi/sentdm/models/channels/voice_retrieve_params.rbi +51 -0
  101. data/rbi/sentdm/models/channels/voice_rotate_secret_params.rbi +64 -0
  102. data/rbi/sentdm/models/channels/voice_secret.rbi +35 -0
  103. data/rbi/sentdm/models/channels/voice_test_params.rbi +61 -0
  104. data/rbi/sentdm/models/channels/voice_token.rbi +76 -0
  105. data/rbi/sentdm/models/channels/voice_update_params.rbi +158 -0
  106. data/rbi/sentdm/models/webhook_list_events_response.rbi +3 -269
  107. data/rbi/sentdm/models.rbi +36 -0
  108. data/rbi/sentdm/resources/calls/participants.rbi +199 -0
  109. data/rbi/sentdm/resources/calls.rbi +206 -0
  110. data/rbi/sentdm/resources/channels/voice.rbi +371 -0
  111. data/rbi/sentdm/resources/channels.rbi +42 -0
  112. data/sig/sentdm/client.rbs +4 -0
  113. data/sig/sentdm/internal/calls_page.rbs +41 -0
  114. data/sig/sentdm/models/api_response_of_call.rbs +39 -0
  115. data/sig/sentdm/models/api_response_of_call_recordings.rbs +39 -0
  116. data/sig/sentdm/models/api_response_of_calls_list.rbs +39 -0
  117. data/sig/sentdm/models/call.rbs +101 -0
  118. data/sig/sentdm/models/call_event.rbs +44 -0
  119. data/sig/sentdm/models/call_event_payload.rbs +68 -0
  120. data/sig/sentdm/models/call_hangup_params.rbs +38 -0
  121. data/sig/sentdm/models/call_list_params.rbs +67 -0
  122. data/sig/sentdm/models/call_list_recordings_params.rbs +30 -0
  123. data/sig/sentdm/models/call_party.rbs +17 -0
  124. data/sig/sentdm/models/call_record_params.rbs +54 -0
  125. data/sig/sentdm/models/call_recording.rbs +32 -0
  126. data/sig/sentdm/models/call_recordings.rbs +17 -0
  127. data/sig/sentdm/models/call_retrieve_params.rbs +30 -0
  128. data/sig/sentdm/models/call_timeline_entry.rbs +19 -0
  129. data/sig/sentdm/models/calls/api_response_of_list_of_call_participant.rbs +41 -0
  130. data/sig/sentdm/models/calls/call_participant.rbs +52 -0
  131. data/sig/sentdm/models/calls/call_participant_target.rbs +23 -0
  132. data/sig/sentdm/models/calls/participant_add_params.rbs +63 -0
  133. data/sig/sentdm/models/calls/participant_list_params.rbs +32 -0
  134. data/sig/sentdm/models/calls/participant_remove_all_params.rbs +34 -0
  135. data/sig/sentdm/models/calls/participant_remove_params.rbs +40 -0
  136. data/sig/sentdm/models/calls/participant_update_params.rbs +61 -0
  137. data/sig/sentdm/models/calls_list.rbs +26 -0
  138. data/sig/sentdm/models/channels/api_response_of_list_of_voice_number.rbs +41 -0
  139. data/sig/sentdm/models/channels/api_response_of_voice_callback_test.rbs +41 -0
  140. data/sig/sentdm/models/channels/api_response_of_voice_number.rbs +41 -0
  141. data/sig/sentdm/models/channels/api_response_of_voice_number_created.rbs +41 -0
  142. data/sig/sentdm/models/channels/api_response_of_voice_secret.rbs +41 -0
  143. data/sig/sentdm/models/channels/api_response_of_voice_token.rbs +41 -0
  144. data/sig/sentdm/models/channels/voice_callback_test.rbs +51 -0
  145. data/sig/sentdm/models/channels/voice_callback_test_error_info.rbs +28 -0
  146. data/sig/sentdm/models/channels/voice_callback_test_request_info.rbs +34 -0
  147. data/sig/sentdm/models/channels/voice_callback_test_response_info.rbs +20 -0
  148. data/sig/sentdm/models/channels/voice_create_params.rbs +64 -0
  149. data/sig/sentdm/models/channels/voice_create_token_params.rbs +61 -0
  150. data/sig/sentdm/models/channels/voice_list_params.rbs +27 -0
  151. data/sig/sentdm/models/channels/voice_number.rbs +57 -0
  152. data/sig/sentdm/models/channels/voice_number_created.rbs +17 -0
  153. data/sig/sentdm/models/channels/voice_retrieve_params.rbs +32 -0
  154. data/sig/sentdm/models/channels/voice_rotate_secret_params.rbs +40 -0
  155. data/sig/sentdm/models/channels/voice_secret.rbs +17 -0
  156. data/sig/sentdm/models/channels/voice_test_params.rbs +40 -0
  157. data/sig/sentdm/models/channels/voice_token.rbs +40 -0
  158. data/sig/sentdm/models/channels/voice_update_params.rbs +78 -0
  159. data/sig/sentdm/models/webhook_list_events_response.rbs +1 -107
  160. data/sig/sentdm/models.rbs +36 -0
  161. data/sig/sentdm/resources/calls/participants.rbs +50 -0
  162. data/sig/sentdm/resources/calls.rbs +50 -0
  163. data/sig/sentdm/resources/channels/voice.rbs +68 -0
  164. data/sig/sentdm/resources/channels.rbs +9 -0
  165. metadata +152 -2
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Calls#hangup
6
+ class CallHangupParams < Sentdm::Models::MutationRequest
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute id
11
+ #
12
+ # @return [String]
13
+ required :id, String
14
+
15
+ # @!attribute idempotency_key
16
+ #
17
+ # @return [String, nil]
18
+ optional :idempotency_key, String
19
+
20
+ # @!attribute x_profile_id
21
+ #
22
+ # @return [String, nil]
23
+ optional :x_profile_id, String
24
+
25
+ # @!method initialize(id:, idempotency_key: nil, x_profile_id: nil, request_options: {})
26
+ # @param id [String]
27
+ # @param idempotency_key [String]
28
+ # @param x_profile_id [String]
29
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,83 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Calls#list
6
+ class CallListParams < Sentdm::Internal::Type::BaseModel
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute direction
11
+ # Optional direction filter: outbound for calls placed from your app, inbound for
12
+ # calls to one of your numbers
13
+ #
14
+ # @return [String, nil]
15
+ optional :direction, String, nil?: true
16
+
17
+ # @!attribute from
18
+ # Only calls started at or after this time (ISO 8601)
19
+ #
20
+ # @return [Time, nil]
21
+ optional :from, Time, nil?: true
22
+
23
+ # @!attribute number
24
+ # Optional filter on the number that owns the call, one of your voice-enabled
25
+ # numbers in E.164 format
26
+ #
27
+ # @return [String, nil]
28
+ optional :number, String, nil?: true
29
+
30
+ # @!attribute page
31
+ # Page number (1-indexed)
32
+ #
33
+ # @return [Integer, nil]
34
+ optional :page, Integer
35
+
36
+ # @!attribute page_size
37
+ # Number of items per page
38
+ #
39
+ # @return [Integer, nil]
40
+ optional :page_size, Integer
41
+
42
+ # @!attribute status
43
+ # Optional status filter: initiated, ringing, answered, completed, failed,
44
+ # no_answer or rejected
45
+ #
46
+ # @return [String, nil]
47
+ optional :status, String, nil?: true
48
+
49
+ # @!attribute to
50
+ # Only calls started at or before this time (ISO 8601)
51
+ #
52
+ # @return [Time, nil]
53
+ optional :to, Time, nil?: true
54
+
55
+ # @!attribute x_profile_id
56
+ #
57
+ # @return [String, nil]
58
+ optional :x_profile_id, String
59
+
60
+ # @!method initialize(direction: nil, from: nil, number: nil, page: nil, page_size: nil, status: nil, to: nil, x_profile_id: nil, request_options: {})
61
+ # Some parameter documentations has been truncated, see
62
+ # {Sentdm::Models::CallListParams} for more details.
63
+ #
64
+ # @param direction [String, nil] Optional direction filter: outbound for calls placed from your app, inbound for
65
+ #
66
+ # @param from [Time, nil] Only calls started at or after this time (ISO 8601)
67
+ #
68
+ # @param number [String, nil] Optional filter on the number that owns the call, one of your voice-enabled numb
69
+ #
70
+ # @param page [Integer] Page number (1-indexed)
71
+ #
72
+ # @param page_size [Integer] Number of items per page
73
+ #
74
+ # @param status [String, nil] Optional status filter: initiated, ringing, answered, completed, failed, no_answ
75
+ #
76
+ # @param to [Time, nil] Only calls started at or before this time (ISO 8601)
77
+ #
78
+ # @param x_profile_id [String]
79
+ #
80
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
81
+ end
82
+ end
83
+ end
@@ -0,0 +1,26 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Calls#list_recordings
6
+ class CallListRecordingsParams < Sentdm::Internal::Type::BaseModel
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute id
11
+ #
12
+ # @return [String]
13
+ required :id, String
14
+
15
+ # @!attribute x_profile_id
16
+ #
17
+ # @return [String, nil]
18
+ optional :x_profile_id, String
19
+
20
+ # @!method initialize(id:, x_profile_id: nil, request_options: {})
21
+ # @param id [String]
22
+ # @param x_profile_id [String]
23
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,31 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ class CallParty < Sentdm::Internal::Type::BaseModel
6
+ # @!attribute kind
7
+ # user for one of your app users, number for a phone number, conference for a
8
+ # room, anonymous for a caller who withheld their number
9
+ #
10
+ # @return [String, nil]
11
+ optional :kind, String
12
+
13
+ # @!attribute value
14
+ # The app user's identity, the phone number in E.164 format, or the room name.
15
+ # Null when the kind is anonymous
16
+ #
17
+ # @return [String, nil]
18
+ optional :value, String, nil?: true
19
+
20
+ # @!method initialize(kind: nil, value: nil)
21
+ # Some parameter documentations has been truncated, see
22
+ # {Sentdm::Models::CallParty} for more details.
23
+ #
24
+ # One end of a call
25
+ #
26
+ # @param kind [String] user for one of your app users, number for a phone number, conference for a room
27
+ #
28
+ # @param value [String, nil] The app user's identity, the phone number in E.164 format, or the room name. Nul
29
+ end
30
+ end
31
+ end
@@ -0,0 +1,55 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Calls#record
6
+ class CallRecordParams < Sentdm::Internal::Type::BaseModel
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute id
11
+ #
12
+ # @return [String]
13
+ required :id, String
14
+
15
+ # @!attribute action
16
+ # start to begin recording, stop to end it
17
+ #
18
+ # @return [String, nil]
19
+ optional :action, String
20
+
21
+ # @!attribute sandbox
22
+ # Sandbox flag - when true, the operation is simulated without side effects Useful
23
+ # for testing integrations without actual execution
24
+ #
25
+ # @return [Boolean, nil]
26
+ optional :sandbox, Sentdm::Internal::Type::Boolean
27
+
28
+ # @!attribute idempotency_key
29
+ #
30
+ # @return [String, nil]
31
+ optional :idempotency_key, String
32
+
33
+ # @!attribute x_profile_id
34
+ #
35
+ # @return [String, nil]
36
+ optional :x_profile_id, String
37
+
38
+ # @!method initialize(id:, action: nil, sandbox: nil, idempotency_key: nil, x_profile_id: nil, request_options: {})
39
+ # Some parameter documentations has been truncated, see
40
+ # {Sentdm::Models::CallRecordParams} for more details.
41
+ #
42
+ # @param id [String]
43
+ #
44
+ # @param action [String] start to begin recording, stop to end it
45
+ #
46
+ # @param sandbox [Boolean] Sandbox flag - when true, the operation is simulated without side effects
47
+ #
48
+ # @param idempotency_key [String]
49
+ #
50
+ # @param x_profile_id [String]
51
+ #
52
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
53
+ end
54
+ end
55
+ end
@@ -0,0 +1,38 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ class CallRecording < Sentdm::Internal::Type::BaseModel
6
+ # @!attribute download_url
7
+ # A pre-signed link that downloads the recording as an MP3 file. Anyone holding it
8
+ # can download the recording until it expires
9
+ #
10
+ # @return [String, nil]
11
+ optional :download_url, String
12
+
13
+ # @!attribute recording_id
14
+ # The recording's id, the one the call.recording_ready webhook announced it under
15
+ #
16
+ # @return [String, nil]
17
+ optional :recording_id, String
18
+
19
+ # @!attribute url_expires_at
20
+ # When the link stops working (UTC). Request the recordings again for a fresh link
21
+ #
22
+ # @return [Time, nil]
23
+ optional :url_expires_at, Time
24
+
25
+ # @!method initialize(download_url: nil, recording_id: nil, url_expires_at: nil)
26
+ # Some parameter documentations has been truncated, see
27
+ # {Sentdm::Models::CallRecording} for more details.
28
+ #
29
+ # A short-lived link to a call recording
30
+ #
31
+ # @param download_url [String] A pre-signed link that downloads the recording as an MP3 file. Anyone holding it
32
+ #
33
+ # @param recording_id [String] The recording's id, the one the call.recording_ready webhook announced it under
34
+ #
35
+ # @param url_expires_at [Time] When the link stops working (UTC). Request the recordings again for a fresh link
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,24 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ class CallRecordings < Sentdm::Internal::Type::BaseModel
6
+ # @!attribute recordings
7
+ # Every recording of the call, oldest first. Empty until the first
8
+ # call.recording_ready webhook has been sent, and for a call that was never
9
+ # recorded
10
+ #
11
+ # @return [Array<Sentdm::Models::CallRecording>, nil]
12
+ optional :recordings, -> { Sentdm::Internal::Type::ArrayOf[Sentdm::CallRecording] }
13
+
14
+ # @!method initialize(recordings: nil)
15
+ # Some parameter documentations has been truncated, see
16
+ # {Sentdm::Models::CallRecordings} for more details.
17
+ #
18
+ # The recordings of a call, each as a short-lived download link
19
+ #
20
+ # @param recordings [Array<Sentdm::Models::CallRecording>] Every recording of the call, oldest first. Empty until the first
21
+ # call.recording\_
22
+ end
23
+ end
24
+ end
@@ -0,0 +1,26 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ # @see Sentdm::Resources::Calls#retrieve
6
+ class CallRetrieveParams < Sentdm::Internal::Type::BaseModel
7
+ extend Sentdm::Internal::Type::RequestParameters::Converter
8
+ include Sentdm::Internal::Type::RequestParameters
9
+
10
+ # @!attribute id
11
+ #
12
+ # @return [String]
13
+ required :id, String
14
+
15
+ # @!attribute x_profile_id
16
+ #
17
+ # @return [String, nil]
18
+ optional :x_profile_id, String
19
+
20
+ # @!method initialize(id:, x_profile_id: nil, request_options: {})
21
+ # @param id [String]
22
+ # @param x_profile_id [String]
23
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,26 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ class CallTimelineEntry < Sentdm::Internal::Type::BaseModel
6
+ # @!attribute status
7
+ # initiated, ringing, answered, completed, failed, no_answer or rejected
8
+ #
9
+ # @return [String, nil]
10
+ optional :status, String
11
+
12
+ # @!attribute timestamp
13
+ # When the call entered this status (UTC)
14
+ #
15
+ # @return [Time, nil]
16
+ optional :timestamp, Time
17
+
18
+ # @!method initialize(status: nil, timestamp: nil)
19
+ # When a call entered a status
20
+ #
21
+ # @param status [String] initiated, ringing, answered, completed, failed, no_answer or rejected
22
+ #
23
+ # @param timestamp [Time] When the call entered this status (UTC)
24
+ end
25
+ end
26
+ end
@@ -0,0 +1,45 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ # @see Sentdm::Resources::Calls::Participants#list
7
+ class APIResponseOfListOfCallParticipant < Sentdm::Internal::Type::BaseModel
8
+ # @!attribute data
9
+ # The response data (null if error)
10
+ #
11
+ # @return [Array<Sentdm::Models::Calls::CallParticipant>, nil]
12
+ optional :data, -> { Sentdm::Internal::Type::ArrayOf[Sentdm::Calls::CallParticipant] }, nil?: true
13
+
14
+ # @!attribute error
15
+ # Error information
16
+ #
17
+ # @return [Sentdm::Models::ErrorDetail, nil]
18
+ optional :error, -> { Sentdm::ErrorDetail }, nil?: true
19
+
20
+ # @!attribute meta
21
+ # Request and response metadata
22
+ #
23
+ # @return [Sentdm::Models::APIMeta, nil]
24
+ optional :meta, -> { Sentdm::APIMeta }
25
+
26
+ # @!attribute success
27
+ # Indicates whether the request was successful
28
+ #
29
+ # @return [Boolean, nil]
30
+ optional :success, Sentdm::Internal::Type::Boolean
31
+
32
+ # @!method initialize(data: nil, error: nil, meta: nil, success: nil)
33
+ # Standard API response envelope for all v3 endpoints
34
+ #
35
+ # @param data [Array<Sentdm::Models::Calls::CallParticipant>, nil] The response data (null if error)
36
+ #
37
+ # @param error [Sentdm::Models::ErrorDetail, nil] Error information
38
+ #
39
+ # @param meta [Sentdm::Models::APIMeta] Request and response metadata
40
+ #
41
+ # @param success [Boolean] Indicates whether the request was successful
42
+ end
43
+ end
44
+ end
45
+ end
@@ -0,0 +1,60 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ class CallParticipant < Sentdm::Internal::Type::BaseModel
7
+ # @!attribute id
8
+ # The participant's own call id: what the mute and remove endpoints take, and what
9
+ # GET /v3/calls/{id} accepts
10
+ #
11
+ # @return [String, nil]
12
+ optional :id, String
13
+
14
+ # @!attribute duration_seconds
15
+ # How long the participant has been connected to the room, in seconds
16
+ #
17
+ # @return [Integer, nil]
18
+ optional :duration_seconds, Integer
19
+
20
+ # @!attribute kind
21
+ # user for one of your app users, number for a phone number, anonymous for a
22
+ # caller who withheld their number
23
+ #
24
+ # @return [String, nil]
25
+ optional :kind, String
26
+
27
+ # @!attribute muted
28
+ # True while the room mutes this participant
29
+ #
30
+ # @return [Boolean, nil]
31
+ optional :muted, Sentdm::Internal::Type::Boolean
32
+
33
+ # @!attribute value
34
+ # The app user's identity or the phone number in E.164 format. Null when the kind
35
+ # is anonymous
36
+ #
37
+ # @return [String, nil]
38
+ optional :value, String, nil?: true
39
+
40
+ # @!method initialize(id: nil, duration_seconds: nil, kind: nil, muted: nil, value: nil)
41
+ # Some parameter documentations has been truncated, see
42
+ # {Sentdm::Models::Calls::CallParticipant} for more details.
43
+ #
44
+ # A participant of a conference call
45
+ #
46
+ # @param id [String] The participant's own call id: what the mute and remove endpoints take, and what
47
+ #
48
+ # @param duration_seconds [Integer] How long the participant has been connected to the room, in seconds
49
+ #
50
+ # @param kind [String] user for one of your app users, number for a phone number, anonymous for a calle
51
+ #
52
+ # @param muted [Boolean] True while the room mutes this participant
53
+ #
54
+ # @param value [String, nil] The app user's identity or the phone number in E.164 format. Null when the kind
55
+ end
56
+ end
57
+
58
+ CallParticipant = Calls::CallParticipant
59
+ end
60
+ end
@@ -0,0 +1,30 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ class CallParticipantTarget < Sentdm::Internal::Type::BaseModel
7
+ # @!attribute kind
8
+ # user for one of your app users, number for a phone number
9
+ #
10
+ # @return [String, nil]
11
+ optional :kind, String
12
+
13
+ # @!attribute value
14
+ # The app user's identity, or the phone number in E.164 format
15
+ #
16
+ # @return [String, nil]
17
+ optional :value, String
18
+
19
+ # @!method initialize(kind: nil, value: nil)
20
+ # A participant to add to a call
21
+ #
22
+ # @param kind [String] user for one of your app users, number for a phone number
23
+ #
24
+ # @param value [String] The app user's identity, or the phone number in E.164 format
25
+ end
26
+ end
27
+
28
+ CallParticipantTarget = Calls::CallParticipantTarget
29
+ end
30
+ end
@@ -0,0 +1,66 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ # @see Sentdm::Resources::Calls::Participants#add
7
+ class ParticipantAddParams < Sentdm::Internal::Type::BaseModel
8
+ extend Sentdm::Internal::Type::RequestParameters::Converter
9
+ include Sentdm::Internal::Type::RequestParameters
10
+
11
+ # @!attribute id
12
+ #
13
+ # @return [String]
14
+ required :id, String
15
+
16
+ # @!attribute caller_id
17
+ # The number shown to a phone participant as the caller, in E.164 format. Must be
18
+ # one of your numbers. The call's owning number when omitted
19
+ #
20
+ # @return [String, nil]
21
+ optional :caller_id, String, nil?: true
22
+
23
+ # @!attribute sandbox
24
+ # Sandbox flag - when true, the operation is simulated without side effects Useful
25
+ # for testing integrations without actual execution
26
+ #
27
+ # @return [Boolean, nil]
28
+ optional :sandbox, Sentdm::Internal::Type::Boolean
29
+
30
+ # @!attribute to
31
+ # A participant to add to a call
32
+ #
33
+ # @return [Sentdm::Models::Calls::CallParticipantTarget, nil]
34
+ optional :to, -> { Sentdm::Calls::CallParticipantTarget }
35
+
36
+ # @!attribute idempotency_key
37
+ #
38
+ # @return [String, nil]
39
+ optional :idempotency_key, String
40
+
41
+ # @!attribute x_profile_id
42
+ #
43
+ # @return [String, nil]
44
+ optional :x_profile_id, String
45
+
46
+ # @!method initialize(id:, caller_id: nil, sandbox: nil, to: nil, idempotency_key: nil, x_profile_id: nil, request_options: {})
47
+ # Some parameter documentations has been truncated, see
48
+ # {Sentdm::Models::Calls::ParticipantAddParams} for more details.
49
+ #
50
+ # @param id [String]
51
+ #
52
+ # @param caller_id [String, nil] The number shown to a phone participant as the caller, in E.164 format. Must be
53
+ #
54
+ # @param sandbox [Boolean] Sandbox flag - when true, the operation is simulated without side effects
55
+ #
56
+ # @param to [Sentdm::Models::Calls::CallParticipantTarget] A participant to add to a call
57
+ #
58
+ # @param idempotency_key [String]
59
+ #
60
+ # @param x_profile_id [String]
61
+ #
62
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
63
+ end
64
+ end
65
+ end
66
+ end
@@ -0,0 +1,28 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ # @see Sentdm::Resources::Calls::Participants#list
7
+ class ParticipantListParams < Sentdm::Internal::Type::BaseModel
8
+ extend Sentdm::Internal::Type::RequestParameters::Converter
9
+ include Sentdm::Internal::Type::RequestParameters
10
+
11
+ # @!attribute id
12
+ #
13
+ # @return [String]
14
+ required :id, String
15
+
16
+ # @!attribute x_profile_id
17
+ #
18
+ # @return [String, nil]
19
+ optional :x_profile_id, String
20
+
21
+ # @!method initialize(id:, x_profile_id: nil, request_options: {})
22
+ # @param id [String]
23
+ # @param x_profile_id [String]
24
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,28 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ # @see Sentdm::Resources::Calls::Participants#remove_all
7
+ class ParticipantRemoveAllParams < Sentdm::Models::MutationRequest
8
+ extend Sentdm::Internal::Type::RequestParameters::Converter
9
+ include Sentdm::Internal::Type::RequestParameters
10
+
11
+ # @!attribute id
12
+ #
13
+ # @return [String]
14
+ required :id, String
15
+
16
+ # @!attribute x_profile_id
17
+ #
18
+ # @return [String, nil]
19
+ optional :x_profile_id, String
20
+
21
+ # @!method initialize(id:, x_profile_id: nil, request_options: {})
22
+ # @param id [String]
23
+ # @param x_profile_id [String]
24
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
25
+ end
26
+ end
27
+ end
28
+ end
@@ -0,0 +1,34 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Sentdm
4
+ module Models
5
+ module Calls
6
+ # @see Sentdm::Resources::Calls::Participants#remove
7
+ class ParticipantRemoveParams < Sentdm::Models::MutationRequest
8
+ extend Sentdm::Internal::Type::RequestParameters::Converter
9
+ include Sentdm::Internal::Type::RequestParameters
10
+
11
+ # @!attribute id
12
+ #
13
+ # @return [String]
14
+ required :id, String
15
+
16
+ # @!attribute participant_id
17
+ #
18
+ # @return [String]
19
+ required :participant_id, String
20
+
21
+ # @!attribute x_profile_id
22
+ #
23
+ # @return [String, nil]
24
+ optional :x_profile_id, String
25
+
26
+ # @!method initialize(id:, participant_id:, x_profile_id: nil, request_options: {})
27
+ # @param id [String]
28
+ # @param participant_id [String]
29
+ # @param x_profile_id [String]
30
+ # @param request_options [Sentdm::RequestOptions, Hash{Symbol=>Object}]
31
+ end
32
+ end
33
+ end
34
+ end