trycourier 4.8.0 → 4.10.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 +41 -0
- data/README.md +1 -1
- data/lib/courier/client.rb +8 -0
- data/lib/courier/internal/util.rb +19 -6
- data/lib/courier/models/associated_notification_list_response.rb +24 -0
- data/lib/courier/models/channel.rb +75 -0
- data/lib/courier/models/channel_metadata.rb +15 -0
- data/lib/courier/models/element_with_checksums.rb +60 -0
- data/lib/courier/models/elemental_content.rb +2 -2
- data/lib/courier/models/elemental_html_node_with_type.rb +24 -0
- data/lib/courier/models/elemental_node.rb +3 -1
- data/lib/courier/models/message_channels.rb +8 -0
- data/lib/courier/models/message_providers.rb +8 -0
- data/lib/courier/models/message_providers_type.rb +38 -0
- data/lib/courier/models/metadata.rb +15 -0
- data/lib/courier/models/notification_archive_params.rb +20 -0
- data/lib/courier/models/notification_content_get_response.rb +26 -0
- data/lib/courier/models/notification_content_mutation_response.rb +61 -0
- data/lib/courier/models/notification_content_put_request.rb +51 -0
- data/lib/courier/models/notification_create_params.rb +14 -0
- data/lib/courier/models/notification_element_put_request.rb +62 -0
- data/lib/courier/models/notification_get_content.rb +0 -1
- data/lib/courier/models/notification_list_params.rb +13 -4
- data/lib/courier/models/notification_list_response.rb +108 -93
- data/lib/courier/models/notification_list_versions_params.rb +37 -0
- data/lib/courier/models/notification_locale_put_request.rb +39 -0
- data/lib/courier/models/notification_publish_params.rb +20 -0
- data/lib/courier/models/notification_put_content_params.rb +20 -0
- data/lib/courier/models/notification_put_element_params.rb +26 -0
- data/lib/courier/models/notification_put_locale_params.rb +26 -0
- data/lib/courier/models/notification_replace_params.rb +20 -0
- data/lib/courier/models/notification_retrieve_content_params.rb +14 -1
- data/lib/courier/models/notification_retrieve_content_response.rb +21 -0
- data/lib/courier/models/notification_retrieve_params.rb +33 -0
- data/lib/courier/models/notification_template_create_request.rb +45 -0
- data/lib/courier/models/notification_template_get_response.rb +92 -0
- data/lib/courier/models/notification_template_mutation_response.rb +51 -0
- data/lib/courier/models/notification_template_payload.rb +98 -0
- data/lib/courier/models/notification_template_publish_request.rb +19 -0
- data/lib/courier/models/notification_template_state.rb +16 -0
- data/lib/courier/models/notification_template_summary.rb +81 -0
- data/lib/courier/models/notification_template_update_request.rb +46 -0
- data/lib/courier/models/notification_template_version_list_response.rb +22 -0
- data/lib/courier/models/provider.rb +67 -0
- data/lib/courier/models/provider_create_params.rb +52 -0
- data/lib/courier/models/provider_delete_params.rb +20 -0
- data/lib/courier/models/provider_list_params.rb +22 -0
- data/lib/courier/models/provider_list_response.rb +24 -0
- data/lib/courier/models/provider_retrieve_params.rb +20 -0
- data/lib/courier/models/provider_update_params.rb +58 -0
- data/lib/courier/models/providers/catalog_list_params.rb +44 -0
- data/lib/courier/models/providers/catalog_list_response.rb +26 -0
- data/lib/courier/models/providers_catalog_entry.rb +86 -0
- data/lib/courier/models/routing_strategy_archive_params.rb +20 -0
- data/lib/courier/models/routing_strategy_create_params.rb +14 -0
- data/lib/courier/models/routing_strategy_create_request.rb +58 -0
- data/lib/courier/models/routing_strategy_get_response.rb +99 -0
- data/lib/courier/models/routing_strategy_list_notifications_params.rb +37 -0
- data/lib/courier/models/routing_strategy_list_params.rb +30 -0
- data/lib/courier/models/routing_strategy_list_response.rb +24 -0
- data/lib/courier/models/routing_strategy_mutation_response.rb +19 -0
- data/lib/courier/models/routing_strategy_replace_params.rb +20 -0
- data/lib/courier/models/routing_strategy_replace_request.rb +59 -0
- data/lib/courier/models/routing_strategy_retrieve_params.rb +20 -0
- data/lib/courier/models/routing_strategy_summary.rb +75 -0
- data/lib/courier/models/send_message_params.rb +6 -154
- data/lib/courier/models/tenant_template_input.rb +6 -152
- data/lib/courier/models/timeouts.rb +21 -0
- data/lib/courier/models/version_node.rb +46 -0
- data/lib/courier/models.rb +110 -0
- data/lib/courier/resources/notifications.rb +289 -12
- data/lib/courier/resources/providers/catalog.rb +49 -0
- data/lib/courier/resources/providers.rb +150 -0
- data/lib/courier/resources/routing_strategies.rb +179 -0
- data/lib/courier/version.rb +1 -1
- data/lib/courier.rb +60 -2
- data/rbi/courier/client.rbi +6 -0
- data/rbi/courier/internal/util.rbi +8 -0
- data/rbi/courier/models/associated_notification_list_response.rbi +45 -0
- data/rbi/courier/models/channel.rbi +106 -0
- data/rbi/courier/models/channel_metadata.rbi +28 -0
- data/rbi/courier/models/element_with_checksums.rbi +109 -0
- data/rbi/courier/models/elemental_content.rbi +6 -3
- data/rbi/courier/models/elemental_html_node_with_type.rbi +59 -0
- data/rbi/courier/models/elemental_node.rbi +2 -1
- data/rbi/courier/models/message_channels.rbi +11 -0
- data/rbi/courier/models/message_providers.rbi +11 -0
- data/rbi/courier/models/message_providers_type.rbi +60 -0
- data/rbi/courier/models/metadata.rbi +26 -0
- data/rbi/courier/models/notification_archive_params.rbi +35 -0
- data/rbi/courier/models/notification_content_get_response.rbi +45 -0
- data/rbi/courier/models/notification_content_mutation_response.rbi +95 -0
- data/rbi/courier/models/notification_content_put_request.rbi +145 -0
- data/rbi/courier/models/notification_create_params.rbi +27 -0
- data/rbi/courier/models/notification_element_put_request.rbi +98 -0
- data/rbi/courier/models/notification_list_params.rbi +15 -2
- data/rbi/courier/models/notification_list_response.rbi +159 -119
- data/rbi/courier/models/notification_list_versions_params.rbi +66 -0
- data/rbi/courier/models/notification_locale_put_request.rbi +79 -0
- data/rbi/courier/models/notification_publish_params.rbi +35 -0
- data/rbi/courier/models/notification_put_content_params.rbi +38 -0
- data/rbi/courier/models/notification_put_element_params.rbi +46 -0
- data/rbi/courier/models/notification_put_locale_params.rbi +46 -0
- data/rbi/courier/models/notification_replace_params.rbi +35 -0
- data/rbi/courier/models/notification_retrieve_content_params.rbi +21 -2
- data/rbi/courier/models/notification_retrieve_content_response.rbi +29 -0
- data/rbi/courier/models/notification_retrieve_params.rbi +54 -0
- data/rbi/courier/models/notification_template_create_request.rbi +102 -0
- data/rbi/courier/models/notification_template_get_response.rbi +162 -0
- data/rbi/courier/models/notification_template_mutation_response.rbi +121 -0
- data/rbi/courier/models/notification_template_payload.rbi +183 -0
- data/rbi/courier/models/notification_template_publish_request.rbi +35 -0
- data/rbi/courier/models/notification_template_state.rbi +26 -0
- data/rbi/courier/models/notification_template_summary.rbi +124 -0
- data/rbi/courier/models/notification_template_update_request.rbi +103 -0
- data/rbi/courier/models/notification_template_version_list_response.rbi +41 -0
- data/rbi/courier/models/provider.rbi +87 -0
- data/rbi/courier/models/provider_create_params.rbi +82 -0
- data/rbi/courier/models/provider_delete_params.rbi +35 -0
- data/rbi/courier/models/provider_list_params.rbi +43 -0
- data/rbi/courier/models/provider_list_response.rbi +42 -0
- data/rbi/courier/models/provider_retrieve_params.rbi +35 -0
- data/rbi/courier/models/provider_update_params.rbi +86 -0
- data/rbi/courier/models/providers/catalog_list_params.rbi +75 -0
- data/rbi/courier/models/providers/catalog_list_response.rbi +47 -0
- data/rbi/courier/models/providers_catalog_entry.rbi +129 -0
- data/rbi/courier/models/routing_strategy_archive_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_create_params.rbi +30 -0
- data/rbi/courier/models/routing_strategy_create_request.rbi +86 -0
- data/rbi/courier/models/routing_strategy_get_response.rbi +121 -0
- data/rbi/courier/models/routing_strategy_list_notifications_params.rbi +63 -0
- data/rbi/courier/models/routing_strategy_list_params.rbi +54 -0
- data/rbi/courier/models/routing_strategy_list_response.rbi +45 -0
- data/rbi/courier/models/routing_strategy_mutation_response.rbi +31 -0
- data/rbi/courier/models/routing_strategy_replace_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_replace_request.rbi +87 -0
- data/rbi/courier/models/routing_strategy_retrieve_params.rbi +38 -0
- data/rbi/courier/models/routing_strategy_summary.rbi +95 -0
- data/rbi/courier/models/send_message_params.rbi +6 -362
- data/rbi/courier/models/tenant_template_input.rbi +8 -336
- data/rbi/courier/models/timeouts.rbi +33 -0
- data/rbi/courier/models/version_node.rbi +65 -0
- data/rbi/courier/models.rbi +122 -0
- data/rbi/courier/resources/notifications.rbi +222 -6
- data/rbi/courier/resources/providers/catalog.rbi +38 -0
- data/rbi/courier/resources/providers.rbi +116 -0
- data/rbi/courier/resources/routing_strategies.rbi +147 -0
- data/sig/courier/client.rbs +4 -0
- data/sig/courier/internal/util.rbs +4 -0
- data/sig/courier/models/associated_notification_list_response.rbs +25 -0
- data/sig/courier/models/channel.rbs +61 -0
- data/sig/courier/models/channel_metadata.rbs +13 -0
- data/sig/courier/models/element_with_checksums.rbs +60 -0
- data/sig/courier/models/elemental_html_node_with_type.rbs +32 -0
- data/sig/courier/models/elemental_node.rbs +1 -0
- data/sig/courier/models/message_channels.rbs +7 -0
- data/sig/courier/models/message_providers.rbs +7 -0
- data/sig/courier/models/message_providers_type.rbs +35 -0
- data/sig/courier/models/metadata.rbs +13 -0
- data/sig/courier/models/notification_archive_params.rbs +20 -0
- data/sig/courier/models/notification_content_get_response.rbs +22 -0
- data/sig/courier/models/notification_content_mutation_response.rbs +47 -0
- data/sig/courier/models/notification_content_put_request.rbs +50 -0
- data/sig/courier/models/notification_create_params.rbs +15 -0
- data/sig/courier/models/notification_element_put_request.rbs +64 -0
- data/sig/courier/models/notification_list_params.rbs +7 -1
- data/sig/courier/models/notification_list_response.rbs +81 -71
- data/sig/courier/models/notification_list_versions_params.rbs +36 -0
- data/sig/courier/models/notification_locale_put_request.rbs +39 -0
- data/sig/courier/models/notification_publish_params.rbs +22 -0
- data/sig/courier/models/notification_put_content_params.rbs +22 -0
- data/sig/courier/models/notification_put_element_params.rbs +32 -0
- data/sig/courier/models/notification_put_locale_params.rbs +32 -0
- data/sig/courier/models/notification_replace_params.rbs +22 -0
- data/sig/courier/models/notification_retrieve_content_params.rbs +12 -2
- data/sig/courier/models/notification_retrieve_content_response.rbs +12 -0
- data/sig/courier/models/notification_retrieve_params.rbs +30 -0
- data/sig/courier/models/notification_template_create_request.rbs +40 -0
- data/sig/courier/models/notification_template_get_response.rbs +72 -0
- data/sig/courier/models/notification_template_mutation_response.rbs +46 -0
- data/sig/courier/models/notification_template_payload.rbs +75 -0
- data/sig/courier/models/notification_template_publish_request.rbs +15 -0
- data/sig/courier/models/notification_template_state.rbs +14 -0
- data/sig/courier/models/notification_template_summary.rbs +70 -0
- data/sig/courier/models/notification_template_update_request.rbs +40 -0
- data/sig/courier/models/notification_template_version_list_response.rbs +22 -0
- data/sig/courier/models/provider.rbs +52 -0
- data/sig/courier/models/provider_create_params.rbs +47 -0
- data/sig/courier/models/provider_delete_params.rbs +20 -0
- data/sig/courier/models/provider_list_params.rbs +25 -0
- data/sig/courier/models/provider_list_response.rbs +22 -0
- data/sig/courier/models/provider_retrieve_params.rbs +20 -0
- data/sig/courier/models/provider_update_params.rbs +52 -0
- data/sig/courier/models/providers/catalog_list_params.rbs +40 -0
- data/sig/courier/models/providers/catalog_list_response.rbs +27 -0
- data/sig/courier/models/providers_catalog_entry.rbs +64 -0
- data/sig/courier/models/routing_strategy_archive_params.rbs +20 -0
- data/sig/courier/models/routing_strategy_create_params.rbs +15 -0
- data/sig/courier/models/routing_strategy_create_request.rbs +45 -0
- data/sig/courier/models/routing_strategy_get_response.rbs +70 -0
- data/sig/courier/models/routing_strategy_list_notifications_params.rbs +34 -0
- data/sig/courier/models/routing_strategy_list_params.rbs +30 -0
- data/sig/courier/models/routing_strategy_list_response.rbs +25 -0
- data/sig/courier/models/routing_strategy_mutation_response.rbs +13 -0
- data/sig/courier/models/routing_strategy_replace_params.rbs +22 -0
- data/sig/courier/models/routing_strategy_replace_request.rbs +45 -0
- data/sig/courier/models/routing_strategy_retrieve_params.rbs +20 -0
- data/sig/courier/models/routing_strategy_summary.rbs +55 -0
- data/sig/courier/models/send_message_params.rbs +8 -130
- data/sig/courier/models/tenant_template_input.rbs +12 -134
- data/sig/courier/models/timeouts.rbs +15 -0
- data/sig/courier/models/version_node.rbs +32 -0
- data/sig/courier/models.rbs +108 -0
- data/sig/courier/resources/notifications.rbs +65 -3
- data/sig/courier/resources/providers/catalog.rbs +16 -0
- data/sig/courier/resources/providers.rbs +38 -0
- data/sig/courier/resources/routing_strategies.rbs +48 -0
- metadata +182 -8
- data/lib/courier/models/notifications/draft_retrieve_content_params.rb +0 -22
- data/lib/courier/resources/notifications/draft.rb +0 -33
- data/rbi/courier/models/notifications/draft_retrieve_content_params.rbi +0 -40
- data/rbi/courier/resources/notifications/draft.rbi +0 -23
- data/sig/courier/models/notifications/draft_retrieve_content_params.rbs +0 -22
- data/sig/courier/resources/notifications/draft.rbs +0 -14
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_locale_put_request =
|
|
4
|
+
{
|
|
5
|
+
elements: ::Array[Courier::NotificationLocalePutRequest::Element],
|
|
6
|
+
state: Courier::Models::notification_template_state
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
class NotificationLocalePutRequest < Courier::Internal::Type::BaseModel
|
|
10
|
+
attr_accessor elements: ::Array[Courier::NotificationLocalePutRequest::Element]
|
|
11
|
+
|
|
12
|
+
attr_reader state: Courier::Models::notification_template_state?
|
|
13
|
+
|
|
14
|
+
def state=: (
|
|
15
|
+
Courier::Models::notification_template_state
|
|
16
|
+
) -> Courier::Models::notification_template_state
|
|
17
|
+
|
|
18
|
+
def initialize: (
|
|
19
|
+
elements: ::Array[Courier::NotificationLocalePutRequest::Element],
|
|
20
|
+
?state: Courier::Models::notification_template_state
|
|
21
|
+
) -> void
|
|
22
|
+
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
elements: ::Array[Courier::NotificationLocalePutRequest::Element],
|
|
25
|
+
state: Courier::Models::notification_template_state
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
type element = { id: String }
|
|
29
|
+
|
|
30
|
+
class Element < Courier::Internal::Type::BaseModel
|
|
31
|
+
attr_accessor id: String
|
|
32
|
+
|
|
33
|
+
def initialize: (id: String) -> void
|
|
34
|
+
|
|
35
|
+
def to_hash: -> { id: String }
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_publish_params =
|
|
4
|
+
{ id: String } & Courier::Internal::Type::request_parameters
|
|
5
|
+
|
|
6
|
+
class NotificationPublishParams < Courier::Models::NotificationTemplatePublishRequest
|
|
7
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Courier::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
def id: -> String
|
|
11
|
+
|
|
12
|
+
def id=: (String _) -> String
|
|
13
|
+
|
|
14
|
+
def initialize: (
|
|
15
|
+
id: String,
|
|
16
|
+
?request_options: Courier::request_opts
|
|
17
|
+
) -> void
|
|
18
|
+
|
|
19
|
+
def to_hash: -> { id: String, request_options: Courier::RequestOptions }
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_put_content_params =
|
|
4
|
+
{ id: String } & Courier::Internal::Type::request_parameters
|
|
5
|
+
|
|
6
|
+
class NotificationPutContentParams < Courier::Models::NotificationContentPutRequest
|
|
7
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Courier::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
def id: -> String
|
|
11
|
+
|
|
12
|
+
def id=: (String _) -> String
|
|
13
|
+
|
|
14
|
+
def initialize: (
|
|
15
|
+
id: String,
|
|
16
|
+
?request_options: Courier::request_opts
|
|
17
|
+
) -> void
|
|
18
|
+
|
|
19
|
+
def to_hash: -> { id: String, request_options: Courier::RequestOptions }
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_put_element_params =
|
|
4
|
+
{ id: String, element_id: String }
|
|
5
|
+
& Courier::Internal::Type::request_parameters
|
|
6
|
+
|
|
7
|
+
class NotificationPutElementParams < Courier::Models::NotificationElementPutRequest
|
|
8
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
9
|
+
include Courier::Internal::Type::RequestParameters
|
|
10
|
+
|
|
11
|
+
def id: -> String
|
|
12
|
+
|
|
13
|
+
def id=: (String _) -> String
|
|
14
|
+
|
|
15
|
+
def element_id: -> String
|
|
16
|
+
|
|
17
|
+
def element_id=: (String _) -> String
|
|
18
|
+
|
|
19
|
+
def initialize: (
|
|
20
|
+
id: String,
|
|
21
|
+
element_id: String,
|
|
22
|
+
?request_options: Courier::request_opts
|
|
23
|
+
) -> void
|
|
24
|
+
|
|
25
|
+
def to_hash: -> {
|
|
26
|
+
id: String,
|
|
27
|
+
element_id: String,
|
|
28
|
+
request_options: Courier::RequestOptions
|
|
29
|
+
}
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_put_locale_params =
|
|
4
|
+
{ id: String, locale_id: String }
|
|
5
|
+
& Courier::Internal::Type::request_parameters
|
|
6
|
+
|
|
7
|
+
class NotificationPutLocaleParams < Courier::Models::NotificationLocalePutRequest
|
|
8
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
9
|
+
include Courier::Internal::Type::RequestParameters
|
|
10
|
+
|
|
11
|
+
def id: -> String
|
|
12
|
+
|
|
13
|
+
def id=: (String _) -> String
|
|
14
|
+
|
|
15
|
+
def locale_id: -> String
|
|
16
|
+
|
|
17
|
+
def locale_id=: (String _) -> String
|
|
18
|
+
|
|
19
|
+
def initialize: (
|
|
20
|
+
id: String,
|
|
21
|
+
locale_id: String,
|
|
22
|
+
?request_options: Courier::request_opts
|
|
23
|
+
) -> void
|
|
24
|
+
|
|
25
|
+
def to_hash: -> {
|
|
26
|
+
id: String,
|
|
27
|
+
locale_id: String,
|
|
28
|
+
request_options: Courier::RequestOptions
|
|
29
|
+
}
|
|
30
|
+
end
|
|
31
|
+
end
|
|
32
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_replace_params =
|
|
4
|
+
{ id: String } & Courier::Internal::Type::request_parameters
|
|
5
|
+
|
|
6
|
+
class NotificationReplaceParams < Courier::Models::NotificationTemplateUpdateRequest
|
|
7
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
8
|
+
include Courier::Internal::Type::RequestParameters
|
|
9
|
+
|
|
10
|
+
def id: -> String
|
|
11
|
+
|
|
12
|
+
def id=: (String _) -> String
|
|
13
|
+
|
|
14
|
+
def initialize: (
|
|
15
|
+
id: String,
|
|
16
|
+
?request_options: Courier::request_opts
|
|
17
|
+
) -> void
|
|
18
|
+
|
|
19
|
+
def to_hash: -> { id: String, request_options: Courier::RequestOptions }
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
module Courier
|
|
2
2
|
module Models
|
|
3
3
|
type notification_retrieve_content_params =
|
|
4
|
-
{ id: String
|
|
4
|
+
{ id: String, version: String }
|
|
5
|
+
& Courier::Internal::Type::request_parameters
|
|
5
6
|
|
|
6
7
|
class NotificationRetrieveContentParams < Courier::Internal::Type::BaseModel
|
|
7
8
|
extend Courier::Internal::Type::RequestParameters::Converter
|
|
@@ -9,12 +10,21 @@ module Courier
|
|
|
9
10
|
|
|
10
11
|
attr_accessor id: String
|
|
11
12
|
|
|
13
|
+
attr_reader version: String?
|
|
14
|
+
|
|
15
|
+
def version=: (String) -> String
|
|
16
|
+
|
|
12
17
|
def initialize: (
|
|
13
18
|
id: String,
|
|
19
|
+
?version: String,
|
|
14
20
|
?request_options: Courier::request_opts
|
|
15
21
|
) -> void
|
|
16
22
|
|
|
17
|
-
def to_hash: -> {
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
id: String,
|
|
25
|
+
version: String,
|
|
26
|
+
request_options: Courier::RequestOptions
|
|
27
|
+
}
|
|
18
28
|
end
|
|
19
29
|
end
|
|
20
30
|
end
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_retrieve_content_response =
|
|
4
|
+
Courier::NotificationContentGetResponse | Courier::NotificationGetContent
|
|
5
|
+
|
|
6
|
+
module NotificationRetrieveContentResponse
|
|
7
|
+
extend Courier::Internal::Type::Union
|
|
8
|
+
|
|
9
|
+
def self?.variants: -> ::Array[Courier::Models::notification_retrieve_content_response]
|
|
10
|
+
end
|
|
11
|
+
end
|
|
12
|
+
end
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_retrieve_params =
|
|
4
|
+
{ id: String, version: String }
|
|
5
|
+
& Courier::Internal::Type::request_parameters
|
|
6
|
+
|
|
7
|
+
class NotificationRetrieveParams < Courier::Internal::Type::BaseModel
|
|
8
|
+
extend Courier::Internal::Type::RequestParameters::Converter
|
|
9
|
+
include Courier::Internal::Type::RequestParameters
|
|
10
|
+
|
|
11
|
+
attr_accessor id: String
|
|
12
|
+
|
|
13
|
+
attr_reader version: String?
|
|
14
|
+
|
|
15
|
+
def version=: (String) -> String
|
|
16
|
+
|
|
17
|
+
def initialize: (
|
|
18
|
+
id: String,
|
|
19
|
+
?version: String,
|
|
20
|
+
?request_options: Courier::request_opts
|
|
21
|
+
) -> void
|
|
22
|
+
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
id: String,
|
|
25
|
+
version: String,
|
|
26
|
+
request_options: Courier::RequestOptions
|
|
27
|
+
}
|
|
28
|
+
end
|
|
29
|
+
end
|
|
30
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_create_request =
|
|
4
|
+
{
|
|
5
|
+
notification: Courier::NotificationTemplatePayload,
|
|
6
|
+
state: Courier::Models::NotificationTemplateCreateRequest::state
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
class NotificationTemplateCreateRequest < Courier::Internal::Type::BaseModel
|
|
10
|
+
attr_accessor notification: Courier::NotificationTemplatePayload
|
|
11
|
+
|
|
12
|
+
attr_reader state: Courier::Models::NotificationTemplateCreateRequest::state?
|
|
13
|
+
|
|
14
|
+
def state=: (
|
|
15
|
+
Courier::Models::NotificationTemplateCreateRequest::state
|
|
16
|
+
) -> Courier::Models::NotificationTemplateCreateRequest::state
|
|
17
|
+
|
|
18
|
+
def initialize: (
|
|
19
|
+
notification: Courier::NotificationTemplatePayload,
|
|
20
|
+
?state: Courier::Models::NotificationTemplateCreateRequest::state
|
|
21
|
+
) -> void
|
|
22
|
+
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
notification: Courier::NotificationTemplatePayload,
|
|
25
|
+
state: Courier::Models::NotificationTemplateCreateRequest::state
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
type state = :DRAFT | :PUBLISHED
|
|
29
|
+
|
|
30
|
+
module State
|
|
31
|
+
extend Courier::Internal::Type::Enum
|
|
32
|
+
|
|
33
|
+
DRAFT: :DRAFT
|
|
34
|
+
PUBLISHED: :PUBLISHED
|
|
35
|
+
|
|
36
|
+
def self?.values: -> ::Array[Courier::Models::NotificationTemplateCreateRequest::state]
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_get_response =
|
|
4
|
+
{
|
|
5
|
+
created: Integer,
|
|
6
|
+
creator: String,
|
|
7
|
+
notification: Courier::NotificationTemplateGetResponse::Notification,
|
|
8
|
+
state: Courier::Models::NotificationTemplateGetResponse::state,
|
|
9
|
+
updated: Integer,
|
|
10
|
+
updater: String
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
class NotificationTemplateGetResponse < Courier::Internal::Type::BaseModel
|
|
14
|
+
attr_accessor created: Integer
|
|
15
|
+
|
|
16
|
+
attr_accessor creator: String
|
|
17
|
+
|
|
18
|
+
attr_accessor notification: Courier::NotificationTemplateGetResponse::Notification
|
|
19
|
+
|
|
20
|
+
attr_accessor state: Courier::Models::NotificationTemplateGetResponse::state
|
|
21
|
+
|
|
22
|
+
attr_reader updated: Integer?
|
|
23
|
+
|
|
24
|
+
def updated=: (Integer) -> Integer
|
|
25
|
+
|
|
26
|
+
attr_reader updater: String?
|
|
27
|
+
|
|
28
|
+
def updater=: (String) -> String
|
|
29
|
+
|
|
30
|
+
def initialize: (
|
|
31
|
+
created: Integer,
|
|
32
|
+
creator: String,
|
|
33
|
+
notification: Courier::NotificationTemplateGetResponse::Notification,
|
|
34
|
+
state: Courier::Models::NotificationTemplateGetResponse::state,
|
|
35
|
+
?updated: Integer,
|
|
36
|
+
?updater: String
|
|
37
|
+
) -> void
|
|
38
|
+
|
|
39
|
+
def to_hash: -> {
|
|
40
|
+
created: Integer,
|
|
41
|
+
creator: String,
|
|
42
|
+
notification: Courier::NotificationTemplateGetResponse::Notification,
|
|
43
|
+
state: Courier::Models::NotificationTemplateGetResponse::state,
|
|
44
|
+
updated: Integer,
|
|
45
|
+
updater: String
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
type notification = { id: String }
|
|
49
|
+
|
|
50
|
+
class Notification < Courier::Models::NotificationTemplatePayload
|
|
51
|
+
def id: -> String
|
|
52
|
+
|
|
53
|
+
def id=: (String _) -> String
|
|
54
|
+
|
|
55
|
+
def initialize: (id: String) -> void
|
|
56
|
+
|
|
57
|
+
def to_hash: -> { id: String }
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
type state = :DRAFT | :PUBLISHED
|
|
61
|
+
|
|
62
|
+
module State
|
|
63
|
+
extend Courier::Internal::Type::Enum
|
|
64
|
+
|
|
65
|
+
DRAFT: :DRAFT
|
|
66
|
+
PUBLISHED: :PUBLISHED
|
|
67
|
+
|
|
68
|
+
def self?.values: -> ::Array[Courier::Models::NotificationTemplateGetResponse::state]
|
|
69
|
+
end
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
end
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_mutation_response =
|
|
4
|
+
{
|
|
5
|
+
notification: Courier::NotificationTemplateMutationResponse::Notification,
|
|
6
|
+
state: Courier::Models::NotificationTemplateMutationResponse::state
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
class NotificationTemplateMutationResponse < Courier::Internal::Type::BaseModel
|
|
10
|
+
attr_accessor notification: Courier::NotificationTemplateMutationResponse::Notification
|
|
11
|
+
|
|
12
|
+
attr_accessor state: Courier::Models::NotificationTemplateMutationResponse::state
|
|
13
|
+
|
|
14
|
+
def initialize: (
|
|
15
|
+
notification: Courier::NotificationTemplateMutationResponse::Notification,
|
|
16
|
+
state: Courier::Models::NotificationTemplateMutationResponse::state
|
|
17
|
+
) -> void
|
|
18
|
+
|
|
19
|
+
def to_hash: -> {
|
|
20
|
+
notification: Courier::NotificationTemplateMutationResponse::Notification,
|
|
21
|
+
state: Courier::Models::NotificationTemplateMutationResponse::state
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
type notification = { id: String }
|
|
25
|
+
|
|
26
|
+
class Notification < Courier::Internal::Type::BaseModel
|
|
27
|
+
attr_accessor id: String
|
|
28
|
+
|
|
29
|
+
def initialize: (id: String) -> void
|
|
30
|
+
|
|
31
|
+
def to_hash: -> { id: String }
|
|
32
|
+
end
|
|
33
|
+
|
|
34
|
+
type state = :DRAFT | :PUBLISHED
|
|
35
|
+
|
|
36
|
+
module State
|
|
37
|
+
extend Courier::Internal::Type::Enum
|
|
38
|
+
|
|
39
|
+
DRAFT: :DRAFT
|
|
40
|
+
PUBLISHED: :PUBLISHED
|
|
41
|
+
|
|
42
|
+
def self?.values: -> ::Array[Courier::Models::NotificationTemplateMutationResponse::state]
|
|
43
|
+
end
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
end
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_payload =
|
|
4
|
+
{
|
|
5
|
+
brand: Courier::NotificationTemplatePayload::Brand?,
|
|
6
|
+
content: Courier::ElementalContent,
|
|
7
|
+
name: String,
|
|
8
|
+
routing: Courier::NotificationTemplatePayload::Routing?,
|
|
9
|
+
subscription: Courier::NotificationTemplatePayload::Subscription?,
|
|
10
|
+
tags: ::Array[String]
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
class NotificationTemplatePayload < Courier::Internal::Type::BaseModel
|
|
14
|
+
attr_accessor brand: Courier::NotificationTemplatePayload::Brand?
|
|
15
|
+
|
|
16
|
+
attr_accessor content: Courier::ElementalContent
|
|
17
|
+
|
|
18
|
+
attr_accessor name: String
|
|
19
|
+
|
|
20
|
+
attr_accessor routing: Courier::NotificationTemplatePayload::Routing?
|
|
21
|
+
|
|
22
|
+
attr_accessor subscription: Courier::NotificationTemplatePayload::Subscription?
|
|
23
|
+
|
|
24
|
+
attr_accessor tags: ::Array[String]
|
|
25
|
+
|
|
26
|
+
def initialize: (
|
|
27
|
+
brand: Courier::NotificationTemplatePayload::Brand?,
|
|
28
|
+
content: Courier::ElementalContent,
|
|
29
|
+
name: String,
|
|
30
|
+
routing: Courier::NotificationTemplatePayload::Routing?,
|
|
31
|
+
subscription: Courier::NotificationTemplatePayload::Subscription?,
|
|
32
|
+
tags: ::Array[String]
|
|
33
|
+
) -> void
|
|
34
|
+
|
|
35
|
+
def to_hash: -> {
|
|
36
|
+
brand: Courier::NotificationTemplatePayload::Brand?,
|
|
37
|
+
content: Courier::ElementalContent,
|
|
38
|
+
name: String,
|
|
39
|
+
routing: Courier::NotificationTemplatePayload::Routing?,
|
|
40
|
+
subscription: Courier::NotificationTemplatePayload::Subscription?,
|
|
41
|
+
tags: ::Array[String]
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
type brand = { id: String }
|
|
45
|
+
|
|
46
|
+
class Brand < Courier::Internal::Type::BaseModel
|
|
47
|
+
attr_accessor id: String
|
|
48
|
+
|
|
49
|
+
def initialize: (id: String) -> void
|
|
50
|
+
|
|
51
|
+
def to_hash: -> { id: String }
|
|
52
|
+
end
|
|
53
|
+
|
|
54
|
+
type routing = { strategy_id: String }
|
|
55
|
+
|
|
56
|
+
class Routing < Courier::Internal::Type::BaseModel
|
|
57
|
+
attr_accessor strategy_id: String
|
|
58
|
+
|
|
59
|
+
def initialize: (strategy_id: String) -> void
|
|
60
|
+
|
|
61
|
+
def to_hash: -> { strategy_id: String }
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
type subscription = { topic_id: String }
|
|
65
|
+
|
|
66
|
+
class Subscription < Courier::Internal::Type::BaseModel
|
|
67
|
+
attr_accessor topic_id: String
|
|
68
|
+
|
|
69
|
+
def initialize: (topic_id: String) -> void
|
|
70
|
+
|
|
71
|
+
def to_hash: -> { topic_id: String }
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
end
|
|
75
|
+
end
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_publish_request = { version: String }
|
|
4
|
+
|
|
5
|
+
class NotificationTemplatePublishRequest < Courier::Internal::Type::BaseModel
|
|
6
|
+
attr_reader version: String?
|
|
7
|
+
|
|
8
|
+
def version=: (String) -> String
|
|
9
|
+
|
|
10
|
+
def initialize: (?version: String) -> void
|
|
11
|
+
|
|
12
|
+
def to_hash: -> { version: String }
|
|
13
|
+
end
|
|
14
|
+
end
|
|
15
|
+
end
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_state = :DRAFT | :PUBLISHED
|
|
4
|
+
|
|
5
|
+
module NotificationTemplateState
|
|
6
|
+
extend Courier::Internal::Type::Enum
|
|
7
|
+
|
|
8
|
+
DRAFT: :DRAFT
|
|
9
|
+
PUBLISHED: :PUBLISHED
|
|
10
|
+
|
|
11
|
+
def self?.values: -> ::Array[Courier::Models::notification_template_state]
|
|
12
|
+
end
|
|
13
|
+
end
|
|
14
|
+
end
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_summary =
|
|
4
|
+
{
|
|
5
|
+
id: String,
|
|
6
|
+
created: Integer,
|
|
7
|
+
creator: String,
|
|
8
|
+
name: String,
|
|
9
|
+
state: Courier::Models::NotificationTemplateSummary::state,
|
|
10
|
+
tags: ::Array[String],
|
|
11
|
+
updated: Integer,
|
|
12
|
+
updater: String
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
class NotificationTemplateSummary < Courier::Internal::Type::BaseModel
|
|
16
|
+
attr_accessor id: String
|
|
17
|
+
|
|
18
|
+
attr_accessor created: Integer
|
|
19
|
+
|
|
20
|
+
attr_accessor creator: String
|
|
21
|
+
|
|
22
|
+
attr_accessor name: String
|
|
23
|
+
|
|
24
|
+
attr_accessor state: Courier::Models::NotificationTemplateSummary::state
|
|
25
|
+
|
|
26
|
+
attr_accessor tags: ::Array[String]
|
|
27
|
+
|
|
28
|
+
attr_reader updated: Integer?
|
|
29
|
+
|
|
30
|
+
def updated=: (Integer) -> Integer
|
|
31
|
+
|
|
32
|
+
attr_reader updater: String?
|
|
33
|
+
|
|
34
|
+
def updater=: (String) -> String
|
|
35
|
+
|
|
36
|
+
def initialize: (
|
|
37
|
+
id: String,
|
|
38
|
+
created: Integer,
|
|
39
|
+
creator: String,
|
|
40
|
+
name: String,
|
|
41
|
+
state: Courier::Models::NotificationTemplateSummary::state,
|
|
42
|
+
tags: ::Array[String],
|
|
43
|
+
?updated: Integer,
|
|
44
|
+
?updater: String
|
|
45
|
+
) -> void
|
|
46
|
+
|
|
47
|
+
def to_hash: -> {
|
|
48
|
+
id: String,
|
|
49
|
+
created: Integer,
|
|
50
|
+
creator: String,
|
|
51
|
+
name: String,
|
|
52
|
+
state: Courier::Models::NotificationTemplateSummary::state,
|
|
53
|
+
tags: ::Array[String],
|
|
54
|
+
updated: Integer,
|
|
55
|
+
updater: String
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
type state = :DRAFT | :PUBLISHED
|
|
59
|
+
|
|
60
|
+
module State
|
|
61
|
+
extend Courier::Internal::Type::Enum
|
|
62
|
+
|
|
63
|
+
DRAFT: :DRAFT
|
|
64
|
+
PUBLISHED: :PUBLISHED
|
|
65
|
+
|
|
66
|
+
def self?.values: -> ::Array[Courier::Models::NotificationTemplateSummary::state]
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
end
|
|
70
|
+
end
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_update_request =
|
|
4
|
+
{
|
|
5
|
+
notification: Courier::NotificationTemplatePayload,
|
|
6
|
+
state: Courier::Models::NotificationTemplateUpdateRequest::state
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
class NotificationTemplateUpdateRequest < Courier::Internal::Type::BaseModel
|
|
10
|
+
attr_accessor notification: Courier::NotificationTemplatePayload
|
|
11
|
+
|
|
12
|
+
attr_reader state: Courier::Models::NotificationTemplateUpdateRequest::state?
|
|
13
|
+
|
|
14
|
+
def state=: (
|
|
15
|
+
Courier::Models::NotificationTemplateUpdateRequest::state
|
|
16
|
+
) -> Courier::Models::NotificationTemplateUpdateRequest::state
|
|
17
|
+
|
|
18
|
+
def initialize: (
|
|
19
|
+
notification: Courier::NotificationTemplatePayload,
|
|
20
|
+
?state: Courier::Models::NotificationTemplateUpdateRequest::state
|
|
21
|
+
) -> void
|
|
22
|
+
|
|
23
|
+
def to_hash: -> {
|
|
24
|
+
notification: Courier::NotificationTemplatePayload,
|
|
25
|
+
state: Courier::Models::NotificationTemplateUpdateRequest::state
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
type state = :DRAFT | :PUBLISHED
|
|
29
|
+
|
|
30
|
+
module State
|
|
31
|
+
extend Courier::Internal::Type::Enum
|
|
32
|
+
|
|
33
|
+
DRAFT: :DRAFT
|
|
34
|
+
PUBLISHED: :PUBLISHED
|
|
35
|
+
|
|
36
|
+
def self?.values: -> ::Array[Courier::Models::NotificationTemplateUpdateRequest::state]
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
|
40
|
+
end
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
module Courier
|
|
2
|
+
module Models
|
|
3
|
+
type notification_template_version_list_response =
|
|
4
|
+
{ paging: Courier::Paging, versions: ::Array[Courier::VersionNode] }
|
|
5
|
+
|
|
6
|
+
class NotificationTemplateVersionListResponse < Courier::Internal::Type::BaseModel
|
|
7
|
+
attr_accessor paging: Courier::Paging
|
|
8
|
+
|
|
9
|
+
attr_accessor versions: ::Array[Courier::VersionNode]
|
|
10
|
+
|
|
11
|
+
def initialize: (
|
|
12
|
+
paging: Courier::Paging,
|
|
13
|
+
versions: ::Array[Courier::VersionNode]
|
|
14
|
+
) -> void
|
|
15
|
+
|
|
16
|
+
def to_hash: -> {
|
|
17
|
+
paging: Courier::Paging,
|
|
18
|
+
versions: ::Array[Courier::VersionNode]
|
|
19
|
+
}
|
|
20
|
+
end
|
|
21
|
+
end
|
|
22
|
+
end
|