daytona_api_client 0.216.0 → 0.216.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 (39) hide show
  1. checksums.yaml +4 -4
  2. data/.openapi-generator/FILES +15 -16
  3. data/lib/daytona_api_client/api/organizations_api.rb +260 -484
  4. data/lib/daytona_api_client/api/sandbox_api.rb +14 -163
  5. data/lib/daytona_api_client/api/users_api.rb +82 -90
  6. data/lib/daytona_api_client/models/account_provider.rb +48 -19
  7. data/lib/daytona_api_client/models/api_key_list.rb +14 -4
  8. data/lib/daytona_api_client/models/create_runner.rb +37 -4
  9. data/lib/daytona_api_client/models/create_runner_sandbox_class.rb +42 -0
  10. data/lib/daytona_api_client/models/daytona_configuration.rb +45 -1
  11. data/lib/daytona_api_client/models/{organization_preview_warning.rb → generate_workos_admin_portal_link.rb} +42 -20
  12. data/lib/daytona_api_client/models/{send_webhook_dto.rb → gpu_capacity.rb} +77 -43
  13. data/lib/daytona_api_client/models/{organization_sso_enabled.rb → gpu_capacity_response.rb} +48 -20
  14. data/lib/daytona_api_client/models/oidc_config.rb +65 -4
  15. data/lib/daytona_api_client/models/organization.rb +38 -1
  16. data/lib/daytona_api_client/models/sandbox_created_webhook.rb +349 -0
  17. data/lib/daytona_api_client/models/{organization_sandbox_default_limited_network_egress.rb → sandbox_identity.rb} +47 -20
  18. data/lib/daytona_api_client/models/sandbox_state_updated_webhook.rb +349 -0
  19. data/lib/daytona_api_client/models/snapshot_created_webhook.rb +349 -0
  20. data/lib/daytona_api_client/models/{create_user.rb → snapshot_removed_webhook.rb} +119 -71
  21. data/lib/daytona_api_client/models/snapshot_state_updated_webhook.rb +376 -0
  22. data/lib/daytona_api_client/models/user.rb +11 -1
  23. data/lib/daytona_api_client/models/volume_created_webhook.rb +349 -0
  24. data/lib/daytona_api_client/models/volume_state_updated_webhook.rb +376 -0
  25. data/lib/daytona_api_client/models/workos_admin_portal_intent.rb +41 -0
  26. data/lib/daytona_api_client/models/{set_snapshot_general_status_dto.rb → workos_admin_portal_link.rb} +20 -20
  27. data/lib/daytona_api_client/models/{admin_create_runner.rb → workos_sso_connection.rb} +123 -120
  28. data/lib/daytona_api_client/version.rb +1 -1
  29. data/lib/daytona_api_client.rb +15 -16
  30. metadata +16 -17
  31. data/lib/daytona_api_client/api/admin_api.rb +0 -1618
  32. data/lib/daytona_api_client/models/admin_create_organization.rb +0 -219
  33. data/lib/daytona_api_client/models/admin_get_webhook_status200_response.rb +0 -147
  34. data/lib/daytona_api_client/models/create_organization_quota.rb +0 -238
  35. data/lib/daytona_api_client/models/create_organization_region_quota.rb +0 -386
  36. data/lib/daytona_api_client/models/organization_suspension.rb +0 -221
  37. data/lib/daytona_api_client/models/paginated_sandboxes_deprecated.rb +0 -244
  38. data/lib/daytona_api_client/models/update_organization_quota.rb +0 -333
  39. data/lib/daytona_api_client/models/update_organization_region_quota.rb +0 -313
@@ -1,313 +0,0 @@
1
- =begin
2
- #Daytona
3
-
4
- #Daytona AI platform API Docs
5
-
6
- The version of the OpenAPI document: 1.0
7
- Contact: support@daytona.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 DaytonaApiClient
17
- class UpdateOrganizationRegionQuota < ApiModelBase
18
- attr_accessor :sandbox_class
19
-
20
- attr_accessor :total_cpu_quota
21
-
22
- attr_accessor :total_memory_quota
23
-
24
- attr_accessor :total_disk_quota
25
-
26
- attr_accessor :total_gpu_quota
27
-
28
- attr_accessor :allowed_gpu_types
29
-
30
- attr_accessor :max_cpu_per_sandbox
31
-
32
- attr_accessor :max_memory_per_sandbox
33
-
34
- attr_accessor :max_disk_per_sandbox
35
-
36
- attr_accessor :max_disk_per_non_ephemeral_sandbox
37
-
38
- # CPU maximum per requested GPU unit for GPU sandboxes.
39
- attr_accessor :max_cpu_per_gpu
40
-
41
- # Memory maximum per requested GPU unit for GPU sandboxes.
42
- attr_accessor :max_memory_per_gpu
43
-
44
- # Disk maximum per requested GPU unit for GPU sandboxes.
45
- attr_accessor :max_disk_per_gpu
46
-
47
- # Maximum sandbox lifespan in minutes, measured from sandbox creation to its auto-destroy deadline. If null or 0, lifespan is unrestricted. When set, sandboxes created without a TTL default to this lifespan and TTL cannot be disabled.
48
- attr_accessor :max_sandbox_lifespan
49
-
50
- class EnumAttributeValidator
51
- attr_reader :datatype
52
- attr_reader :allowable_values
53
-
54
- def initialize(datatype, allowable_values)
55
- @allowable_values = allowable_values.map do |value|
56
- case datatype.to_s
57
- when /Integer/i
58
- value.to_i
59
- when /Float/i
60
- value.to_f
61
- else
62
- value
63
- end
64
- end
65
- end
66
-
67
- def valid?(value)
68
- !value || allowable_values.include?(value)
69
- end
70
- end
71
-
72
- # Attribute mapping from ruby-style variable name to JSON key.
73
- def self.attribute_map
74
- {
75
- :'sandbox_class' => :'sandboxClass',
76
- :'total_cpu_quota' => :'totalCpuQuota',
77
- :'total_memory_quota' => :'totalMemoryQuota',
78
- :'total_disk_quota' => :'totalDiskQuota',
79
- :'total_gpu_quota' => :'totalGpuQuota',
80
- :'allowed_gpu_types' => :'allowedGpuTypes',
81
- :'max_cpu_per_sandbox' => :'maxCpuPerSandbox',
82
- :'max_memory_per_sandbox' => :'maxMemoryPerSandbox',
83
- :'max_disk_per_sandbox' => :'maxDiskPerSandbox',
84
- :'max_disk_per_non_ephemeral_sandbox' => :'maxDiskPerNonEphemeralSandbox',
85
- :'max_cpu_per_gpu' => :'maxCpuPerGpu',
86
- :'max_memory_per_gpu' => :'maxMemoryPerGpu',
87
- :'max_disk_per_gpu' => :'maxDiskPerGpu',
88
- :'max_sandbox_lifespan' => :'maxSandboxLifespan'
89
- }
90
- end
91
-
92
- # Returns attribute mapping this model knows about
93
- def self.acceptable_attribute_map
94
- attribute_map
95
- end
96
-
97
- # Returns all the JSON keys this model knows about
98
- def self.acceptable_attributes
99
- acceptable_attribute_map.values
100
- end
101
-
102
- # Attribute type mapping.
103
- def self.openapi_types
104
- {
105
- :'sandbox_class' => :'SandboxClass',
106
- :'total_cpu_quota' => :'Float',
107
- :'total_memory_quota' => :'Float',
108
- :'total_disk_quota' => :'Float',
109
- :'total_gpu_quota' => :'Float',
110
- :'allowed_gpu_types' => :'Array<GpuType>',
111
- :'max_cpu_per_sandbox' => :'Float',
112
- :'max_memory_per_sandbox' => :'Float',
113
- :'max_disk_per_sandbox' => :'Float',
114
- :'max_disk_per_non_ephemeral_sandbox' => :'Float',
115
- :'max_cpu_per_gpu' => :'Float',
116
- :'max_memory_per_gpu' => :'Float',
117
- :'max_disk_per_gpu' => :'Float',
118
- :'max_sandbox_lifespan' => :'Float'
119
- }
120
- end
121
-
122
- # List of attributes with nullable: true
123
- def self.openapi_nullable
124
- Set.new([
125
- :'total_cpu_quota',
126
- :'total_memory_quota',
127
- :'total_disk_quota',
128
- :'total_gpu_quota',
129
- :'allowed_gpu_types',
130
- :'max_cpu_per_sandbox',
131
- :'max_memory_per_sandbox',
132
- :'max_disk_per_sandbox',
133
- :'max_disk_per_non_ephemeral_sandbox',
134
- :'max_cpu_per_gpu',
135
- :'max_memory_per_gpu',
136
- :'max_disk_per_gpu',
137
- :'max_sandbox_lifespan'
138
- ])
139
- end
140
-
141
- # Initializes the object
142
- # @param [Hash] attributes Model attributes in the form of hash
143
- def initialize(attributes = {})
144
- if (!attributes.is_a?(Hash))
145
- fail ArgumentError, "The input argument (attributes) must be a hash in `DaytonaApiClient::UpdateOrganizationRegionQuota` initialize method"
146
- end
147
-
148
- # check to see if the attribute exists and convert string to symbol for hash key
149
- acceptable_attribute_map = self.class.acceptable_attribute_map
150
- attributes = attributes.each_with_object({}) { |(k, v), h|
151
- if (!acceptable_attribute_map.key?(k.to_sym))
152
- fail ArgumentError, "`#{k}` is not a valid attribute in `DaytonaApiClient::UpdateOrganizationRegionQuota`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
153
- end
154
- h[k.to_sym] = v
155
- }
156
-
157
- if attributes.key?(:'sandbox_class')
158
- self.sandbox_class = attributes[:'sandbox_class']
159
- end
160
-
161
- if attributes.key?(:'total_cpu_quota')
162
- self.total_cpu_quota = attributes[:'total_cpu_quota']
163
- else
164
- self.total_cpu_quota = nil
165
- end
166
-
167
- if attributes.key?(:'total_memory_quota')
168
- self.total_memory_quota = attributes[:'total_memory_quota']
169
- else
170
- self.total_memory_quota = nil
171
- end
172
-
173
- if attributes.key?(:'total_disk_quota')
174
- self.total_disk_quota = attributes[:'total_disk_quota']
175
- else
176
- self.total_disk_quota = nil
177
- end
178
-
179
- if attributes.key?(:'total_gpu_quota')
180
- self.total_gpu_quota = attributes[:'total_gpu_quota']
181
- else
182
- self.total_gpu_quota = nil
183
- end
184
-
185
- if attributes.key?(:'allowed_gpu_types')
186
- if (value = attributes[:'allowed_gpu_types']).is_a?(Array)
187
- self.allowed_gpu_types = value
188
- end
189
- end
190
-
191
- if attributes.key?(:'max_cpu_per_sandbox')
192
- self.max_cpu_per_sandbox = attributes[:'max_cpu_per_sandbox']
193
- end
194
-
195
- if attributes.key?(:'max_memory_per_sandbox')
196
- self.max_memory_per_sandbox = attributes[:'max_memory_per_sandbox']
197
- end
198
-
199
- if attributes.key?(:'max_disk_per_sandbox')
200
- self.max_disk_per_sandbox = attributes[:'max_disk_per_sandbox']
201
- end
202
-
203
- if attributes.key?(:'max_disk_per_non_ephemeral_sandbox')
204
- self.max_disk_per_non_ephemeral_sandbox = attributes[:'max_disk_per_non_ephemeral_sandbox']
205
- end
206
-
207
- if attributes.key?(:'max_cpu_per_gpu')
208
- self.max_cpu_per_gpu = attributes[:'max_cpu_per_gpu']
209
- end
210
-
211
- if attributes.key?(:'max_memory_per_gpu')
212
- self.max_memory_per_gpu = attributes[:'max_memory_per_gpu']
213
- end
214
-
215
- if attributes.key?(:'max_disk_per_gpu')
216
- self.max_disk_per_gpu = attributes[:'max_disk_per_gpu']
217
- end
218
-
219
- if attributes.key?(:'max_sandbox_lifespan')
220
- self.max_sandbox_lifespan = attributes[:'max_sandbox_lifespan']
221
- end
222
- end
223
-
224
- # Show invalid properties with the reasons. Usually used together with valid?
225
- # @return Array for valid properties with the reasons
226
- def list_invalid_properties
227
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
228
- invalid_properties = Array.new
229
- invalid_properties
230
- end
231
-
232
- # Check to see if the all the properties in the model are valid
233
- # @return true if the model is valid
234
- def valid?
235
- warn '[DEPRECATED] the `valid?` method is obsolete'
236
- true
237
- end
238
-
239
- # Checks equality by comparing each attribute.
240
- # @param [Object] Object to be compared
241
- def ==(o)
242
- return true if self.equal?(o)
243
- self.class == o.class &&
244
- sandbox_class == o.sandbox_class &&
245
- total_cpu_quota == o.total_cpu_quota &&
246
- total_memory_quota == o.total_memory_quota &&
247
- total_disk_quota == o.total_disk_quota &&
248
- total_gpu_quota == o.total_gpu_quota &&
249
- allowed_gpu_types == o.allowed_gpu_types &&
250
- max_cpu_per_sandbox == o.max_cpu_per_sandbox &&
251
- max_memory_per_sandbox == o.max_memory_per_sandbox &&
252
- max_disk_per_sandbox == o.max_disk_per_sandbox &&
253
- max_disk_per_non_ephemeral_sandbox == o.max_disk_per_non_ephemeral_sandbox &&
254
- max_cpu_per_gpu == o.max_cpu_per_gpu &&
255
- max_memory_per_gpu == o.max_memory_per_gpu &&
256
- max_disk_per_gpu == o.max_disk_per_gpu &&
257
- max_sandbox_lifespan == o.max_sandbox_lifespan
258
- end
259
-
260
- # @see the `==` method
261
- # @param [Object] Object to be compared
262
- def eql?(o)
263
- self == o
264
- end
265
-
266
- # Calculates hash code according to all attributes.
267
- # @return [Integer] Hash code
268
- def hash
269
- [sandbox_class, total_cpu_quota, total_memory_quota, total_disk_quota, total_gpu_quota, allowed_gpu_types, max_cpu_per_sandbox, max_memory_per_sandbox, max_disk_per_sandbox, max_disk_per_non_ephemeral_sandbox, max_cpu_per_gpu, max_memory_per_gpu, max_disk_per_gpu, max_sandbox_lifespan].hash
270
- end
271
-
272
- # Builds the object from hash
273
- # @param [Hash] attributes Model attributes in the form of hash
274
- # @return [Object] Returns the model itself
275
- def self.build_from_hash(attributes)
276
- return nil unless attributes.is_a?(Hash)
277
- attributes = attributes.transform_keys(&:to_sym)
278
- transformed_hash = {}
279
- openapi_types.each_pair do |key, type|
280
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
281
- transformed_hash["#{key}"] = nil
282
- elsif type =~ /\AArray<(.*)>/i
283
- # check to ensure the input is an array given that the attribute
284
- # is documented as an array but the input is not
285
- if attributes[attribute_map[key]].is_a?(Array)
286
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
287
- end
288
- elsif !attributes[attribute_map[key]].nil?
289
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
290
- end
291
- end
292
- new(transformed_hash)
293
- end
294
-
295
- # Returns the object in the form of hash
296
- # @return [Hash] Returns the object in the form of hash
297
- def to_hash
298
- hash = {}
299
- self.class.attribute_map.each_pair do |attr, param|
300
- value = self.send(attr)
301
- if value.nil?
302
- is_nullable = self.class.openapi_nullable.include?(attr)
303
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
304
- end
305
-
306
- hash[param] = _to_hash(value)
307
- end
308
- hash
309
- end
310
-
311
- end
312
-
313
- end