knockapi 1.16.0 → 1.18.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +36 -0
- data/README.md +1 -1
- data/lib/knockapi/internal/transport/pooled_net_requester.rb +30 -24
- data/lib/knockapi/internal/util.rb +5 -5
- data/lib/knockapi/models/identify_user_request.rb +2 -2
- data/lib/knockapi/models/inline_identify_user_request.rb +2 -2
- data/lib/knockapi/models/inline_object_request.rb +2 -2
- data/lib/knockapi/models/message.rb +94 -3
- data/lib/knockapi/models/messages/batch_archive_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_mark_as_interacted_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_mark_as_read_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_mark_as_seen_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_mark_as_unread_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_mark_as_unseen_response.rb +1 -1
- data/lib/knockapi/models/messages/batch_unarchive_response.rb +1 -1
- data/lib/knockapi/models/object_set_params.rb +2 -2
- data/lib/knockapi/models/objects/bulk_set_params.rb +2 -2
- data/lib/knockapi/models/recipients/channel_data.rb +133 -11
- data/lib/knockapi/models/recipients/channel_data_request.rb +151 -9
- data/lib/knockapi/models/recipients/inline_channel_data_request.rb +149 -7
- data/lib/knockapi/models/recipients/preference_set.rb +130 -3
- data/lib/knockapi/models/recipients/preference_set_request.rb +136 -3
- data/lib/knockapi/models/tenant_request.rb +2 -2
- data/lib/knockapi/models/tenant_set_params.rb +2 -2
- data/lib/knockapi/models/users/guide_get_channel_response.rb +270 -34
- data/lib/knockapi/resources/messages/batch.rb +7 -7
- data/lib/knockapi/resources/objects.rb +7 -3
- data/lib/knockapi/resources/tenants.rb +1 -1
- data/lib/knockapi/resources/users.rb +7 -3
- data/lib/knockapi/version.rb +1 -1
- data/lib/knockapi.rb +0 -2
- data/rbi/knockapi/models/identify_user_request.rbi +15 -9
- data/rbi/knockapi/models/inline_identify_user_request.rbi +15 -9
- data/rbi/knockapi/models/inline_object_request.rbi +15 -9
- data/rbi/knockapi/models/message.rbi +123 -2
- data/rbi/knockapi/models/messages/batch_archive_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_mark_as_interacted_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_mark_as_read_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_mark_as_seen_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_mark_as_unread_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_mark_as_unseen_response.rbi +1 -1
- data/rbi/knockapi/models/messages/batch_unarchive_response.rbi +1 -1
- data/rbi/knockapi/models/object_set_params.rbi +20 -12
- data/rbi/knockapi/models/objects/bulk_set_params.rbi +15 -9
- data/rbi/knockapi/models/recipients/channel_data.rbi +250 -12
- data/rbi/knockapi/models/recipients/channel_data_request.rbi +298 -14
- data/rbi/knockapi/models/recipients/inline_channel_data_request.rbi +281 -5
- data/rbi/knockapi/models/recipients/preference_set.rbi +279 -0
- data/rbi/knockapi/models/recipients/preference_set_request.rbi +299 -0
- data/rbi/knockapi/models/tenant_request.rbi +15 -9
- data/rbi/knockapi/models/tenant_set_params.rbi +15 -9
- data/rbi/knockapi/models/users/guide_get_channel_response.rbi +532 -70
- data/rbi/knockapi/resources/messages/batch.rbi +7 -7
- data/rbi/knockapi/resources/objects.rbi +26 -6
- data/rbi/knockapi/resources/tenants.rbi +5 -3
- data/rbi/knockapi/resources/users.rbi +26 -6
- data/sig/knockapi/models/message.rbs +79 -0
- data/sig/knockapi/models/messages/batch_archive_response.rbs +1 -1
- data/sig/knockapi/models/messages/batch_mark_as_interacted_response.rbs +1 -2
- data/sig/knockapi/models/messages/batch_mark_as_read_response.rbs +1 -1
- data/sig/knockapi/models/messages/batch_mark_as_seen_response.rbs +1 -1
- data/sig/knockapi/models/messages/batch_mark_as_unread_response.rbs +1 -1
- data/sig/knockapi/models/messages/batch_mark_as_unseen_response.rbs +1 -1
- data/sig/knockapi/models/messages/batch_unarchive_response.rbs +1 -1
- data/sig/knockapi/models/recipients/channel_data.rbs +97 -7
- data/sig/knockapi/models/recipients/channel_data_request.rbs +108 -5
- data/sig/knockapi/models/recipients/inline_channel_data_request.rbs +108 -5
- data/sig/knockapi/models/recipients/preference_set.rbs +87 -0
- data/sig/knockapi/models/recipients/preference_set_request.rbs +87 -0
- data/sig/knockapi/models/users/guide_get_channel_response.rbs +294 -31
- data/sig/knockapi/resources/objects.rbs +2 -0
- data/sig/knockapi/resources/users.rbs +2 -0
- metadata +2 -8
- data/lib/knockapi/models/recipients/one_signal_channel_data.rb +0 -20
- data/lib/knockapi/models/recipients/push_channel_data.rb +0 -20
- data/rbi/knockapi/models/recipients/one_signal_channel_data.rbi +0 -33
- data/rbi/knockapi/models/recipients/push_channel_data.rbi +0 -33
- data/sig/knockapi/models/recipients/one_signal_channel_data.rbs +0 -15
- data/sig/knockapi/models/recipients/push_channel_data.rbs +0 -15
|
@@ -5,81 +5,317 @@ module Knockapi
|
|
|
5
5
|
module Users
|
|
6
6
|
# @see Knockapi::Resources::Users::Guides#get_channel
|
|
7
7
|
class GuideGetChannelResponse < Knockapi::Internal::Type::BaseModel
|
|
8
|
-
# @!attribute
|
|
8
|
+
# @!attribute entries
|
|
9
9
|
# A list of guides.
|
|
10
10
|
#
|
|
11
|
-
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::
|
|
12
|
-
required :
|
|
13
|
-
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::
|
|
11
|
+
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry>]
|
|
12
|
+
required :entries,
|
|
13
|
+
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::Entry] }
|
|
14
14
|
|
|
15
|
-
# @!attribute
|
|
16
|
-
#
|
|
15
|
+
# @!attribute guide_group_display_logs
|
|
16
|
+
# A map of guide group keys to their last display timestamps.
|
|
17
17
|
#
|
|
18
|
-
# @return [
|
|
19
|
-
|
|
18
|
+
# @return [Hash{Symbol=>Time}]
|
|
19
|
+
required :guide_group_display_logs, Knockapi::Internal::Type::HashOf[Time]
|
|
20
20
|
|
|
21
|
-
# @!
|
|
21
|
+
# @!attribute guide_groups
|
|
22
|
+
# A list of guide groups with their display sequences and intervals.
|
|
23
|
+
#
|
|
24
|
+
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::GuideGroup>]
|
|
25
|
+
required :guide_groups,
|
|
26
|
+
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::GuideGroup] }
|
|
27
|
+
|
|
28
|
+
# @!method initialize(entries:, guide_group_display_logs:, guide_groups:)
|
|
22
29
|
# A response for a list of guides.
|
|
23
30
|
#
|
|
24
|
-
# @param
|
|
31
|
+
# @param entries [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry>] A list of guides.
|
|
32
|
+
#
|
|
33
|
+
# @param guide_group_display_logs [Hash{Symbol=>Time}] A map of guide group keys to their last display timestamps.
|
|
25
34
|
#
|
|
26
|
-
# @param
|
|
35
|
+
# @param guide_groups [Array<Knockapi::Models::Users::GuideGetChannelResponse::GuideGroup>] A list of guide groups with their display sequences and intervals.
|
|
27
36
|
|
|
28
|
-
class
|
|
37
|
+
class Entry < Knockapi::Internal::Type::BaseModel
|
|
29
38
|
# @!attribute id
|
|
30
39
|
# The unique identifier for the guide.
|
|
31
40
|
#
|
|
32
41
|
# @return [String, nil]
|
|
33
42
|
optional :id, String
|
|
34
43
|
|
|
44
|
+
# @!attribute _typename
|
|
45
|
+
# The typename of the schema.
|
|
46
|
+
#
|
|
47
|
+
# @return [String, nil]
|
|
48
|
+
optional :_typename, String, api_name: :__typename
|
|
49
|
+
|
|
50
|
+
# @!attribute activation_url_patterns
|
|
51
|
+
# A list of URL Patterns to evaluate user's current location to activate the
|
|
52
|
+
# guide, if matched
|
|
53
|
+
#
|
|
54
|
+
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLPattern>, nil]
|
|
55
|
+
optional :activation_url_patterns,
|
|
56
|
+
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLPattern] }
|
|
57
|
+
|
|
58
|
+
# @!attribute activation_url_rules
|
|
59
|
+
# A list of URL rules to evaluate user's current location to activate the guide,
|
|
60
|
+
# if matched
|
|
61
|
+
#
|
|
62
|
+
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLRule>, nil]
|
|
63
|
+
optional :activation_url_rules,
|
|
64
|
+
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLRule] }
|
|
65
|
+
|
|
35
66
|
# @!attribute active
|
|
36
67
|
# Whether the guide is active.
|
|
37
68
|
#
|
|
38
69
|
# @return [Boolean, nil]
|
|
39
70
|
optional :active, Knockapi::Internal::Type::Boolean
|
|
40
71
|
|
|
41
|
-
# @!attribute
|
|
42
|
-
#
|
|
72
|
+
# @!attribute bypass_global_group_limit
|
|
73
|
+
#
|
|
74
|
+
# @return [Boolean, nil]
|
|
75
|
+
optional :bypass_global_group_limit, Knockapi::Internal::Type::Boolean
|
|
76
|
+
|
|
77
|
+
# @!attribute channel_id
|
|
43
78
|
#
|
|
44
79
|
# @return [String, nil]
|
|
45
|
-
optional :
|
|
80
|
+
optional :channel_id, String
|
|
46
81
|
|
|
47
|
-
# @!attribute
|
|
48
|
-
# The metadata of the guide.
|
|
82
|
+
# @!attribute inserted_at
|
|
49
83
|
#
|
|
50
|
-
# @return [
|
|
51
|
-
optional :
|
|
84
|
+
# @return [Time, nil]
|
|
85
|
+
optional :inserted_at, Time
|
|
52
86
|
|
|
53
|
-
# @!attribute
|
|
54
|
-
# The
|
|
87
|
+
# @!attribute key
|
|
88
|
+
# The key of the guide.
|
|
55
89
|
#
|
|
56
90
|
# @return [String, nil]
|
|
57
|
-
optional :
|
|
91
|
+
optional :key, String
|
|
58
92
|
|
|
59
|
-
# @!
|
|
93
|
+
# @!attribute semver
|
|
94
|
+
#
|
|
95
|
+
# @return [String, nil]
|
|
96
|
+
optional :semver, String
|
|
97
|
+
|
|
98
|
+
# @!attribute steps
|
|
99
|
+
#
|
|
100
|
+
# @return [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step>, nil]
|
|
101
|
+
optional :steps,
|
|
102
|
+
-> { Knockapi::Internal::Type::ArrayOf[Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step] }
|
|
103
|
+
|
|
104
|
+
# @!attribute type
|
|
105
|
+
# The type of the guide.
|
|
106
|
+
#
|
|
107
|
+
# @return [String, nil]
|
|
108
|
+
optional :type, String
|
|
109
|
+
|
|
110
|
+
# @!attribute updated_at
|
|
111
|
+
#
|
|
112
|
+
# @return [Time, nil]
|
|
113
|
+
optional :updated_at, Time
|
|
114
|
+
|
|
115
|
+
# @!method initialize(id: nil, _typename: nil, activation_url_patterns: nil, activation_url_rules: nil, active: nil, bypass_global_group_limit: nil, channel_id: nil, inserted_at: nil, key: nil, semver: nil, steps: nil, type: nil, updated_at: nil)
|
|
116
|
+
# Some parameter documentations has been truncated, see
|
|
117
|
+
# {Knockapi::Models::Users::GuideGetChannelResponse::Entry} for more details.
|
|
118
|
+
#
|
|
60
119
|
# @param id [String] The unique identifier for the guide.
|
|
61
120
|
#
|
|
121
|
+
# @param _typename [String] The typename of the schema.
|
|
122
|
+
#
|
|
123
|
+
# @param activation_url_patterns [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLPattern>] A list of URL Patterns to evaluate user's current location to activate the guide
|
|
124
|
+
#
|
|
125
|
+
# @param activation_url_rules [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::ActivationURLRule>] A list of URL rules to evaluate user's current location to activate the guide, i
|
|
126
|
+
#
|
|
62
127
|
# @param active [Boolean] Whether the guide is active.
|
|
63
128
|
#
|
|
64
|
-
# @param
|
|
129
|
+
# @param bypass_global_group_limit [Boolean]
|
|
130
|
+
#
|
|
131
|
+
# @param channel_id [String]
|
|
132
|
+
#
|
|
133
|
+
# @param inserted_at [Time]
|
|
65
134
|
#
|
|
66
|
-
# @param
|
|
135
|
+
# @param key [String] The key of the guide.
|
|
67
136
|
#
|
|
68
|
-
# @param
|
|
137
|
+
# @param semver [String]
|
|
138
|
+
#
|
|
139
|
+
# @param steps [Array<Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step>]
|
|
140
|
+
#
|
|
141
|
+
# @param type [String] The type of the guide.
|
|
142
|
+
#
|
|
143
|
+
# @param updated_at [Time]
|
|
144
|
+
|
|
145
|
+
class ActivationURLPattern < Knockapi::Internal::Type::BaseModel
|
|
146
|
+
# @!attribute directive
|
|
147
|
+
# The directive for the URL pattern ('allow' or 'block')
|
|
148
|
+
#
|
|
149
|
+
# @return [String, nil]
|
|
150
|
+
optional :directive, String
|
|
151
|
+
|
|
152
|
+
# @!attribute pathname
|
|
153
|
+
# The pathname pattern to match (supports wildcards like /\*)
|
|
154
|
+
#
|
|
155
|
+
# @return [String, nil]
|
|
156
|
+
optional :pathname, String
|
|
157
|
+
|
|
158
|
+
# @!method initialize(directive: nil, pathname: nil)
|
|
159
|
+
# @param directive [String] The directive for the URL pattern ('allow' or 'block')
|
|
160
|
+
#
|
|
161
|
+
# @param pathname [String] The pathname pattern to match (supports wildcards like /\*)
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
class ActivationURLRule < Knockapi::Internal::Type::BaseModel
|
|
165
|
+
# @!attribute argument
|
|
166
|
+
# The value to compare against
|
|
167
|
+
#
|
|
168
|
+
# @return [String, nil]
|
|
169
|
+
optional :argument, String
|
|
170
|
+
|
|
171
|
+
# @!attribute directive
|
|
172
|
+
# The directive for the URL pattern ('allow' or 'block')
|
|
173
|
+
#
|
|
174
|
+
# @return [String, nil]
|
|
175
|
+
optional :directive, String
|
|
176
|
+
|
|
177
|
+
# @!attribute operator
|
|
178
|
+
# The comparison operator ('contains' or 'equal_to')
|
|
179
|
+
#
|
|
180
|
+
# @return [String, nil]
|
|
181
|
+
optional :operator, String
|
|
182
|
+
|
|
183
|
+
# @!attribute variable
|
|
184
|
+
# The variable to evaluate ('pathname')
|
|
185
|
+
#
|
|
186
|
+
# @return [String, nil]
|
|
187
|
+
optional :variable, String
|
|
188
|
+
|
|
189
|
+
# @!method initialize(argument: nil, directive: nil, operator: nil, variable: nil)
|
|
190
|
+
# @param argument [String] The value to compare against
|
|
191
|
+
#
|
|
192
|
+
# @param directive [String] The directive for the URL pattern ('allow' or 'block')
|
|
193
|
+
#
|
|
194
|
+
# @param operator [String] The comparison operator ('contains' or 'equal_to')
|
|
195
|
+
#
|
|
196
|
+
# @param variable [String] The variable to evaluate ('pathname')
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
class Step < Knockapi::Internal::Type::BaseModel
|
|
200
|
+
# @!attribute content
|
|
201
|
+
#
|
|
202
|
+
# @return [Hash{Symbol=>Object}, nil]
|
|
203
|
+
optional :content, Knockapi::Internal::Type::HashOf[Knockapi::Internal::Type::Unknown]
|
|
204
|
+
|
|
205
|
+
# @!attribute message
|
|
206
|
+
#
|
|
207
|
+
# @return [Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step::Message, nil]
|
|
208
|
+
optional :message, -> { Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step::Message }
|
|
209
|
+
|
|
210
|
+
# @!attribute ref
|
|
211
|
+
#
|
|
212
|
+
# @return [String, nil]
|
|
213
|
+
optional :ref, String
|
|
214
|
+
|
|
215
|
+
# @!attribute schema_key
|
|
216
|
+
#
|
|
217
|
+
# @return [String, nil]
|
|
218
|
+
optional :schema_key, String
|
|
219
|
+
|
|
220
|
+
# @!attribute schema_semver
|
|
221
|
+
#
|
|
222
|
+
# @return [String, nil]
|
|
223
|
+
optional :schema_semver, String
|
|
224
|
+
|
|
225
|
+
# @!attribute schema_variant_key
|
|
226
|
+
#
|
|
227
|
+
# @return [String, nil]
|
|
228
|
+
optional :schema_variant_key, String
|
|
229
|
+
|
|
230
|
+
# @!method initialize(content: nil, message: nil, ref: nil, schema_key: nil, schema_semver: nil, schema_variant_key: nil)
|
|
231
|
+
# @param content [Hash{Symbol=>Object}]
|
|
232
|
+
# @param message [Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step::Message]
|
|
233
|
+
# @param ref [String]
|
|
234
|
+
# @param schema_key [String]
|
|
235
|
+
# @param schema_semver [String]
|
|
236
|
+
# @param schema_variant_key [String]
|
|
237
|
+
|
|
238
|
+
# @see Knockapi::Models::Users::GuideGetChannelResponse::Entry::Step#message
|
|
239
|
+
class Message < Knockapi::Internal::Type::BaseModel
|
|
240
|
+
# @!attribute id
|
|
241
|
+
#
|
|
242
|
+
# @return [String, nil]
|
|
243
|
+
optional :id, String, nil?: true
|
|
244
|
+
|
|
245
|
+
# @!attribute archived_at
|
|
246
|
+
#
|
|
247
|
+
# @return [Time, nil]
|
|
248
|
+
optional :archived_at, Time, nil?: true
|
|
249
|
+
|
|
250
|
+
# @!attribute interacted_at
|
|
251
|
+
#
|
|
252
|
+
# @return [Time, nil]
|
|
253
|
+
optional :interacted_at, Time, nil?: true
|
|
254
|
+
|
|
255
|
+
# @!attribute link_clicked_at
|
|
256
|
+
#
|
|
257
|
+
# @return [Time, nil]
|
|
258
|
+
optional :link_clicked_at, Time, nil?: true
|
|
259
|
+
|
|
260
|
+
# @!attribute read_at
|
|
261
|
+
#
|
|
262
|
+
# @return [Time, nil]
|
|
263
|
+
optional :read_at, Time, nil?: true
|
|
264
|
+
|
|
265
|
+
# @!attribute seen_at
|
|
266
|
+
#
|
|
267
|
+
# @return [Time, nil]
|
|
268
|
+
optional :seen_at, Time, nil?: true
|
|
269
|
+
|
|
270
|
+
# @!method initialize(id: nil, archived_at: nil, interacted_at: nil, link_clicked_at: nil, read_at: nil, seen_at: nil)
|
|
271
|
+
# @param id [String, nil]
|
|
272
|
+
# @param archived_at [Time, nil]
|
|
273
|
+
# @param interacted_at [Time, nil]
|
|
274
|
+
# @param link_clicked_at [Time, nil]
|
|
275
|
+
# @param read_at [Time, nil]
|
|
276
|
+
# @param seen_at [Time, nil]
|
|
277
|
+
end
|
|
278
|
+
end
|
|
69
279
|
end
|
|
70
280
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
# @!attribute id
|
|
74
|
-
# Unique identifier for the recipient.
|
|
281
|
+
class GuideGroup < Knockapi::Internal::Type::BaseModel
|
|
282
|
+
# @!attribute _typename
|
|
75
283
|
#
|
|
76
284
|
# @return [String, nil]
|
|
77
|
-
optional :
|
|
285
|
+
optional :_typename, String, api_name: :__typename
|
|
286
|
+
|
|
287
|
+
# @!attribute display_interval
|
|
288
|
+
#
|
|
289
|
+
# @return [Integer, nil]
|
|
290
|
+
optional :display_interval, Integer
|
|
78
291
|
|
|
79
|
-
# @!
|
|
80
|
-
# The recipient of the guide.
|
|
292
|
+
# @!attribute display_sequence
|
|
81
293
|
#
|
|
82
|
-
# @
|
|
294
|
+
# @return [Array<String>, nil]
|
|
295
|
+
optional :display_sequence, Knockapi::Internal::Type::ArrayOf[String]
|
|
296
|
+
|
|
297
|
+
# @!attribute inserted_at
|
|
298
|
+
#
|
|
299
|
+
# @return [Time, nil]
|
|
300
|
+
optional :inserted_at, Time
|
|
301
|
+
|
|
302
|
+
# @!attribute key
|
|
303
|
+
#
|
|
304
|
+
# @return [String, nil]
|
|
305
|
+
optional :key, String
|
|
306
|
+
|
|
307
|
+
# @!attribute updated_at
|
|
308
|
+
#
|
|
309
|
+
# @return [Time, nil]
|
|
310
|
+
optional :updated_at, Time
|
|
311
|
+
|
|
312
|
+
# @!method initialize(_typename: nil, display_interval: nil, display_sequence: nil, inserted_at: nil, key: nil, updated_at: nil)
|
|
313
|
+
# @param _typename [String]
|
|
314
|
+
# @param display_interval [Integer]
|
|
315
|
+
# @param display_sequence [Array<String>]
|
|
316
|
+
# @param inserted_at [Time]
|
|
317
|
+
# @param key [String]
|
|
318
|
+
# @param updated_at [Time]
|
|
83
319
|
end
|
|
84
320
|
end
|
|
85
321
|
end
|
|
@@ -22,7 +22,7 @@ module Knockapi
|
|
|
22
22
|
method: :post,
|
|
23
23
|
path: "v1/messages/batch/archived",
|
|
24
24
|
body: parsed,
|
|
25
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
25
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
26
26
|
options: options
|
|
27
27
|
)
|
|
28
28
|
end
|
|
@@ -72,7 +72,7 @@ module Knockapi
|
|
|
72
72
|
method: :post,
|
|
73
73
|
path: "v1/messages/batch/interacted",
|
|
74
74
|
body: parsed,
|
|
75
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
75
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
76
76
|
options: options
|
|
77
77
|
)
|
|
78
78
|
end
|
|
@@ -95,7 +95,7 @@ module Knockapi
|
|
|
95
95
|
method: :post,
|
|
96
96
|
path: "v1/messages/batch/read",
|
|
97
97
|
body: parsed,
|
|
98
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
98
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
99
99
|
options: options
|
|
100
100
|
)
|
|
101
101
|
end
|
|
@@ -119,7 +119,7 @@ module Knockapi
|
|
|
119
119
|
method: :post,
|
|
120
120
|
path: "v1/messages/batch/seen",
|
|
121
121
|
body: parsed,
|
|
122
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
122
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
123
123
|
options: options
|
|
124
124
|
)
|
|
125
125
|
end
|
|
@@ -143,7 +143,7 @@ module Knockapi
|
|
|
143
143
|
method: :post,
|
|
144
144
|
path: "v1/messages/batch/unread",
|
|
145
145
|
body: parsed,
|
|
146
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
146
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
147
147
|
options: options
|
|
148
148
|
)
|
|
149
149
|
end
|
|
@@ -167,7 +167,7 @@ module Knockapi
|
|
|
167
167
|
method: :post,
|
|
168
168
|
path: "v1/messages/batch/unseen",
|
|
169
169
|
body: parsed,
|
|
170
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
170
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
171
171
|
options: options
|
|
172
172
|
)
|
|
173
173
|
end
|
|
@@ -191,7 +191,7 @@ module Knockapi
|
|
|
191
191
|
method: :post,
|
|
192
192
|
path: "v1/messages/batch/unarchived",
|
|
193
193
|
body: parsed,
|
|
194
|
-
model: Knockapi::Internal::Type::ArrayOf[Knockapi::
|
|
194
|
+
model: Knockapi::Internal::Type::ArrayOf[Knockapi::Message],
|
|
195
195
|
options: options
|
|
196
196
|
)
|
|
197
197
|
end
|
|
@@ -368,7 +368,7 @@ module Knockapi
|
|
|
368
368
|
#
|
|
369
369
|
# @param id [String] Unique identifier for the object.
|
|
370
370
|
#
|
|
371
|
-
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::
|
|
371
|
+
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly, Knockapi::Models::Recipients::SlackChannelData, Knockapi::Models::Recipients::MsTeamsChannelData, Knockapi::Models::Recipients::DiscordChannelData}] A request to set channel data for a type of channel inline.
|
|
372
372
|
#
|
|
373
373
|
# @param locale [String, nil] The locale of the object. Used for [message localization](/concepts/translations
|
|
374
374
|
#
|
|
@@ -404,7 +404,7 @@ module Knockapi
|
|
|
404
404
|
#
|
|
405
405
|
# @param channel_id [String] The unique identifier for the channel.
|
|
406
406
|
#
|
|
407
|
-
# @param data [Knockapi::Models::Recipients::
|
|
407
|
+
# @param data [Knockapi::Models::Recipients::ChannelDataRequest::Data::PushChannelDataTokensOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::PushChannelDataDevicesOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::AwssnsPushChannelDataTargetArNsOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::AwssnsPushChannelDataDevicesOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::OneSignalChannelDataPlayerIDsOnly, Knockapi::Models::Recipients::SlackChannelData, Knockapi::Models::Recipients::MsTeamsChannelData, Knockapi::Models::Recipients::DiscordChannelData] Channel data for a given channel type.
|
|
408
408
|
#
|
|
409
409
|
# @param request_options [Knockapi::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
410
410
|
#
|
|
@@ -434,7 +434,7 @@ module Knockapi
|
|
|
434
434
|
# `tenant.id`. Learn more about
|
|
435
435
|
# [per-tenant preferences](/preferences/tenant-preferences).
|
|
436
436
|
#
|
|
437
|
-
# @overload set_preferences(collection, object_id_, id, _persistence_strategy: nil, categories: nil, channel_types: nil, workflows: nil, request_options: {})
|
|
437
|
+
# @overload set_preferences(collection, object_id_, id, _persistence_strategy: nil, categories: nil, channel_types: nil, channels: nil, commercial_subscribed: nil, workflows: nil, request_options: {})
|
|
438
438
|
#
|
|
439
439
|
# @param collection [String] The collection this object belongs to.
|
|
440
440
|
#
|
|
@@ -448,6 +448,10 @@ module Knockapi
|
|
|
448
448
|
#
|
|
449
449
|
# @param channel_types [Knockapi::Models::Recipients::PreferenceSetChannelTypes, nil] Channel type preferences.
|
|
450
450
|
#
|
|
451
|
+
# @param channels [Hash{Symbol=>Boolean, Knockapi::Models::Recipients::PreferenceSetRequest::Channel::PreferenceSetChannelSetting}, nil] Channel preferences.
|
|
452
|
+
#
|
|
453
|
+
# @param commercial_subscribed [Boolean, nil] Whether the recipient is subscribed to commercial communications. When false, th
|
|
454
|
+
#
|
|
451
455
|
# @param workflows [Hash{Symbol=>Boolean, Knockapi::Models::Recipients::PreferenceSetRequest::Workflow::PreferenceSetWorkflowCategorySettingObject}, nil] An object where the key is the workflow key and the values are the preference se
|
|
452
456
|
#
|
|
453
457
|
# @param request_options [Knockapi::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
@@ -84,7 +84,7 @@ module Knockapi
|
|
|
84
84
|
#
|
|
85
85
|
# @param id [String] The unique identifier for the tenant.
|
|
86
86
|
#
|
|
87
|
-
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::
|
|
87
|
+
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly, Knockapi::Models::Recipients::SlackChannelData, Knockapi::Models::Recipients::MsTeamsChannelData, Knockapi::Models::Recipients::DiscordChannelData}, nil] A request to set channel data for a type of channel inline.
|
|
88
88
|
#
|
|
89
89
|
# @param settings [Knockapi::Models::TenantSetParams::Settings] The settings for the tenant. Includes branding and preference set.
|
|
90
90
|
#
|
|
@@ -25,7 +25,7 @@ module Knockapi
|
|
|
25
25
|
#
|
|
26
26
|
# @param avatar [String, nil] A URL for the avatar of the user.
|
|
27
27
|
#
|
|
28
|
-
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::
|
|
28
|
+
# @param channel_data [Hash{Symbol=>Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly, Knockapi::Models::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly, Knockapi::Models::Recipients::SlackChannelData, Knockapi::Models::Recipients::MsTeamsChannelData, Knockapi::Models::Recipients::DiscordChannelData}, nil] A request to set channel data for a type of channel inline.
|
|
29
29
|
#
|
|
30
30
|
# @param created_at [Time, nil] The creation date of the user from your system.
|
|
31
31
|
#
|
|
@@ -354,7 +354,7 @@ module Knockapi
|
|
|
354
354
|
#
|
|
355
355
|
# @param channel_id [String] The unique identifier for the channel.
|
|
356
356
|
#
|
|
357
|
-
# @param data [Knockapi::Models::Recipients::
|
|
357
|
+
# @param data [Knockapi::Models::Recipients::ChannelDataRequest::Data::PushChannelDataTokensOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::PushChannelDataDevicesOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::AwssnsPushChannelDataTargetArNsOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::AwssnsPushChannelDataDevicesOnly, Knockapi::Models::Recipients::ChannelDataRequest::Data::OneSignalChannelDataPlayerIDsOnly, Knockapi::Models::Recipients::SlackChannelData, Knockapi::Models::Recipients::MsTeamsChannelData, Knockapi::Models::Recipients::DiscordChannelData] Channel data for a given channel type.
|
|
358
358
|
#
|
|
359
359
|
# @param request_options [Knockapi::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
360
360
|
#
|
|
@@ -380,7 +380,7 @@ module Knockapi
|
|
|
380
380
|
# Use '**persistence_strategy**': 'merge' to merge with existing preferences
|
|
381
381
|
# instead.
|
|
382
382
|
#
|
|
383
|
-
# @overload set_preferences(user_id, id, _persistence_strategy: nil, categories: nil, channel_types: nil, workflows: nil, request_options: {})
|
|
383
|
+
# @overload set_preferences(user_id, id, _persistence_strategy: nil, categories: nil, channel_types: nil, channels: nil, commercial_subscribed: nil, workflows: nil, request_options: {})
|
|
384
384
|
#
|
|
385
385
|
# @param user_id [String] The unique identifier of the user.
|
|
386
386
|
#
|
|
@@ -392,6 +392,10 @@ module Knockapi
|
|
|
392
392
|
#
|
|
393
393
|
# @param channel_types [Knockapi::Models::Recipients::PreferenceSetChannelTypes, nil] Channel type preferences.
|
|
394
394
|
#
|
|
395
|
+
# @param channels [Hash{Symbol=>Boolean, Knockapi::Models::Recipients::PreferenceSetRequest::Channel::PreferenceSetChannelSetting}, nil] Channel preferences.
|
|
396
|
+
#
|
|
397
|
+
# @param commercial_subscribed [Boolean, nil] Whether the recipient is subscribed to commercial communications. When false, th
|
|
398
|
+
#
|
|
395
399
|
# @param workflows [Hash{Symbol=>Boolean, Knockapi::Models::Recipients::PreferenceSetRequest::Workflow::PreferenceSetWorkflowCategorySettingObject}, nil] An object where the key is the workflow key and the values are the preference se
|
|
396
400
|
#
|
|
397
401
|
# @param request_options [Knockapi::RequestOptions, Hash{Symbol=>Object}, nil]
|
data/lib/knockapi/version.rb
CHANGED
data/lib/knockapi.rb
CHANGED
|
@@ -151,11 +151,9 @@ require_relative "knockapi/models/recipients/discord_channel_data"
|
|
|
151
151
|
require_relative "knockapi/models/recipients/inline_channel_data_request"
|
|
152
152
|
require_relative "knockapi/models/recipients/inline_preference_set_request"
|
|
153
153
|
require_relative "knockapi/models/recipients/ms_teams_channel_data"
|
|
154
|
-
require_relative "knockapi/models/recipients/one_signal_channel_data"
|
|
155
154
|
require_relative "knockapi/models/recipients/preference_set"
|
|
156
155
|
require_relative "knockapi/models/recipients/preference_set_channel_types"
|
|
157
156
|
require_relative "knockapi/models/recipients/preference_set_channel_type_setting"
|
|
158
|
-
require_relative "knockapi/models/recipients/push_channel_data"
|
|
159
157
|
require_relative "knockapi/models/recipients/channel_data"
|
|
160
158
|
require_relative "knockapi/models/recipients/slack_channel_data"
|
|
161
159
|
require_relative "knockapi/models/recipients/subscription"
|
|
@@ -19,9 +19,11 @@ module Knockapi
|
|
|
19
19
|
T::Hash[
|
|
20
20
|
Symbol,
|
|
21
21
|
T.any(
|
|
22
|
-
Knockapi::Recipients::
|
|
23
|
-
Knockapi::Recipients::
|
|
24
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
22
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly,
|
|
23
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly,
|
|
24
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly,
|
|
25
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly,
|
|
26
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly,
|
|
25
27
|
Knockapi::Recipients::SlackChannelData,
|
|
26
28
|
Knockapi::Recipients::MsTeamsChannelData,
|
|
27
29
|
Knockapi::Recipients::DiscordChannelData
|
|
@@ -81,9 +83,11 @@ module Knockapi
|
|
|
81
83
|
T::Hash[
|
|
82
84
|
Symbol,
|
|
83
85
|
T.any(
|
|
84
|
-
Knockapi::Recipients::
|
|
85
|
-
Knockapi::Recipients::
|
|
86
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
86
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly::OrHash,
|
|
87
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly::OrHash,
|
|
88
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly::OrHash,
|
|
89
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly::OrHash,
|
|
90
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly::OrHash,
|
|
87
91
|
Knockapi::Recipients::SlackChannelData::OrHash,
|
|
88
92
|
Knockapi::Recipients::MsTeamsChannelData::OrHash,
|
|
89
93
|
Knockapi::Recipients::DiscordChannelData::OrHash
|
|
@@ -142,9 +146,11 @@ module Knockapi
|
|
|
142
146
|
T::Hash[
|
|
143
147
|
Symbol,
|
|
144
148
|
T.any(
|
|
145
|
-
Knockapi::Recipients::
|
|
146
|
-
Knockapi::Recipients::
|
|
147
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
149
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly,
|
|
150
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly,
|
|
151
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly,
|
|
152
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly,
|
|
153
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly,
|
|
148
154
|
Knockapi::Recipients::SlackChannelData,
|
|
149
155
|
Knockapi::Recipients::MsTeamsChannelData,
|
|
150
156
|
Knockapi::Recipients::DiscordChannelData
|
|
@@ -26,9 +26,11 @@ module Knockapi
|
|
|
26
26
|
T::Hash[
|
|
27
27
|
Symbol,
|
|
28
28
|
T.any(
|
|
29
|
-
Knockapi::Recipients::
|
|
30
|
-
Knockapi::Recipients::
|
|
31
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
29
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly,
|
|
30
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly,
|
|
31
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly,
|
|
32
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly,
|
|
33
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly,
|
|
32
34
|
Knockapi::Recipients::SlackChannelData,
|
|
33
35
|
Knockapi::Recipients::MsTeamsChannelData,
|
|
34
36
|
Knockapi::Recipients::DiscordChannelData
|
|
@@ -90,9 +92,11 @@ module Knockapi
|
|
|
90
92
|
T::Hash[
|
|
91
93
|
Symbol,
|
|
92
94
|
T.any(
|
|
93
|
-
Knockapi::Recipients::
|
|
94
|
-
Knockapi::Recipients::
|
|
95
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
95
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly::OrHash,
|
|
96
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly::OrHash,
|
|
97
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly::OrHash,
|
|
98
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly::OrHash,
|
|
99
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly::OrHash,
|
|
96
100
|
Knockapi::Recipients::SlackChannelData::OrHash,
|
|
97
101
|
Knockapi::Recipients::MsTeamsChannelData::OrHash,
|
|
98
102
|
Knockapi::Recipients::DiscordChannelData::OrHash
|
|
@@ -154,9 +158,11 @@ module Knockapi
|
|
|
154
158
|
T::Hash[
|
|
155
159
|
Symbol,
|
|
156
160
|
T.any(
|
|
157
|
-
Knockapi::Recipients::
|
|
158
|
-
Knockapi::Recipients::
|
|
159
|
-
Knockapi::Recipients::InlineChannelDataRequestItem::
|
|
161
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataTokensOnly,
|
|
162
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::PushChannelDataDevicesOnly,
|
|
163
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataTargetArNsOnly,
|
|
164
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::AwssnsPushChannelDataDevicesOnly,
|
|
165
|
+
Knockapi::Recipients::InlineChannelDataRequestItem::OneSignalChannelDataPlayerIDsOnly,
|
|
160
166
|
Knockapi::Recipients::SlackChannelData,
|
|
161
167
|
Knockapi::Recipients::MsTeamsChannelData,
|
|
162
168
|
Knockapi::Recipients::DiscordChannelData
|