moderation_api 3.2.0 → 3.4.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 (64) hide show
  1. checksums.yaml +4 -4
  2. data/lib/moderation_api/authors.rb +759 -0
  3. data/lib/moderation_api/content.rb +506 -0
  4. data/lib/moderation_api/items.rb +4 -4
  5. data/lib/moderation_api/models/components/queueitem.rb +2 -2
  6. data/lib/moderation_api/models/operations/allowcontent_request.rb +45 -0
  7. data/lib/moderation_api/models/operations/allowcontent_request.rbi +26 -0
  8. data/lib/moderation_api/models/operations/allowcontent_requestbody.rb +67 -0
  9. data/lib/moderation_api/models/operations/allowcontent_requestbody.rbi +32 -0
  10. data/lib/moderation_api/models/operations/allowcontent_response.rb +51 -0
  11. data/lib/moderation_api/models/operations/allowcontent_response.rbi +32 -0
  12. data/lib/moderation_api/models/operations/allowcontent_responsebody.rb +35 -0
  13. data/lib/moderation_api/models/operations/allowcontent_responsebody.rbi +14 -0
  14. data/lib/moderation_api/models/operations/blockauthor_request.rb +45 -0
  15. data/lib/moderation_api/models/operations/blockauthor_request.rbi +26 -0
  16. data/lib/moderation_api/models/operations/blockauthor_requestbody.rb +35 -0
  17. data/lib/moderation_api/models/operations/blockauthor_requestbody.rbi +14 -0
  18. data/lib/moderation_api/models/operations/blockauthor_response.rb +51 -0
  19. data/lib/moderation_api/models/operations/blockauthor_response.rbi +32 -0
  20. data/lib/moderation_api/models/operations/blockauthor_responsebody.rb +35 -0
  21. data/lib/moderation_api/models/operations/blockauthor_responsebody.rbi +14 -0
  22. data/lib/moderation_api/models/operations/deletewordlist_request.rb +39 -0
  23. data/lib/moderation_api/models/operations/deletewordlist_request.rbi +20 -0
  24. data/lib/moderation_api/models/operations/deletewordlist_response.rb +51 -0
  25. data/lib/moderation_api/models/operations/deletewordlist_response.rbi +32 -0
  26. data/lib/moderation_api/models/operations/deletewordlist_responsebody.rb +47 -0
  27. data/lib/moderation_api/models/operations/deletewordlist_responsebody.rbi +26 -0
  28. data/lib/moderation_api/models/operations/executeaction_requestbody.rb +29 -2
  29. data/lib/moderation_api/models/operations/executeaction_requestbody.rbi +12 -0
  30. data/lib/moderation_api/models/operations/rejectcontent_request.rb +45 -0
  31. data/lib/moderation_api/models/operations/rejectcontent_request.rbi +26 -0
  32. data/lib/moderation_api/models/operations/rejectcontent_requestbody.rb +67 -0
  33. data/lib/moderation_api/models/operations/rejectcontent_requestbody.rbi +32 -0
  34. data/lib/moderation_api/models/operations/rejectcontent_response.rb +51 -0
  35. data/lib/moderation_api/models/operations/rejectcontent_response.rbi +32 -0
  36. data/lib/moderation_api/models/operations/rejectcontent_responsebody.rb +35 -0
  37. data/lib/moderation_api/models/operations/rejectcontent_responsebody.rbi +14 -0
  38. data/lib/moderation_api/models/operations/resolvequeueitem_request.rb +1 -1
  39. data/lib/moderation_api/models/operations/resolvequeueitems_requestbody.rb +1 -1
  40. data/lib/moderation_api/models/operations/resolvequeueitems_responsebody.rb +1 -1
  41. data/lib/moderation_api/models/operations/suspendauthor_request.rb +45 -0
  42. data/lib/moderation_api/models/operations/suspendauthor_request.rbi +26 -0
  43. data/lib/moderation_api/models/operations/suspendauthor_requestbody.rb +43 -0
  44. data/lib/moderation_api/models/operations/suspendauthor_requestbody.rbi +20 -0
  45. data/lib/moderation_api/models/operations/suspendauthor_response.rb +51 -0
  46. data/lib/moderation_api/models/operations/suspendauthor_response.rbi +32 -0
  47. data/lib/moderation_api/models/operations/suspendauthor_responsebody.rb +35 -0
  48. data/lib/moderation_api/models/operations/suspendauthor_responsebody.rbi +14 -0
  49. data/lib/moderation_api/models/operations/unblockauthor_request.rb +45 -0
  50. data/lib/moderation_api/models/operations/unblockauthor_request.rbi +26 -0
  51. data/lib/moderation_api/models/operations/unblockauthor_requestbody.rb +35 -0
  52. data/lib/moderation_api/models/operations/unblockauthor_requestbody.rbi +14 -0
  53. data/lib/moderation_api/models/operations/unblockauthor_response.rb +51 -0
  54. data/lib/moderation_api/models/operations/unblockauthor_response.rbi +32 -0
  55. data/lib/moderation_api/models/operations/unblockauthor_responsebody.rb +35 -0
  56. data/lib/moderation_api/models/operations/unblockauthor_responsebody.rbi +14 -0
  57. data/lib/moderation_api/models/operations/unicode_spoofing.rb +1 -1
  58. data/lib/moderation_api/models/operations/unresolvequeueitem_request.rb +1 -1
  59. data/lib/moderation_api/models/operations.rb +23 -0
  60. data/lib/moderation_api/moderationapi.rb +3 -3
  61. data/lib/moderation_api/sdkconfiguration.rb +2 -2
  62. data/lib/moderation_api/wordlist.rb +216 -0
  63. data/lib/moderation_api.rb +1 -1
  64. metadata +48 -2
@@ -0,0 +1,67 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class AllowContentRequestBody
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # Why the action was taken. Saved with the action and sent in the webhook event.
15
+ field(
16
+ :reason,
17
+ Crystalline::Nilable.new(::String),
18
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("reason")}}
19
+ )
20
+ # The queue the content is reviewed in. Defaults to the project's default queue.
21
+ field(
22
+ :queue_id,
23
+ Crystalline::Nilable.new(::String),
24
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("queueId")}}
25
+ )
26
+ # The user ID or email of the organization member who made the decision. The action is recorded as theirs.
27
+ field(
28
+ :moderator,
29
+ Crystalline::Nilable.new(::String),
30
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("moderator")}}
31
+ )
32
+ # Record an allow or reject decision as a casebook case. Defaults to true when `moderator` is set, else false. Without `moderator`, the case is recorded as System.
33
+ field(
34
+ :create_casebook_case,
35
+ Crystalline::Nilable.new(Crystalline::Boolean.new),
36
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("createCasebookCase")}}
37
+ )
38
+
39
+ sig {
40
+ params(
41
+ reason: T.nilable(::String),
42
+ queue_id: T.nilable(::String),
43
+ moderator: T.nilable(::String),
44
+ create_casebook_case: T.nilable(T::Boolean)
45
+ )
46
+ .void
47
+ }
48
+ def initialize(reason: nil, queue_id: nil, moderator: nil, create_casebook_case: nil)
49
+ @reason = reason
50
+ @queue_id = queue_id
51
+ @moderator = moderator
52
+ @create_casebook_case = create_casebook_case
53
+ end
54
+
55
+ sig { params(other: T.untyped).returns(T::Boolean) }
56
+ def ==(other)
57
+ return false unless other.is_a?(self.class)
58
+ return false unless @reason == other.reason
59
+ return false unless @queue_id == other.queue_id
60
+ return false unless @moderator == other.moderator
61
+ return false unless @create_casebook_case == other.create_casebook_case
62
+ true
63
+ end
64
+ end
65
+ end
66
+ end
67
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::AllowContentRequestBody
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::AllowContentRequestBody
9
+ def reason
10
+ end
11
+
12
+ def reason=(str_)
13
+ end
14
+
15
+ def queue_id
16
+ end
17
+
18
+ def queue_id=(str_)
19
+ end
20
+
21
+ def moderator
22
+ end
23
+
24
+ def moderator=(str_)
25
+ end
26
+
27
+ def create_casebook_case
28
+ end
29
+
30
+ def create_casebook_case=(str_)
31
+ end
32
+ end
@@ -0,0 +1,51 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class AllowContentResponse
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # HTTP response content type for this operation
15
+ field :content_type, ::String
16
+ # HTTP response status code for this operation
17
+ field :status_code, ::Integer
18
+ # Raw HTTP response; suitable for custom response parsing
19
+ field :raw_response, ::Faraday::Response
20
+ # Action executed successfully
21
+ field :object, Crystalline::Nilable.new(Models::Operations::AllowContentResponseBody)
22
+
23
+ sig {
24
+ params(
25
+ content_type: ::String,
26
+ status_code: ::Integer,
27
+ raw_response: ::Faraday::Response,
28
+ object: T.nilable(Models::Operations::AllowContentResponseBody)
29
+ )
30
+ .void
31
+ }
32
+ def initialize(content_type:, status_code:, raw_response:, object: nil)
33
+ @content_type = content_type
34
+ @status_code = status_code
35
+ @raw_response = raw_response
36
+ @object = object
37
+ end
38
+
39
+ sig { params(other: T.untyped).returns(T::Boolean) }
40
+ def ==(other)
41
+ return false unless other.is_a?(self.class)
42
+ return false unless @content_type == other.content_type
43
+ return false unless @status_code == other.status_code
44
+ return false unless @raw_response == other.raw_response
45
+ return false unless @object == other.object
46
+ true
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::AllowContentResponse
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::AllowContentResponse
9
+ def content_type
10
+ end
11
+
12
+ def content_type=(str_)
13
+ end
14
+
15
+ def status_code
16
+ end
17
+
18
+ def status_code=(str_)
19
+ end
20
+
21
+ def raw_response
22
+ end
23
+
24
+ def raw_response=(str_)
25
+ end
26
+
27
+ def object
28
+ end
29
+
30
+ def object=(str_)
31
+ end
32
+ end
@@ -0,0 +1,35 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+ # Execution result
10
+ class AllowContentResponseBody
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # Whether the action was executed successfully
15
+ field(
16
+ :success,
17
+ Crystalline::Boolean.new,
18
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("success"), required: true}}
19
+ )
20
+
21
+ sig { params(success: T::Boolean).void }
22
+ def initialize(success:)
23
+ @success = success
24
+ end
25
+
26
+ sig { params(other: T.untyped).returns(T::Boolean) }
27
+ def ==(other)
28
+ return false unless other.is_a?(self.class)
29
+ return false unless @success == other.success
30
+ true
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,14 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::AllowContentResponseBody
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::AllowContentResponseBody
9
+ def success
10
+ end
11
+
12
+ def success=(str_)
13
+ end
14
+ end
@@ -0,0 +1,45 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class BlockAuthorRequest
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # Either external ID or the ID assigned by moderation API.
15
+ field :id, ::String, {'path_param': {'field_name': "id", 'style': "simple", 'explode': false}}
16
+
17
+ field :body, Models::Operations::BlockAuthorRequestBody, {'request': {'media_type': "application/json"}}
18
+ # The project to act on, by ID or name. Required with an organization key unless the key reaches only one project; list projects with GET /projects. A project key acts on its own project and needs no value: naming another one is an error.
19
+ field(
20
+ :project_id,
21
+ Crystalline::Nilable.new(::String),
22
+ {'header': {'field_name': "Project-Id", 'style': "simple", 'explode': false}}
23
+ )
24
+
25
+ sig {
26
+ params(id: ::String, body: Models::Operations::BlockAuthorRequestBody, project_id: T.nilable(::String)).void
27
+ }
28
+ def initialize(id:, body:, project_id: nil)
29
+ @id = id
30
+ @body = body
31
+ @project_id = project_id
32
+ end
33
+
34
+ sig { params(other: T.untyped).returns(T::Boolean) }
35
+ def ==(other)
36
+ return false unless other.is_a?(self.class)
37
+ return false unless @id == other.id
38
+ return false unless @body == other.body
39
+ return false unless @project_id == other.project_id
40
+ true
41
+ end
42
+ end
43
+ end
44
+ end
45
+ end
@@ -0,0 +1,26 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::BlockAuthorRequest
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::BlockAuthorRequest
9
+ def id
10
+ end
11
+
12
+ def id=(str_)
13
+ end
14
+
15
+ def body
16
+ end
17
+
18
+ def body=(str_)
19
+ end
20
+
21
+ def project_id
22
+ end
23
+
24
+ def project_id=(str_)
25
+ end
26
+ end
@@ -0,0 +1,35 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class BlockAuthorRequestBody
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # Why the action was taken. Saved with the action and sent in the webhook event.
15
+ field(
16
+ :reason,
17
+ Crystalline::Nilable.new(::String),
18
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("reason")}}
19
+ )
20
+
21
+ sig { params(reason: T.nilable(::String)).void }
22
+ def initialize(reason: nil)
23
+ @reason = reason
24
+ end
25
+
26
+ sig { params(other: T.untyped).returns(T::Boolean) }
27
+ def ==(other)
28
+ return false unless other.is_a?(self.class)
29
+ return false unless @reason == other.reason
30
+ true
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,14 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::BlockAuthorRequestBody
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::BlockAuthorRequestBody
9
+ def reason
10
+ end
11
+
12
+ def reason=(str_)
13
+ end
14
+ end
@@ -0,0 +1,51 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class BlockAuthorResponse
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # HTTP response content type for this operation
15
+ field :content_type, ::String
16
+ # HTTP response status code for this operation
17
+ field :status_code, ::Integer
18
+ # Raw HTTP response; suitable for custom response parsing
19
+ field :raw_response, ::Faraday::Response
20
+ # Action executed successfully
21
+ field :object, Crystalline::Nilable.new(Models::Operations::BlockAuthorResponseBody)
22
+
23
+ sig {
24
+ params(
25
+ content_type: ::String,
26
+ status_code: ::Integer,
27
+ raw_response: ::Faraday::Response,
28
+ object: T.nilable(Models::Operations::BlockAuthorResponseBody)
29
+ )
30
+ .void
31
+ }
32
+ def initialize(content_type:, status_code:, raw_response:, object: nil)
33
+ @content_type = content_type
34
+ @status_code = status_code
35
+ @raw_response = raw_response
36
+ @object = object
37
+ end
38
+
39
+ sig { params(other: T.untyped).returns(T::Boolean) }
40
+ def ==(other)
41
+ return false unless other.is_a?(self.class)
42
+ return false unless @content_type == other.content_type
43
+ return false unless @status_code == other.status_code
44
+ return false unless @raw_response == other.raw_response
45
+ return false unless @object == other.object
46
+ true
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::BlockAuthorResponse
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::BlockAuthorResponse
9
+ def content_type
10
+ end
11
+
12
+ def content_type=(str_)
13
+ end
14
+
15
+ def status_code
16
+ end
17
+
18
+ def status_code=(str_)
19
+ end
20
+
21
+ def raw_response
22
+ end
23
+
24
+ def raw_response=(str_)
25
+ end
26
+
27
+ def object
28
+ end
29
+
30
+ def object=(str_)
31
+ end
32
+ end
@@ -0,0 +1,35 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+ # Execution result
10
+ class BlockAuthorResponseBody
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # Whether the action was executed successfully
15
+ field(
16
+ :success,
17
+ Crystalline::Boolean.new,
18
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("success"), required: true}}
19
+ )
20
+
21
+ sig { params(success: T::Boolean).void }
22
+ def initialize(success:)
23
+ @success = success
24
+ end
25
+
26
+ sig { params(other: T.untyped).returns(T::Boolean) }
27
+ def ==(other)
28
+ return false unless other.is_a?(self.class)
29
+ return false unless @success == other.success
30
+ true
31
+ end
32
+ end
33
+ end
34
+ end
35
+ end
@@ -0,0 +1,14 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::BlockAuthorResponseBody
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::BlockAuthorResponseBody
9
+ def success
10
+ end
11
+
12
+ def success=(str_)
13
+ end
14
+ end
@@ -0,0 +1,39 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class DeleteWordlistRequest
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # ID of the wordlist to delete
15
+ field :id, ::String, {'path_param': {'field_name': "id", 'style': "simple", 'explode': false}}
16
+ # The project to act on, by ID or name. Required with an organization key unless the key reaches only one project; list projects with GET /projects. A project key acts on its own project and needs no value: naming another one is an error.
17
+ field(
18
+ :project_id,
19
+ Crystalline::Nilable.new(::String),
20
+ {'header': {'field_name': "Project-Id", 'style': "simple", 'explode': false}}
21
+ )
22
+
23
+ sig { params(id: ::String, project_id: T.nilable(::String)).void }
24
+ def initialize(id:, project_id: nil)
25
+ @id = id
26
+ @project_id = project_id
27
+ end
28
+
29
+ sig { params(other: T.untyped).returns(T::Boolean) }
30
+ def ==(other)
31
+ return false unless other.is_a?(self.class)
32
+ return false unless @id == other.id
33
+ return false unless @project_id == other.project_id
34
+ true
35
+ end
36
+ end
37
+ end
38
+ end
39
+ end
@@ -0,0 +1,20 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::DeleteWordlistRequest
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::DeleteWordlistRequest
9
+ def id
10
+ end
11
+
12
+ def id=(str_)
13
+ end
14
+
15
+ def project_id
16
+ end
17
+
18
+ def project_id=(str_)
19
+ end
20
+ end
@@ -0,0 +1,51 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+
10
+ class DeleteWordlistResponse
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # HTTP response content type for this operation
15
+ field :content_type, ::String
16
+ # HTTP response status code for this operation
17
+ field :status_code, ::Integer
18
+ # Raw HTTP response; suitable for custom response parsing
19
+ field :raw_response, ::Faraday::Response
20
+ # Wordlist deleted successfully
21
+ field :object, Crystalline::Nilable.new(Models::Operations::DeleteWordlistResponseBody)
22
+
23
+ sig {
24
+ params(
25
+ content_type: ::String,
26
+ status_code: ::Integer,
27
+ raw_response: ::Faraday::Response,
28
+ object: T.nilable(Models::Operations::DeleteWordlistResponseBody)
29
+ )
30
+ .void
31
+ }
32
+ def initialize(content_type:, status_code:, raw_response:, object: nil)
33
+ @content_type = content_type
34
+ @status_code = status_code
35
+ @raw_response = raw_response
36
+ @object = object
37
+ end
38
+
39
+ sig { params(other: T.untyped).returns(T::Boolean) }
40
+ def ==(other)
41
+ return false unless other.is_a?(self.class)
42
+ return false unless @content_type == other.content_type
43
+ return false unless @status_code == other.status_code
44
+ return false unless @raw_response == other.raw_response
45
+ return false unless @object == other.object
46
+ true
47
+ end
48
+ end
49
+ end
50
+ end
51
+ end
@@ -0,0 +1,32 @@
1
+ # typed: true
2
+ # frozen_string_literal: true
3
+
4
+ class ModerationApi::Models::Operations::DeleteWordlistResponse
5
+ extend ::Crystalline::MetadataFields::ClassMethods
6
+ end
7
+
8
+ class ModerationApi::Models::Operations::DeleteWordlistResponse
9
+ def content_type
10
+ end
11
+
12
+ def content_type=(str_)
13
+ end
14
+
15
+ def status_code
16
+ end
17
+
18
+ def status_code=(str_)
19
+ end
20
+
21
+ def raw_response
22
+ end
23
+
24
+ def raw_response=(str_)
25
+ end
26
+
27
+ def object
28
+ end
29
+
30
+ def object=(str_)
31
+ end
32
+ end
@@ -0,0 +1,47 @@
1
+ # Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
2
+
3
+ # typed: true
4
+ # frozen_string_literal: true
5
+
6
+ module ModerationApi
7
+ module Models
8
+ module Operations
9
+ # Wordlist deleted successfully
10
+ class DeleteWordlistResponseBody
11
+ extend T::Sig
12
+ include Crystalline::MetadataFields
13
+
14
+ # ID of the deleted wordlist
15
+ field :id, ::String, {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("id"), required: true}}
16
+ # Whether the wordlist was deleted
17
+ field(
18
+ :deleted,
19
+ Crystalline::Boolean.new,
20
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("deleted"), required: true}}
21
+ )
22
+ # IDs of the channels that used the wordlist. It was removed from them.
23
+ field(
24
+ :detached_channel_ids,
25
+ Crystalline::Array.new(::String),
26
+ {'format_json': {'letter_case': ::ModerationApi::Utils.field_name("detachedChannelIds"), required: true}}
27
+ )
28
+
29
+ sig { params(id: ::String, deleted: T::Boolean, detached_channel_ids: T::Array[::String]).void }
30
+ def initialize(id:, deleted:, detached_channel_ids:)
31
+ @id = id
32
+ @deleted = deleted
33
+ @detached_channel_ids = detached_channel_ids
34
+ end
35
+
36
+ sig { params(other: T.untyped).returns(T::Boolean) }
37
+ def ==(other)
38
+ return false unless other.is_a?(self.class)
39
+ return false unless @id == other.id
40
+ return false unless @deleted == other.deleted
41
+ return false unless @detached_channel_ids == other.detached_channel_ids
42
+ true
43
+ end
44
+ end
45
+ end
46
+ end
47
+ end