prelude-sdk 0.1.0 → 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 (58) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +13 -0
  3. data/README.md +9 -9
  4. data/lib/prelude_sdk/client.rb +4 -0
  5. data/lib/prelude_sdk/models/notify_get_subscription_config_params.rb +14 -0
  6. data/lib/prelude_sdk/models/notify_get_subscription_config_response.rb +120 -0
  7. data/lib/prelude_sdk/models/notify_get_subscription_phone_number_params.rb +20 -0
  8. data/lib/prelude_sdk/models/notify_get_subscription_phone_number_response.rb +104 -0
  9. data/lib/prelude_sdk/models/notify_list_subscription_configs_params.rb +30 -0
  10. data/lib/prelude_sdk/models/notify_list_subscription_configs_response.rb +144 -0
  11. data/lib/prelude_sdk/models/notify_list_subscription_phone_number_events_params.rb +37 -0
  12. data/lib/prelude_sdk/models/notify_list_subscription_phone_number_events_response.rb +132 -0
  13. data/lib/prelude_sdk/models/notify_list_subscription_phone_numbers_params.rb +49 -0
  14. data/lib/prelude_sdk/models/notify_list_subscription_phone_numbers_response.rb +132 -0
  15. data/lib/prelude_sdk/models/notify_send_batch_params.rb +110 -0
  16. data/lib/prelude_sdk/models/notify_send_batch_response.rb +201 -0
  17. data/lib/prelude_sdk/models/notify_send_params.rb +118 -0
  18. data/lib/prelude_sdk/models/notify_send_response.rb +94 -0
  19. data/lib/prelude_sdk/models.rb +15 -0
  20. data/lib/prelude_sdk/resources/notify.rb +247 -0
  21. data/lib/prelude_sdk/version.rb +1 -1
  22. data/lib/prelude_sdk.rb +16 -0
  23. data/manifest.yaml +1 -0
  24. data/rbi/prelude_sdk/client.rbi +3 -0
  25. data/rbi/prelude_sdk/models/notify_get_subscription_config_params.rbi +30 -0
  26. data/rbi/prelude_sdk/models/notify_get_subscription_config_response.rbi +224 -0
  27. data/rbi/prelude_sdk/models/notify_get_subscription_phone_number_params.rbi +38 -0
  28. data/rbi/prelude_sdk/models/notify_get_subscription_phone_number_response.rbi +199 -0
  29. data/rbi/prelude_sdk/models/notify_list_subscription_configs_params.rbi +60 -0
  30. data/rbi/prelude_sdk/models/notify_list_subscription_configs_response.rbi +286 -0
  31. data/rbi/prelude_sdk/models/notify_list_subscription_phone_number_events_params.rbi +66 -0
  32. data/rbi/prelude_sdk/models/notify_list_subscription_phone_number_events_response.rbi +259 -0
  33. data/rbi/prelude_sdk/models/notify_list_subscription_phone_numbers_params.rbi +119 -0
  34. data/rbi/prelude_sdk/models/notify_list_subscription_phone_numbers_response.rbi +259 -0
  35. data/rbi/prelude_sdk/models/notify_send_batch_params.rbi +191 -0
  36. data/rbi/prelude_sdk/models/notify_send_batch_response.rbi +360 -0
  37. data/rbi/prelude_sdk/models/notify_send_params.rbi +201 -0
  38. data/rbi/prelude_sdk/models/notify_send_response.rbi +128 -0
  39. data/rbi/prelude_sdk/models.rbi +19 -0
  40. data/rbi/prelude_sdk/resources/notify.rbi +218 -0
  41. data/sig/prelude_sdk/client.rbs +2 -0
  42. data/sig/prelude_sdk/models/notify_get_subscription_config_params.rbs +15 -0
  43. data/sig/prelude_sdk/models/notify_get_subscription_config_response.rbs +95 -0
  44. data/sig/prelude_sdk/models/notify_get_subscription_phone_number_params.rbs +23 -0
  45. data/sig/prelude_sdk/models/notify_get_subscription_phone_number_response.rbs +71 -0
  46. data/sig/prelude_sdk/models/notify_list_subscription_configs_params.rbs +32 -0
  47. data/sig/prelude_sdk/models/notify_list_subscription_configs_response.rbs +119 -0
  48. data/sig/prelude_sdk/models/notify_list_subscription_phone_number_events_params.rbs +36 -0
  49. data/sig/prelude_sdk/models/notify_list_subscription_phone_number_events_response.rbs +95 -0
  50. data/sig/prelude_sdk/models/notify_list_subscription_phone_numbers_params.rbs +55 -0
  51. data/sig/prelude_sdk/models/notify_list_subscription_phone_numbers_response.rbs +95 -0
  52. data/sig/prelude_sdk/models/notify_send_batch_params.rbs +100 -0
  53. data/sig/prelude_sdk/models/notify_send_batch_response.rbs +187 -0
  54. data/sig/prelude_sdk/models/notify_send_params.rbs +100 -0
  55. data/sig/prelude_sdk/models/notify_send_response.rbs +73 -0
  56. data/sig/prelude_sdk/models.rbs +14 -0
  57. data/sig/prelude_sdk/resources/notify.rbs +68 -0
  58. metadata +47 -2
@@ -0,0 +1,218 @@
1
+ # typed: strong
2
+
3
+ module PreludeSDK
4
+ module Resources
5
+ class Notify
6
+ # Retrieve a specific subscription management configuration by its ID.
7
+ sig do
8
+ params(
9
+ config_id: String,
10
+ request_options: PreludeSDK::RequestOptions::OrHash
11
+ ).returns(PreludeSDK::Models::NotifyGetSubscriptionConfigResponse)
12
+ end
13
+ def get_subscription_config(
14
+ # The subscription configuration ID
15
+ config_id,
16
+ request_options: {}
17
+ )
18
+ end
19
+
20
+ # Retrieve the current subscription status for a specific phone number within a
21
+ # subscription configuration.
22
+ sig do
23
+ params(
24
+ phone_number: String,
25
+ config_id: String,
26
+ request_options: PreludeSDK::RequestOptions::OrHash
27
+ ).returns(PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse)
28
+ end
29
+ def get_subscription_phone_number(
30
+ # The phone number in E.164 format (e.g., +33612345678)
31
+ phone_number,
32
+ # The subscription configuration ID
33
+ config_id:,
34
+ request_options: {}
35
+ )
36
+ end
37
+
38
+ # Retrieve a paginated list of subscription management configurations for your
39
+ # account.
40
+ #
41
+ # Each configuration represents a subscription management setup with phone numbers
42
+ # for receiving opt-out/opt-in requests and a callback URL for webhook events.
43
+ sig do
44
+ params(
45
+ cursor: String,
46
+ limit: Integer,
47
+ request_options: PreludeSDK::RequestOptions::OrHash
48
+ ).returns(PreludeSDK::Models::NotifyListSubscriptionConfigsResponse)
49
+ end
50
+ def list_subscription_configs(
51
+ # Pagination cursor from the previous response
52
+ cursor: nil,
53
+ # Maximum number of configurations to return per page
54
+ limit: nil,
55
+ request_options: {}
56
+ )
57
+ end
58
+
59
+ # Retrieve a paginated list of subscription events (status changes) for a specific
60
+ # phone number within a subscription configuration.
61
+ #
62
+ # Events are ordered by timestamp in descending order (most recent first).
63
+ sig do
64
+ params(
65
+ phone_number: String,
66
+ config_id: String,
67
+ cursor: String,
68
+ limit: Integer,
69
+ request_options: PreludeSDK::RequestOptions::OrHash
70
+ ).returns(
71
+ PreludeSDK::Models::NotifyListSubscriptionPhoneNumberEventsResponse
72
+ )
73
+ end
74
+ def list_subscription_phone_number_events(
75
+ # Path param: The phone number in E.164 format (e.g., +33612345678)
76
+ phone_number,
77
+ # Path param: The subscription configuration ID
78
+ config_id:,
79
+ # Query param: Pagination cursor from the previous response
80
+ cursor: nil,
81
+ # Query param: Maximum number of events to return per page
82
+ limit: nil,
83
+ request_options: {}
84
+ )
85
+ end
86
+
87
+ # Retrieve a paginated list of phone numbers and their subscription statuses for a
88
+ # specific subscription configuration.
89
+ #
90
+ # You can optionally filter by subscription state (SUB or UNSUB).
91
+ sig do
92
+ params(
93
+ config_id: String,
94
+ cursor: String,
95
+ limit: Integer,
96
+ state:
97
+ PreludeSDK::NotifyListSubscriptionPhoneNumbersParams::State::OrSymbol,
98
+ request_options: PreludeSDK::RequestOptions::OrHash
99
+ ).returns(
100
+ PreludeSDK::Models::NotifyListSubscriptionPhoneNumbersResponse
101
+ )
102
+ end
103
+ def list_subscription_phone_numbers(
104
+ # The subscription configuration ID
105
+ config_id,
106
+ # Pagination cursor from the previous response
107
+ cursor: nil,
108
+ # Maximum number of phone numbers to return per page
109
+ limit: nil,
110
+ # Filter by subscription state
111
+ state: nil,
112
+ request_options: {}
113
+ )
114
+ end
115
+
116
+ # Send transactional and marketing messages to your users via SMS and WhatsApp
117
+ # with automatic compliance enforcement.
118
+ sig do
119
+ params(
120
+ template_id: String,
121
+ to: String,
122
+ callback_url: String,
123
+ correlation_id: String,
124
+ expires_at: Time,
125
+ from: String,
126
+ locale: String,
127
+ preferred_channel:
128
+ PreludeSDK::NotifySendParams::PreferredChannel::OrSymbol,
129
+ schedule_at: Time,
130
+ variables: T::Hash[Symbol, String],
131
+ request_options: PreludeSDK::RequestOptions::OrHash
132
+ ).returns(PreludeSDK::Models::NotifySendResponse)
133
+ end
134
+ def send_(
135
+ # The template identifier configured by your Customer Success team.
136
+ template_id:,
137
+ # The recipient's phone number in E.164 format.
138
+ to:,
139
+ # The URL where webhooks will be sent for message delivery events.
140
+ callback_url: nil,
141
+ # A user-defined identifier to correlate this message with your internal systems.
142
+ # It is returned in the response and any webhook events that refer to this
143
+ # message.
144
+ correlation_id: nil,
145
+ # The message expiration date in RFC3339 format. The message will not be sent if
146
+ # this time is reached.
147
+ expires_at: nil,
148
+ # The Sender ID. Must be approved for your account.
149
+ from: nil,
150
+ # A BCP-47 formatted locale string with the language the text message will be sent
151
+ # to. If there's no locale set, the language will be determined by the country
152
+ # code of the phone number. If the language specified doesn't exist, the default
153
+ # set on the template will be used.
154
+ locale: nil,
155
+ # The preferred channel to be used in priority for message delivery. If the
156
+ # channel is unavailable, the system will fallback to other available channels.
157
+ preferred_channel: nil,
158
+ # Schedule the message for future delivery in RFC3339 format. Marketing messages
159
+ # can be scheduled up to 90 days in advance and will be automatically adjusted for
160
+ # compliance with local time window restrictions.
161
+ schedule_at: nil,
162
+ # The variables to be replaced in the template.
163
+ variables: nil,
164
+ request_options: {}
165
+ )
166
+ end
167
+
168
+ # Send the same message to multiple recipients in a single request.
169
+ sig do
170
+ params(
171
+ template_id: String,
172
+ to: T::Array[String],
173
+ callback_url: String,
174
+ correlation_id: String,
175
+ expires_at: Time,
176
+ from: String,
177
+ locale: String,
178
+ preferred_channel:
179
+ PreludeSDK::NotifySendBatchParams::PreferredChannel::OrSymbol,
180
+ schedule_at: Time,
181
+ variables: T::Hash[Symbol, String],
182
+ request_options: PreludeSDK::RequestOptions::OrHash
183
+ ).returns(PreludeSDK::Models::NotifySendBatchResponse)
184
+ end
185
+ def send_batch(
186
+ # The template identifier configured by your Customer Success team.
187
+ template_id:,
188
+ # The list of recipients' phone numbers in E.164 format.
189
+ to:,
190
+ # The URL where webhooks will be sent for delivery events.
191
+ callback_url: nil,
192
+ # A user-defined identifier to correlate this request with your internal systems.
193
+ correlation_id: nil,
194
+ # The message expiration date in RFC3339 format. Messages will not be sent after
195
+ # this time.
196
+ expires_at: nil,
197
+ # The Sender ID. Must be approved for your account.
198
+ from: nil,
199
+ # A BCP-47 formatted locale string.
200
+ locale: nil,
201
+ # Preferred channel for delivery. If unavailable, automatic fallback applies.
202
+ preferred_channel: nil,
203
+ # Schedule delivery in RFC3339 format. Marketing sends may be adjusted to comply
204
+ # with local time windows.
205
+ schedule_at: nil,
206
+ # The variables to be replaced in the template.
207
+ variables: nil,
208
+ request_options: {}
209
+ )
210
+ end
211
+
212
+ # @api private
213
+ sig { params(client: PreludeSDK::Client).returns(T.attached_class) }
214
+ def self.new(client:)
215
+ end
216
+ end
217
+ end
218
+ end
@@ -12,6 +12,8 @@ module PreludeSDK
12
12
 
13
13
  attr_reader lookup: PreludeSDK::Resources::Lookup
14
14
 
15
+ attr_reader notify: PreludeSDK::Resources::Notify
16
+
15
17
  attr_reader transactional: PreludeSDK::Resources::Transactional
16
18
 
17
19
  attr_reader verification: PreludeSDK::Resources::Verification
@@ -0,0 +1,15 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_get_subscription_config_params =
4
+ { } & PreludeSDK::Internal::Type::request_parameters
5
+
6
+ class NotifyGetSubscriptionConfigParams < PreludeSDK::Internal::Type::BaseModel
7
+ extend PreludeSDK::Internal::Type::RequestParameters::Converter
8
+ include PreludeSDK::Internal::Type::RequestParameters
9
+
10
+ def initialize: (?request_options: PreludeSDK::request_opts) -> void
11
+
12
+ def to_hash: -> { request_options: PreludeSDK::RequestOptions }
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,95 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_get_subscription_config_response =
4
+ {
5
+ id: String,
6
+ callback_url: String,
7
+ created_at: Time,
8
+ messages: PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::Messages,
9
+ name: String,
10
+ updated_at: Time,
11
+ mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]
12
+ }
13
+
14
+ class NotifyGetSubscriptionConfigResponse < PreludeSDK::Internal::Type::BaseModel
15
+ attr_accessor id: String
16
+
17
+ attr_accessor callback_url: String
18
+
19
+ attr_accessor created_at: Time
20
+
21
+ attr_accessor messages: PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::Messages
22
+
23
+ attr_accessor name: String
24
+
25
+ attr_accessor updated_at: Time
26
+
27
+ attr_reader mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]?
28
+
29
+ def mo_phone_numbers=: (
30
+ ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]
31
+ ) -> ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]
32
+
33
+ def initialize: (
34
+ id: String,
35
+ callback_url: String,
36
+ created_at: Time,
37
+ messages: PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::Messages,
38
+ name: String,
39
+ updated_at: Time,
40
+ ?mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]
41
+ ) -> void
42
+
43
+ def to_hash: -> {
44
+ id: String,
45
+ callback_url: String,
46
+ created_at: Time,
47
+ messages: PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::Messages,
48
+ name: String,
49
+ updated_at: Time,
50
+ mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyGetSubscriptionConfigResponse::MoPhoneNumber]
51
+ }
52
+
53
+ type messages =
54
+ { help_message: String, start_message: String, stop_message: String }
55
+
56
+ class Messages < PreludeSDK::Internal::Type::BaseModel
57
+ attr_reader help_message: String?
58
+
59
+ def help_message=: (String) -> String
60
+
61
+ attr_reader start_message: String?
62
+
63
+ def start_message=: (String) -> String
64
+
65
+ attr_reader stop_message: String?
66
+
67
+ def stop_message=: (String) -> String
68
+
69
+ def initialize: (
70
+ ?help_message: String,
71
+ ?start_message: String,
72
+ ?stop_message: String
73
+ ) -> void
74
+
75
+ def to_hash: -> {
76
+ help_message: String,
77
+ start_message: String,
78
+ stop_message: String
79
+ }
80
+ end
81
+
82
+ type mo_phone_number = { country_code: String, phone_number: String }
83
+
84
+ class MoPhoneNumber < PreludeSDK::Internal::Type::BaseModel
85
+ attr_accessor country_code: String
86
+
87
+ attr_accessor phone_number: String
88
+
89
+ def initialize: (country_code: String, phone_number: String) -> void
90
+
91
+ def to_hash: -> { country_code: String, phone_number: String }
92
+ end
93
+ end
94
+ end
95
+ end
@@ -0,0 +1,23 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_get_subscription_phone_number_params =
4
+ { config_id: String } & PreludeSDK::Internal::Type::request_parameters
5
+
6
+ class NotifyGetSubscriptionPhoneNumberParams < PreludeSDK::Internal::Type::BaseModel
7
+ extend PreludeSDK::Internal::Type::RequestParameters::Converter
8
+ include PreludeSDK::Internal::Type::RequestParameters
9
+
10
+ attr_accessor config_id: String
11
+
12
+ def initialize: (
13
+ config_id: String,
14
+ ?request_options: PreludeSDK::request_opts
15
+ ) -> void
16
+
17
+ def to_hash: -> {
18
+ config_id: String,
19
+ request_options: PreludeSDK::RequestOptions
20
+ }
21
+ end
22
+ end
23
+ end
@@ -0,0 +1,71 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_get_subscription_phone_number_response =
4
+ {
5
+ config_id: String,
6
+ phone_number: String,
7
+ source: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::source,
8
+ state: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::state,
9
+ updated_at: Time,
10
+ reason: String
11
+ }
12
+
13
+ class NotifyGetSubscriptionPhoneNumberResponse < PreludeSDK::Internal::Type::BaseModel
14
+ attr_accessor config_id: String
15
+
16
+ attr_accessor phone_number: String
17
+
18
+ attr_accessor source: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::source
19
+
20
+ attr_accessor state: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::state
21
+
22
+ attr_accessor updated_at: Time
23
+
24
+ attr_reader reason: String?
25
+
26
+ def reason=: (String) -> String
27
+
28
+ def initialize: (
29
+ config_id: String,
30
+ phone_number: String,
31
+ source: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::source,
32
+ state: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::state,
33
+ updated_at: Time,
34
+ ?reason: String
35
+ ) -> void
36
+
37
+ def to_hash: -> {
38
+ config_id: String,
39
+ phone_number: String,
40
+ source: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::source,
41
+ state: PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::state,
42
+ updated_at: Time,
43
+ reason: String
44
+ }
45
+
46
+ type source = :MO_KEYWORD | :API | :CSV_IMPORT | :CARRIER_DISCONNECT
47
+
48
+ module Source
49
+ extend PreludeSDK::Internal::Type::Enum
50
+
51
+ MO_KEYWORD: :MO_KEYWORD
52
+ API: :API
53
+ CSV_IMPORT: :CSV_IMPORT
54
+ CARRIER_DISCONNECT: :CARRIER_DISCONNECT
55
+
56
+ def self?.values: -> ::Array[PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::source]
57
+ end
58
+
59
+ type state = :SUB | :UNSUB
60
+
61
+ module State
62
+ extend PreludeSDK::Internal::Type::Enum
63
+
64
+ SUB: :SUB
65
+ UNSUB: :UNSUB
66
+
67
+ def self?.values: -> ::Array[PreludeSDK::Models::NotifyGetSubscriptionPhoneNumberResponse::state]
68
+ end
69
+ end
70
+ end
71
+ end
@@ -0,0 +1,32 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_list_subscription_configs_params =
4
+ { cursor: String, limit: Integer }
5
+ & PreludeSDK::Internal::Type::request_parameters
6
+
7
+ class NotifyListSubscriptionConfigsParams < PreludeSDK::Internal::Type::BaseModel
8
+ extend PreludeSDK::Internal::Type::RequestParameters::Converter
9
+ include PreludeSDK::Internal::Type::RequestParameters
10
+
11
+ attr_reader cursor: String?
12
+
13
+ def cursor=: (String) -> String
14
+
15
+ attr_reader limit: Integer?
16
+
17
+ def limit=: (Integer) -> Integer
18
+
19
+ def initialize: (
20
+ ?cursor: String,
21
+ ?limit: Integer,
22
+ ?request_options: PreludeSDK::request_opts
23
+ ) -> void
24
+
25
+ def to_hash: -> {
26
+ cursor: String,
27
+ limit: Integer,
28
+ request_options: PreludeSDK::RequestOptions
29
+ }
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,119 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_list_subscription_configs_response =
4
+ {
5
+ configs: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config],
6
+ next_cursor: String
7
+ }
8
+
9
+ class NotifyListSubscriptionConfigsResponse < PreludeSDK::Internal::Type::BaseModel
10
+ attr_accessor configs: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config]
11
+
12
+ attr_reader next_cursor: String?
13
+
14
+ def next_cursor=: (String) -> String
15
+
16
+ def initialize: (
17
+ configs: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config],
18
+ ?next_cursor: String
19
+ ) -> void
20
+
21
+ def to_hash: -> {
22
+ configs: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config],
23
+ next_cursor: String
24
+ }
25
+
26
+ type config =
27
+ {
28
+ id: String,
29
+ callback_url: String,
30
+ created_at: Time,
31
+ messages: PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::Messages,
32
+ name: String,
33
+ updated_at: Time,
34
+ mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]
35
+ }
36
+
37
+ class Config < PreludeSDK::Internal::Type::BaseModel
38
+ attr_accessor id: String
39
+
40
+ attr_accessor callback_url: String
41
+
42
+ attr_accessor created_at: Time
43
+
44
+ attr_accessor messages: PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::Messages
45
+
46
+ attr_accessor name: String
47
+
48
+ attr_accessor updated_at: Time
49
+
50
+ attr_reader mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]?
51
+
52
+ def mo_phone_numbers=: (
53
+ ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]
54
+ ) -> ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]
55
+
56
+ def initialize: (
57
+ id: String,
58
+ callback_url: String,
59
+ created_at: Time,
60
+ messages: PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::Messages,
61
+ name: String,
62
+ updated_at: Time,
63
+ ?mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]
64
+ ) -> void
65
+
66
+ def to_hash: -> {
67
+ id: String,
68
+ callback_url: String,
69
+ created_at: Time,
70
+ messages: PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::Messages,
71
+ name: String,
72
+ updated_at: Time,
73
+ mo_phone_numbers: ::Array[PreludeSDK::Models::NotifyListSubscriptionConfigsResponse::Config::MoPhoneNumber]
74
+ }
75
+
76
+ type messages =
77
+ { help_message: String, start_message: String, stop_message: String }
78
+
79
+ class Messages < PreludeSDK::Internal::Type::BaseModel
80
+ attr_reader help_message: String?
81
+
82
+ def help_message=: (String) -> String
83
+
84
+ attr_reader start_message: String?
85
+
86
+ def start_message=: (String) -> String
87
+
88
+ attr_reader stop_message: String?
89
+
90
+ def stop_message=: (String) -> String
91
+
92
+ def initialize: (
93
+ ?help_message: String,
94
+ ?start_message: String,
95
+ ?stop_message: String
96
+ ) -> void
97
+
98
+ def to_hash: -> {
99
+ help_message: String,
100
+ start_message: String,
101
+ stop_message: String
102
+ }
103
+ end
104
+
105
+ type mo_phone_number = { country_code: String, phone_number: String }
106
+
107
+ class MoPhoneNumber < PreludeSDK::Internal::Type::BaseModel
108
+ attr_accessor country_code: String
109
+
110
+ attr_accessor phone_number: String
111
+
112
+ def initialize: (country_code: String, phone_number: String) -> void
113
+
114
+ def to_hash: -> { country_code: String, phone_number: String }
115
+ end
116
+ end
117
+ end
118
+ end
119
+ end
@@ -0,0 +1,36 @@
1
+ module PreludeSDK
2
+ module Models
3
+ type notify_list_subscription_phone_number_events_params =
4
+ { config_id: String, cursor: String, limit: Integer }
5
+ & PreludeSDK::Internal::Type::request_parameters
6
+
7
+ class NotifyListSubscriptionPhoneNumberEventsParams < PreludeSDK::Internal::Type::BaseModel
8
+ extend PreludeSDK::Internal::Type::RequestParameters::Converter
9
+ include PreludeSDK::Internal::Type::RequestParameters
10
+
11
+ attr_accessor config_id: String
12
+
13
+ attr_reader cursor: String?
14
+
15
+ def cursor=: (String) -> String
16
+
17
+ attr_reader limit: Integer?
18
+
19
+ def limit=: (Integer) -> Integer
20
+
21
+ def initialize: (
22
+ config_id: String,
23
+ ?cursor: String,
24
+ ?limit: Integer,
25
+ ?request_options: PreludeSDK::request_opts
26
+ ) -> void
27
+
28
+ def to_hash: -> {
29
+ config_id: String,
30
+ cursor: String,
31
+ limit: Integer,
32
+ request_options: PreludeSDK::RequestOptions
33
+ }
34
+ end
35
+ end
36
+ end