moderation_api 1.2.0 → 1.2.2

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 (176) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +87 -0
  3. data/README.md +61 -106
  4. data/docs/AccountApi.md +5 -5
  5. data/docs/AccountGet200Response.md +2 -2
  6. data/docs/AccountGet200ResponseCurrentProject.md +2 -2
  7. data/docs/ActionsCreateRequest.md +2 -2
  8. data/docs/ActionsCreateRequestWebhooksInner.md +2 -2
  9. data/docs/ActionsDelete200Response.md +2 -2
  10. data/docs/ActionsExecute200Response.md +2 -2
  11. data/docs/ActionsExecuteDeprecatedRequest.md +2 -2
  12. data/docs/ActionsExecuteRequest.md +2 -2
  13. data/docs/ActionsGet200Response.md +2 -2
  14. data/docs/ActionsGet200ResponseWebhooksInner.md +2 -2
  15. data/docs/ActionsList200ResponseInner.md +2 -2
  16. data/docs/ActionsList200ResponseInnerPossibleValuesInner.md +2 -2
  17. data/docs/ActionsList400Response.md +2 -2
  18. data/docs/ActionsList400ResponseIssuesInner.md +2 -2
  19. data/docs/ActionsUpdateRequest.md +2 -2
  20. data/docs/ModerateApi.md +26 -26
  21. data/docs/ModerationAudioRequest.md +2 -2
  22. data/docs/ModerationImage200Response.md +2 -2
  23. data/docs/ModerationImage200ResponseLabelsInner.md +2 -2
  24. data/docs/ModerationImageRequest.md +2 -2
  25. data/docs/ModerationObject200Response.md +2 -2
  26. data/docs/ModerationObject200ResponseAllOfEntitiesInner.md +2 -2
  27. data/docs/ModerationObject200ResponseAllOfFieldsInner.md +2 -2
  28. data/docs/ModerationObject200ResponseAllOfLabelsInner.md +2 -2
  29. data/docs/ModerationObjectRequest.md +2 -2
  30. data/docs/ModerationObjectRequestValue.md +2 -2
  31. data/docs/ModerationObjectRequestValueDataValue.md +2 -2
  32. data/docs/ModerationText200Response.md +2 -2
  33. data/docs/ModerationText200ResponseAllOfAddress.md +2 -2
  34. data/docs/ModerationText200ResponseAllOfEmail.md +2 -2
  35. data/docs/ModerationText200ResponseAllOfName.md +2 -2
  36. data/docs/ModerationText200ResponseAllOfNsfw.md +2 -2
  37. data/docs/ModerationText200ResponseAllOfNsfwLabelScores.md +2 -2
  38. data/docs/ModerationText200ResponseAllOfPhone.md +2 -2
  39. data/docs/ModerationText200ResponseAllOfProfanity.md +2 -2
  40. data/docs/ModerationText200ResponseAllOfPropriety.md +2 -2
  41. data/docs/ModerationText200ResponseAllOfProprietyLabelScores.md +2 -2
  42. data/docs/ModerationText200ResponseAllOfQuality.md +2 -2
  43. data/docs/ModerationText200ResponseAllOfQualityLabelScores.md +2 -2
  44. data/docs/ModerationText200ResponseAllOfRequest.md +2 -2
  45. data/docs/ModerationText200ResponseAllOfSensitive.md +2 -2
  46. data/docs/ModerationText200ResponseAllOfSentiment.md +2 -2
  47. data/docs/ModerationText200ResponseAllOfSentimentLabelScores.md +2 -2
  48. data/docs/ModerationText200ResponseAllOfToxicity.md +2 -2
  49. data/docs/ModerationText200ResponseAllOfToxicityLabelScores.md +2 -2
  50. data/docs/ModerationText200ResponseAllOfUrl.md +2 -2
  51. data/docs/ModerationText200ResponseAllOfUsername.md +2 -2
  52. data/docs/ModerationText200ResponseAllOfWordlist.md +2 -2
  53. data/docs/ModerationText200ResponseAllOfWordlistsInner.md +2 -2
  54. data/docs/ModerationTextRequest.md +2 -2
  55. data/docs/ModerationVideo200Response.md +2 -2
  56. data/docs/ModerationVideoRequest.md +2 -2
  57. data/docs/QueueActionsApi.md +33 -33
  58. data/lib/moderation_api/api/account_api.rb +1 -1
  59. data/lib/moderation_api/api/moderate_api.rb +1 -1
  60. data/lib/moderation_api/api/queue_actions_api.rb +1 -1
  61. data/lib/moderation_api/api_client.rb +2 -2
  62. data/lib/moderation_api/api_error.rb +1 -1
  63. data/lib/moderation_api/configuration.rb +1 -1
  64. data/lib/moderation_api/models/account_get200_response.rb +4 -4
  65. data/lib/moderation_api/models/account_get200_response_current_project.rb +4 -4
  66. data/lib/moderation_api/models/actions_create_request.rb +4 -4
  67. data/lib/moderation_api/models/actions_create_request_webhooks_inner.rb +4 -4
  68. data/lib/moderation_api/models/actions_delete200_response.rb +4 -4
  69. data/lib/moderation_api/models/actions_execute200_response.rb +4 -4
  70. data/lib/moderation_api/models/actions_execute_deprecated_request.rb +4 -4
  71. data/lib/moderation_api/models/actions_execute_request.rb +4 -4
  72. data/lib/moderation_api/models/actions_get200_response.rb +4 -4
  73. data/lib/moderation_api/models/actions_get200_response_webhooks_inner.rb +4 -4
  74. data/lib/moderation_api/models/actions_list200_response_inner.rb +4 -4
  75. data/lib/moderation_api/models/actions_list200_response_inner_possible_values_inner.rb +4 -4
  76. data/lib/moderation_api/models/actions_list400_response.rb +4 -4
  77. data/lib/moderation_api/models/actions_list400_response_issues_inner.rb +4 -4
  78. data/lib/moderation_api/models/actions_update_request.rb +4 -4
  79. data/lib/moderation_api/models/moderation_audio_request.rb +4 -4
  80. data/lib/moderation_api/models/moderation_image200_response.rb +4 -4
  81. data/lib/moderation_api/models/moderation_image200_response_labels_inner.rb +4 -4
  82. data/lib/moderation_api/models/moderation_image_request.rb +4 -4
  83. data/lib/moderation_api/models/moderation_object200_response.rb +4 -4
  84. data/lib/moderation_api/models/moderation_object200_response_all_of_entities_inner.rb +4 -4
  85. data/lib/moderation_api/models/moderation_object200_response_all_of_fields_inner.rb +4 -4
  86. data/lib/moderation_api/models/moderation_object200_response_all_of_labels_inner.rb +4 -4
  87. data/lib/moderation_api/models/moderation_object_request.rb +4 -4
  88. data/lib/moderation_api/models/moderation_object_request_value.rb +4 -4
  89. data/lib/moderation_api/models/moderation_object_request_value_data_value.rb +4 -4
  90. data/lib/moderation_api/models/moderation_text200_response.rb +4 -4
  91. data/lib/moderation_api/models/moderation_text200_response_all_of_address.rb +4 -4
  92. data/lib/moderation_api/models/moderation_text200_response_all_of_email.rb +4 -4
  93. data/lib/moderation_api/models/moderation_text200_response_all_of_name.rb +4 -4
  94. data/lib/moderation_api/models/moderation_text200_response_all_of_nsfw.rb +4 -4
  95. data/lib/moderation_api/models/moderation_text200_response_all_of_nsfw_label_scores.rb +4 -4
  96. data/lib/moderation_api/models/moderation_text200_response_all_of_phone.rb +4 -4
  97. data/lib/moderation_api/models/moderation_text200_response_all_of_profanity.rb +4 -4
  98. data/lib/moderation_api/models/moderation_text200_response_all_of_propriety.rb +4 -4
  99. data/lib/moderation_api/models/moderation_text200_response_all_of_propriety_label_scores.rb +4 -4
  100. data/lib/moderation_api/models/moderation_text200_response_all_of_quality.rb +4 -4
  101. data/lib/moderation_api/models/moderation_text200_response_all_of_quality_label_scores.rb +4 -4
  102. data/lib/moderation_api/models/moderation_text200_response_all_of_request.rb +4 -4
  103. data/lib/moderation_api/models/moderation_text200_response_all_of_sensitive.rb +4 -4
  104. data/lib/moderation_api/models/moderation_text200_response_all_of_sentiment.rb +4 -4
  105. data/lib/moderation_api/models/moderation_text200_response_all_of_sentiment_label_scores.rb +4 -4
  106. data/lib/moderation_api/models/moderation_text200_response_all_of_toxicity.rb +4 -4
  107. data/lib/moderation_api/models/moderation_text200_response_all_of_toxicity_label_scores.rb +4 -4
  108. data/lib/moderation_api/models/moderation_text200_response_all_of_url.rb +4 -4
  109. data/lib/moderation_api/models/moderation_text200_response_all_of_username.rb +4 -4
  110. data/lib/moderation_api/models/moderation_text200_response_all_of_wordlist.rb +4 -4
  111. data/lib/moderation_api/models/moderation_text200_response_all_of_wordlists_inner.rb +4 -4
  112. data/lib/moderation_api/models/moderation_text_request.rb +4 -4
  113. data/lib/moderation_api/models/moderation_video200_response.rb +4 -4
  114. data/lib/moderation_api/models/moderation_video_request.rb +4 -4
  115. data/lib/moderation_api/version.rb +2 -2
  116. data/lib/moderation_api/webhook.rb +41 -0
  117. data/lib/moderation_api.rb +56 -56
  118. data/moderation_api-1.2.0.gem +0 -0
  119. data/moderation_api-1.2.1.gem +0 -0
  120. data/moderation_api.gemspec +3 -3
  121. data/ruby_config.yaml +30 -0
  122. data/spec/api/account_api_spec.rb +3 -3
  123. data/spec/api/moderate_api_spec.rb +3 -3
  124. data/spec/api/queue_actions_api_spec.rb +3 -3
  125. data/spec/models/account_get200_response_current_project_spec.rb +4 -4
  126. data/spec/models/account_get200_response_spec.rb +4 -4
  127. data/spec/models/actions_create_request_spec.rb +4 -4
  128. data/spec/models/actions_create_request_webhooks_inner_spec.rb +4 -4
  129. data/spec/models/actions_delete200_response_spec.rb +4 -4
  130. data/spec/models/actions_execute200_response_spec.rb +4 -4
  131. data/spec/models/actions_execute_deprecated_request_spec.rb +4 -4
  132. data/spec/models/actions_execute_request_spec.rb +4 -4
  133. data/spec/models/actions_get200_response_spec.rb +4 -4
  134. data/spec/models/actions_get200_response_webhooks_inner_spec.rb +4 -4
  135. data/spec/models/actions_list200_response_inner_possible_values_inner_spec.rb +4 -4
  136. data/spec/models/actions_list200_response_inner_spec.rb +4 -4
  137. data/spec/models/actions_list400_response_issues_inner_spec.rb +4 -4
  138. data/spec/models/actions_list400_response_spec.rb +4 -4
  139. data/spec/models/actions_update_request_spec.rb +4 -4
  140. data/spec/models/moderation_audio_request_spec.rb +4 -4
  141. data/spec/models/moderation_image200_response_labels_inner_spec.rb +4 -4
  142. data/spec/models/moderation_image200_response_spec.rb +4 -4
  143. data/spec/models/moderation_image_request_spec.rb +4 -4
  144. data/spec/models/moderation_object200_response_all_of_entities_inner_spec.rb +4 -4
  145. data/spec/models/moderation_object200_response_all_of_fields_inner_spec.rb +4 -4
  146. data/spec/models/moderation_object200_response_all_of_labels_inner_spec.rb +4 -4
  147. data/spec/models/moderation_object200_response_spec.rb +4 -4
  148. data/spec/models/moderation_object_request_spec.rb +4 -4
  149. data/spec/models/moderation_object_request_value_data_value_spec.rb +4 -4
  150. data/spec/models/moderation_object_request_value_spec.rb +4 -4
  151. data/spec/models/moderation_text200_response_all_of_address_spec.rb +4 -4
  152. data/spec/models/moderation_text200_response_all_of_email_spec.rb +4 -4
  153. data/spec/models/moderation_text200_response_all_of_name_spec.rb +4 -4
  154. data/spec/models/moderation_text200_response_all_of_nsfw_label_scores_spec.rb +4 -4
  155. data/spec/models/moderation_text200_response_all_of_nsfw_spec.rb +4 -4
  156. data/spec/models/moderation_text200_response_all_of_phone_spec.rb +4 -4
  157. data/spec/models/moderation_text200_response_all_of_profanity_spec.rb +4 -4
  158. data/spec/models/moderation_text200_response_all_of_propriety_label_scores_spec.rb +4 -4
  159. data/spec/models/moderation_text200_response_all_of_propriety_spec.rb +4 -4
  160. data/spec/models/moderation_text200_response_all_of_quality_label_scores_spec.rb +4 -4
  161. data/spec/models/moderation_text200_response_all_of_quality_spec.rb +4 -4
  162. data/spec/models/moderation_text200_response_all_of_request_spec.rb +4 -4
  163. data/spec/models/moderation_text200_response_all_of_sensitive_spec.rb +4 -4
  164. data/spec/models/moderation_text200_response_all_of_sentiment_label_scores_spec.rb +4 -4
  165. data/spec/models/moderation_text200_response_all_of_sentiment_spec.rb +4 -4
  166. data/spec/models/moderation_text200_response_all_of_toxicity_label_scores_spec.rb +4 -4
  167. data/spec/models/moderation_text200_response_all_of_toxicity_spec.rb +4 -4
  168. data/spec/models/moderation_text200_response_all_of_url_spec.rb +4 -4
  169. data/spec/models/moderation_text200_response_all_of_username_spec.rb +4 -4
  170. data/spec/models/moderation_text200_response_all_of_wordlist_spec.rb +4 -4
  171. data/spec/models/moderation_text200_response_all_of_wordlists_inner_spec.rb +4 -4
  172. data/spec/models/moderation_text200_response_spec.rb +4 -4
  173. data/spec/models/moderation_text_request_spec.rb +4 -4
  174. data/spec/models/moderation_video200_response_spec.rb +4 -4
  175. data/spec/models/moderation_video_request_spec.rb +4 -4
  176. metadata +9 -4
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  class ModerationText200Response
18
18
  # Success if the request was successful
19
19
  attr_accessor :status
@@ -147,13 +147,13 @@ module ModerationAPI
147
147
  # @param [Hash] attributes Model attributes in the form of hash
148
148
  def initialize(attributes = {})
149
149
  if (!attributes.is_a?(Hash))
150
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200Response` initialize method"
150
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200Response` initialize method"
151
151
  end
152
152
 
153
153
  # check to see if the attribute exists and convert string to symbol for hash key
154
154
  attributes = attributes.each_with_object({}) { |(k, v), h|
155
155
  if (!self.class.attribute_map.key?(k.to_sym))
156
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200Response`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
156
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200Response`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
157
157
  end
158
158
  h[k.to_sym] = v
159
159
  }
@@ -432,7 +432,7 @@ module ModerationAPI
432
432
  end
433
433
  else # model
434
434
  # models (e.g. Pet) or oneOf
435
- klass = ModerationAPI.const_get(type)
435
+ klass = ModerationApi.const_get(type)
436
436
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
437
437
  end
438
438
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The address entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/address
18
18
  class ModerationText200ResponseAllOfAddress
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfAddress` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfAddress` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfAddress`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfAddress`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The email entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/email
18
18
  class ModerationText200ResponseAllOfEmail
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfEmail` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfEmail` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfEmail`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfEmail`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The name entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/name
18
18
  class ModerationText200ResponseAllOfName
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfName` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfName` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfName`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfName`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The NSFW model output if enabled in your project. Read more at https://docs.moderationapi.com/models/nsfw
18
18
  class ModerationText200ResponseAllOfNsfw
19
19
  # The label of the model
@@ -67,13 +67,13 @@ module ModerationAPI
67
67
  # @param [Hash] attributes Model attributes in the form of hash
68
68
  def initialize(attributes = {})
69
69
  if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfNsfw` initialize method"
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfNsfw` initialize method"
71
71
  end
72
72
 
73
73
  # check to see if the attribute exists and convert string to symbol for hash key
74
74
  attributes = attributes.each_with_object({}) { |(k, v), h|
75
75
  if (!self.class.attribute_map.key?(k.to_sym))
76
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfNsfw`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfNsfw`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
77
  end
78
78
  h[k.to_sym] = v
79
79
  }
@@ -199,7 +199,7 @@ module ModerationAPI
199
199
  end
200
200
  else # model
201
201
  # models (e.g. Pet) or oneOf
202
- klass = ModerationAPI.const_get(type)
202
+ klass = ModerationApi.const_get(type)
203
203
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
204
204
  end
205
205
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The confidence of all labels
18
18
  class ModerationText200ResponseAllOfNsfwLabelScores
19
19
  # Mentions religion, politics, race, etc., but is neutral or positive.
@@ -57,13 +57,13 @@ module ModerationAPI
57
57
  # @param [Hash] attributes Model attributes in the form of hash
58
58
  def initialize(attributes = {})
59
59
  if (!attributes.is_a?(Hash))
60
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfNsfwLabelScores` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfNsfwLabelScores` initialize method"
61
61
  end
62
62
 
63
63
  # check to see if the attribute exists and convert string to symbol for hash key
64
64
  attributes = attributes.each_with_object({}) { |(k, v), h|
65
65
  if (!self.class.attribute_map.key?(k.to_sym))
66
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfNsfwLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
66
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfNsfwLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
67
  end
68
68
  h[k.to_sym] = v
69
69
  }
@@ -179,7 +179,7 @@ module ModerationAPI
179
179
  end
180
180
  else # model
181
181
  # models (e.g. Pet) or oneOf
182
- klass = ModerationAPI.const_get(type)
182
+ klass = ModerationApi.const_get(type)
183
183
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
184
184
  end
185
185
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The phone entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/phone
18
18
  class ModerationText200ResponseAllOfPhone
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfPhone` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfPhone` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfPhone`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfPhone`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The profanity entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/profanity
18
18
  class ModerationText200ResponseAllOfProfanity
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfProfanity` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfProfanity` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfProfanity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfProfanity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The propriety model output if enabled in your project. Read more at https://docs.moderationapi.com/models/propriety
18
18
  class ModerationText200ResponseAllOfPropriety
19
19
  # The label of the model
@@ -67,13 +67,13 @@ module ModerationAPI
67
67
  # @param [Hash] attributes Model attributes in the form of hash
68
68
  def initialize(attributes = {})
69
69
  if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfPropriety` initialize method"
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfPropriety` initialize method"
71
71
  end
72
72
 
73
73
  # check to see if the attribute exists and convert string to symbol for hash key
74
74
  attributes = attributes.each_with_object({}) { |(k, v), h|
75
75
  if (!self.class.attribute_map.key?(k.to_sym))
76
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfPropriety`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfPropriety`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
77
  end
78
78
  h[k.to_sym] = v
79
79
  }
@@ -199,7 +199,7 @@ module ModerationAPI
199
199
  end
200
200
  else # model
201
201
  # models (e.g. Pet) or oneOf
202
- klass = ModerationAPI.const_get(type)
202
+ klass = ModerationApi.const_get(type)
203
203
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
204
204
  end
205
205
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The confidence of all labels
18
18
  class ModerationText200ResponseAllOfProprietyLabelScores
19
19
  # Pickup lines, compliments on appearance, etc.
@@ -57,13 +57,13 @@ module ModerationAPI
57
57
  # @param [Hash] attributes Model attributes in the form of hash
58
58
  def initialize(attributes = {})
59
59
  if (!attributes.is_a?(Hash))
60
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfProprietyLabelScores` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfProprietyLabelScores` initialize method"
61
61
  end
62
62
 
63
63
  # check to see if the attribute exists and convert string to symbol for hash key
64
64
  attributes = attributes.each_with_object({}) { |(k, v), h|
65
65
  if (!self.class.attribute_map.key?(k.to_sym))
66
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfProprietyLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
66
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfProprietyLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
67
  end
68
68
  h[k.to_sym] = v
69
69
  }
@@ -179,7 +179,7 @@ module ModerationAPI
179
179
  end
180
180
  else # model
181
181
  # models (e.g. Pet) or oneOf
182
- klass = ModerationAPI.const_get(type)
182
+ klass = ModerationApi.const_get(type)
183
183
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
184
184
  end
185
185
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The spam model output if enabled in your project. Read more at https://docs.moderationapi.com/models/spam
18
18
  class ModerationText200ResponseAllOfQuality
19
19
  # The label of the model
@@ -67,13 +67,13 @@ module ModerationAPI
67
67
  # @param [Hash] attributes Model attributes in the form of hash
68
68
  def initialize(attributes = {})
69
69
  if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfQuality` initialize method"
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfQuality` initialize method"
71
71
  end
72
72
 
73
73
  # check to see if the attribute exists and convert string to symbol for hash key
74
74
  attributes = attributes.each_with_object({}) { |(k, v), h|
75
75
  if (!self.class.attribute_map.key?(k.to_sym))
76
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfQuality`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfQuality`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
77
  end
78
78
  h[k.to_sym] = v
79
79
  }
@@ -199,7 +199,7 @@ module ModerationAPI
199
199
  end
200
200
  else # model
201
201
  # models (e.g. Pet) or oneOf
202
- klass = ModerationAPI.const_get(type)
202
+ klass = ModerationApi.const_get(type)
203
203
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
204
204
  end
205
205
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The confidence of all labels
18
18
  class ModerationText200ResponseAllOfQualityLabelScores
19
19
  # Trivial or short content.
@@ -62,13 +62,13 @@ module ModerationAPI
62
62
  # @param [Hash] attributes Model attributes in the form of hash
63
63
  def initialize(attributes = {})
64
64
  if (!attributes.is_a?(Hash))
65
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfQualityLabelScores` initialize method"
65
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfQualityLabelScores` initialize method"
66
66
  end
67
67
 
68
68
  # check to see if the attribute exists and convert string to symbol for hash key
69
69
  attributes = attributes.each_with_object({}) { |(k, v), h|
70
70
  if (!self.class.attribute_map.key?(k.to_sym))
71
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfQualityLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
71
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfQualityLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
72
72
  end
73
73
  h[k.to_sym] = v
74
74
  }
@@ -189,7 +189,7 @@ module ModerationAPI
189
189
  end
190
190
  else # model
191
191
  # models (e.g. Pet) or oneOf
192
- klass = ModerationAPI.const_get(type)
192
+ klass = ModerationApi.const_get(type)
193
193
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
194
194
  end
195
195
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # Information about the request
18
18
  class ModerationText200ResponseAllOfRequest
19
19
  # The timestamp of the request
@@ -53,13 +53,13 @@ module ModerationAPI
53
53
  # @param [Hash] attributes Model attributes in the form of hash
54
54
  def initialize(attributes = {})
55
55
  if (!attributes.is_a?(Hash))
56
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfRequest` initialize method"
56
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfRequest` initialize method"
57
57
  end
58
58
 
59
59
  # check to see if the attribute exists and convert string to symbol for hash key
60
60
  attributes = attributes.each_with_object({}) { |(k, v), h|
61
61
  if (!self.class.attribute_map.key?(k.to_sym))
62
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
62
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfRequest`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
63
63
  end
64
64
  h[k.to_sym] = v
65
65
  }
@@ -184,7 +184,7 @@ module ModerationAPI
184
184
  end
185
185
  else # model
186
186
  # models (e.g. Pet) or oneOf
187
- klass = ModerationAPI.const_get(type)
187
+ klass = ModerationApi.const_get(type)
188
188
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
189
189
  end
190
190
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The sensitive numbers entity matcher output if enabled in your project. Read more at https://docs.moderationapi.com/models/sensitive
18
18
  class ModerationText200ResponseAllOfSensitive
19
19
  # The detection mode.
@@ -96,13 +96,13 @@ module ModerationAPI
96
96
  # @param [Hash] attributes Model attributes in the form of hash
97
97
  def initialize(attributes = {})
98
98
  if (!attributes.is_a?(Hash))
99
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfSensitive` initialize method"
99
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfSensitive` initialize method"
100
100
  end
101
101
 
102
102
  # check to see if the attribute exists and convert string to symbol for hash key
103
103
  attributes = attributes.each_with_object({}) { |(k, v), h|
104
104
  if (!self.class.attribute_map.key?(k.to_sym))
105
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfSensitive`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
105
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfSensitive`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
106
106
  end
107
107
  h[k.to_sym] = v
108
108
  }
@@ -247,7 +247,7 @@ module ModerationAPI
247
247
  end
248
248
  else # model
249
249
  # models (e.g. Pet) or oneOf
250
- klass = ModerationAPI.const_get(type)
250
+ klass = ModerationApi.const_get(type)
251
251
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
252
252
  end
253
253
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The sentiment model output if enabled in your project. Read more at https://docs.moderationapi.com/models/sentiment
18
18
  class ModerationText200ResponseAllOfSentiment
19
19
  # The label of the model
@@ -67,13 +67,13 @@ module ModerationAPI
67
67
  # @param [Hash] attributes Model attributes in the form of hash
68
68
  def initialize(attributes = {})
69
69
  if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfSentiment` initialize method"
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfSentiment` initialize method"
71
71
  end
72
72
 
73
73
  # check to see if the attribute exists and convert string to symbol for hash key
74
74
  attributes = attributes.each_with_object({}) { |(k, v), h|
75
75
  if (!self.class.attribute_map.key?(k.to_sym))
76
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfSentiment`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfSentiment`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
77
  end
78
78
  h[k.to_sym] = v
79
79
  }
@@ -199,7 +199,7 @@ module ModerationAPI
199
199
  end
200
200
  else # model
201
201
  # models (e.g. Pet) or oneOf
202
- klass = ModerationAPI.const_get(type)
202
+ klass = ModerationApi.const_get(type)
203
203
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
204
204
  end
205
205
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The confidence of all labels
18
18
  class ModerationText200ResponseAllOfSentimentLabelScores
19
19
  # Positive sentiment.
@@ -57,13 +57,13 @@ module ModerationAPI
57
57
  # @param [Hash] attributes Model attributes in the form of hash
58
58
  def initialize(attributes = {})
59
59
  if (!attributes.is_a?(Hash))
60
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfSentimentLabelScores` initialize method"
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfSentimentLabelScores` initialize method"
61
61
  end
62
62
 
63
63
  # check to see if the attribute exists and convert string to symbol for hash key
64
64
  attributes = attributes.each_with_object({}) { |(k, v), h|
65
65
  if (!self.class.attribute_map.key?(k.to_sym))
66
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfSentimentLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
66
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfSentimentLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
67
67
  end
68
68
  h[k.to_sym] = v
69
69
  }
@@ -179,7 +179,7 @@ module ModerationAPI
179
179
  end
180
180
  else # model
181
181
  # models (e.g. Pet) or oneOf
182
- klass = ModerationAPI.const_get(type)
182
+ klass = ModerationApi.const_get(type)
183
183
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
184
184
  end
185
185
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The toxicity model output if enabled in your project. Read more at https://docs.moderationapi.com/models/toxicity
18
18
  class ModerationText200ResponseAllOfToxicity
19
19
  attr_accessor :label_scores
@@ -67,13 +67,13 @@ module ModerationAPI
67
67
  # @param [Hash] attributes Model attributes in the form of hash
68
68
  def initialize(attributes = {})
69
69
  if (!attributes.is_a?(Hash))
70
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfToxicity` initialize method"
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfToxicity` initialize method"
71
71
  end
72
72
 
73
73
  # check to see if the attribute exists and convert string to symbol for hash key
74
74
  attributes = attributes.each_with_object({}) { |(k, v), h|
75
75
  if (!self.class.attribute_map.key?(k.to_sym))
76
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfToxicity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
76
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfToxicity`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
77
77
  end
78
78
  h[k.to_sym] = v
79
79
  }
@@ -206,7 +206,7 @@ module ModerationAPI
206
206
  end
207
207
  else # model
208
208
  # models (e.g. Pet) or oneOf
209
- klass = ModerationAPI.const_get(type)
209
+ klass = ModerationApi.const_get(type)
210
210
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
211
211
  end
212
212
  end
@@ -13,7 +13,7 @@ Generator version: 7.10.0
13
13
  require 'date'
14
14
  require 'time'
15
15
 
16
- module ModerationAPI
16
+ module ModerationApi
17
17
  # The confidence of all labels
18
18
  class ModerationText200ResponseAllOfToxicityLabelScores
19
19
  # Rude or disrespectful content.
@@ -77,13 +77,13 @@ module ModerationAPI
77
77
  # @param [Hash] attributes Model attributes in the form of hash
78
78
  def initialize(attributes = {})
79
79
  if (!attributes.is_a?(Hash))
80
- fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationAPI::ModerationText200ResponseAllOfToxicityLabelScores` initialize method"
80
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ModerationApi::ModerationText200ResponseAllOfToxicityLabelScores` initialize method"
81
81
  end
82
82
 
83
83
  # check to see if the attribute exists and convert string to symbol for hash key
84
84
  attributes = attributes.each_with_object({}) { |(k, v), h|
85
85
  if (!self.class.attribute_map.key?(k.to_sym))
86
- fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationAPI::ModerationText200ResponseAllOfToxicityLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
86
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ModerationApi::ModerationText200ResponseAllOfToxicityLabelScores`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
87
87
  end
88
88
  h[k.to_sym] = v
89
89
  }
@@ -219,7 +219,7 @@ module ModerationAPI
219
219
  end
220
220
  else # model
221
221
  # models (e.g. Pet) or oneOf
222
- klass = ModerationAPI.const_get(type)
222
+ klass = ModerationApi.const_get(type)
223
223
  klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
224
224
  end
225
225
  end