knockapi 1.6.0 → 1.7.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 +14 -0
- data/README.md +1 -1
- data/lib/knockapi/models/identify_user_request.rb +2 -0
- data/lib/knockapi/models/inline_identify_user_request.rb +2 -0
- data/lib/knockapi/models/inline_object_request.rb +5 -0
- data/lib/knockapi/models/object_set_params.rb +2 -0
- data/lib/knockapi/models/objects/bulk_set_params.rb +5 -0
- data/lib/knockapi/models/tenant_request.rb +5 -0
- data/lib/knockapi/resources/users/bulk.rb +8 -7
- data/lib/knockapi/version.rb +1 -1
- data/rbi/knockapi/models/identify_user_request.rbi +4 -0
- data/rbi/knockapi/models/inline_identify_user_request.rbi +4 -0
- data/rbi/knockapi/models/inline_object_request.rbi +4 -0
- data/rbi/knockapi/models/object_set_params.rbi +4 -0
- data/rbi/knockapi/models/objects/bulk_set_params.rbi +4 -0
- data/rbi/knockapi/models/tenant_request.rbi +4 -0
- data/rbi/knockapi/resources/objects.rbi +2 -0
- data/rbi/knockapi/resources/users/bulk.rbi +8 -7
- data/rbi/knockapi/resources/users.rbi +2 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a8fe0e1d10c71e9d8525e72100489e37c46340b10b56774afdb51c91e42edd82
|
4
|
+
data.tar.gz: '033928a1fd5f48acc9a83424c4c9f57a63fedd47510d3f6be6be822c6b0784e1'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1d390284ec7a8d3d6229b24536c000a93c86864fcd8280ce8c9d9c5b68ee3ca6d18cb9ec2a8cf0c69609e839941cef90e34b5e2355a0b77caf152c3db1a983b2
|
7
|
+
data.tar.gz: aa2d1c5854f1f2f747862ef533f4fa6867dc0379cfff4d7fb03b6d5197bc29ea4d634c595e26ab9c454c9da589217d4c84e037b26e019b9071df5a53ae73278e
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,19 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 1.7.0 (2025-06-12)
|
4
|
+
|
5
|
+
Full Changelog: [v1.6.0...v1.7.0](https://github.com/knocklabs/knock-ruby/compare/v1.6.0...v1.7.0)
|
6
|
+
|
7
|
+
### Features
|
8
|
+
|
9
|
+
* **api:** api update ([ccc6df0](https://github.com/knocklabs/knock-ruby/commit/ccc6df0d616d93198a605ec4c986e03369a8843b))
|
10
|
+
* **api:** api update ([fddf322](https://github.com/knocklabs/knock-ruby/commit/fddf3226958f8a212c5c3fa4d0dc8f72c01dcbe5))
|
11
|
+
|
12
|
+
|
13
|
+
### Chores
|
14
|
+
|
15
|
+
* **ci:** link to correct github repo ([acd8f88](https://github.com/knocklabs/knock-ruby/commit/acd8f8882a660c449b45113b848944327382f1a0))
|
16
|
+
|
3
17
|
## 1.6.0 (2025-06-06)
|
4
18
|
|
5
19
|
Full Changelog: [v1.5.0...v1.6.0](https://github.com/knocklabs/knock-ruby/compare/v1.5.0...v1.6.0)
|
data/README.md
CHANGED
@@ -52,6 +52,8 @@ module Knockapi
|
|
52
52
|
|
53
53
|
# @!attribute preferences
|
54
54
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
55
|
+
# Preferences that are set inline will be merged into any existing preferences
|
56
|
+
# rather than replacing them.
|
55
57
|
#
|
56
58
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
57
59
|
optional :preferences,
|
@@ -58,6 +58,8 @@ module Knockapi
|
|
58
58
|
|
59
59
|
# @!attribute preferences
|
60
60
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
61
|
+
# Preferences that are set inline will be merged into any existing preferences
|
62
|
+
# rather than replacing them.
|
61
63
|
#
|
62
64
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
63
65
|
optional :preferences,
|
@@ -33,6 +33,8 @@ module Knockapi
|
|
33
33
|
|
34
34
|
# @!attribute preferences
|
35
35
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
36
|
+
# Preferences that are set inline will be merged into any existing preferences
|
37
|
+
# rather than replacing them.
|
36
38
|
#
|
37
39
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
38
40
|
optional :preferences,
|
@@ -40,6 +42,9 @@ module Knockapi
|
|
40
42
|
nil?: true
|
41
43
|
|
42
44
|
# @!method initialize(id:, collection:, channel_data: nil, created_at: nil, preferences: nil)
|
45
|
+
# Some parameter documentations has been truncated, see
|
46
|
+
# {Knockapi::Models::InlineObjectRequest} for more details.
|
47
|
+
#
|
43
48
|
# A custom [Object](/concepts/objects) entity which belongs to a collection.
|
44
49
|
#
|
45
50
|
# @param id [String] Unique identifier for the object.
|
@@ -25,6 +25,8 @@ module Knockapi
|
|
25
25
|
|
26
26
|
# @!attribute preferences
|
27
27
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
28
|
+
# Preferences that are set inline will be merged into any existing preferences
|
29
|
+
# rather than replacing them.
|
28
30
|
#
|
29
31
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
30
32
|
optional :preferences,
|
@@ -44,6 +44,8 @@ module Knockapi
|
|
44
44
|
|
45
45
|
# @!attribute preferences
|
46
46
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
47
|
+
# Preferences that are set inline will be merged into any existing preferences
|
48
|
+
# rather than replacing them.
|
47
49
|
#
|
48
50
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
49
51
|
optional :preferences,
|
@@ -51,6 +53,9 @@ module Knockapi
|
|
51
53
|
nil?: true
|
52
54
|
|
53
55
|
# @!method initialize(id:, channel_data: nil, created_at: nil, preferences: nil)
|
56
|
+
# Some parameter documentations has been truncated, see
|
57
|
+
# {Knockapi::Models::Objects::BulkSetParams::Object} for more details.
|
58
|
+
#
|
54
59
|
# A custom [Object](/concepts/objects) entity which belongs to a collection.
|
55
60
|
#
|
56
61
|
# @param id [String] Unique identifier for the object.
|
@@ -21,6 +21,8 @@ module Knockapi
|
|
21
21
|
|
22
22
|
# @!attribute preferences
|
23
23
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
24
|
+
# Preferences that are set inline will be merged into any existing preferences
|
25
|
+
# rather than replacing them.
|
24
26
|
#
|
25
27
|
# @return [Hash{Symbol=>Knockapi::Models::Recipients::PreferenceSetRequest}, nil]
|
26
28
|
optional :preferences,
|
@@ -34,6 +36,9 @@ module Knockapi
|
|
34
36
|
optional :settings, -> { Knockapi::TenantRequest::Settings }
|
35
37
|
|
36
38
|
# @!method initialize(id:, channel_data: nil, preferences: nil, settings: nil)
|
39
|
+
# Some parameter documentations has been truncated, see
|
40
|
+
# {Knockapi::Models::TenantRequest} for more details.
|
41
|
+
#
|
37
42
|
# A tenant to be set in the system. You can supply any additional properties on
|
38
43
|
# the tenant object.
|
39
44
|
#
|
@@ -4,8 +4,7 @@ module Knockapi
|
|
4
4
|
module Resources
|
5
5
|
class Users
|
6
6
|
class Bulk
|
7
|
-
#
|
8
|
-
# delete and returns a bulk operation that can be queried for progress.
|
7
|
+
# Permanently deletes up to 1,000 users at a time.
|
9
8
|
#
|
10
9
|
# @overload delete(user_ids:, request_options: {})
|
11
10
|
#
|
@@ -28,8 +27,8 @@ module Knockapi
|
|
28
27
|
end
|
29
28
|
|
30
29
|
# Identifies multiple users in a single operation. Allows creating or updating up
|
31
|
-
# to
|
32
|
-
# data.
|
30
|
+
# to 1,000 users in a single batch with various properties, preferences, and
|
31
|
+
# channel data.
|
33
32
|
#
|
34
33
|
# @overload identify(users:, request_options: {})
|
35
34
|
#
|
@@ -51,9 +50,11 @@ module Knockapi
|
|
51
50
|
)
|
52
51
|
end
|
53
52
|
|
54
|
-
#
|
55
|
-
#
|
56
|
-
#
|
53
|
+
# Bulk sets the preferences for up to 1,000 users at a time. The preference
|
54
|
+
# set `:id` can be either `default` or a `tenant.id`. Learn more
|
55
|
+
# about [per-tenant preferences](/preferences/tenant-preferences). Note that this
|
56
|
+
# is a destructive operation and will replace any existing users' preferences with
|
57
|
+
# the preferences sent.
|
57
58
|
#
|
58
59
|
# @overload set_preferences(preferences:, user_ids:, request_options: {})
|
59
60
|
#
|
data/lib/knockapi/version.rb
CHANGED
@@ -53,6 +53,8 @@ module Knockapi
|
|
53
53
|
attr_accessor :phone_number
|
54
54
|
|
55
55
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
56
|
+
# Preferences that are set inline will be merged into any existing preferences
|
57
|
+
# rather than replacing them.
|
56
58
|
sig do
|
57
59
|
returns(
|
58
60
|
T.nilable(T::Hash[Symbol, Knockapi::Recipients::PreferenceSetRequest])
|
@@ -118,6 +120,8 @@ module Knockapi
|
|
118
120
|
# user (required for SMS channels).
|
119
121
|
phone_number: nil,
|
120
122
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
123
|
+
# Preferences that are set inline will be merged into any existing preferences
|
124
|
+
# rather than replacing them.
|
121
125
|
preferences: nil,
|
122
126
|
# The timezone of the user. Must be a
|
123
127
|
# valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
|
@@ -60,6 +60,8 @@ module Knockapi
|
|
60
60
|
attr_accessor :phone_number
|
61
61
|
|
62
62
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
63
|
+
# Preferences that are set inline will be merged into any existing preferences
|
64
|
+
# rather than replacing them.
|
63
65
|
sig do
|
64
66
|
returns(
|
65
67
|
T.nilable(T::Hash[Symbol, Knockapi::Recipients::PreferenceSetRequest])
|
@@ -129,6 +131,8 @@ module Knockapi
|
|
129
131
|
# user (required for SMS channels).
|
130
132
|
phone_number: nil,
|
131
133
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
134
|
+
# Preferences that are set inline will be merged into any existing preferences
|
135
|
+
# rather than replacing them.
|
132
136
|
preferences: nil,
|
133
137
|
# The timezone of the user. Must be a
|
134
138
|
# valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
|
@@ -40,6 +40,8 @@ module Knockapi
|
|
40
40
|
attr_accessor :created_at
|
41
41
|
|
42
42
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
43
|
+
# Preferences that are set inline will be merged into any existing preferences
|
44
|
+
# rather than replacing them.
|
43
45
|
sig do
|
44
46
|
returns(
|
45
47
|
T.nilable(T::Hash[Symbol, Knockapi::Recipients::PreferenceSetRequest])
|
@@ -85,6 +87,8 @@ module Knockapi
|
|
85
87
|
# Timestamp when the resource was created.
|
86
88
|
created_at: nil,
|
87
89
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
90
|
+
# Preferences that are set inline will be merged into any existing preferences
|
91
|
+
# rather than replacing them.
|
88
92
|
preferences: nil
|
89
93
|
)
|
90
94
|
end
|
@@ -53,6 +53,8 @@ module Knockapi
|
|
53
53
|
attr_accessor :locale
|
54
54
|
|
55
55
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
56
|
+
# Preferences that are set inline will be merged into any existing preferences
|
57
|
+
# rather than replacing them.
|
56
58
|
sig do
|
57
59
|
returns(
|
58
60
|
T.nilable(T::Hash[Symbol, Knockapi::Recipients::PreferenceSetRequest])
|
@@ -102,6 +104,8 @@ module Knockapi
|
|
102
104
|
# [message localization](/concepts/translations).
|
103
105
|
locale: nil,
|
104
106
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
107
|
+
# Preferences that are set inline will be merged into any existing preferences
|
108
|
+
# rather than replacing them.
|
105
109
|
preferences: nil,
|
106
110
|
# The timezone of the object. Must be a
|
107
111
|
# valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
|
@@ -77,6 +77,8 @@ module Knockapi
|
|
77
77
|
attr_accessor :created_at
|
78
78
|
|
79
79
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
80
|
+
# Preferences that are set inline will be merged into any existing preferences
|
81
|
+
# rather than replacing them.
|
80
82
|
sig do
|
81
83
|
returns(
|
82
84
|
T.nilable(
|
@@ -121,6 +123,8 @@ module Knockapi
|
|
121
123
|
# Timestamp when the resource was created.
|
122
124
|
created_at: nil,
|
123
125
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
126
|
+
# Preferences that are set inline will be merged into any existing preferences
|
127
|
+
# rather than replacing them.
|
124
128
|
preferences: nil
|
125
129
|
)
|
126
130
|
end
|
@@ -32,6 +32,8 @@ module Knockapi
|
|
32
32
|
attr_accessor :channel_data
|
33
33
|
|
34
34
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
35
|
+
# Preferences that are set inline will be merged into any existing preferences
|
36
|
+
# rather than replacing them.
|
35
37
|
sig do
|
36
38
|
returns(
|
37
39
|
T.nilable(T::Hash[Symbol, Knockapi::Recipients::PreferenceSetRequest])
|
@@ -80,6 +82,8 @@ module Knockapi
|
|
80
82
|
# A request to set channel data for a type of channel inline.
|
81
83
|
channel_data: nil,
|
82
84
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
85
|
+
# Preferences that are set inline will be merged into any existing preferences
|
86
|
+
# rather than replacing them.
|
83
87
|
preferences: nil,
|
84
88
|
# The settings for the tenant. Includes branding and preference set.
|
85
89
|
settings: nil
|
@@ -378,6 +378,8 @@ module Knockapi
|
|
378
378
|
# [message localization](/concepts/translations).
|
379
379
|
locale: nil,
|
380
380
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
381
|
+
# Preferences that are set inline will be merged into any existing preferences
|
382
|
+
# rather than replacing them.
|
381
383
|
preferences: nil,
|
382
384
|
# The timezone of the object. Must be a
|
383
385
|
# valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
|
@@ -4,8 +4,7 @@ module Knockapi
|
|
4
4
|
module Resources
|
5
5
|
class Users
|
6
6
|
class Bulk
|
7
|
-
#
|
8
|
-
# delete and returns a bulk operation that can be queried for progress.
|
7
|
+
# Permanently deletes up to 1,000 users at a time.
|
9
8
|
sig do
|
10
9
|
params(
|
11
10
|
user_ids: T::Array[String],
|
@@ -20,8 +19,8 @@ module Knockapi
|
|
20
19
|
end
|
21
20
|
|
22
21
|
# Identifies multiple users in a single operation. Allows creating or updating up
|
23
|
-
# to
|
24
|
-
# data.
|
22
|
+
# to 1,000 users in a single batch with various properties, preferences, and
|
23
|
+
# channel data.
|
25
24
|
sig do
|
26
25
|
params(
|
27
26
|
users: T::Array[Knockapi::InlineIdentifyUserRequest::OrHash],
|
@@ -35,9 +34,11 @@ module Knockapi
|
|
35
34
|
)
|
36
35
|
end
|
37
36
|
|
38
|
-
#
|
39
|
-
#
|
40
|
-
#
|
37
|
+
# Bulk sets the preferences for up to 1,000 users at a time. The preference
|
38
|
+
# set `:id` can be either `default` or a `tenant.id`. Learn more
|
39
|
+
# about [per-tenant preferences](/preferences/tenant-preferences). Note that this
|
40
|
+
# is a destructive operation and will replace any existing users' preferences with
|
41
|
+
# the preferences sent.
|
41
42
|
sig do
|
42
43
|
params(
|
43
44
|
preferences: Knockapi::Recipients::PreferenceSetRequest::OrHash,
|
@@ -67,6 +67,8 @@ module Knockapi
|
|
67
67
|
# user (required for SMS channels).
|
68
68
|
phone_number: nil,
|
69
69
|
# Inline set preferences for a recipient, where the key is the preference set id.
|
70
|
+
# Preferences that are set inline will be merged into any existing preferences
|
71
|
+
# rather than replacing them.
|
70
72
|
preferences: nil,
|
71
73
|
# The timezone of the user. Must be a
|
72
74
|
# valid [tz database time zone string](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: knockapi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.7.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Knock
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-06-
|
11
|
+
date: 2025-06-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: connection_pool
|