cogbox_api_client 0.190.1

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 (219) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +39 -0
  3. data/.openapi-generator/FILES +212 -0
  4. data/.openapi-generator/VERSION +1 -0
  5. data/.openapi-generator-ignore +31 -0
  6. data/.rspec +2 -0
  7. data/.rubocop.yml +148 -0
  8. data/Rakefile +10 -0
  9. data/cogbox_api_client.gemspec +39 -0
  10. data/fix-gemspec.sh +11 -0
  11. data/lib/cogbox_api_client/api/admin_api.rb +1449 -0
  12. data/lib/cogbox_api_client/api/api_keys_api.rb +401 -0
  13. data/lib/cogbox_api_client/api/audit_api.rb +110 -0
  14. data/lib/cogbox_api_client/api/config_api.rb +77 -0
  15. data/lib/cogbox_api_client/api/docker_registry_api.rb +411 -0
  16. data/lib/cogbox_api_client/api/health_api.rb +126 -0
  17. data/lib/cogbox_api_client/api/jobs_api.rb +299 -0
  18. data/lib/cogbox_api_client/api/object_storage_api.rb +80 -0
  19. data/lib/cogbox_api_client/api/organizations_api.rb +2615 -0
  20. data/lib/cogbox_api_client/api/preview_api.rb +278 -0
  21. data/lib/cogbox_api_client/api/regions_api.rb +77 -0
  22. data/lib/cogbox_api_client/api/runners_api.rb +711 -0
  23. data/lib/cogbox_api_client/api/sandbox_api.rb +3064 -0
  24. data/lib/cogbox_api_client/api/snapshots_api.rb +567 -0
  25. data/lib/cogbox_api_client/api/toolbox_api.rb +5108 -0
  26. data/lib/cogbox_api_client/api/users_api.rb +316 -0
  27. data/lib/cogbox_api_client/api/volumes_api.rb +342 -0
  28. data/lib/cogbox_api_client/api/webhooks_api.rb +276 -0
  29. data/lib/cogbox_api_client/api_client.rb +397 -0
  30. data/lib/cogbox_api_client/api_error.rb +58 -0
  31. data/lib/cogbox_api_client/api_model_base.rb +88 -0
  32. data/lib/cogbox_api_client/configuration.rb +309 -0
  33. data/lib/cogbox_api_client/models/account_provider.rb +190 -0
  34. data/lib/cogbox_api_client/models/admin_create_runner.rb +326 -0
  35. data/lib/cogbox_api_client/models/admin_get_webhook_status200_response.rb +147 -0
  36. data/lib/cogbox_api_client/models/announcement.rb +175 -0
  37. data/lib/cogbox_api_client/models/api_key_list.rb +313 -0
  38. data/lib/cogbox_api_client/models/api_key_response.rb +273 -0
  39. data/lib/cogbox_api_client/models/audit_log.rb +369 -0
  40. data/lib/cogbox_api_client/models/build_info.rb +241 -0
  41. data/lib/cogbox_api_client/models/cogbox_configuration.rb +507 -0
  42. data/lib/cogbox_api_client/models/command.rb +202 -0
  43. data/lib/cogbox_api_client/models/completion_context.rb +173 -0
  44. data/lib/cogbox_api_client/models/completion_item.rb +218 -0
  45. data/lib/cogbox_api_client/models/completion_list.rb +192 -0
  46. data/lib/cogbox_api_client/models/compressed_screenshot_response.rb +185 -0
  47. data/lib/cogbox_api_client/models/computer_use_start_response.rb +192 -0
  48. data/lib/cogbox_api_client/models/computer_use_status_response.rb +189 -0
  49. data/lib/cogbox_api_client/models/computer_use_stop_response.rb +192 -0
  50. data/lib/cogbox_api_client/models/create_api_key.rb +217 -0
  51. data/lib/cogbox_api_client/models/create_build_info.rb +177 -0
  52. data/lib/cogbox_api_client/models/create_docker_registry.rb +256 -0
  53. data/lib/cogbox_api_client/models/create_linked_account.rb +192 -0
  54. data/lib/cogbox_api_client/models/create_organization.rb +192 -0
  55. data/lib/cogbox_api_client/models/create_organization_invitation.rb +255 -0
  56. data/lib/cogbox_api_client/models/create_organization_quota.rb +219 -0
  57. data/lib/cogbox_api_client/models/create_organization_region_quota.rb +372 -0
  58. data/lib/cogbox_api_client/models/create_organization_role.rb +233 -0
  59. data/lib/cogbox_api_client/models/create_region.rb +198 -0
  60. data/lib/cogbox_api_client/models/create_region_response.rb +209 -0
  61. data/lib/cogbox_api_client/models/create_runner.rb +202 -0
  62. data/lib/cogbox_api_client/models/create_runner_response.rb +192 -0
  63. data/lib/cogbox_api_client/models/create_sandbox.rb +356 -0
  64. data/lib/cogbox_api_client/models/create_sandbox_snapshot.rb +177 -0
  65. data/lib/cogbox_api_client/models/create_session_request.rb +165 -0
  66. data/lib/cogbox_api_client/models/create_snapshot.rb +291 -0
  67. data/lib/cogbox_api_client/models/create_user.rb +269 -0
  68. data/lib/cogbox_api_client/models/create_volume.rb +164 -0
  69. data/lib/cogbox_api_client/models/display_info_response.rb +167 -0
  70. data/lib/cogbox_api_client/models/docker_registry.rb +378 -0
  71. data/lib/cogbox_api_client/models/download_files.rb +167 -0
  72. data/lib/cogbox_api_client/models/execute_request.rb +184 -0
  73. data/lib/cogbox_api_client/models/execute_response.rb +192 -0
  74. data/lib/cogbox_api_client/models/file_info.rb +346 -0
  75. data/lib/cogbox_api_client/models/file_status.rb +242 -0
  76. data/lib/cogbox_api_client/models/fork_sandbox.rb +148 -0
  77. data/lib/cogbox_api_client/models/git_add_request.rb +193 -0
  78. data/lib/cogbox_api_client/models/git_branch_request.rb +190 -0
  79. data/lib/cogbox_api_client/models/git_checkout_request.rb +190 -0
  80. data/lib/cogbox_api_client/models/git_clone_request.rb +226 -0
  81. data/lib/cogbox_api_client/models/git_commit_info.rb +268 -0
  82. data/lib/cogbox_api_client/models/git_commit_request.rb +254 -0
  83. data/lib/cogbox_api_client/models/git_commit_response.rb +164 -0
  84. data/lib/cogbox_api_client/models/git_delete_branch_request.rb +190 -0
  85. data/lib/cogbox_api_client/models/git_repo_request.rb +182 -0
  86. data/lib/cogbox_api_client/models/git_status.rb +219 -0
  87. data/lib/cogbox_api_client/models/gpu_type.rb +41 -0
  88. data/lib/cogbox_api_client/models/health_controller_check200_response.rb +182 -0
  89. data/lib/cogbox_api_client/models/health_controller_check200_response_info_value.rb +164 -0
  90. data/lib/cogbox_api_client/models/health_controller_check503_response.rb +182 -0
  91. data/lib/cogbox_api_client/models/job.rb +366 -0
  92. data/lib/cogbox_api_client/models/job_status.rb +43 -0
  93. data/lib/cogbox_api_client/models/job_type.rb +54 -0
  94. data/lib/cogbox_api_client/models/keyboard_hotkey_request.rb +165 -0
  95. data/lib/cogbox_api_client/models/keyboard_press_request.rb +177 -0
  96. data/lib/cogbox_api_client/models/keyboard_type_request.rb +175 -0
  97. data/lib/cogbox_api_client/models/list_branch_response.rb +166 -0
  98. data/lib/cogbox_api_client/models/list_sandboxes_response.rb +180 -0
  99. data/lib/cogbox_api_client/models/log_entry.rb +334 -0
  100. data/lib/cogbox_api_client/models/lsp_completion_params.rb +254 -0
  101. data/lib/cogbox_api_client/models/lsp_document_request.rb +219 -0
  102. data/lib/cogbox_api_client/models/lsp_location.rb +190 -0
  103. data/lib/cogbox_api_client/models/lsp_server_request.rb +192 -0
  104. data/lib/cogbox_api_client/models/lsp_symbol.rb +216 -0
  105. data/lib/cogbox_api_client/models/match.rb +216 -0
  106. data/lib/cogbox_api_client/models/metric_data_point.rb +192 -0
  107. data/lib/cogbox_api_client/models/metric_series.rb +194 -0
  108. data/lib/cogbox_api_client/models/metrics_response.rb +167 -0
  109. data/lib/cogbox_api_client/models/mouse_click_request.rb +212 -0
  110. data/lib/cogbox_api_client/models/mouse_click_response.rb +192 -0
  111. data/lib/cogbox_api_client/models/mouse_drag_request.rb +256 -0
  112. data/lib/cogbox_api_client/models/mouse_drag_response.rb +192 -0
  113. data/lib/cogbox_api_client/models/mouse_move_request.rb +192 -0
  114. data/lib/cogbox_api_client/models/mouse_move_response.rb +192 -0
  115. data/lib/cogbox_api_client/models/mouse_position.rb +192 -0
  116. data/lib/cogbox_api_client/models/mouse_scroll_request.rb +229 -0
  117. data/lib/cogbox_api_client/models/mouse_scroll_response.rb +165 -0
  118. data/lib/cogbox_api_client/models/oidc_config.rb +219 -0
  119. data/lib/cogbox_api_client/models/organization.rb +698 -0
  120. data/lib/cogbox_api_client/models/organization_invitation.rb +463 -0
  121. data/lib/cogbox_api_client/models/organization_role.rb +341 -0
  122. data/lib/cogbox_api_client/models/organization_sandbox_default_limited_network_egress.rb +165 -0
  123. data/lib/cogbox_api_client/models/organization_suspension.rb +221 -0
  124. data/lib/cogbox_api_client/models/organization_usage_overview.rb +270 -0
  125. data/lib/cogbox_api_client/models/organization_user.rb +380 -0
  126. data/lib/cogbox_api_client/models/otel_config.rb +178 -0
  127. data/lib/cogbox_api_client/models/paginated_audit_logs.rb +254 -0
  128. data/lib/cogbox_api_client/models/paginated_jobs.rb +244 -0
  129. data/lib/cogbox_api_client/models/paginated_logs.rb +248 -0
  130. data/lib/cogbox_api_client/models/paginated_sandboxes_deprecated.rb +244 -0
  131. data/lib/cogbox_api_client/models/paginated_snapshots.rb +244 -0
  132. data/lib/cogbox_api_client/models/paginated_traces.rb +248 -0
  133. data/lib/cogbox_api_client/models/poll_jobs_response.rb +167 -0
  134. data/lib/cogbox_api_client/models/port_preview_url.rb +219 -0
  135. data/lib/cogbox_api_client/models/position.rb +190 -0
  136. data/lib/cogbox_api_client/models/posthog_config.rb +192 -0
  137. data/lib/cogbox_api_client/models/process_errors_response.rb +192 -0
  138. data/lib/cogbox_api_client/models/process_logs_response.rb +192 -0
  139. data/lib/cogbox_api_client/models/process_restart_response.rb +192 -0
  140. data/lib/cogbox_api_client/models/process_status_response.rb +192 -0
  141. data/lib/cogbox_api_client/models/project_dir_response.rb +147 -0
  142. data/lib/cogbox_api_client/models/pty_create_request.rb +217 -0
  143. data/lib/cogbox_api_client/models/pty_create_response.rb +165 -0
  144. data/lib/cogbox_api_client/models/pty_list_response.rb +167 -0
  145. data/lib/cogbox_api_client/models/pty_resize_request.rb +192 -0
  146. data/lib/cogbox_api_client/models/pty_session_info.rb +354 -0
  147. data/lib/cogbox_api_client/models/range.rb +190 -0
  148. data/lib/cogbox_api_client/models/rate_limit_config.rb +178 -0
  149. data/lib/cogbox_api_client/models/rate_limit_entry.rb +158 -0
  150. data/lib/cogbox_api_client/models/regenerate_api_key_response.rb +165 -0
  151. data/lib/cogbox_api_client/models/region.rb +339 -0
  152. data/lib/cogbox_api_client/models/region_quota.rb +437 -0
  153. data/lib/cogbox_api_client/models/region_screenshot_response.rb +185 -0
  154. data/lib/cogbox_api_client/models/region_type.rb +42 -0
  155. data/lib/cogbox_api_client/models/region_usage_overview.rb +515 -0
  156. data/lib/cogbox_api_client/models/registry_push_access_dto.rb +300 -0
  157. data/lib/cogbox_api_client/models/replace_request.rb +218 -0
  158. data/lib/cogbox_api_client/models/replace_result.rb +165 -0
  159. data/lib/cogbox_api_client/models/resize_sandbox.rb +225 -0
  160. data/lib/cogbox_api_client/models/runner.rb +710 -0
  161. data/lib/cogbox_api_client/models/runner_class.rb +40 -0
  162. data/lib/cogbox_api_client/models/runner_full.rb +747 -0
  163. data/lib/cogbox_api_client/models/runner_health_metrics.rb +482 -0
  164. data/lib/cogbox_api_client/models/runner_healthcheck.rb +217 -0
  165. data/lib/cogbox_api_client/models/runner_service_health.rb +202 -0
  166. data/lib/cogbox_api_client/models/runner_snapshot_dto.rb +202 -0
  167. data/lib/cogbox_api_client/models/runner_state.rb +44 -0
  168. data/lib/cogbox_api_client/models/sandbox.rb +788 -0
  169. data/lib/cogbox_api_client/models/sandbox_class.rb +43 -0
  170. data/lib/cogbox_api_client/models/sandbox_desired_state.rb +45 -0
  171. data/lib/cogbox_api_client/models/sandbox_labels.rb +167 -0
  172. data/lib/cogbox_api_client/models/sandbox_list_item.rb +658 -0
  173. data/lib/cogbox_api_client/models/sandbox_list_sort_direction.rb +41 -0
  174. data/lib/cogbox_api_client/models/sandbox_list_sort_field.rb +45 -0
  175. data/lib/cogbox_api_client/models/sandbox_state.rb +61 -0
  176. data/lib/cogbox_api_client/models/sandbox_volume.rb +202 -0
  177. data/lib/cogbox_api_client/models/screenshot_response.rb +185 -0
  178. data/lib/cogbox_api_client/models/search_files_response.rb +166 -0
  179. data/lib/cogbox_api_client/models/send_webhook_dto.rb +224 -0
  180. data/lib/cogbox_api_client/models/session.rb +180 -0
  181. data/lib/cogbox_api_client/models/session_execute_request.rb +185 -0
  182. data/lib/cogbox_api_client/models/session_execute_response.rb +168 -0
  183. data/lib/cogbox_api_client/models/set_snapshot_general_status_dto.rb +165 -0
  184. data/lib/cogbox_api_client/models/signed_port_preview_url.rb +246 -0
  185. data/lib/cogbox_api_client/models/snapshot_dto.rb +562 -0
  186. data/lib/cogbox_api_client/models/snapshot_manager_credentials.rb +192 -0
  187. data/lib/cogbox_api_client/models/snapshot_state.rb +47 -0
  188. data/lib/cogbox_api_client/models/ssh_access_dto.rb +327 -0
  189. data/lib/cogbox_api_client/models/ssh_access_validation_dto.rb +192 -0
  190. data/lib/cogbox_api_client/models/storage_access_dto.rb +300 -0
  191. data/lib/cogbox_api_client/models/toolbox_proxy_url.rb +165 -0
  192. data/lib/cogbox_api_client/models/trace_span.rb +332 -0
  193. data/lib/cogbox_api_client/models/trace_summary.rb +310 -0
  194. data/lib/cogbox_api_client/models/update_docker_registry.rb +239 -0
  195. data/lib/cogbox_api_client/models/update_job_status.rb +207 -0
  196. data/lib/cogbox_api_client/models/update_organization_default_region.rb +165 -0
  197. data/lib/cogbox_api_client/models/update_organization_invitation.rb +228 -0
  198. data/lib/cogbox_api_client/models/update_organization_member_access.rb +218 -0
  199. data/lib/cogbox_api_client/models/update_organization_quota.rb +295 -0
  200. data/lib/cogbox_api_client/models/update_organization_region_quota.rb +299 -0
  201. data/lib/cogbox_api_client/models/update_organization_role.rb +233 -0
  202. data/lib/cogbox_api_client/models/update_region.rb +171 -0
  203. data/lib/cogbox_api_client/models/update_sandbox_network_settings.rb +168 -0
  204. data/lib/cogbox_api_client/models/update_sandbox_state_dto.rb +209 -0
  205. data/lib/cogbox_api_client/models/url.rb +165 -0
  206. data/lib/cogbox_api_client/models/user.rb +275 -0
  207. data/lib/cogbox_api_client/models/user_home_dir_response.rb +147 -0
  208. data/lib/cogbox_api_client/models/user_public_key.rb +192 -0
  209. data/lib/cogbox_api_client/models/volume_dto.rb +346 -0
  210. data/lib/cogbox_api_client/models/volume_state.rb +46 -0
  211. data/lib/cogbox_api_client/models/webhook_app_portal_access.rb +192 -0
  212. data/lib/cogbox_api_client/models/webhook_event.rb +46 -0
  213. data/lib/cogbox_api_client/models/webhook_initialization_status.rb +272 -0
  214. data/lib/cogbox_api_client/models/windows_response.rb +194 -0
  215. data/lib/cogbox_api_client/models/work_dir_response.rb +147 -0
  216. data/lib/cogbox_api_client/version.rb +15 -0
  217. data/lib/cogbox_api_client.rb +241 -0
  218. data/project.json +68 -0
  219. metadata +297 -0
@@ -0,0 +1,229 @@
1
+ =begin
2
+ #Cogbox
3
+
4
+ #Cogbox AI platform API Docs
5
+
6
+ The version of the OpenAPI document: 1.0
7
+ Contact: support@cogbox.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.21.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module CogboxApiClient
17
+ class MouseScrollRequest < ApiModelBase
18
+ # The X coordinate where to perform the scroll operation
19
+ attr_accessor :x
20
+
21
+ # The Y coordinate where to perform the scroll operation
22
+ attr_accessor :y
23
+
24
+ # The scroll direction (up, down)
25
+ attr_accessor :direction
26
+
27
+ # The number of scroll units to scroll. Defaults to 1
28
+ attr_accessor :amount
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ def self.attribute_map
32
+ {
33
+ :'x' => :'x',
34
+ :'y' => :'y',
35
+ :'direction' => :'direction',
36
+ :'amount' => :'amount'
37
+ }
38
+ end
39
+
40
+ # Returns attribute mapping this model knows about
41
+ def self.acceptable_attribute_map
42
+ attribute_map
43
+ end
44
+
45
+ # Returns all the JSON keys this model knows about
46
+ def self.acceptable_attributes
47
+ acceptable_attribute_map.values
48
+ end
49
+
50
+ # Attribute type mapping.
51
+ def self.openapi_types
52
+ {
53
+ :'x' => :'Float',
54
+ :'y' => :'Float',
55
+ :'direction' => :'String',
56
+ :'amount' => :'Float'
57
+ }
58
+ end
59
+
60
+ # List of attributes with nullable: true
61
+ def self.openapi_nullable
62
+ Set.new([
63
+ ])
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `CogboxApiClient::MouseScrollRequest` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ acceptable_attribute_map = self.class.acceptable_attribute_map
75
+ attributes = attributes.each_with_object({}) { |(k, v), h|
76
+ if (!acceptable_attribute_map.key?(k.to_sym))
77
+ fail ArgumentError, "`#{k}` is not a valid attribute in `CogboxApiClient::MouseScrollRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
78
+ end
79
+ h[k.to_sym] = v
80
+ }
81
+
82
+ if attributes.key?(:'x')
83
+ self.x = attributes[:'x']
84
+ else
85
+ self.x = nil
86
+ end
87
+
88
+ if attributes.key?(:'y')
89
+ self.y = attributes[:'y']
90
+ else
91
+ self.y = nil
92
+ end
93
+
94
+ if attributes.key?(:'direction')
95
+ self.direction = attributes[:'direction']
96
+ else
97
+ self.direction = nil
98
+ end
99
+
100
+ if attributes.key?(:'amount')
101
+ self.amount = attributes[:'amount']
102
+ end
103
+ end
104
+
105
+ # Show invalid properties with the reasons. Usually used together with valid?
106
+ # @return Array for valid properties with the reasons
107
+ def list_invalid_properties
108
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
109
+ invalid_properties = Array.new
110
+ if @x.nil?
111
+ invalid_properties.push('invalid value for "x", x cannot be nil.')
112
+ end
113
+
114
+ if @y.nil?
115
+ invalid_properties.push('invalid value for "y", y cannot be nil.')
116
+ end
117
+
118
+ if @direction.nil?
119
+ invalid_properties.push('invalid value for "direction", direction cannot be nil.')
120
+ end
121
+
122
+ invalid_properties
123
+ end
124
+
125
+ # Check to see if the all the properties in the model are valid
126
+ # @return true if the model is valid
127
+ def valid?
128
+ warn '[DEPRECATED] the `valid?` method is obsolete'
129
+ return false if @x.nil?
130
+ return false if @y.nil?
131
+ return false if @direction.nil?
132
+ true
133
+ end
134
+
135
+ # Custom attribute writer method with validation
136
+ # @param [Object] x Value to be assigned
137
+ def x=(x)
138
+ if x.nil?
139
+ fail ArgumentError, 'x cannot be nil'
140
+ end
141
+
142
+ @x = x
143
+ end
144
+
145
+ # Custom attribute writer method with validation
146
+ # @param [Object] y Value to be assigned
147
+ def y=(y)
148
+ if y.nil?
149
+ fail ArgumentError, 'y cannot be nil'
150
+ end
151
+
152
+ @y = y
153
+ end
154
+
155
+ # Custom attribute writer method with validation
156
+ # @param [Object] direction Value to be assigned
157
+ def direction=(direction)
158
+ if direction.nil?
159
+ fail ArgumentError, 'direction cannot be nil'
160
+ end
161
+
162
+ @direction = direction
163
+ end
164
+
165
+ # Checks equality by comparing each attribute.
166
+ # @param [Object] Object to be compared
167
+ def ==(o)
168
+ return true if self.equal?(o)
169
+ self.class == o.class &&
170
+ x == o.x &&
171
+ y == o.y &&
172
+ direction == o.direction &&
173
+ amount == o.amount
174
+ end
175
+
176
+ # @see the `==` method
177
+ # @param [Object] Object to be compared
178
+ def eql?(o)
179
+ self == o
180
+ end
181
+
182
+ # Calculates hash code according to all attributes.
183
+ # @return [Integer] Hash code
184
+ def hash
185
+ [x, y, direction, amount].hash
186
+ end
187
+
188
+ # Builds the object from hash
189
+ # @param [Hash] attributes Model attributes in the form of hash
190
+ # @return [Object] Returns the model itself
191
+ def self.build_from_hash(attributes)
192
+ return nil unless attributes.is_a?(Hash)
193
+ attributes = attributes.transform_keys(&:to_sym)
194
+ transformed_hash = {}
195
+ openapi_types.each_pair do |key, type|
196
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
197
+ transformed_hash["#{key}"] = nil
198
+ elsif type =~ /\AArray<(.*)>/i
199
+ # check to ensure the input is an array given that the attribute
200
+ # is documented as an array but the input is not
201
+ if attributes[attribute_map[key]].is_a?(Array)
202
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
203
+ end
204
+ elsif !attributes[attribute_map[key]].nil?
205
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
206
+ end
207
+ end
208
+ new(transformed_hash)
209
+ end
210
+
211
+ # Returns the object in the form of hash
212
+ # @return [Hash] Returns the object in the form of hash
213
+ def to_hash
214
+ hash = {}
215
+ self.class.attribute_map.each_pair do |attr, param|
216
+ value = self.send(attr)
217
+ if value.nil?
218
+ is_nullable = self.class.openapi_nullable.include?(attr)
219
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
220
+ end
221
+
222
+ hash[param] = _to_hash(value)
223
+ end
224
+ hash
225
+ end
226
+
227
+ end
228
+
229
+ end
@@ -0,0 +1,165 @@
1
+ =begin
2
+ #Cogbox
3
+
4
+ #Cogbox AI platform API Docs
5
+
6
+ The version of the OpenAPI document: 1.0
7
+ Contact: support@cogbox.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.21.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module CogboxApiClient
17
+ class MouseScrollResponse < ApiModelBase
18
+ # Whether the mouse scroll operation was successful
19
+ attr_accessor :success
20
+
21
+ # Attribute mapping from ruby-style variable name to JSON key.
22
+ def self.attribute_map
23
+ {
24
+ :'success' => :'success'
25
+ }
26
+ end
27
+
28
+ # Returns attribute mapping this model knows about
29
+ def self.acceptable_attribute_map
30
+ attribute_map
31
+ end
32
+
33
+ # Returns all the JSON keys this model knows about
34
+ def self.acceptable_attributes
35
+ acceptable_attribute_map.values
36
+ end
37
+
38
+ # Attribute type mapping.
39
+ def self.openapi_types
40
+ {
41
+ :'success' => :'Boolean'
42
+ }
43
+ end
44
+
45
+ # List of attributes with nullable: true
46
+ def self.openapi_nullable
47
+ Set.new([
48
+ ])
49
+ end
50
+
51
+ # Initializes the object
52
+ # @param [Hash] attributes Model attributes in the form of hash
53
+ def initialize(attributes = {})
54
+ if (!attributes.is_a?(Hash))
55
+ fail ArgumentError, "The input argument (attributes) must be a hash in `CogboxApiClient::MouseScrollResponse` initialize method"
56
+ end
57
+
58
+ # check to see if the attribute exists and convert string to symbol for hash key
59
+ acceptable_attribute_map = self.class.acceptable_attribute_map
60
+ attributes = attributes.each_with_object({}) { |(k, v), h|
61
+ if (!acceptable_attribute_map.key?(k.to_sym))
62
+ fail ArgumentError, "`#{k}` is not a valid attribute in `CogboxApiClient::MouseScrollResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
+ end
64
+ h[k.to_sym] = v
65
+ }
66
+
67
+ if attributes.key?(:'success')
68
+ self.success = attributes[:'success']
69
+ else
70
+ self.success = nil
71
+ end
72
+ end
73
+
74
+ # Show invalid properties with the reasons. Usually used together with valid?
75
+ # @return Array for valid properties with the reasons
76
+ def list_invalid_properties
77
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
78
+ invalid_properties = Array.new
79
+ if @success.nil?
80
+ invalid_properties.push('invalid value for "success", success cannot be nil.')
81
+ end
82
+
83
+ invalid_properties
84
+ end
85
+
86
+ # Check to see if the all the properties in the model are valid
87
+ # @return true if the model is valid
88
+ def valid?
89
+ warn '[DEPRECATED] the `valid?` method is obsolete'
90
+ return false if @success.nil?
91
+ true
92
+ end
93
+
94
+ # Custom attribute writer method with validation
95
+ # @param [Object] success Value to be assigned
96
+ def success=(success)
97
+ if success.nil?
98
+ fail ArgumentError, 'success cannot be nil'
99
+ end
100
+
101
+ @success = success
102
+ end
103
+
104
+ # Checks equality by comparing each attribute.
105
+ # @param [Object] Object to be compared
106
+ def ==(o)
107
+ return true if self.equal?(o)
108
+ self.class == o.class &&
109
+ success == o.success
110
+ end
111
+
112
+ # @see the `==` method
113
+ # @param [Object] Object to be compared
114
+ def eql?(o)
115
+ self == o
116
+ end
117
+
118
+ # Calculates hash code according to all attributes.
119
+ # @return [Integer] Hash code
120
+ def hash
121
+ [success].hash
122
+ end
123
+
124
+ # Builds the object from hash
125
+ # @param [Hash] attributes Model attributes in the form of hash
126
+ # @return [Object] Returns the model itself
127
+ def self.build_from_hash(attributes)
128
+ return nil unless attributes.is_a?(Hash)
129
+ attributes = attributes.transform_keys(&:to_sym)
130
+ transformed_hash = {}
131
+ openapi_types.each_pair do |key, type|
132
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
133
+ transformed_hash["#{key}"] = nil
134
+ elsif type =~ /\AArray<(.*)>/i
135
+ # check to ensure the input is an array given that the attribute
136
+ # is documented as an array but the input is not
137
+ if attributes[attribute_map[key]].is_a?(Array)
138
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
139
+ end
140
+ elsif !attributes[attribute_map[key]].nil?
141
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
142
+ end
143
+ end
144
+ new(transformed_hash)
145
+ end
146
+
147
+ # Returns the object in the form of hash
148
+ # @return [Hash] Returns the object in the form of hash
149
+ def to_hash
150
+ hash = {}
151
+ self.class.attribute_map.each_pair do |attr, param|
152
+ value = self.send(attr)
153
+ if value.nil?
154
+ is_nullable = self.class.openapi_nullable.include?(attr)
155
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
156
+ end
157
+
158
+ hash[param] = _to_hash(value)
159
+ end
160
+ hash
161
+ end
162
+
163
+ end
164
+
165
+ end
@@ -0,0 +1,219 @@
1
+ =begin
2
+ #Cogbox
3
+
4
+ #Cogbox AI platform API Docs
5
+
6
+ The version of the OpenAPI document: 1.0
7
+ Contact: support@cogbox.com
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.21.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module CogboxApiClient
17
+ class OidcConfig < ApiModelBase
18
+ # OIDC issuer
19
+ attr_accessor :issuer
20
+
21
+ # OIDC client ID
22
+ attr_accessor :client_id
23
+
24
+ # OIDC audience
25
+ attr_accessor :audience
26
+
27
+ # Attribute mapping from ruby-style variable name to JSON key.
28
+ def self.attribute_map
29
+ {
30
+ :'issuer' => :'issuer',
31
+ :'client_id' => :'clientId',
32
+ :'audience' => :'audience'
33
+ }
34
+ end
35
+
36
+ # Returns attribute mapping this model knows about
37
+ def self.acceptable_attribute_map
38
+ attribute_map
39
+ end
40
+
41
+ # Returns all the JSON keys this model knows about
42
+ def self.acceptable_attributes
43
+ acceptable_attribute_map.values
44
+ end
45
+
46
+ # Attribute type mapping.
47
+ def self.openapi_types
48
+ {
49
+ :'issuer' => :'String',
50
+ :'client_id' => :'String',
51
+ :'audience' => :'String'
52
+ }
53
+ end
54
+
55
+ # List of attributes with nullable: true
56
+ def self.openapi_nullable
57
+ Set.new([
58
+ ])
59
+ end
60
+
61
+ # Initializes the object
62
+ # @param [Hash] attributes Model attributes in the form of hash
63
+ def initialize(attributes = {})
64
+ if (!attributes.is_a?(Hash))
65
+ fail ArgumentError, "The input argument (attributes) must be a hash in `CogboxApiClient::OidcConfig` initialize method"
66
+ end
67
+
68
+ # check to see if the attribute exists and convert string to symbol for hash key
69
+ acceptable_attribute_map = self.class.acceptable_attribute_map
70
+ attributes = attributes.each_with_object({}) { |(k, v), h|
71
+ if (!acceptable_attribute_map.key?(k.to_sym))
72
+ fail ArgumentError, "`#{k}` is not a valid attribute in `CogboxApiClient::OidcConfig`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
73
+ end
74
+ h[k.to_sym] = v
75
+ }
76
+
77
+ if attributes.key?(:'issuer')
78
+ self.issuer = attributes[:'issuer']
79
+ else
80
+ self.issuer = nil
81
+ end
82
+
83
+ if attributes.key?(:'client_id')
84
+ self.client_id = attributes[:'client_id']
85
+ else
86
+ self.client_id = nil
87
+ end
88
+
89
+ if attributes.key?(:'audience')
90
+ self.audience = attributes[:'audience']
91
+ else
92
+ self.audience = nil
93
+ end
94
+ end
95
+
96
+ # Show invalid properties with the reasons. Usually used together with valid?
97
+ # @return Array for valid properties with the reasons
98
+ def list_invalid_properties
99
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
100
+ invalid_properties = Array.new
101
+ if @issuer.nil?
102
+ invalid_properties.push('invalid value for "issuer", issuer cannot be nil.')
103
+ end
104
+
105
+ if @client_id.nil?
106
+ invalid_properties.push('invalid value for "client_id", client_id cannot be nil.')
107
+ end
108
+
109
+ if @audience.nil?
110
+ invalid_properties.push('invalid value for "audience", audience cannot be nil.')
111
+ end
112
+
113
+ invalid_properties
114
+ end
115
+
116
+ # Check to see if the all the properties in the model are valid
117
+ # @return true if the model is valid
118
+ def valid?
119
+ warn '[DEPRECATED] the `valid?` method is obsolete'
120
+ return false if @issuer.nil?
121
+ return false if @client_id.nil?
122
+ return false if @audience.nil?
123
+ true
124
+ end
125
+
126
+ # Custom attribute writer method with validation
127
+ # @param [Object] issuer Value to be assigned
128
+ def issuer=(issuer)
129
+ if issuer.nil?
130
+ fail ArgumentError, 'issuer cannot be nil'
131
+ end
132
+
133
+ @issuer = issuer
134
+ end
135
+
136
+ # Custom attribute writer method with validation
137
+ # @param [Object] client_id Value to be assigned
138
+ def client_id=(client_id)
139
+ if client_id.nil?
140
+ fail ArgumentError, 'client_id cannot be nil'
141
+ end
142
+
143
+ @client_id = client_id
144
+ end
145
+
146
+ # Custom attribute writer method with validation
147
+ # @param [Object] audience Value to be assigned
148
+ def audience=(audience)
149
+ if audience.nil?
150
+ fail ArgumentError, 'audience cannot be nil'
151
+ end
152
+
153
+ @audience = audience
154
+ end
155
+
156
+ # Checks equality by comparing each attribute.
157
+ # @param [Object] Object to be compared
158
+ def ==(o)
159
+ return true if self.equal?(o)
160
+ self.class == o.class &&
161
+ issuer == o.issuer &&
162
+ client_id == o.client_id &&
163
+ audience == o.audience
164
+ end
165
+
166
+ # @see the `==` method
167
+ # @param [Object] Object to be compared
168
+ def eql?(o)
169
+ self == o
170
+ end
171
+
172
+ # Calculates hash code according to all attributes.
173
+ # @return [Integer] Hash code
174
+ def hash
175
+ [issuer, client_id, audience].hash
176
+ end
177
+
178
+ # Builds the object from hash
179
+ # @param [Hash] attributes Model attributes in the form of hash
180
+ # @return [Object] Returns the model itself
181
+ def self.build_from_hash(attributes)
182
+ return nil unless attributes.is_a?(Hash)
183
+ attributes = attributes.transform_keys(&:to_sym)
184
+ transformed_hash = {}
185
+ openapi_types.each_pair do |key, type|
186
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
187
+ transformed_hash["#{key}"] = nil
188
+ elsif type =~ /\AArray<(.*)>/i
189
+ # check to ensure the input is an array given that the attribute
190
+ # is documented as an array but the input is not
191
+ if attributes[attribute_map[key]].is_a?(Array)
192
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
193
+ end
194
+ elsif !attributes[attribute_map[key]].nil?
195
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
196
+ end
197
+ end
198
+ new(transformed_hash)
199
+ end
200
+
201
+ # Returns the object in the form of hash
202
+ # @return [Hash] Returns the object in the form of hash
203
+ def to_hash
204
+ hash = {}
205
+ self.class.attribute_map.each_pair do |attr, param|
206
+ value = self.send(attr)
207
+ if value.nil?
208
+ is_nullable = self.class.openapi_nullable.include?(attr)
209
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
210
+ end
211
+
212
+ hash[param] = _to_hash(value)
213
+ end
214
+ hash
215
+ end
216
+
217
+ end
218
+
219
+ end