trycourier 4.16.0 → 4.17.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.
Files changed (77) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +8 -0
  3. data/lib/courier/client.rb +4 -0
  4. data/lib/courier/models/preference_section_archive_params.rb +20 -0
  5. data/lib/courier/models/preference_section_create_params.rb +14 -0
  6. data/lib/courier/models/preference_section_create_request.rb +36 -0
  7. data/lib/courier/models/preference_section_get_response.rb +83 -0
  8. data/lib/courier/models/preference_section_list_params.rb +14 -0
  9. data/lib/courier/models/preference_section_list_response.rb +18 -0
  10. data/lib/courier/models/preference_section_publish_params.rb +14 -0
  11. data/lib/courier/models/preference_section_replace_params.rb +20 -0
  12. data/lib/courier/models/preference_section_replace_request.rb +37 -0
  13. data/lib/courier/models/preference_section_retrieve_params.rb +20 -0
  14. data/lib/courier/models/preference_sections/topic_archive_params.rb +28 -0
  15. data/lib/courier/models/preference_sections/topic_create_params.rb +22 -0
  16. data/lib/courier/models/preference_sections/topic_list_params.rb +22 -0
  17. data/lib/courier/models/preference_sections/topic_replace_params.rb +28 -0
  18. data/lib/courier/models/preference_sections/topic_retrieve_params.rb +28 -0
  19. data/lib/courier/models/preference_topic_create_request.rb +93 -0
  20. data/lib/courier/models/preference_topic_get_response.rb +124 -0
  21. data/lib/courier/models/preference_topic_list_response.rb +17 -0
  22. data/lib/courier/models/preference_topic_replace_request.rb +90 -0
  23. data/lib/courier/models/publish_preferences_response.rb +51 -0
  24. data/lib/courier/models.rb +32 -0
  25. data/lib/courier/resources/preference_sections/topics.rb +173 -0
  26. data/lib/courier/resources/preference_sections.rb +155 -0
  27. data/lib/courier/version.rb +1 -1
  28. data/lib/courier.rb +22 -0
  29. data/rbi/courier/client.rbi +3 -0
  30. data/rbi/courier/models/preference_section_archive_params.rbi +38 -0
  31. data/rbi/courier/models/preference_section_create_params.rbi +30 -0
  32. data/rbi/courier/models/preference_section_create_request.rbi +61 -0
  33. data/rbi/courier/models/preference_section_get_response.rbi +106 -0
  34. data/rbi/courier/models/preference_section_list_params.rbi +30 -0
  35. data/rbi/courier/models/preference_section_list_response.rbi +35 -0
  36. data/rbi/courier/models/preference_section_publish_params.rbi +30 -0
  37. data/rbi/courier/models/preference_section_replace_params.rbi +38 -0
  38. data/rbi/courier/models/preference_section_replace_request.rbi +62 -0
  39. data/rbi/courier/models/preference_section_retrieve_params.rbi +38 -0
  40. data/rbi/courier/models/preference_sections/topic_archive_params.rbi +48 -0
  41. data/rbi/courier/models/preference_sections/topic_create_params.rbi +40 -0
  42. data/rbi/courier/models/preference_sections/topic_list_params.rbi +40 -0
  43. data/rbi/courier/models/preference_sections/topic_replace_params.rbi +48 -0
  44. data/rbi/courier/models/preference_sections/topic_retrieve_params.rbi +48 -0
  45. data/rbi/courier/models/preference_topic_create_request.rbi +181 -0
  46. data/rbi/courier/models/preference_topic_get_response.rbi +209 -0
  47. data/rbi/courier/models/preference_topic_list_response.rbi +35 -0
  48. data/rbi/courier/models/preference_topic_replace_request.rbi +180 -0
  49. data/rbi/courier/models/publish_preferences_response.rbi +70 -0
  50. data/rbi/courier/models.rbi +38 -0
  51. data/rbi/courier/resources/preference_sections/topics.rbi +149 -0
  52. data/rbi/courier/resources/preference_sections.rbi +113 -0
  53. data/sig/courier/client.rbs +2 -0
  54. data/sig/courier/models/preference_section_archive_params.rbs +23 -0
  55. data/sig/courier/models/preference_section_create_params.rbs +15 -0
  56. data/sig/courier/models/preference_section_create_request.rbs +30 -0
  57. data/sig/courier/models/preference_section_get_response.rbs +60 -0
  58. data/sig/courier/models/preference_section_list_params.rbs +15 -0
  59. data/sig/courier/models/preference_section_list_response.rbs +18 -0
  60. data/sig/courier/models/preference_section_publish_params.rbs +15 -0
  61. data/sig/courier/models/preference_section_replace_params.rbs +25 -0
  62. data/sig/courier/models/preference_section_replace_request.rbs +30 -0
  63. data/sig/courier/models/preference_section_retrieve_params.rbs +23 -0
  64. data/sig/courier/models/preference_sections/topic_archive_params.rbs +30 -0
  65. data/sig/courier/models/preference_sections/topic_create_params.rbs +27 -0
  66. data/sig/courier/models/preference_sections/topic_list_params.rbs +25 -0
  67. data/sig/courier/models/preference_sections/topic_replace_params.rbs +34 -0
  68. data/sig/courier/models/preference_sections/topic_retrieve_params.rbs +30 -0
  69. data/sig/courier/models/preference_topic_create_request.rbs +68 -0
  70. data/sig/courier/models/preference_topic_get_response.rbs +93 -0
  71. data/sig/courier/models/preference_topic_list_response.rbs +16 -0
  72. data/sig/courier/models/preference_topic_replace_request.rbs +68 -0
  73. data/sig/courier/models/publish_preferences_response.rbs +40 -0
  74. data/sig/courier/models.rbs +32 -0
  75. data/sig/courier/resources/preference_sections/topics.rbs +49 -0
  76. data/sig/courier/resources/preference_sections.rbs +42 -0
  77. metadata +68 -2
data/lib/courier.rb CHANGED
@@ -72,6 +72,10 @@ require_relative "courier/models/notification_template_publish_request"
72
72
  require_relative "courier/models/notification_element_put_request"
73
73
  require_relative "courier/models/notification_template_update_request"
74
74
  require_relative "courier/models/notification_template_payload"
75
+ require_relative "courier/models/preference_section_create_request"
76
+ require_relative "courier/models/preference_section_replace_request"
77
+ require_relative "courier/models/preference_topic_create_request"
78
+ require_relative "courier/models/preference_topic_replace_request"
75
79
  require_relative "courier/models/routing_strategy_create_request"
76
80
  require_relative "courier/models/routing_strategy_replace_request"
77
81
  require_relative "courier/models/base_template_tenant_association"
@@ -275,7 +279,22 @@ require_relative "courier/models/pagerduty_recipient"
275
279
  require_relative "courier/models/paging"
276
280
  require_relative "courier/models/post_tenant_template_publish_response"
277
281
  require_relative "courier/models/preference"
282
+ require_relative "courier/models/preference_section_archive_params"
283
+ require_relative "courier/models/preference_section_create_params"
284
+ require_relative "courier/models/preference_section_get_response"
285
+ require_relative "courier/models/preference_section_list_params"
286
+ require_relative "courier/models/preference_section_list_response"
287
+ require_relative "courier/models/preference_section_publish_params"
288
+ require_relative "courier/models/preference_section_replace_params"
289
+ require_relative "courier/models/preference_section_retrieve_params"
290
+ require_relative "courier/models/preference_sections/topic_archive_params"
291
+ require_relative "courier/models/preference_sections/topic_create_params"
292
+ require_relative "courier/models/preference_sections/topic_list_params"
293
+ require_relative "courier/models/preference_sections/topic_replace_params"
294
+ require_relative "courier/models/preference_sections/topic_retrieve_params"
278
295
  require_relative "courier/models/preference_status"
296
+ require_relative "courier/models/preference_topic_get_response"
297
+ require_relative "courier/models/preference_topic_list_response"
279
298
  require_relative "courier/models/profile_create_params"
280
299
  require_relative "courier/models/profile_create_response"
281
300
  require_relative "courier/models/profile_delete_params"
@@ -300,6 +319,7 @@ require_relative "courier/models/providers/catalog_list_params"
300
319
  require_relative "courier/models/providers/catalog_list_response"
301
320
  require_relative "courier/models/providers_catalog_entry"
302
321
  require_relative "courier/models/provider_update_params"
322
+ require_relative "courier/models/publish_preferences_response"
303
323
  require_relative "courier/models/put_subscriptions_recipient"
304
324
  require_relative "courier/models/put_tenant_template_response"
305
325
  require_relative "courier/models/recipient_preferences"
@@ -408,6 +428,8 @@ require_relative "courier/resources/lists/subscriptions"
408
428
  require_relative "courier/resources/messages"
409
429
  require_relative "courier/resources/notifications"
410
430
  require_relative "courier/resources/notifications/checks"
431
+ require_relative "courier/resources/preference_sections"
432
+ require_relative "courier/resources/preference_sections/topics"
411
433
  require_relative "courier/resources/profiles"
412
434
  require_relative "courier/resources/profiles/lists"
413
435
  require_relative "courier/resources/providers"
@@ -61,6 +61,9 @@ module Courier
61
61
  sig { returns(Courier::Resources::RoutingStrategies) }
62
62
  attr_reader :routing_strategies
63
63
 
64
+ sig { returns(Courier::Resources::PreferenceSections) }
65
+ attr_reader :preference_sections
66
+
64
67
  sig { returns(Courier::Resources::Profiles) }
65
68
  attr_reader :profiles
66
69
 
@@ -0,0 +1,38 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionArchiveParams < 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::PreferenceSectionArchiveParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig { returns(String) }
18
+ attr_accessor :section_id
19
+
20
+ sig do
21
+ params(
22
+ section_id: String,
23
+ request_options: Courier::RequestOptions::OrHash
24
+ ).returns(T.attached_class)
25
+ end
26
+ def self.new(section_id:, request_options: {})
27
+ end
28
+
29
+ sig do
30
+ override.returns(
31
+ { section_id: String, request_options: Courier::RequestOptions }
32
+ )
33
+ end
34
+ def to_hash
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,30 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionCreateParams < Courier::Models::PreferenceSectionCreateRequest
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::PreferenceSectionCreateParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig do
18
+ params(request_options: Courier::RequestOptions::OrHash).returns(
19
+ T.attached_class
20
+ )
21
+ end
22
+ def self.new(request_options: {})
23
+ end
24
+
25
+ sig { override.returns({ request_options: Courier::RequestOptions }) }
26
+ def to_hash
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,61 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionCreateRequest < Courier::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ Courier::PreferenceSectionCreateRequest,
10
+ Courier::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ # Human-readable name for the section.
15
+ sig { returns(String) }
16
+ attr_accessor :name
17
+
18
+ # Whether the section defines custom routing for its topics.
19
+ sig { returns(T.nilable(T::Boolean)) }
20
+ attr_accessor :has_custom_routing
21
+
22
+ # Default channels for the section. Defaults to empty if omitted.
23
+ sig do
24
+ returns(T.nilable(T::Array[Courier::ChannelClassification::OrSymbol]))
25
+ end
26
+ attr_accessor :routing_options
27
+
28
+ # Request body for creating a preference section.
29
+ sig do
30
+ params(
31
+ name: String,
32
+ has_custom_routing: T.nilable(T::Boolean),
33
+ routing_options:
34
+ T.nilable(T::Array[Courier::ChannelClassification::OrSymbol])
35
+ ).returns(T.attached_class)
36
+ end
37
+ def self.new(
38
+ # Human-readable name for the section.
39
+ name:,
40
+ # Whether the section defines custom routing for its topics.
41
+ has_custom_routing: nil,
42
+ # Default channels for the section. Defaults to empty if omitted.
43
+ routing_options: nil
44
+ )
45
+ end
46
+
47
+ sig do
48
+ override.returns(
49
+ {
50
+ name: String,
51
+ has_custom_routing: T.nilable(T::Boolean),
52
+ routing_options:
53
+ T.nilable(T::Array[Courier::ChannelClassification::OrSymbol])
54
+ }
55
+ )
56
+ end
57
+ def to_hash
58
+ end
59
+ end
60
+ end
61
+ end
@@ -0,0 +1,106 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionGetResponse < Courier::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ Courier::PreferenceSectionGetResponse,
10
+ Courier::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ # The preference section id.
15
+ sig { returns(String) }
16
+ attr_accessor :id
17
+
18
+ # ISO-8601 timestamp of when the section was created.
19
+ sig { returns(String) }
20
+ attr_accessor :created
21
+
22
+ # Whether the section defines custom routing for its topics.
23
+ sig { returns(T::Boolean) }
24
+ attr_accessor :has_custom_routing
25
+
26
+ # Human-readable name.
27
+ sig { returns(String) }
28
+ attr_accessor :name
29
+
30
+ # Default channels for the section. May be empty.
31
+ sig { returns(T::Array[Courier::ChannelClassification::TaggedSymbol]) }
32
+ attr_accessor :routing_options
33
+
34
+ # The topics contained in this section.
35
+ sig { returns(T::Array[Courier::PreferenceTopicGetResponse]) }
36
+ attr_accessor :topics
37
+
38
+ # Id of the creator.
39
+ sig { returns(T.nilable(String)) }
40
+ attr_accessor :creator
41
+
42
+ # ISO-8601 timestamp of the last update.
43
+ sig { returns(T.nilable(String)) }
44
+ attr_accessor :updated
45
+
46
+ # Id of the last updater.
47
+ sig { returns(T.nilable(String)) }
48
+ attr_accessor :updater
49
+
50
+ # A preference section in your workspace, including its topics.
51
+ sig do
52
+ params(
53
+ id: String,
54
+ created: String,
55
+ has_custom_routing: T::Boolean,
56
+ name: String,
57
+ routing_options: T::Array[Courier::ChannelClassification::OrSymbol],
58
+ topics: T::Array[Courier::PreferenceTopicGetResponse::OrHash],
59
+ creator: T.nilable(String),
60
+ updated: T.nilable(String),
61
+ updater: T.nilable(String)
62
+ ).returns(T.attached_class)
63
+ end
64
+ def self.new(
65
+ # The preference section id.
66
+ id:,
67
+ # ISO-8601 timestamp of when the section was created.
68
+ created:,
69
+ # Whether the section defines custom routing for its topics.
70
+ has_custom_routing:,
71
+ # Human-readable name.
72
+ name:,
73
+ # Default channels for the section. May be empty.
74
+ routing_options:,
75
+ # The topics contained in this section.
76
+ topics:,
77
+ # Id of the creator.
78
+ creator: nil,
79
+ # ISO-8601 timestamp of the last update.
80
+ updated: nil,
81
+ # Id of the last updater.
82
+ updater: nil
83
+ )
84
+ end
85
+
86
+ sig do
87
+ override.returns(
88
+ {
89
+ id: String,
90
+ created: String,
91
+ has_custom_routing: T::Boolean,
92
+ name: String,
93
+ routing_options:
94
+ T::Array[Courier::ChannelClassification::TaggedSymbol],
95
+ topics: T::Array[Courier::PreferenceTopicGetResponse],
96
+ creator: T.nilable(String),
97
+ updated: T.nilable(String),
98
+ updater: T.nilable(String)
99
+ }
100
+ )
101
+ end
102
+ def to_hash
103
+ end
104
+ end
105
+ end
106
+ end
@@ -0,0 +1,30 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionListParams < 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::PreferenceSectionListParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig do
18
+ params(request_options: Courier::RequestOptions::OrHash).returns(
19
+ T.attached_class
20
+ )
21
+ end
22
+ def self.new(request_options: {})
23
+ end
24
+
25
+ sig { override.returns({ request_options: Courier::RequestOptions }) }
26
+ def to_hash
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,35 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionListResponse < Courier::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ Courier::PreferenceSectionListResponse,
10
+ Courier::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ sig { returns(T::Array[Courier::PreferenceSectionGetResponse]) }
15
+ attr_accessor :results
16
+
17
+ # The workspace's preference sections, each with its topics.
18
+ sig do
19
+ params(
20
+ results: T::Array[Courier::PreferenceSectionGetResponse::OrHash]
21
+ ).returns(T.attached_class)
22
+ end
23
+ def self.new(results:)
24
+ end
25
+
26
+ sig do
27
+ override.returns(
28
+ { results: T::Array[Courier::PreferenceSectionGetResponse] }
29
+ )
30
+ end
31
+ def to_hash
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,30 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionPublishParams < 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::PreferenceSectionPublishParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig do
18
+ params(request_options: Courier::RequestOptions::OrHash).returns(
19
+ T.attached_class
20
+ )
21
+ end
22
+ def self.new(request_options: {})
23
+ end
24
+
25
+ sig { override.returns({ request_options: Courier::RequestOptions }) }
26
+ def to_hash
27
+ end
28
+ end
29
+ end
30
+ end
@@ -0,0 +1,38 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionReplaceParams < Courier::Models::PreferenceSectionReplaceRequest
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::PreferenceSectionReplaceParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig { returns(String) }
18
+ attr_accessor :section_id
19
+
20
+ sig do
21
+ params(
22
+ section_id: String,
23
+ request_options: Courier::RequestOptions::OrHash
24
+ ).returns(T.attached_class)
25
+ end
26
+ def self.new(section_id:, request_options: {})
27
+ end
28
+
29
+ sig do
30
+ override.returns(
31
+ { section_id: String, request_options: Courier::RequestOptions }
32
+ )
33
+ end
34
+ def to_hash
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,62 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionReplaceRequest < Courier::Internal::Type::BaseModel
6
+ OrHash =
7
+ T.type_alias do
8
+ T.any(
9
+ Courier::PreferenceSectionReplaceRequest,
10
+ Courier::Internal::AnyHash
11
+ )
12
+ end
13
+
14
+ # Human-readable name for the section.
15
+ sig { returns(String) }
16
+ attr_accessor :name
17
+
18
+ # Whether the section defines custom routing for its topics.
19
+ sig { returns(T.nilable(T::Boolean)) }
20
+ attr_accessor :has_custom_routing
21
+
22
+ # Default channels for the section. Omit to clear.
23
+ sig do
24
+ returns(T.nilable(T::Array[Courier::ChannelClassification::OrSymbol]))
25
+ end
26
+ attr_accessor :routing_options
27
+
28
+ # Request body for replacing a preference section. Full document replacement;
29
+ # missing optional fields are cleared.
30
+ sig do
31
+ params(
32
+ name: String,
33
+ has_custom_routing: T.nilable(T::Boolean),
34
+ routing_options:
35
+ T.nilable(T::Array[Courier::ChannelClassification::OrSymbol])
36
+ ).returns(T.attached_class)
37
+ end
38
+ def self.new(
39
+ # Human-readable name for the section.
40
+ name:,
41
+ # Whether the section defines custom routing for its topics.
42
+ has_custom_routing: nil,
43
+ # Default channels for the section. Omit to clear.
44
+ routing_options: nil
45
+ )
46
+ end
47
+
48
+ sig do
49
+ override.returns(
50
+ {
51
+ name: String,
52
+ has_custom_routing: T.nilable(T::Boolean),
53
+ routing_options:
54
+ T.nilable(T::Array[Courier::ChannelClassification::OrSymbol])
55
+ }
56
+ )
57
+ end
58
+ def to_hash
59
+ end
60
+ end
61
+ end
62
+ end
@@ -0,0 +1,38 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ class PreferenceSectionRetrieveParams < 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::PreferenceSectionRetrieveParams,
13
+ Courier::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig { returns(String) }
18
+ attr_accessor :section_id
19
+
20
+ sig do
21
+ params(
22
+ section_id: String,
23
+ request_options: Courier::RequestOptions::OrHash
24
+ ).returns(T.attached_class)
25
+ end
26
+ def self.new(section_id:, request_options: {})
27
+ end
28
+
29
+ sig do
30
+ override.returns(
31
+ { section_id: String, request_options: Courier::RequestOptions }
32
+ )
33
+ end
34
+ def to_hash
35
+ end
36
+ end
37
+ end
38
+ end
@@ -0,0 +1,48 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ module PreferenceSections
6
+ class TopicArchiveParams < Courier::Internal::Type::BaseModel
7
+ extend Courier::Internal::Type::RequestParameters::Converter
8
+ include Courier::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(
13
+ Courier::PreferenceSections::TopicArchiveParams,
14
+ Courier::Internal::AnyHash
15
+ )
16
+ end
17
+
18
+ sig { returns(String) }
19
+ attr_accessor :section_id
20
+
21
+ sig { returns(String) }
22
+ attr_accessor :topic_id
23
+
24
+ sig do
25
+ params(
26
+ section_id: String,
27
+ topic_id: String,
28
+ request_options: Courier::RequestOptions::OrHash
29
+ ).returns(T.attached_class)
30
+ end
31
+ def self.new(section_id:, topic_id:, request_options: {})
32
+ end
33
+
34
+ sig do
35
+ override.returns(
36
+ {
37
+ section_id: String,
38
+ topic_id: String,
39
+ request_options: Courier::RequestOptions
40
+ }
41
+ )
42
+ end
43
+ def to_hash
44
+ end
45
+ end
46
+ end
47
+ end
48
+ end
@@ -0,0 +1,40 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ module PreferenceSections
6
+ class TopicCreateParams < Courier::Models::PreferenceTopicCreateRequest
7
+ extend Courier::Internal::Type::RequestParameters::Converter
8
+ include Courier::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(
13
+ Courier::PreferenceSections::TopicCreateParams,
14
+ Courier::Internal::AnyHash
15
+ )
16
+ end
17
+
18
+ sig { returns(String) }
19
+ attr_accessor :section_id
20
+
21
+ sig do
22
+ params(
23
+ section_id: String,
24
+ request_options: Courier::RequestOptions::OrHash
25
+ ).returns(T.attached_class)
26
+ end
27
+ def self.new(section_id:, request_options: {})
28
+ end
29
+
30
+ sig do
31
+ override.returns(
32
+ { section_id: String, request_options: Courier::RequestOptions }
33
+ )
34
+ end
35
+ def to_hash
36
+ end
37
+ end
38
+ end
39
+ end
40
+ end
@@ -0,0 +1,40 @@
1
+ # typed: strong
2
+
3
+ module Courier
4
+ module Models
5
+ module PreferenceSections
6
+ class TopicListParams < Courier::Internal::Type::BaseModel
7
+ extend Courier::Internal::Type::RequestParameters::Converter
8
+ include Courier::Internal::Type::RequestParameters
9
+
10
+ OrHash =
11
+ T.type_alias do
12
+ T.any(
13
+ Courier::PreferenceSections::TopicListParams,
14
+ Courier::Internal::AnyHash
15
+ )
16
+ end
17
+
18
+ sig { returns(String) }
19
+ attr_accessor :section_id
20
+
21
+ sig do
22
+ params(
23
+ section_id: String,
24
+ request_options: Courier::RequestOptions::OrHash
25
+ ).returns(T.attached_class)
26
+ end
27
+ def self.new(section_id:, request_options: {})
28
+ end
29
+
30
+ sig do
31
+ override.returns(
32
+ { section_id: String, request_options: Courier::RequestOptions }
33
+ )
34
+ end
35
+ def to_hash
36
+ end
37
+ end
38
+ end
39
+ end
40
+ end