trycourier 4.4.0 → 4.5.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/trycourier/internal/transport/pooled_net_requester.rb +12 -10
- data/lib/trycourier/internal/type/base_model.rb +4 -3
- data/lib/trycourier/internal/type/union.rb +7 -9
- data/lib/trycourier/internal/util.rb +7 -2
- data/lib/trycourier/models/airship_profile.rb +21 -0
- data/lib/trycourier/models/airship_profile_audience.rb +15 -0
- data/lib/trycourier/models/audience.rb +3 -3
- data/lib/trycourier/models/audience_filter.rb +52 -0
- data/lib/trycourier/models/audience_recipient.rb +36 -0
- data/lib/trycourier/models/audience_update_params.rb +3 -3
- data/lib/trycourier/models/device_type.rb +7 -0
- data/lib/trycourier/models/discord.rb +16 -0
- data/lib/trycourier/models/expo.rb +16 -0
- data/lib/trycourier/models/filter.rb +8 -51
- data/lib/trycourier/models/filter_config.rb +8 -51
- data/lib/trycourier/models/intercom.rb +21 -0
- data/lib/trycourier/models/intercom_recipient.rb +15 -0
- data/lib/trycourier/models/list_filter.rb +52 -0
- data/lib/trycourier/models/list_pattern_recipient.rb +23 -0
- data/lib/trycourier/models/list_recipient.rb +29 -0
- data/lib/trycourier/models/ms_teams.rb +22 -0
- data/lib/trycourier/models/ms_teams_base_properties.rb +21 -0
- data/lib/trycourier/models/ms_teams_recipient.rb +17 -0
- data/lib/trycourier/models/multiple_tokens.rb +15 -0
- data/lib/trycourier/models/nested_filter_config.rb +49 -0
- data/lib/trycourier/models/pagerduty.rb +33 -0
- data/lib/trycourier/models/pagerduty_recipient.rb +17 -0
- data/lib/trycourier/models/send_direct_message.rb +15 -0
- data/lib/trycourier/models/send_message_params.rb +24 -7
- data/lib/trycourier/models/send_to_channel.rb +15 -0
- data/lib/trycourier/models/send_to_ms_teams_channel_id.rb +27 -0
- data/lib/trycourier/models/send_to_ms_teams_channel_name.rb +33 -0
- data/lib/trycourier/models/send_to_ms_teams_conversation_id.rb +27 -0
- data/lib/trycourier/models/send_to_ms_teams_email.rb +27 -0
- data/lib/trycourier/models/send_to_ms_teams_user_id.rb +27 -0
- data/lib/trycourier/models/send_to_slack_channel.rb +21 -0
- data/lib/trycourier/models/send_to_slack_email.rb +21 -0
- data/lib/trycourier/models/send_to_slack_user_id.rb +21 -0
- data/lib/trycourier/models/single_filter_config.rb +62 -0
- data/lib/trycourier/models/slack.rb +18 -0
- data/lib/trycourier/models/slack_base_properties.rb +15 -0
- data/lib/trycourier/models/slack_recipient.rb +17 -0
- data/lib/trycourier/models/token.rb +15 -0
- data/lib/trycourier/models/user_profile.rb +274 -0
- data/lib/trycourier/models/user_profile_firebase_token.rb +19 -0
- data/lib/trycourier/models/webhook_auth_mode.rb +16 -0
- data/lib/trycourier/models/webhook_authentication.rb +40 -0
- data/lib/trycourier/models/webhook_method.rb +15 -0
- data/lib/trycourier/models/webhook_profile.rb +53 -0
- data/lib/trycourier/models/webhook_profile_type.rb +15 -0
- data/lib/trycourier/models/webhook_recipient.rb +17 -0
- data/lib/trycourier/models.rb +84 -2
- data/lib/trycourier/resources/audiences.rb +1 -1
- data/lib/trycourier/version.rb +1 -1
- data/lib/trycourier.rb +42 -1
- data/rbi/trycourier/models/airship_profile.rbi +41 -0
- data/rbi/trycourier/models/airship_profile_audience.rbi +26 -0
- data/rbi/trycourier/models/audience.rbi +8 -7
- data/rbi/trycourier/models/audience_filter.rbi +88 -0
- data/rbi/trycourier/models/audience_recipient.rbi +52 -0
- data/rbi/trycourier/models/audience_update_params.rbi +25 -7
- data/rbi/trycourier/models/device_type.rbi +7 -0
- data/rbi/trycourier/models/discord.rbi +18 -0
- data/rbi/trycourier/models/expo.rbi +16 -0
- data/rbi/trycourier/models/filter.rbi +8 -78
- data/rbi/trycourier/models/filter_config.rbi +8 -83
- data/rbi/trycourier/models/intercom.rbi +35 -0
- data/rbi/trycourier/models/intercom_recipient.rbi +23 -0
- data/rbi/trycourier/models/list_filter.rbi +86 -0
- data/rbi/trycourier/models/list_pattern_recipient.rbi +39 -0
- data/rbi/trycourier/models/list_recipient.rbi +44 -0
- data/rbi/trycourier/models/ms_teams.rbi +24 -0
- data/rbi/trycourier/models/ms_teams_base_properties.rbi +31 -0
- data/rbi/trycourier/models/ms_teams_recipient.rbi +58 -0
- data/rbi/trycourier/models/multiple_tokens.rbi +27 -0
- data/rbi/trycourier/models/nested_filter_config.rbi +104 -0
- data/rbi/trycourier/models/pagerduty.rbi +53 -0
- data/rbi/trycourier/models/pagerduty_recipient.rbi +31 -0
- data/rbi/trycourier/models/send_direct_message.rbi +23 -0
- data/rbi/trycourier/models/send_message_params.rbi +34 -10
- data/rbi/trycourier/models/send_to_channel.rbi +23 -0
- data/rbi/trycourier/models/send_to_ms_teams_channel_id.rbi +42 -0
- data/rbi/trycourier/models/send_to_ms_teams_channel_name.rbi +51 -0
- data/rbi/trycourier/models/send_to_ms_teams_conversation_id.rbi +42 -0
- data/rbi/trycourier/models/send_to_ms_teams_email.rbi +37 -0
- data/rbi/trycourier/models/send_to_ms_teams_user_id.rbi +37 -0
- data/rbi/trycourier/models/send_to_slack_channel.rbi +28 -0
- data/rbi/trycourier/models/send_to_slack_email.rbi +28 -0
- data/rbi/trycourier/models/send_to_slack_user_id.rbi +28 -0
- data/rbi/trycourier/models/single_filter_config.rbi +116 -0
- data/rbi/trycourier/models/slack.rbi +22 -0
- data/rbi/trycourier/models/slack_base_properties.rbi +23 -0
- data/rbi/trycourier/models/slack_recipient.rbi +52 -0
- data/rbi/trycourier/models/token.rbi +21 -0
- data/rbi/trycourier/models/user_profile.rbi +377 -0
- data/rbi/trycourier/models/user_profile_firebase_token.rbi +25 -0
- data/rbi/trycourier/models/webhook_auth_mode.rbi +22 -0
- data/rbi/trycourier/models/webhook_authentication.rbi +64 -0
- data/rbi/trycourier/models/webhook_method.rbi +21 -0
- data/rbi/trycourier/models/webhook_profile.rbi +80 -0
- data/rbi/trycourier/models/webhook_profile_type.rbi +22 -0
- data/rbi/trycourier/models/webhook_recipient.rbi +31 -0
- data/rbi/trycourier/models.rbi +84 -2
- data/rbi/trycourier/resources/audiences.rbi +7 -1
- data/sig/trycourier/models/airship_profile.rbs +25 -0
- data/sig/trycourier/models/airship_profile_audience.rbs +13 -0
- data/sig/trycourier/models/audience.rbs +4 -4
- data/sig/trycourier/models/audience_filter.rbs +50 -0
- data/sig/trycourier/models/audience_recipient.rbs +30 -0
- data/sig/trycourier/models/audience_update_params.rbs +8 -4
- data/sig/trycourier/models/device_type.rbs +5 -0
- data/sig/trycourier/models/discord.rbs +11 -0
- data/sig/trycourier/models/expo.rbs +11 -0
- data/sig/trycourier/models/filter.rbs +4 -61
- data/sig/trycourier/models/filter_config.rbs +4 -61
- data/sig/trycourier/models/intercom.rbs +15 -0
- data/sig/trycourier/models/intercom_recipient.rbs +13 -0
- data/sig/trycourier/models/list_filter.rbs +50 -0
- data/sig/trycourier/models/list_pattern_recipient.rbs +19 -0
- data/sig/trycourier/models/list_recipient.rbs +30 -0
- data/sig/trycourier/models/ms_teams.rbs +16 -0
- data/sig/trycourier/models/ms_teams_base_properties.rbs +15 -0
- data/sig/trycourier/models/ms_teams_recipient.rbs +13 -0
- data/sig/trycourier/models/multiple_tokens.rbs +13 -0
- data/sig/trycourier/models/nested_filter_config.rbs +64 -0
- data/sig/trycourier/models/pagerduty.rbs +35 -0
- data/sig/trycourier/models/pagerduty_recipient.rbs +13 -0
- data/sig/trycourier/models/send_direct_message.rbs +13 -0
- data/sig/trycourier/models/send_message_params.rbs +9 -3
- data/sig/trycourier/models/send_to_channel.rbs +13 -0
- data/sig/trycourier/models/send_to_ms_teams_channel_id.rbs +26 -0
- data/sig/trycourier/models/send_to_ms_teams_channel_name.rbs +35 -0
- data/sig/trycourier/models/send_to_ms_teams_conversation_id.rbs +26 -0
- data/sig/trycourier/models/send_to_ms_teams_email.rbs +22 -0
- data/sig/trycourier/models/send_to_ms_teams_user_id.rbs +26 -0
- data/sig/trycourier/models/send_to_slack_channel.rbs +15 -0
- data/sig/trycourier/models/send_to_slack_email.rbs +15 -0
- data/sig/trycourier/models/send_to_slack_user_id.rbs +15 -0
- data/sig/trycourier/models/single_filter_config.rbs +69 -0
- data/sig/trycourier/models/slack.rbs +14 -0
- data/sig/trycourier/models/slack_base_properties.rbs +13 -0
- data/sig/trycourier/models/slack_recipient.rbs +13 -0
- data/sig/trycourier/models/token.rbs +13 -0
- data/sig/trycourier/models/user_profile.rbs +212 -0
- data/sig/trycourier/models/user_profile_firebase_token.rbs +13 -0
- data/sig/trycourier/models/webhook_auth_mode.rbs +15 -0
- data/sig/trycourier/models/webhook_authentication.rbs +35 -0
- data/sig/trycourier/models/webhook_method.rbs +14 -0
- data/sig/trycourier/models/webhook_profile.rbs +40 -0
- data/sig/trycourier/models/webhook_profile_type.rbs +14 -0
- data/sig/trycourier/models/webhook_recipient.rbs +13 -0
- data/sig/trycourier/models.rbs +86 -4
- data/sig/trycourier/resources/audiences.rbs +1 -1
- metadata +128 -5
- data/lib/trycourier/models/recipient.rb +0 -113
- data/rbi/trycourier/models/recipient.rbi +0 -161
- data/sig/trycourier/models/recipient.rbs +0 -92
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class MsTeamsBaseProperties < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute service_url
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :service_url, String
|
|
10
|
+
|
|
11
|
+
# @!attribute tenant_id
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :tenant_id, String
|
|
15
|
+
|
|
16
|
+
# @!method initialize(service_url:, tenant_id:)
|
|
17
|
+
# @param service_url [String]
|
|
18
|
+
# @param tenant_id [String]
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class MsTeamsRecipient < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute ms_teams
|
|
7
|
+
#
|
|
8
|
+
# @return [Trycourier::Models::SendToMsTeamsUserID, Trycourier::Models::SendToMsTeamsEmail, Trycourier::Models::SendToMsTeamsChannelID, Trycourier::Models::SendToMsTeamsConversationID, Trycourier::Models::SendToMsTeamsChannelName]
|
|
9
|
+
required :ms_teams, union: -> { Trycourier::MsTeams }
|
|
10
|
+
|
|
11
|
+
# @!method initialize(ms_teams:)
|
|
12
|
+
# Send via Microsoft Teams
|
|
13
|
+
#
|
|
14
|
+
# @param ms_teams [Trycourier::Models::SendToMsTeamsUserID, Trycourier::Models::SendToMsTeamsEmail, Trycourier::Models::SendToMsTeamsChannelID, Trycourier::Models::SendToMsTeamsConversationID, Trycourier::Models::SendToMsTeamsChannelName]
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class MultipleTokens < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute tokens
|
|
7
|
+
#
|
|
8
|
+
# @return [Array<Trycourier::Models::Token>]
|
|
9
|
+
required :tokens, -> { Trycourier::Internal::Type::ArrayOf[Trycourier::Token] }
|
|
10
|
+
|
|
11
|
+
# @!method initialize(tokens:)
|
|
12
|
+
# @param tokens [Array<Trycourier::Models::Token>]
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class NestedFilterConfig < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute operator
|
|
7
|
+
# The operator to use for filtering
|
|
8
|
+
#
|
|
9
|
+
# @return [Symbol, Trycourier::Models::NestedFilterConfig::Operator]
|
|
10
|
+
required :operator, enum: -> { Trycourier::NestedFilterConfig::Operator }
|
|
11
|
+
|
|
12
|
+
# @!attribute rules
|
|
13
|
+
#
|
|
14
|
+
# @return [Array<Trycourier::Models::FilterConfig>]
|
|
15
|
+
required :rules, -> { Trycourier::Internal::Type::ArrayOf[union: Trycourier::FilterConfig] }
|
|
16
|
+
|
|
17
|
+
# @!method initialize(operator:, rules:)
|
|
18
|
+
# @param operator [Symbol, Trycourier::Models::NestedFilterConfig::Operator] The operator to use for filtering
|
|
19
|
+
#
|
|
20
|
+
# @param rules [Array<Trycourier::Models::FilterConfig>]
|
|
21
|
+
|
|
22
|
+
# The operator to use for filtering
|
|
23
|
+
#
|
|
24
|
+
# @see Trycourier::Models::NestedFilterConfig#operator
|
|
25
|
+
module Operator
|
|
26
|
+
extend Trycourier::Internal::Type::Enum
|
|
27
|
+
|
|
28
|
+
ENDS_WITH = :ENDS_WITH
|
|
29
|
+
EQ = :EQ
|
|
30
|
+
EXISTS = :EXISTS
|
|
31
|
+
GT = :GT
|
|
32
|
+
GTE = :GTE
|
|
33
|
+
INCLUDES = :INCLUDES
|
|
34
|
+
IS_AFTER = :IS_AFTER
|
|
35
|
+
IS_BEFORE = :IS_BEFORE
|
|
36
|
+
LT = :LT
|
|
37
|
+
LTE = :LTE
|
|
38
|
+
NEQ = :NEQ
|
|
39
|
+
OMIT = :OMIT
|
|
40
|
+
STARTS_WITH = :STARTS_WITH
|
|
41
|
+
AND = :AND
|
|
42
|
+
OR = :OR
|
|
43
|
+
|
|
44
|
+
# @!method self.values
|
|
45
|
+
# @return [Array<Symbol>]
|
|
46
|
+
end
|
|
47
|
+
end
|
|
48
|
+
end
|
|
49
|
+
end
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class Pagerduty < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute event_action
|
|
7
|
+
#
|
|
8
|
+
# @return [String, nil]
|
|
9
|
+
optional :event_action, String, nil?: true
|
|
10
|
+
|
|
11
|
+
# @!attribute routing_key
|
|
12
|
+
#
|
|
13
|
+
# @return [String, nil]
|
|
14
|
+
optional :routing_key, String, nil?: true
|
|
15
|
+
|
|
16
|
+
# @!attribute severity
|
|
17
|
+
#
|
|
18
|
+
# @return [String, nil]
|
|
19
|
+
optional :severity, String, nil?: true
|
|
20
|
+
|
|
21
|
+
# @!attribute source
|
|
22
|
+
#
|
|
23
|
+
# @return [String, nil]
|
|
24
|
+
optional :source, String, nil?: true
|
|
25
|
+
|
|
26
|
+
# @!method initialize(event_action: nil, routing_key: nil, severity: nil, source: nil)
|
|
27
|
+
# @param event_action [String, nil]
|
|
28
|
+
# @param routing_key [String, nil]
|
|
29
|
+
# @param severity [String, nil]
|
|
30
|
+
# @param source [String, nil]
|
|
31
|
+
end
|
|
32
|
+
end
|
|
33
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class PagerdutyRecipient < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute pagerduty
|
|
7
|
+
#
|
|
8
|
+
# @return [Trycourier::Models::Pagerduty]
|
|
9
|
+
required :pagerduty, -> { Trycourier::Pagerduty }
|
|
10
|
+
|
|
11
|
+
# @!method initialize(pagerduty:)
|
|
12
|
+
# Send via PagerDuty
|
|
13
|
+
#
|
|
14
|
+
# @param pagerduty [Trycourier::Models::Pagerduty]
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendDirectMessage < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute user_id
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :user_id, String
|
|
10
|
+
|
|
11
|
+
# @!method initialize(user_id:)
|
|
12
|
+
# @param user_id [String]
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -100,7 +100,7 @@ module Trycourier
|
|
|
100
100
|
# @!attribute to
|
|
101
101
|
# The recipient or a list of recipients of the message
|
|
102
102
|
#
|
|
103
|
-
# @return [Trycourier::Models::UserRecipient,
|
|
103
|
+
# @return [Trycourier::Models::UserRecipient, Trycourier::Models::AudienceRecipient, Trycourier::Models::ListRecipient, Trycourier::Models::ListPatternRecipient, Trycourier::Models::SlackRecipient, Trycourier::Models::MsTeamsRecipient, Trycourier::Models::PagerdutyRecipient, Trycourier::Models::WebhookRecipient, nil]
|
|
104
104
|
optional :to, union: -> { Trycourier::SendMessageParams::Message::To }, nil?: true
|
|
105
105
|
|
|
106
106
|
# @!method initialize(brand_id: nil, channels: nil, content: nil, context: nil, data: nil, delay: nil, expiry: nil, metadata: nil, preferences: nil, providers: nil, routing: nil, template: nil, timeout: nil, to: nil)
|
|
@@ -136,7 +136,7 @@ module Trycourier
|
|
|
136
136
|
#
|
|
137
137
|
# @param timeout [Trycourier::Models::SendMessageParams::Message::Timeout, nil]
|
|
138
138
|
#
|
|
139
|
-
# @param to [Trycourier::Models::UserRecipient,
|
|
139
|
+
# @param to [Trycourier::Models::UserRecipient, Trycourier::Models::AudienceRecipient, Trycourier::Models::ListRecipient, Trycourier::Models::ListPatternRecipient, Trycourier::Models::SlackRecipient, Trycourier::Models::MsTeamsRecipient, Trycourier::Models::PagerdutyRecipient, Trycourier::Models::WebhookRecipient, nil] The recipient or a list of recipients of the message
|
|
140
140
|
|
|
141
141
|
class Channel < Trycourier::Internal::Type::BaseModel
|
|
142
142
|
# @!attribute brand_id
|
|
@@ -504,15 +504,32 @@ module Trycourier
|
|
|
504
504
|
module To
|
|
505
505
|
extend Trycourier::Internal::Type::Union
|
|
506
506
|
|
|
507
|
+
# Send to a specific user by user_id, email, phone_number, or list_id
|
|
507
508
|
variant -> { Trycourier::UserRecipient }
|
|
508
509
|
|
|
509
|
-
|
|
510
|
+
# Send to all users in an audience
|
|
511
|
+
variant -> { Trycourier::AudienceRecipient }
|
|
510
512
|
|
|
511
|
-
#
|
|
512
|
-
|
|
513
|
+
# Send to all users in a specific list
|
|
514
|
+
variant -> { Trycourier::ListRecipient }
|
|
515
|
+
|
|
516
|
+
# Send to users in lists matching a pattern
|
|
517
|
+
variant -> { Trycourier::ListPatternRecipient }
|
|
518
|
+
|
|
519
|
+
# Send via Slack (channel, email, or user_id)
|
|
520
|
+
variant -> { Trycourier::SlackRecipient }
|
|
521
|
+
|
|
522
|
+
# Send via Microsoft Teams
|
|
523
|
+
variant -> { Trycourier::MsTeamsRecipient }
|
|
513
524
|
|
|
514
|
-
#
|
|
515
|
-
|
|
525
|
+
# Send via PagerDuty
|
|
526
|
+
variant -> { Trycourier::PagerdutyRecipient }
|
|
527
|
+
|
|
528
|
+
# Send via webhook
|
|
529
|
+
variant -> { Trycourier::WebhookRecipient }
|
|
530
|
+
|
|
531
|
+
# @!method self.variants
|
|
532
|
+
# @return [Array(Trycourier::Models::UserRecipient, Trycourier::Models::AudienceRecipient, Trycourier::Models::ListRecipient, Trycourier::Models::ListPatternRecipient, Trycourier::Models::SlackRecipient, Trycourier::Models::MsTeamsRecipient, Trycourier::Models::PagerdutyRecipient, Trycourier::Models::WebhookRecipient)]
|
|
516
533
|
end
|
|
517
534
|
end
|
|
518
535
|
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToChannel < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute channel_id
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :channel_id, String
|
|
10
|
+
|
|
11
|
+
# @!method initialize(channel_id:)
|
|
12
|
+
# @param channel_id [String]
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToMsTeamsChannelID < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute channel_id
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :channel_id, String
|
|
10
|
+
|
|
11
|
+
# @!attribute service_url
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :service_url, String
|
|
15
|
+
|
|
16
|
+
# @!attribute tenant_id
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :tenant_id, String
|
|
20
|
+
|
|
21
|
+
# @!method initialize(channel_id:, service_url:, tenant_id:)
|
|
22
|
+
# @param channel_id [String]
|
|
23
|
+
# @param service_url [String]
|
|
24
|
+
# @param tenant_id [String]
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToMsTeamsChannelName < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute channel_name
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :channel_name, String
|
|
10
|
+
|
|
11
|
+
# @!attribute service_url
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :service_url, String
|
|
15
|
+
|
|
16
|
+
# @!attribute team_id
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :team_id, String
|
|
20
|
+
|
|
21
|
+
# @!attribute tenant_id
|
|
22
|
+
#
|
|
23
|
+
# @return [String]
|
|
24
|
+
required :tenant_id, String
|
|
25
|
+
|
|
26
|
+
# @!method initialize(channel_name:, service_url:, team_id:, tenant_id:)
|
|
27
|
+
# @param channel_name [String]
|
|
28
|
+
# @param service_url [String]
|
|
29
|
+
# @param team_id [String]
|
|
30
|
+
# @param tenant_id [String]
|
|
31
|
+
end
|
|
32
|
+
end
|
|
33
|
+
end
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToMsTeamsConversationID < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute conversation_id
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :conversation_id, String
|
|
10
|
+
|
|
11
|
+
# @!attribute service_url
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :service_url, String
|
|
15
|
+
|
|
16
|
+
# @!attribute tenant_id
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :tenant_id, String
|
|
20
|
+
|
|
21
|
+
# @!method initialize(conversation_id:, service_url:, tenant_id:)
|
|
22
|
+
# @param conversation_id [String]
|
|
23
|
+
# @param service_url [String]
|
|
24
|
+
# @param tenant_id [String]
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToMsTeamsEmail < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute email
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :email, String
|
|
10
|
+
|
|
11
|
+
# @!attribute service_url
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :service_url, String
|
|
15
|
+
|
|
16
|
+
# @!attribute tenant_id
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :tenant_id, String
|
|
20
|
+
|
|
21
|
+
# @!method initialize(email:, service_url:, tenant_id:)
|
|
22
|
+
# @param email [String]
|
|
23
|
+
# @param service_url [String]
|
|
24
|
+
# @param tenant_id [String]
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToMsTeamsUserID < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute service_url
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :service_url, String
|
|
10
|
+
|
|
11
|
+
# @!attribute tenant_id
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :tenant_id, String
|
|
15
|
+
|
|
16
|
+
# @!attribute user_id
|
|
17
|
+
#
|
|
18
|
+
# @return [String]
|
|
19
|
+
required :user_id, String
|
|
20
|
+
|
|
21
|
+
# @!method initialize(service_url:, tenant_id:, user_id:)
|
|
22
|
+
# @param service_url [String]
|
|
23
|
+
# @param tenant_id [String]
|
|
24
|
+
# @param user_id [String]
|
|
25
|
+
end
|
|
26
|
+
end
|
|
27
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToSlackChannel < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute access_token
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :access_token, String
|
|
10
|
+
|
|
11
|
+
# @!attribute channel
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :channel, String
|
|
15
|
+
|
|
16
|
+
# @!method initialize(access_token:, channel:)
|
|
17
|
+
# @param access_token [String]
|
|
18
|
+
# @param channel [String]
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToSlackEmail < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute access_token
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :access_token, String
|
|
10
|
+
|
|
11
|
+
# @!attribute email
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :email, String
|
|
15
|
+
|
|
16
|
+
# @!method initialize(access_token:, email:)
|
|
17
|
+
# @param access_token [String]
|
|
18
|
+
# @param email [String]
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SendToSlackUserID < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute access_token
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :access_token, String
|
|
10
|
+
|
|
11
|
+
# @!attribute user_id
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :user_id, String
|
|
15
|
+
|
|
16
|
+
# @!method initialize(access_token:, user_id:)
|
|
17
|
+
# @param access_token [String]
|
|
18
|
+
# @param user_id [String]
|
|
19
|
+
end
|
|
20
|
+
end
|
|
21
|
+
end
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SingleFilterConfig < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute operator
|
|
7
|
+
# The operator to use for filtering
|
|
8
|
+
#
|
|
9
|
+
# @return [Symbol, Trycourier::Models::SingleFilterConfig::Operator]
|
|
10
|
+
required :operator, enum: -> { Trycourier::SingleFilterConfig::Operator }
|
|
11
|
+
|
|
12
|
+
# @!attribute path
|
|
13
|
+
# The attribe name from profile whose value will be operated against the filter
|
|
14
|
+
# value
|
|
15
|
+
#
|
|
16
|
+
# @return [String]
|
|
17
|
+
required :path, String
|
|
18
|
+
|
|
19
|
+
# @!attribute value
|
|
20
|
+
# The value to use for filtering
|
|
21
|
+
#
|
|
22
|
+
# @return [String]
|
|
23
|
+
required :value, String
|
|
24
|
+
|
|
25
|
+
# @!method initialize(operator:, path:, value:)
|
|
26
|
+
# Some parameter documentations has been truncated, see
|
|
27
|
+
# {Trycourier::Models::SingleFilterConfig} for more details.
|
|
28
|
+
#
|
|
29
|
+
# @param operator [Symbol, Trycourier::Models::SingleFilterConfig::Operator] The operator to use for filtering
|
|
30
|
+
#
|
|
31
|
+
# @param path [String] The attribe name from profile whose value will be operated against the filter va
|
|
32
|
+
#
|
|
33
|
+
# @param value [String] The value to use for filtering
|
|
34
|
+
|
|
35
|
+
# The operator to use for filtering
|
|
36
|
+
#
|
|
37
|
+
# @see Trycourier::Models::SingleFilterConfig#operator
|
|
38
|
+
module Operator
|
|
39
|
+
extend Trycourier::Internal::Type::Enum
|
|
40
|
+
|
|
41
|
+
ENDS_WITH = :ENDS_WITH
|
|
42
|
+
EQ = :EQ
|
|
43
|
+
EXISTS = :EXISTS
|
|
44
|
+
GT = :GT
|
|
45
|
+
GTE = :GTE
|
|
46
|
+
INCLUDES = :INCLUDES
|
|
47
|
+
IS_AFTER = :IS_AFTER
|
|
48
|
+
IS_BEFORE = :IS_BEFORE
|
|
49
|
+
LT = :LT
|
|
50
|
+
LTE = :LTE
|
|
51
|
+
NEQ = :NEQ
|
|
52
|
+
OMIT = :OMIT
|
|
53
|
+
STARTS_WITH = :STARTS_WITH
|
|
54
|
+
AND = :AND
|
|
55
|
+
OR = :OR
|
|
56
|
+
|
|
57
|
+
# @!method self.values
|
|
58
|
+
# @return [Array<Symbol>]
|
|
59
|
+
end
|
|
60
|
+
end
|
|
61
|
+
end
|
|
62
|
+
end
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
module Slack
|
|
6
|
+
extend Trycourier::Internal::Type::Union
|
|
7
|
+
|
|
8
|
+
variant -> { Trycourier::SendToSlackChannel }
|
|
9
|
+
|
|
10
|
+
variant -> { Trycourier::SendToSlackEmail }
|
|
11
|
+
|
|
12
|
+
variant -> { Trycourier::SendToSlackUserID }
|
|
13
|
+
|
|
14
|
+
# @!method self.variants
|
|
15
|
+
# @return [Array(Trycourier::Models::SendToSlackChannel, Trycourier::Models::SendToSlackEmail, Trycourier::Models::SendToSlackUserID)]
|
|
16
|
+
end
|
|
17
|
+
end
|
|
18
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SlackBaseProperties < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute access_token
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :access_token, String
|
|
10
|
+
|
|
11
|
+
# @!method initialize(access_token:)
|
|
12
|
+
# @param access_token [String]
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class SlackRecipient < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute slack
|
|
7
|
+
#
|
|
8
|
+
# @return [Trycourier::Models::SendToSlackChannel, Trycourier::Models::SendToSlackEmail, Trycourier::Models::SendToSlackUserID]
|
|
9
|
+
required :slack, union: -> { Trycourier::Slack }
|
|
10
|
+
|
|
11
|
+
# @!method initialize(slack:)
|
|
12
|
+
# Send via Slack (channel, email, or user_id)
|
|
13
|
+
#
|
|
14
|
+
# @param slack [Trycourier::Models::SendToSlackChannel, Trycourier::Models::SendToSlackEmail, Trycourier::Models::SendToSlackUserID]
|
|
15
|
+
end
|
|
16
|
+
end
|
|
17
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Trycourier
|
|
4
|
+
module Models
|
|
5
|
+
class Token < Trycourier::Internal::Type::BaseModel
|
|
6
|
+
# @!attribute token
|
|
7
|
+
#
|
|
8
|
+
# @return [String]
|
|
9
|
+
required :token, String
|
|
10
|
+
|
|
11
|
+
# @!method initialize(token:)
|
|
12
|
+
# @param token [String]
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|