trycourier 5.0.0 → 6.0.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 +11 -0
- data/README.md +1 -1
- data/lib/courier/internal/type/union.rb +7 -7
- data/lib/courier/models/apn.rb +19 -0
- data/lib/courier/models/expo.rb +1 -0
- data/lib/courier/models/multiple_tokens.rb +26 -3
- data/lib/courier/models/user_profile.rb +8 -4
- data/lib/courier/models.rb +2 -2
- data/lib/courier/resources/notifications.rb +0 -22
- data/lib/courier/version.rb +1 -1
- data/lib/courier.rb +1 -1
- data/rbi/courier/models/apn.rbi +18 -0
- data/rbi/courier/models/expo.rbi +1 -0
- data/rbi/courier/models/multiple_tokens.rbi +32 -4
- data/rbi/courier/models/user_profile.rbi +14 -3
- data/rbi/courier/models.rbi +2 -2
- data/rbi/courier/resources/notifications.rbi +0 -16
- data/sig/courier/models/apn.rbs +11 -0
- data/sig/courier/models/multiple_tokens.rbs +14 -4
- data/sig/courier/models/user_profile.rbs +4 -4
- data/sig/courier/models.rbs +2 -2
- data/sig/courier/resources/notifications.rbs +0 -5
- metadata +5 -5
- data/lib/courier/models/notification_duplicate_params.rb +0 -20
- data/rbi/courier/models/notification_duplicate_params.rbi +0 -38
- data/sig/courier/models/notification_duplicate_params.rbs +0 -20
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: ed641b11a038a01c22274260fc705dea6b9b111be8cd53b64e422aff9406454f
|
|
4
|
+
data.tar.gz: bcf80f73aa74a8fa95b82c7d2aea347fc8119acc264a9f09f1674a0da6abed60
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1750e07548991a86cb4ad3dcac19af5079dc36802b7564619bb2658b4257752427bd8108c4649f469330278bc6115124174a3f177236fc4b68286257d5ee6bb0
|
|
7
|
+
data.tar.gz: ffd4fccb77fbc287d6b1959741ea4e9472e951d1da0736de3ad5182dc7a90d8f310128e7d9e1ae77959c8978089997c6a2a4e91daade9126094029ce9f4146fe
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [6.0.0](https://github.com/trycourier/courier-ruby/compare/v5.0.0...v6.0.0) (2026-08-17)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### ⚠ BREAKING CHANGES
|
|
7
|
+
|
|
8
|
+
* **api:** match the spec to the backend — apn/expo token types and the phantom notifications.duplicate ([#128](https://github.com/trycourier/courier-ruby/issues/128))
|
|
9
|
+
|
|
10
|
+
### Features
|
|
11
|
+
|
|
12
|
+
* **api:** match the spec to the backend — apn/expo token types and the phantom notifications.duplicate ([#128](https://github.com/trycourier/courier-ruby/issues/128)) ([5034ea3](https://github.com/trycourier/courier-ruby/commit/5034ea33f5242443ce08ef9005d3d02e9f471531))
|
|
13
|
+
|
|
3
14
|
## [5.0.0](https://github.com/trycourier/courier-ruby/compare/v4.26.2...v5.0.0) (2026-08-17)
|
|
4
15
|
|
|
5
16
|
|
data/README.md
CHANGED
|
@@ -6,14 +6,14 @@ module Courier
|
|
|
6
6
|
# @api private
|
|
7
7
|
#
|
|
8
8
|
# @example
|
|
9
|
-
# # `
|
|
10
|
-
# case
|
|
11
|
-
# when Courier::
|
|
12
|
-
# puts(
|
|
13
|
-
# when Courier::
|
|
14
|
-
# puts(
|
|
9
|
+
# # `apn` is a `Courier::Apn`
|
|
10
|
+
# case apn
|
|
11
|
+
# when Courier::Token
|
|
12
|
+
# puts(apn.token)
|
|
13
|
+
# when Courier::MultipleTokens
|
|
14
|
+
# puts(apn.tokens)
|
|
15
15
|
# else
|
|
16
|
-
# puts(
|
|
16
|
+
# puts(apn)
|
|
17
17
|
# end
|
|
18
18
|
module Union
|
|
19
19
|
include Courier::Internal::Type::Converter
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
# Apple Push Notification device tokens. Supply either a single `token` or a
|
|
6
|
+
# `tokens` value. A bare string is rejected by the provider — the token must be
|
|
7
|
+
# wrapped in this object.
|
|
8
|
+
module Apn
|
|
9
|
+
extend Courier::Internal::Type::Union
|
|
10
|
+
|
|
11
|
+
variant -> { Courier::Token }
|
|
12
|
+
|
|
13
|
+
variant -> { Courier::MultipleTokens }
|
|
14
|
+
|
|
15
|
+
# @!method self.variants
|
|
16
|
+
# @return [Array(Courier::Models::Token, Courier::Models::MultipleTokens)]
|
|
17
|
+
end
|
|
18
|
+
end
|
|
19
|
+
end
|
data/lib/courier/models/expo.rb
CHANGED
|
@@ -4,12 +4,35 @@ module Courier
|
|
|
4
4
|
module Models
|
|
5
5
|
class MultipleTokens < Courier::Internal::Type::BaseModel
|
|
6
6
|
# @!attribute tokens
|
|
7
|
+
# One device token, or an array of them. The values are the token strings
|
|
8
|
+
# themselves — not objects.
|
|
7
9
|
#
|
|
8
|
-
# @return [Array<
|
|
9
|
-
required :tokens, -> { Courier::
|
|
10
|
+
# @return [String, Array<String>]
|
|
11
|
+
required :tokens, union: -> { Courier::MultipleTokens::Tokens }
|
|
10
12
|
|
|
11
13
|
# @!method initialize(tokens:)
|
|
12
|
-
#
|
|
14
|
+
# Some parameter documentations has been truncated, see
|
|
15
|
+
# {Courier::Models::MultipleTokens} for more details.
|
|
16
|
+
#
|
|
17
|
+
# @param tokens [String, Array<String>] One device token, or an array of them. The values are the token strings themselv
|
|
18
|
+
|
|
19
|
+
# One device token, or an array of them. The values are the token strings
|
|
20
|
+
# themselves — not objects.
|
|
21
|
+
#
|
|
22
|
+
# @see Courier::Models::MultipleTokens#tokens
|
|
23
|
+
module Tokens
|
|
24
|
+
extend Courier::Internal::Type::Union
|
|
25
|
+
|
|
26
|
+
variant String
|
|
27
|
+
|
|
28
|
+
variant -> { Courier::Models::MultipleTokens::Tokens::StringArray }
|
|
29
|
+
|
|
30
|
+
# @!method self.variants
|
|
31
|
+
# @return [Array(String, Array<String>)]
|
|
32
|
+
|
|
33
|
+
# @type [Courier::Internal::Type::Converter]
|
|
34
|
+
StringArray = Courier::Internal::Type::ArrayOf[String]
|
|
35
|
+
end
|
|
13
36
|
end
|
|
14
37
|
end
|
|
15
38
|
end
|
|
@@ -14,9 +14,12 @@ module Courier
|
|
|
14
14
|
optional :airship, -> { Courier::AirshipProfile }, nil?: true
|
|
15
15
|
|
|
16
16
|
# @!attribute apn
|
|
17
|
+
# Apple Push Notification device tokens. Supply either a single `token` or a
|
|
18
|
+
# `tokens` value. A bare string is rejected by the provider — the token must be
|
|
19
|
+
# wrapped in this object.
|
|
17
20
|
#
|
|
18
|
-
# @return [
|
|
19
|
-
optional :apn,
|
|
21
|
+
# @return [Courier::Models::Token, Courier::Models::MultipleTokens, nil]
|
|
22
|
+
optional :apn, union: -> { Courier::Apn }, nil?: true
|
|
20
23
|
|
|
21
24
|
# @!attribute aws_sns
|
|
22
25
|
# Routes a push notification through the AWS SNS provider. The target ARN must be
|
|
@@ -54,6 +57,7 @@ module Courier
|
|
|
54
57
|
optional :email_verified, Courier::Internal::Type::Boolean, nil?: true
|
|
55
58
|
|
|
56
59
|
# @!attribute expo
|
|
60
|
+
# Expo push tokens. Supply either a single `token` or a `tokens` value.
|
|
57
61
|
#
|
|
58
62
|
# @return [Courier::Models::Token, Courier::Models::MultipleTokens, nil]
|
|
59
63
|
optional :expo, union: -> { Courier::Expo }, nil?: true
|
|
@@ -174,7 +178,7 @@ module Courier
|
|
|
174
178
|
#
|
|
175
179
|
# @param airship [Courier::Models::AirshipProfile, nil]
|
|
176
180
|
#
|
|
177
|
-
# @param apn [
|
|
181
|
+
# @param apn [Courier::Models::Token, Courier::Models::MultipleTokens, nil] Apple Push Notification device tokens. Supply either a single `token` or a `toke
|
|
178
182
|
#
|
|
179
183
|
# @param aws_sns [Courier::Models::AwsSns, nil] Routes a push notification through the AWS SNS provider. The target ARN must be
|
|
180
184
|
#
|
|
@@ -188,7 +192,7 @@ module Courier
|
|
|
188
192
|
#
|
|
189
193
|
# @param email_verified [Boolean, nil]
|
|
190
194
|
#
|
|
191
|
-
# @param expo [Courier::Models::Token, Courier::Models::MultipleTokens, nil]
|
|
195
|
+
# @param expo [Courier::Models::Token, Courier::Models::MultipleTokens, nil] Expo push tokens. Supply either a single `token` or a `tokens` value.
|
|
192
196
|
#
|
|
193
197
|
# @param facebook_psid [String, nil]
|
|
194
198
|
#
|
data/lib/courier/models.rb
CHANGED
|
@@ -45,6 +45,8 @@ module Courier
|
|
|
45
45
|
|
|
46
46
|
Alignment = Courier::Models::Alignment
|
|
47
47
|
|
|
48
|
+
Apn = Courier::Models::Apn
|
|
49
|
+
|
|
48
50
|
AssociatedNotificationListResponse = Courier::Models::AssociatedNotificationListResponse
|
|
49
51
|
|
|
50
52
|
Audience = Courier::Models::Audience
|
|
@@ -392,8 +394,6 @@ module Courier
|
|
|
392
394
|
|
|
393
395
|
NotificationCreateParams = Courier::Models::NotificationCreateParams
|
|
394
396
|
|
|
395
|
-
NotificationDuplicateParams = Courier::Models::NotificationDuplicateParams
|
|
396
|
-
|
|
397
397
|
NotificationElementPutRequest = Courier::Models::NotificationElementPutRequest
|
|
398
398
|
|
|
399
399
|
NotificationGetContent = Courier::Models::NotificationGetContent
|
|
@@ -123,28 +123,6 @@ module Courier
|
|
|
123
123
|
)
|
|
124
124
|
end
|
|
125
125
|
|
|
126
|
-
# Copies a notification template within the same workspace and environment,
|
|
127
|
-
# appending " COPY" to the title. The copy is standalone and independently
|
|
128
|
-
# editable.
|
|
129
|
-
#
|
|
130
|
-
# @overload duplicate(id, request_options: {})
|
|
131
|
-
#
|
|
132
|
-
# @param id [String] Template ID (nt\_ prefix).
|
|
133
|
-
#
|
|
134
|
-
# @param request_options [Courier::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
135
|
-
#
|
|
136
|
-
# @return [Courier::Models::NotificationTemplateResponse]
|
|
137
|
-
#
|
|
138
|
-
# @see Courier::Models::NotificationDuplicateParams
|
|
139
|
-
def duplicate(id, params = {})
|
|
140
|
-
@client.request(
|
|
141
|
-
method: :post,
|
|
142
|
-
path: ["notifications/%1$s/duplicate", id],
|
|
143
|
-
model: Courier::NotificationTemplateResponse,
|
|
144
|
-
options: params[:request_options]
|
|
145
|
-
)
|
|
146
|
-
end
|
|
147
|
-
|
|
148
126
|
# Returns a notification template's published versions, most recent first, for
|
|
149
127
|
# comparison or rollback. Paged.
|
|
150
128
|
#
|
data/lib/courier/version.rb
CHANGED
data/lib/courier.rb
CHANGED
|
@@ -91,6 +91,7 @@ require_relative "courier/models/workspace_preference_topic_replace_request"
|
|
|
91
91
|
require_relative "courier/models/airship_profile"
|
|
92
92
|
require_relative "courier/models/airship_profile_audience"
|
|
93
93
|
require_relative "courier/models/alignment"
|
|
94
|
+
require_relative "courier/models/apn"
|
|
94
95
|
require_relative "courier/models/associated_notification_list_response"
|
|
95
96
|
require_relative "courier/models/audience"
|
|
96
97
|
require_relative "courier/models/audience_delete_params"
|
|
@@ -279,7 +280,6 @@ require_relative "courier/models/notification_archive_params"
|
|
|
279
280
|
require_relative "courier/models/notification_content_get_response"
|
|
280
281
|
require_relative "courier/models/notification_content_mutation_response"
|
|
281
282
|
require_relative "courier/models/notification_create_params"
|
|
282
|
-
require_relative "courier/models/notification_duplicate_params"
|
|
283
283
|
require_relative "courier/models/notification_get_content"
|
|
284
284
|
require_relative "courier/models/notification_list_params"
|
|
285
285
|
require_relative "courier/models/notification_list_response"
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# typed: strong
|
|
2
|
+
|
|
3
|
+
module Courier
|
|
4
|
+
module Models
|
|
5
|
+
# Apple Push Notification device tokens. Supply either a single `token` or a
|
|
6
|
+
# `tokens` value. A bare string is rejected by the provider — the token must be
|
|
7
|
+
# wrapped in this object.
|
|
8
|
+
module Apn
|
|
9
|
+
extend Courier::Internal::Type::Union
|
|
10
|
+
|
|
11
|
+
Variants = T.type_alias { T.any(Courier::Token, Courier::MultipleTokens) }
|
|
12
|
+
|
|
13
|
+
sig { override.returns(T::Array[Courier::Apn::Variants]) }
|
|
14
|
+
def self.variants
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
data/rbi/courier/models/expo.rbi
CHANGED
|
@@ -8,20 +8,48 @@ module Courier
|
|
|
8
8
|
T.any(Courier::MultipleTokens, Courier::Internal::AnyHash)
|
|
9
9
|
end
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
# One device token, or an array of them. The values are the token strings
|
|
12
|
+
# themselves — not objects.
|
|
13
|
+
sig { returns(Courier::MultipleTokens::Tokens::Variants) }
|
|
12
14
|
attr_accessor :tokens
|
|
13
15
|
|
|
14
16
|
sig do
|
|
15
|
-
params(tokens:
|
|
17
|
+
params(tokens: Courier::MultipleTokens::Tokens::Variants).returns(
|
|
16
18
|
T.attached_class
|
|
17
19
|
)
|
|
18
20
|
end
|
|
19
|
-
def self.new(
|
|
21
|
+
def self.new(
|
|
22
|
+
# One device token, or an array of them. The values are the token strings
|
|
23
|
+
# themselves — not objects.
|
|
24
|
+
tokens:
|
|
25
|
+
)
|
|
20
26
|
end
|
|
21
27
|
|
|
22
|
-
sig
|
|
28
|
+
sig do
|
|
29
|
+
override.returns({ tokens: Courier::MultipleTokens::Tokens::Variants })
|
|
30
|
+
end
|
|
23
31
|
def to_hash
|
|
24
32
|
end
|
|
33
|
+
|
|
34
|
+
# One device token, or an array of them. The values are the token strings
|
|
35
|
+
# themselves — not objects.
|
|
36
|
+
module Tokens
|
|
37
|
+
extend Courier::Internal::Type::Union
|
|
38
|
+
|
|
39
|
+
Variants = T.type_alias { T.any(String, T::Array[String]) }
|
|
40
|
+
|
|
41
|
+
sig do
|
|
42
|
+
override.returns(T::Array[Courier::MultipleTokens::Tokens::Variants])
|
|
43
|
+
end
|
|
44
|
+
def self.variants
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
StringArray =
|
|
48
|
+
T.let(
|
|
49
|
+
Courier::Internal::Type::ArrayOf[String],
|
|
50
|
+
Courier::Internal::Type::Converter
|
|
51
|
+
)
|
|
52
|
+
end
|
|
25
53
|
end
|
|
26
54
|
end
|
|
27
55
|
end
|
|
@@ -20,7 +20,10 @@ module Courier
|
|
|
20
20
|
sig { params(airship: T.nilable(Courier::AirshipProfile::OrHash)).void }
|
|
21
21
|
attr_writer :airship
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
# Apple Push Notification device tokens. Supply either a single `token` or a
|
|
24
|
+
# `tokens` value. A bare string is rejected by the provider — the token must be
|
|
25
|
+
# wrapped in this object.
|
|
26
|
+
sig { returns(T.nilable(T.any(Courier::Token, Courier::MultipleTokens))) }
|
|
24
27
|
attr_accessor :apn
|
|
25
28
|
|
|
26
29
|
# Routes a push notification through the AWS SNS provider. The target ARN must be
|
|
@@ -53,6 +56,7 @@ module Courier
|
|
|
53
56
|
sig { returns(T.nilable(T::Boolean)) }
|
|
54
57
|
attr_accessor :email_verified
|
|
55
58
|
|
|
59
|
+
# Expo push tokens. Supply either a single `token` or a `tokens` value.
|
|
56
60
|
sig { returns(T.nilable(T.any(Courier::Token, Courier::MultipleTokens))) }
|
|
57
61
|
attr_accessor :expo
|
|
58
62
|
|
|
@@ -148,7 +152,10 @@ module Courier
|
|
|
148
152
|
params(
|
|
149
153
|
address: T.nilable(Courier::UserProfile::Address::OrHash),
|
|
150
154
|
airship: T.nilable(Courier::AirshipProfile::OrHash),
|
|
151
|
-
apn:
|
|
155
|
+
apn:
|
|
156
|
+
T.nilable(
|
|
157
|
+
T.any(Courier::Token::OrHash, Courier::MultipleTokens::OrHash)
|
|
158
|
+
),
|
|
152
159
|
aws_sns: T.nilable(Courier::AwsSns::OrHash),
|
|
153
160
|
birthdate: T.nilable(String),
|
|
154
161
|
custom: T.nilable(T::Hash[Symbol, T.anything]),
|
|
@@ -208,6 +215,9 @@ module Courier
|
|
|
208
215
|
def self.new(
|
|
209
216
|
address: nil,
|
|
210
217
|
airship: nil,
|
|
218
|
+
# Apple Push Notification device tokens. Supply either a single `token` or a
|
|
219
|
+
# `tokens` value. A bare string is rejected by the provider — the token must be
|
|
220
|
+
# wrapped in this object.
|
|
211
221
|
apn: nil,
|
|
212
222
|
# Routes a push notification through the AWS SNS provider. The target ARN must be
|
|
213
223
|
# nested under `aws_sns` — a top-level `target_arn` on the profile is ignored by
|
|
@@ -220,6 +230,7 @@ module Courier
|
|
|
220
230
|
discord: nil,
|
|
221
231
|
email: nil,
|
|
222
232
|
email_verified: nil,
|
|
233
|
+
# Expo push tokens. Supply either a single `token` or a `tokens` value.
|
|
223
234
|
expo: nil,
|
|
224
235
|
facebook_psid: nil,
|
|
225
236
|
family_name: nil,
|
|
@@ -250,7 +261,7 @@ module Courier
|
|
|
250
261
|
{
|
|
251
262
|
address: T.nilable(Courier::UserProfile::Address),
|
|
252
263
|
airship: T.nilable(Courier::AirshipProfile),
|
|
253
|
-
apn: T.nilable(
|
|
264
|
+
apn: T.nilable(T.any(Courier::Token, Courier::MultipleTokens)),
|
|
254
265
|
aws_sns: T.nilable(Courier::AwsSns),
|
|
255
266
|
birthdate: T.nilable(String),
|
|
256
267
|
custom: T.nilable(T::Hash[Symbol, T.anything]),
|
data/rbi/courier/models.rbi
CHANGED
|
@@ -7,6 +7,8 @@ module Courier
|
|
|
7
7
|
|
|
8
8
|
Alignment = Courier::Models::Alignment
|
|
9
9
|
|
|
10
|
+
Apn = Courier::Models::Apn
|
|
11
|
+
|
|
10
12
|
AssociatedNotificationListResponse =
|
|
11
13
|
Courier::Models::AssociatedNotificationListResponse
|
|
12
14
|
|
|
@@ -362,8 +364,6 @@ module Courier
|
|
|
362
364
|
|
|
363
365
|
NotificationCreateParams = Courier::Models::NotificationCreateParams
|
|
364
366
|
|
|
365
|
-
NotificationDuplicateParams = Courier::Models::NotificationDuplicateParams
|
|
366
|
-
|
|
367
367
|
NotificationElementPutRequest = Courier::Models::NotificationElementPutRequest
|
|
368
368
|
|
|
369
369
|
NotificationGetContent = Courier::Models::NotificationGetContent
|
|
@@ -99,22 +99,6 @@ module Courier
|
|
|
99
99
|
)
|
|
100
100
|
end
|
|
101
101
|
|
|
102
|
-
# Copies a notification template within the same workspace and environment,
|
|
103
|
-
# appending " COPY" to the title. The copy is standalone and independently
|
|
104
|
-
# editable.
|
|
105
|
-
sig do
|
|
106
|
-
params(
|
|
107
|
-
id: String,
|
|
108
|
-
request_options: Courier::RequestOptions::OrHash
|
|
109
|
-
).returns(Courier::NotificationTemplateResponse)
|
|
110
|
-
end
|
|
111
|
-
def duplicate(
|
|
112
|
-
# Template ID (nt\_ prefix).
|
|
113
|
-
id,
|
|
114
|
-
request_options: {}
|
|
115
|
-
)
|
|
116
|
-
end
|
|
117
|
-
|
|
118
102
|
# Returns a notification template's published versions, most recent first, for
|
|
119
103
|
# comparison or rollback. Paged.
|
|
120
104
|
sig do
|
|
@@ -1,13 +1,23 @@
|
|
|
1
1
|
module Courier
|
|
2
2
|
module Models
|
|
3
|
-
type multiple_tokens = { tokens:
|
|
3
|
+
type multiple_tokens = { tokens: Courier::Models::MultipleTokens::tokens }
|
|
4
4
|
|
|
5
5
|
class MultipleTokens < Courier::Internal::Type::BaseModel
|
|
6
|
-
attr_accessor tokens:
|
|
6
|
+
attr_accessor tokens: Courier::Models::MultipleTokens::tokens
|
|
7
7
|
|
|
8
|
-
def initialize: (tokens:
|
|
8
|
+
def initialize: (tokens: Courier::Models::MultipleTokens::tokens) -> void
|
|
9
9
|
|
|
10
|
-
def to_hash: -> { tokens:
|
|
10
|
+
def to_hash: -> { tokens: Courier::Models::MultipleTokens::tokens }
|
|
11
|
+
|
|
12
|
+
type tokens = String | ::Array[String]
|
|
13
|
+
|
|
14
|
+
module Tokens
|
|
15
|
+
extend Courier::Internal::Type::Union
|
|
16
|
+
|
|
17
|
+
def self?.variants: -> ::Array[Courier::Models::MultipleTokens::tokens]
|
|
18
|
+
|
|
19
|
+
StringArray: Courier::Internal::Type::Converter
|
|
20
|
+
end
|
|
11
21
|
end
|
|
12
22
|
end
|
|
13
23
|
end
|
|
@@ -4,7 +4,7 @@ module Courier
|
|
|
4
4
|
{
|
|
5
5
|
address: Courier::UserProfile::Address?,
|
|
6
6
|
airship: Courier::AirshipProfile?,
|
|
7
|
-
apn:
|
|
7
|
+
apn: Courier::Models::apn?,
|
|
8
8
|
aws_sns: Courier::AwsSns?,
|
|
9
9
|
birthdate: String?,
|
|
10
10
|
custom: ::Hash[Symbol, top]?,
|
|
@@ -40,7 +40,7 @@ module Courier
|
|
|
40
40
|
|
|
41
41
|
attr_accessor airship: Courier::AirshipProfile?
|
|
42
42
|
|
|
43
|
-
attr_accessor apn:
|
|
43
|
+
attr_accessor apn: Courier::Models::apn?
|
|
44
44
|
|
|
45
45
|
attr_accessor aws_sns: Courier::AwsSns?
|
|
46
46
|
|
|
@@ -101,7 +101,7 @@ module Courier
|
|
|
101
101
|
def initialize: (
|
|
102
102
|
?address: Courier::UserProfile::Address?,
|
|
103
103
|
?airship: Courier::AirshipProfile?,
|
|
104
|
-
?apn:
|
|
104
|
+
?apn: Courier::Models::apn?,
|
|
105
105
|
?aws_sns: Courier::AwsSns?,
|
|
106
106
|
?birthdate: String?,
|
|
107
107
|
?custom: ::Hash[Symbol, top]?,
|
|
@@ -135,7 +135,7 @@ module Courier
|
|
|
135
135
|
def to_hash: -> {
|
|
136
136
|
address: Courier::UserProfile::Address?,
|
|
137
137
|
airship: Courier::AirshipProfile?,
|
|
138
|
-
apn:
|
|
138
|
+
apn: Courier::Models::apn?,
|
|
139
139
|
aws_sns: Courier::AwsSns?,
|
|
140
140
|
birthdate: String?,
|
|
141
141
|
custom: ::Hash[Symbol, top]?,
|
data/sig/courier/models.rbs
CHANGED
|
@@ -5,6 +5,8 @@ module Courier
|
|
|
5
5
|
|
|
6
6
|
module Alignment = Courier::Models::Alignment
|
|
7
7
|
|
|
8
|
+
module Apn = Courier::Models::Apn
|
|
9
|
+
|
|
8
10
|
class AssociatedNotificationListResponse = Courier::Models::AssociatedNotificationListResponse
|
|
9
11
|
|
|
10
12
|
class Audience = Courier::Models::Audience
|
|
@@ -349,8 +351,6 @@ module Courier
|
|
|
349
351
|
|
|
350
352
|
class NotificationCreateParams = Courier::Models::NotificationCreateParams
|
|
351
353
|
|
|
352
|
-
class NotificationDuplicateParams = Courier::Models::NotificationDuplicateParams
|
|
353
|
-
|
|
354
354
|
class NotificationElementPutRequest = Courier::Models::NotificationElementPutRequest
|
|
355
355
|
|
|
356
356
|
class NotificationGetContent = Courier::Models::NotificationGetContent
|
|
@@ -26,11 +26,6 @@ module Courier
|
|
|
26
26
|
|
|
27
27
|
def archive: (String id, ?request_options: Courier::request_opts) -> nil
|
|
28
28
|
|
|
29
|
-
def duplicate: (
|
|
30
|
-
String id,
|
|
31
|
-
?request_options: Courier::request_opts
|
|
32
|
-
) -> Courier::NotificationTemplateResponse
|
|
33
|
-
|
|
34
29
|
def list_versions: (
|
|
35
30
|
String id,
|
|
36
31
|
?cursor: String,
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: trycourier
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 6.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Courier
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-08-
|
|
11
|
+
date: 2026-08-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: cgi
|
|
@@ -72,6 +72,7 @@ files:
|
|
|
72
72
|
- lib/courier/models/airship_profile.rb
|
|
73
73
|
- lib/courier/models/airship_profile_audience.rb
|
|
74
74
|
- lib/courier/models/alignment.rb
|
|
75
|
+
- lib/courier/models/apn.rb
|
|
75
76
|
- lib/courier/models/associated_notification_list_response.rb
|
|
76
77
|
- lib/courier/models/audience.rb
|
|
77
78
|
- lib/courier/models/audience_delete_params.rb
|
|
@@ -276,7 +277,6 @@ files:
|
|
|
276
277
|
- lib/courier/models/notification_content_mutation_response.rb
|
|
277
278
|
- lib/courier/models/notification_content_put_request.rb
|
|
278
279
|
- lib/courier/models/notification_create_params.rb
|
|
279
|
-
- lib/courier/models/notification_duplicate_params.rb
|
|
280
280
|
- lib/courier/models/notification_element_put_request.rb
|
|
281
281
|
- lib/courier/models/notification_get_content.rb
|
|
282
282
|
- lib/courier/models/notification_list_params.rb
|
|
@@ -524,6 +524,7 @@ files:
|
|
|
524
524
|
- rbi/courier/models/airship_profile.rbi
|
|
525
525
|
- rbi/courier/models/airship_profile_audience.rbi
|
|
526
526
|
- rbi/courier/models/alignment.rbi
|
|
527
|
+
- rbi/courier/models/apn.rbi
|
|
527
528
|
- rbi/courier/models/associated_notification_list_response.rbi
|
|
528
529
|
- rbi/courier/models/audience.rbi
|
|
529
530
|
- rbi/courier/models/audience_delete_params.rbi
|
|
@@ -728,7 +729,6 @@ files:
|
|
|
728
729
|
- rbi/courier/models/notification_content_mutation_response.rbi
|
|
729
730
|
- rbi/courier/models/notification_content_put_request.rbi
|
|
730
731
|
- rbi/courier/models/notification_create_params.rbi
|
|
731
|
-
- rbi/courier/models/notification_duplicate_params.rbi
|
|
732
732
|
- rbi/courier/models/notification_element_put_request.rbi
|
|
733
733
|
- rbi/courier/models/notification_get_content.rbi
|
|
734
734
|
- rbi/courier/models/notification_list_params.rbi
|
|
@@ -975,6 +975,7 @@ files:
|
|
|
975
975
|
- sig/courier/models/airship_profile.rbs
|
|
976
976
|
- sig/courier/models/airship_profile_audience.rbs
|
|
977
977
|
- sig/courier/models/alignment.rbs
|
|
978
|
+
- sig/courier/models/apn.rbs
|
|
978
979
|
- sig/courier/models/associated_notification_list_response.rbs
|
|
979
980
|
- sig/courier/models/audience.rbs
|
|
980
981
|
- sig/courier/models/audience_delete_params.rbs
|
|
@@ -1179,7 +1180,6 @@ files:
|
|
|
1179
1180
|
- sig/courier/models/notification_content_mutation_response.rbs
|
|
1180
1181
|
- sig/courier/models/notification_content_put_request.rbs
|
|
1181
1182
|
- sig/courier/models/notification_create_params.rbs
|
|
1182
|
-
- sig/courier/models/notification_duplicate_params.rbs
|
|
1183
1183
|
- sig/courier/models/notification_element_put_request.rbs
|
|
1184
1184
|
- sig/courier/models/notification_get_content.rbs
|
|
1185
1185
|
- sig/courier/models/notification_list_params.rbs
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
module Courier
|
|
4
|
-
module Models
|
|
5
|
-
# @see Courier::Resources::Notifications#duplicate
|
|
6
|
-
class NotificationDuplicateParams < Courier::Internal::Type::BaseModel
|
|
7
|
-
extend Courier::Internal::Type::RequestParameters::Converter
|
|
8
|
-
include Courier::Internal::Type::RequestParameters
|
|
9
|
-
|
|
10
|
-
# @!attribute id
|
|
11
|
-
#
|
|
12
|
-
# @return [String]
|
|
13
|
-
required :id, String
|
|
14
|
-
|
|
15
|
-
# @!method initialize(id:, request_options: {})
|
|
16
|
-
# @param id [String]
|
|
17
|
-
# @param request_options [Courier::RequestOptions, Hash{Symbol=>Object}]
|
|
18
|
-
end
|
|
19
|
-
end
|
|
20
|
-
end
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
# typed: strong
|
|
2
|
-
|
|
3
|
-
module Courier
|
|
4
|
-
module Models
|
|
5
|
-
class NotificationDuplicateParams < Courier::Internal::Type::BaseModel
|
|
6
|
-
extend Courier::Internal::Type::RequestParameters::Converter
|
|
7
|
-
include Courier::Internal::Type::RequestParameters
|
|
8
|
-
|
|
9
|
-
OrHash =
|
|
10
|
-
T.type_alias do
|
|
11
|
-
T.any(
|
|
12
|
-
Courier::NotificationDuplicateParams,
|
|
13
|
-
Courier::Internal::AnyHash
|
|
14
|
-
)
|
|
15
|
-
end
|
|
16
|
-
|
|
17
|
-
sig { returns(String) }
|
|
18
|
-
attr_accessor :id
|
|
19
|
-
|
|
20
|
-
sig do
|
|
21
|
-
params(
|
|
22
|
-
id: String,
|
|
23
|
-
request_options: Courier::RequestOptions::OrHash
|
|
24
|
-
).returns(T.attached_class)
|
|
25
|
-
end
|
|
26
|
-
def self.new(id:, request_options: {})
|
|
27
|
-
end
|
|
28
|
-
|
|
29
|
-
sig do
|
|
30
|
-
override.returns(
|
|
31
|
-
{ id: String, request_options: Courier::RequestOptions }
|
|
32
|
-
)
|
|
33
|
-
end
|
|
34
|
-
def to_hash
|
|
35
|
-
end
|
|
36
|
-
end
|
|
37
|
-
end
|
|
38
|
-
end
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
module Courier
|
|
2
|
-
module Models
|
|
3
|
-
type notification_duplicate_params =
|
|
4
|
-
{ id: String } & Courier::Internal::Type::request_parameters
|
|
5
|
-
|
|
6
|
-
class NotificationDuplicateParams < Courier::Internal::Type::BaseModel
|
|
7
|
-
extend Courier::Internal::Type::RequestParameters::Converter
|
|
8
|
-
include Courier::Internal::Type::RequestParameters
|
|
9
|
-
|
|
10
|
-
attr_accessor id: String
|
|
11
|
-
|
|
12
|
-
def initialize: (
|
|
13
|
-
id: String,
|
|
14
|
-
?request_options: Courier::request_opts
|
|
15
|
-
) -> void
|
|
16
|
-
|
|
17
|
-
def to_hash: -> { id: String, request_options: Courier::RequestOptions }
|
|
18
|
-
end
|
|
19
|
-
end
|
|
20
|
-
end
|