daytona_api_client 0.167.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (210) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +9 -0
  3. data/Gemfile.lock +101 -0
  4. data/daytona_api_client.gemspec +2 -2
  5. data/lib/daytona_api_client/api/api_keys_api.rb +1 -1
  6. data/lib/daytona_api_client/api/audit_api.rb +139 -9
  7. data/lib/daytona_api_client/api/docker_registry_api.rb +66 -5
  8. data/lib/daytona_api_client/api/health_api.rb +2 -53
  9. data/lib/daytona_api_client/api/organizations_api.rb +162 -953
  10. data/lib/daytona_api_client/api/preview_api.rb +7 -76
  11. data/lib/daytona_api_client/api/runners_api.rb +21 -408
  12. data/lib/daytona_api_client/api/sandbox_api.rb +214 -1462
  13. data/lib/daytona_api_client/api/snapshots_api.rb +110 -36
  14. data/lib/daytona_api_client/api/toolbox_api.rb +740 -740
  15. data/lib/daytona_api_client/api/users_api.rb +238 -1
  16. data/lib/daytona_api_client/api/volumes_api.rb +1 -1
  17. data/lib/daytona_api_client/api/webhooks_api.rb +267 -4
  18. data/lib/daytona_api_client/api/workspace_api.rb +5 -5
  19. data/lib/daytona_api_client/api_client.rb +1 -1
  20. data/lib/daytona_api_client/configuration.rb +1 -4
  21. data/lib/daytona_api_client/models/account_provider.rb +0 -2
  22. data/lib/daytona_api_client/models/announcement.rb +0 -2
  23. data/lib/daytona_api_client/models/api_key_list.rb +0 -2
  24. data/lib/daytona_api_client/models/api_key_response.rb +0 -2
  25. data/lib/daytona_api_client/models/audit_log.rb +1 -21
  26. data/lib/daytona_api_client/models/build_info.rb +4 -33
  27. data/lib/daytona_api_client/models/command.rb +0 -2
  28. data/lib/daytona_api_client/models/completion_context.rb +0 -2
  29. data/lib/daytona_api_client/models/completion_item.rb +0 -2
  30. data/lib/daytona_api_client/models/completion_list.rb +0 -2
  31. data/lib/daytona_api_client/models/compressed_screenshot_response.rb +0 -2
  32. data/lib/daytona_api_client/models/computer_use_start_response.rb +0 -2
  33. data/lib/daytona_api_client/models/computer_use_status_response.rb +0 -2
  34. data/lib/daytona_api_client/models/computer_use_stop_response.rb +0 -2
  35. data/lib/daytona_api_client/models/create_api_key.rb +1 -3
  36. data/lib/daytona_api_client/models/{job.rb → create_audit_log.rb} +79 -168
  37. data/lib/daytona_api_client/models/create_build_info.rb +0 -2
  38. data/lib/daytona_api_client/models/create_docker_registry.rb +65 -6
  39. data/lib/daytona_api_client/models/create_linked_account.rb +0 -2
  40. data/lib/daytona_api_client/models/create_organization.rb +4 -33
  41. data/lib/daytona_api_client/models/create_organization_invitation.rb +0 -2
  42. data/lib/daytona_api_client/models/create_organization_quota.rb +0 -2
  43. data/lib/daytona_api_client/models/create_organization_role.rb +0 -2
  44. data/lib/daytona_api_client/models/create_runner.rb +315 -33
  45. data/lib/daytona_api_client/models/create_sandbox.rb +1 -13
  46. data/lib/daytona_api_client/models/create_session_request.rb +0 -2
  47. data/lib/daytona_api_client/models/create_snapshot.rb +14 -16
  48. data/lib/daytona_api_client/models/create_user.rb +1 -12
  49. data/lib/daytona_api_client/models/create_volume.rb +0 -2
  50. data/lib/daytona_api_client/models/create_workspace.rb +0 -2
  51. data/lib/daytona_api_client/models/daytona_configuration.rb +4 -53
  52. data/lib/daytona_api_client/models/display_info_response.rb +0 -2
  53. data/lib/daytona_api_client/models/docker_registry.rb +0 -2
  54. data/lib/daytona_api_client/models/download_files.rb +0 -2
  55. data/lib/daytona_api_client/models/execute_request.rb +0 -2
  56. data/lib/daytona_api_client/models/execute_response.rb +0 -2
  57. data/lib/daytona_api_client/models/file_info.rb +0 -2
  58. data/lib/daytona_api_client/models/file_status.rb +0 -2
  59. data/lib/daytona_api_client/models/git_add_request.rb +0 -2
  60. data/lib/daytona_api_client/models/git_branch_request.rb +0 -2
  61. data/lib/daytona_api_client/models/git_checkout_request.rb +0 -2
  62. data/lib/daytona_api_client/models/git_clone_request.rb +0 -2
  63. data/lib/daytona_api_client/models/git_commit_info.rb +0 -2
  64. data/lib/daytona_api_client/models/git_commit_request.rb +0 -2
  65. data/lib/daytona_api_client/models/git_commit_response.rb +0 -2
  66. data/lib/daytona_api_client/models/git_delete_branch_request.rb +0 -2
  67. data/lib/daytona_api_client/models/git_repo_request.rb +0 -2
  68. data/lib/daytona_api_client/models/git_status.rb +0 -2
  69. data/lib/daytona_api_client/models/health_controller_check200_response.rb +0 -2
  70. data/lib/daytona_api_client/models/health_controller_check200_response_info_value.rb +0 -2
  71. data/lib/daytona_api_client/models/health_controller_check503_response.rb +0 -2
  72. data/lib/daytona_api_client/models/keyboard_hotkey_request.rb +0 -2
  73. data/lib/daytona_api_client/models/keyboard_press_request.rb +0 -2
  74. data/lib/daytona_api_client/models/keyboard_type_request.rb +0 -2
  75. data/lib/daytona_api_client/models/list_branch_response.rb +0 -2
  76. data/lib/daytona_api_client/models/lsp_completion_params.rb +0 -2
  77. data/lib/daytona_api_client/models/lsp_document_request.rb +0 -2
  78. data/lib/daytona_api_client/models/lsp_location.rb +0 -2
  79. data/lib/daytona_api_client/models/lsp_server_request.rb +0 -2
  80. data/lib/daytona_api_client/models/lsp_symbol.rb +0 -2
  81. data/lib/daytona_api_client/models/match.rb +0 -2
  82. data/lib/daytona_api_client/models/mouse_click_request.rb +0 -2
  83. data/lib/daytona_api_client/models/mouse_click_response.rb +0 -2
  84. data/lib/daytona_api_client/models/mouse_drag_request.rb +0 -2
  85. data/lib/daytona_api_client/models/mouse_drag_response.rb +0 -2
  86. data/lib/daytona_api_client/models/mouse_move_request.rb +0 -2
  87. data/lib/daytona_api_client/models/mouse_move_response.rb +0 -2
  88. data/lib/daytona_api_client/models/mouse_position.rb +0 -2
  89. data/lib/daytona_api_client/models/mouse_scroll_request.rb +0 -2
  90. data/lib/daytona_api_client/models/mouse_scroll_response.rb +0 -2
  91. data/lib/daytona_api_client/models/oidc_config.rb +0 -2
  92. data/lib/daytona_api_client/models/organization.rb +85 -148
  93. data/lib/daytona_api_client/models/organization_invitation.rb +0 -2
  94. data/lib/daytona_api_client/models/organization_role.rb +0 -2
  95. data/lib/daytona_api_client/models/organization_sandbox_default_limited_network_egress.rb +0 -2
  96. data/lib/daytona_api_client/models/organization_suspension.rb +5 -9
  97. data/lib/daytona_api_client/models/organization_usage_overview.rb +146 -20
  98. data/lib/daytona_api_client/models/organization_user.rb +0 -2
  99. data/lib/daytona_api_client/models/paginated_audit_logs.rb +4 -16
  100. data/lib/daytona_api_client/models/paginated_sandboxes.rb +0 -2
  101. data/lib/daytona_api_client/models/paginated_snapshots.rb +0 -2
  102. data/lib/daytona_api_client/models/{paginated_jobs.rb → paginated_snapshots_dto.rb} +4 -6
  103. data/lib/daytona_api_client/models/port_preview_url.rb +14 -33
  104. data/lib/daytona_api_client/models/position.rb +0 -2
  105. data/lib/daytona_api_client/models/posthog_config.rb +0 -2
  106. data/lib/daytona_api_client/models/process_errors_response.rb +0 -2
  107. data/lib/daytona_api_client/models/process_logs_response.rb +0 -2
  108. data/lib/daytona_api_client/models/process_restart_response.rb +0 -2
  109. data/lib/daytona_api_client/models/process_status_response.rb +0 -2
  110. data/lib/daytona_api_client/models/project_dir_response.rb +0 -2
  111. data/lib/daytona_api_client/models/pty_create_request.rb +0 -2
  112. data/lib/daytona_api_client/models/pty_create_response.rb +0 -2
  113. data/lib/daytona_api_client/models/pty_list_response.rb +0 -2
  114. data/lib/daytona_api_client/models/pty_resize_request.rb +0 -2
  115. data/lib/daytona_api_client/models/pty_session_info.rb +0 -2
  116. data/lib/daytona_api_client/models/range.rb +0 -2
  117. data/lib/daytona_api_client/models/region.rb +4 -180
  118. data/lib/daytona_api_client/models/region_screenshot_response.rb +0 -2
  119. data/lib/daytona_api_client/models/registry_push_access_dto.rb +0 -2
  120. data/lib/daytona_api_client/models/replace_request.rb +0 -2
  121. data/lib/daytona_api_client/models/replace_result.rb +0 -2
  122. data/lib/daytona_api_client/models/runner.rb +117 -108
  123. data/lib/daytona_api_client/models/runner_snapshot_dto.rb +17 -2
  124. data/lib/daytona_api_client/models/sandbox.rb +14 -80
  125. data/lib/daytona_api_client/models/sandbox_info.rb +0 -2
  126. data/lib/daytona_api_client/models/sandbox_labels.rb +0 -2
  127. data/lib/daytona_api_client/models/sandbox_state.rb +1 -4
  128. data/lib/daytona_api_client/models/sandbox_volume.rb +4 -16
  129. data/lib/daytona_api_client/models/screenshot_response.rb +0 -2
  130. data/lib/daytona_api_client/models/search_files_response.rb +0 -2
  131. data/lib/daytona_api_client/models/send_webhook_dto.rb +1 -25
  132. data/lib/daytona_api_client/models/session.rb +0 -2
  133. data/lib/daytona_api_client/models/session_execute_request.rb +0 -2
  134. data/lib/daytona_api_client/models/session_execute_response.rb +0 -2
  135. data/lib/daytona_api_client/models/set_snapshot_general_status_dto.rb +0 -2
  136. data/lib/daytona_api_client/models/snapshot_dto.rb +4 -38
  137. data/lib/daytona_api_client/models/snapshot_state.rb +4 -1
  138. data/lib/daytona_api_client/models/ssh_access_dto.rb +4 -33
  139. data/lib/daytona_api_client/models/ssh_access_validation_dto.rb +24 -6
  140. data/lib/daytona_api_client/models/storage_access_dto.rb +0 -2
  141. data/lib/daytona_api_client/models/update_docker_registry.rb +0 -2
  142. data/lib/daytona_api_client/models/update_organization_invitation.rb +0 -2
  143. data/lib/daytona_api_client/models/update_organization_member_access.rb +0 -2
  144. data/lib/daytona_api_client/models/update_organization_quota.rb +41 -92
  145. data/lib/daytona_api_client/models/update_organization_role.rb +0 -2
  146. data/lib/daytona_api_client/models/update_sandbox_state_dto.rb +6 -28
  147. data/lib/daytona_api_client/models/user.rb +0 -2
  148. data/lib/daytona_api_client/models/user_home_dir_response.rb +0 -2
  149. data/lib/daytona_api_client/models/user_public_key.rb +0 -2
  150. data/lib/daytona_api_client/models/volume_dto.rb +0 -2
  151. data/lib/daytona_api_client/models/webhook_app_portal_access.rb +1 -30
  152. data/lib/daytona_api_client/models/{admin_get_webhook_status200_response.rb → webhook_controller_get_status200_response.rb} +3 -5
  153. data/lib/daytona_api_client/models/webhook_initialization_status.rb +0 -2
  154. data/lib/daytona_api_client/models/windows_response.rb +0 -2
  155. data/lib/daytona_api_client/models/work_dir_response.rb +0 -2
  156. data/lib/daytona_api_client/models/workspace.rb +27 -66
  157. data/lib/daytona_api_client/version.rb +1 -1
  158. data/lib/daytona_api_client.rb +2 -46
  159. data/project.json +11 -38
  160. metadata +6 -54
  161. data/.gitignore +0 -39
  162. data/.openapi-generator/FILES +0 -209
  163. data/.openapi-generator/VERSION +0 -1
  164. data/.openapi-generator-ignore +0 -31
  165. data/.rspec +0 -2
  166. data/.rubocop.yml +0 -148
  167. data/fix-gemspec.sh +0 -11
  168. data/lib/daytona_api_client/api/admin_api.rb +0 -1151
  169. data/lib/daytona_api_client/api/jobs_api.rb +0 -299
  170. data/lib/daytona_api_client/api/regions_api.rb +0 -77
  171. data/lib/daytona_api_client/models/admin_create_runner.rb +0 -387
  172. data/lib/daytona_api_client/models/create_region.rb +0 -271
  173. data/lib/daytona_api_client/models/create_region_response.rb +0 -282
  174. data/lib/daytona_api_client/models/create_runner_response.rb +0 -265
  175. data/lib/daytona_api_client/models/create_sandbox_snapshot.rb +0 -238
  176. data/lib/daytona_api_client/models/fork_sandbox.rb +0 -221
  177. data/lib/daytona_api_client/models/job_status.rb +0 -42
  178. data/lib/daytona_api_client/models/job_type.rb +0 -52
  179. data/lib/daytona_api_client/models/log_entry.rb +0 -407
  180. data/lib/daytona_api_client/models/metric_data_point.rb +0 -265
  181. data/lib/daytona_api_client/models/metric_series.rb +0 -267
  182. data/lib/daytona_api_client/models/metrics_response.rb +0 -240
  183. data/lib/daytona_api_client/models/otel_config.rb +0 -251
  184. data/lib/daytona_api_client/models/paginated_logs.rb +0 -321
  185. data/lib/daytona_api_client/models/paginated_traces.rb +0 -321
  186. data/lib/daytona_api_client/models/poll_jobs_response.rb +0 -240
  187. data/lib/daytona_api_client/models/rate_limit_config.rb +0 -251
  188. data/lib/daytona_api_client/models/rate_limit_entry.rb +0 -231
  189. data/lib/daytona_api_client/models/regenerate_api_key_response.rb +0 -238
  190. data/lib/daytona_api_client/models/region_quota.rb +0 -389
  191. data/lib/daytona_api_client/models/region_type.rb +0 -41
  192. data/lib/daytona_api_client/models/region_usage_overview.rb +0 -393
  193. data/lib/daytona_api_client/models/resize_sandbox.rb +0 -298
  194. data/lib/daytona_api_client/models/runner_class.rb +0 -40
  195. data/lib/daytona_api_client/models/runner_full.rb +0 -808
  196. data/lib/daytona_api_client/models/runner_health_metrics.rb +0 -535
  197. data/lib/daytona_api_client/models/runner_healthcheck.rb +0 -290
  198. data/lib/daytona_api_client/models/runner_service_health.rb +0 -275
  199. data/lib/daytona_api_client/models/signed_port_preview_url.rb +0 -319
  200. data/lib/daytona_api_client/models/snapshot_manager_credentials.rb +0 -265
  201. data/lib/daytona_api_client/models/toolbox_proxy_url.rb +0 -238
  202. data/lib/daytona_api_client/models/trace_span.rb +0 -405
  203. data/lib/daytona_api_client/models/trace_summary.rb +0 -383
  204. data/lib/daytona_api_client/models/update_job_status.rb +0 -280
  205. data/lib/daytona_api_client/models/update_organization_default_region.rb +0 -238
  206. data/lib/daytona_api_client/models/update_organization_region_quota.rb +0 -287
  207. data/lib/daytona_api_client/models/update_region.rb +0 -244
  208. data/lib/daytona_api_client/models/url.rb +0 -238
  209. data/lib/daytona_api_client/models/webhook_event.rb +0 -45
  210. data/lib/daytona_api_client/models/workspace_port_preview_url.rb +0 -265
@@ -22,16 +22,16 @@ module DaytonaApiClient
22
22
  # Accept organization invitation
23
23
  # @param invitation_id [String] Invitation ID
24
24
  # @param [Hash] opts the optional parameters
25
- # @return [OrganizationInvitation]
25
+ # @return [nil]
26
26
  def accept_organization_invitation(invitation_id, opts = {})
27
- data, _status_code, _headers = accept_organization_invitation_with_http_info(invitation_id, opts)
28
- data
27
+ accept_organization_invitation_with_http_info(invitation_id, opts)
28
+ nil
29
29
  end
30
30
 
31
31
  # Accept organization invitation
32
32
  # @param invitation_id [String] Invitation ID
33
33
  # @param [Hash] opts the optional parameters
34
- # @return [Array<(OrganizationInvitation, Integer, Hash)>] OrganizationInvitation data, response status code and response headers
34
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
35
35
  def accept_organization_invitation_with_http_info(invitation_id, opts = {})
36
36
  if @api_client.config.debugging
37
37
  @api_client.config.logger.debug 'Calling API: OrganizationsApi.accept_organization_invitation ...'
@@ -48,8 +48,6 @@ module DaytonaApiClient
48
48
 
49
49
  # header parameters
50
50
  header_params = opts[:header_params] || {}
51
- # HTTP header 'Accept' (if needed)
52
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
53
51
 
54
52
  # form parameters
55
53
  form_params = opts[:form_params] || {}
@@ -58,7 +56,7 @@ module DaytonaApiClient
58
56
  post_body = opts[:debug_body]
59
57
 
60
58
  # return_type
61
- return_type = opts[:debug_return_type] || 'OrganizationInvitation'
59
+ return_type = opts[:debug_return_type]
62
60
 
63
61
  # auth_names
64
62
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
@@ -179,7 +177,7 @@ module DaytonaApiClient
179
177
  # HTTP header 'Content-Type'
180
178
  content_type = @api_client.select_header_content_type(['application/json'])
181
179
  if !content_type.nil?
182
- header_params['Content-Type'] = content_type
180
+ header_params['Content-Type'] = content_type
183
181
  end
184
182
 
185
183
  # form parameters
@@ -251,7 +249,7 @@ module DaytonaApiClient
251
249
  # HTTP header 'Content-Type'
252
250
  content_type = @api_client.select_header_content_type(['application/json'])
253
251
  if !content_type.nil?
254
- header_params['Content-Type'] = content_type
252
+ header_params['Content-Type'] = content_type
255
253
  end
256
254
 
257
255
  # form parameters
@@ -323,7 +321,7 @@ module DaytonaApiClient
323
321
  # HTTP header 'Content-Type'
324
322
  content_type = @api_client.select_header_content_type(['application/json'])
325
323
  if !content_type.nil?
326
- header_params['Content-Type'] = content_type
324
+ header_params['Content-Type'] = content_type
327
325
  end
328
326
 
329
327
  # form parameters
@@ -355,75 +353,6 @@ module DaytonaApiClient
355
353
  return data, status_code, headers
356
354
  end
357
355
 
358
- # Create a new region
359
- # @param create_region [CreateRegion]
360
- # @param [Hash] opts the optional parameters
361
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
362
- # @return [CreateRegionResponse]
363
- def create_region(create_region, opts = {})
364
- data, _status_code, _headers = create_region_with_http_info(create_region, opts)
365
- data
366
- end
367
-
368
- # Create a new region
369
- # @param create_region [CreateRegion]
370
- # @param [Hash] opts the optional parameters
371
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
372
- # @return [Array<(CreateRegionResponse, Integer, Hash)>] CreateRegionResponse data, response status code and response headers
373
- def create_region_with_http_info(create_region, opts = {})
374
- if @api_client.config.debugging
375
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.create_region ...'
376
- end
377
- # verify the required parameter 'create_region' is set
378
- if @api_client.config.client_side_validation && create_region.nil?
379
- fail ArgumentError, "Missing the required parameter 'create_region' when calling OrganizationsApi.create_region"
380
- end
381
- # resource path
382
- local_var_path = '/regions'
383
-
384
- # query parameters
385
- query_params = opts[:query_params] || {}
386
-
387
- # header parameters
388
- header_params = opts[:header_params] || {}
389
- # HTTP header 'Accept' (if needed)
390
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
391
- # HTTP header 'Content-Type'
392
- content_type = @api_client.select_header_content_type(['application/json'])
393
- if !content_type.nil?
394
- header_params['Content-Type'] = content_type
395
- end
396
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
397
-
398
- # form parameters
399
- form_params = opts[:form_params] || {}
400
-
401
- # http body (model)
402
- post_body = opts[:debug_body] || @api_client.object_to_http_body(create_region)
403
-
404
- # return_type
405
- return_type = opts[:debug_return_type] || 'CreateRegionResponse'
406
-
407
- # auth_names
408
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
409
-
410
- new_options = opts.merge(
411
- :operation => :"OrganizationsApi.create_region",
412
- :header_params => header_params,
413
- :query_params => query_params,
414
- :form_params => form_params,
415
- :body => post_body,
416
- :auth_names => auth_names,
417
- :return_type => return_type
418
- )
419
-
420
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
421
- if @api_client.config.debugging
422
- @api_client.config.logger.debug "API called: OrganizationsApi#create_region\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
423
- end
424
- return data, status_code, headers
425
- end
426
-
427
356
  # Decline organization invitation
428
357
  # @param invitation_id [String] Invitation ID
429
358
  # @param [Hash] opts the optional parameters
@@ -672,38 +601,37 @@ module DaytonaApiClient
672
601
  return data, status_code, headers
673
602
  end
674
603
 
675
- # Delete a region
676
- # @param id [String] Region ID
604
+ # Get organization by ID
605
+ # @param organization_id [String] Organization ID
677
606
  # @param [Hash] opts the optional parameters
678
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
679
- # @return [nil]
680
- def delete_region(id, opts = {})
681
- delete_region_with_http_info(id, opts)
682
- nil
607
+ # @return [Organization]
608
+ def get_organization(organization_id, opts = {})
609
+ data, _status_code, _headers = get_organization_with_http_info(organization_id, opts)
610
+ data
683
611
  end
684
612
 
685
- # Delete a region
686
- # @param id [String] Region ID
613
+ # Get organization by ID
614
+ # @param organization_id [String] Organization ID
687
615
  # @param [Hash] opts the optional parameters
688
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
689
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
690
- def delete_region_with_http_info(id, opts = {})
616
+ # @return [Array<(Organization, Integer, Hash)>] Organization data, response status code and response headers
617
+ def get_organization_with_http_info(organization_id, opts = {})
691
618
  if @api_client.config.debugging
692
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.delete_region ...'
619
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization ...'
693
620
  end
694
- # verify the required parameter 'id' is set
695
- if @api_client.config.client_side_validation && id.nil?
696
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.delete_region"
621
+ # verify the required parameter 'organization_id' is set
622
+ if @api_client.config.client_side_validation && organization_id.nil?
623
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.get_organization"
697
624
  end
698
625
  # resource path
699
- local_var_path = '/regions/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
626
+ local_var_path = '/organizations/{organizationId}'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
700
627
 
701
628
  # query parameters
702
629
  query_params = opts[:query_params] || {}
703
630
 
704
631
  # header parameters
705
632
  header_params = opts[:header_params] || {}
706
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
633
+ # HTTP header 'Accept' (if needed)
634
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
707
635
 
708
636
  # form parameters
709
637
  form_params = opts[:form_params] || {}
@@ -712,13 +640,13 @@ module DaytonaApiClient
712
640
  post_body = opts[:debug_body]
713
641
 
714
642
  # return_type
715
- return_type = opts[:debug_return_type]
643
+ return_type = opts[:debug_return_type] || 'Organization'
716
644
 
717
645
  # auth_names
718
646
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
719
647
 
720
648
  new_options = opts.merge(
721
- :operation => :"OrganizationsApi.delete_region",
649
+ :operation => :"OrganizationsApi.get_organization",
722
650
  :header_params => header_params,
723
651
  :query_params => query_params,
724
652
  :form_params => form_params,
@@ -727,36 +655,36 @@ module DaytonaApiClient
727
655
  :return_type => return_type
728
656
  )
729
657
 
730
- data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
658
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
731
659
  if @api_client.config.debugging
732
- @api_client.config.logger.debug "API called: OrganizationsApi#delete_region\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
660
+ @api_client.config.logger.debug "API called: OrganizationsApi#get_organization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
733
661
  end
734
662
  return data, status_code, headers
735
663
  end
736
664
 
737
- # Get organization by ID
738
- # @param organization_id [String] Organization ID
665
+ # Get organization by sandbox ID
666
+ # @param sandbox_id [String] Sandbox ID
739
667
  # @param [Hash] opts the optional parameters
740
668
  # @return [Organization]
741
- def get_organization(organization_id, opts = {})
742
- data, _status_code, _headers = get_organization_with_http_info(organization_id, opts)
669
+ def get_organization_by_sandbox_id(sandbox_id, opts = {})
670
+ data, _status_code, _headers = get_organization_by_sandbox_id_with_http_info(sandbox_id, opts)
743
671
  data
744
672
  end
745
673
 
746
- # Get organization by ID
747
- # @param organization_id [String] Organization ID
674
+ # Get organization by sandbox ID
675
+ # @param sandbox_id [String] Sandbox ID
748
676
  # @param [Hash] opts the optional parameters
749
677
  # @return [Array<(Organization, Integer, Hash)>] Organization data, response status code and response headers
750
- def get_organization_with_http_info(organization_id, opts = {})
678
+ def get_organization_by_sandbox_id_with_http_info(sandbox_id, opts = {})
751
679
  if @api_client.config.debugging
752
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization ...'
680
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization_by_sandbox_id ...'
753
681
  end
754
- # verify the required parameter 'organization_id' is set
755
- if @api_client.config.client_side_validation && organization_id.nil?
756
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.get_organization"
682
+ # verify the required parameter 'sandbox_id' is set
683
+ if @api_client.config.client_side_validation && sandbox_id.nil?
684
+ fail ArgumentError, "Missing the required parameter 'sandbox_id' when calling OrganizationsApi.get_organization_by_sandbox_id"
757
685
  end
758
686
  # resource path
759
- local_var_path = '/organizations/{organizationId}'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
687
+ local_var_path = '/organizations/by-sandbox-id/{sandboxId}'.sub('{' + 'sandboxId' + '}', CGI.escape(sandbox_id.to_s))
760
688
 
761
689
  # query parameters
762
690
  query_params = opts[:query_params] || {}
@@ -779,7 +707,7 @@ module DaytonaApiClient
779
707
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
780
708
 
781
709
  new_options = opts.merge(
782
- :operation => :"OrganizationsApi.get_organization",
710
+ :operation => :"OrganizationsApi.get_organization_by_sandbox_id",
783
711
  :header_params => header_params,
784
712
  :query_params => query_params,
785
713
  :form_params => form_params,
@@ -790,7 +718,7 @@ module DaytonaApiClient
790
718
 
791
719
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
792
720
  if @api_client.config.debugging
793
- @api_client.config.logger.debug "API called: OrganizationsApi#get_organization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
721
+ @api_client.config.logger.debug "API called: OrganizationsApi#get_organization_by_sandbox_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
794
722
  end
795
723
  return data, status_code, headers
796
724
  end
@@ -850,29 +778,29 @@ module DaytonaApiClient
850
778
  return data, status_code, headers
851
779
  end
852
780
 
853
- # Get organization OTEL config by organization ID
781
+ # Get organization current usage overview
854
782
  # @param organization_id [String] Organization ID
855
783
  # @param [Hash] opts the optional parameters
856
- # @return [OtelConfig]
857
- def get_organization_otel_config(organization_id, opts = {})
858
- data, _status_code, _headers = get_organization_otel_config_with_http_info(organization_id, opts)
784
+ # @return [OrganizationUsageOverview]
785
+ def get_organization_usage_overview(organization_id, opts = {})
786
+ data, _status_code, _headers = get_organization_usage_overview_with_http_info(organization_id, opts)
859
787
  data
860
788
  end
861
789
 
862
- # Get organization OTEL config by organization ID
790
+ # Get organization current usage overview
863
791
  # @param organization_id [String] Organization ID
864
792
  # @param [Hash] opts the optional parameters
865
- # @return [Array<(OtelConfig, Integer, Hash)>] OtelConfig data, response status code and response headers
866
- def get_organization_otel_config_with_http_info(organization_id, opts = {})
793
+ # @return [Array<(OrganizationUsageOverview, Integer, Hash)>] OrganizationUsageOverview data, response status code and response headers
794
+ def get_organization_usage_overview_with_http_info(organization_id, opts = {})
867
795
  if @api_client.config.debugging
868
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization_otel_config ...'
796
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization_usage_overview ...'
869
797
  end
870
798
  # verify the required parameter 'organization_id' is set
871
799
  if @api_client.config.client_side_validation && organization_id.nil?
872
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.get_organization_otel_config"
800
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.get_organization_usage_overview"
873
801
  end
874
802
  # resource path
875
- local_var_path = '/organizations/{organizationId}/otel-config'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
803
+ local_var_path = '/organizations/{organizationId}/usage'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
876
804
 
877
805
  # query parameters
878
806
  query_params = opts[:query_params] || {}
@@ -889,13 +817,13 @@ module DaytonaApiClient
889
817
  post_body = opts[:debug_body]
890
818
 
891
819
  # return_type
892
- return_type = opts[:debug_return_type] || 'OtelConfig'
820
+ return_type = opts[:debug_return_type] || 'OrganizationUsageOverview'
893
821
 
894
822
  # auth_names
895
823
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
896
824
 
897
825
  new_options = opts.merge(
898
- :operation => :"OrganizationsApi.get_organization_otel_config",
826
+ :operation => :"OrganizationsApi.get_organization_usage_overview",
899
827
  :header_params => header_params,
900
828
  :query_params => query_params,
901
829
  :form_params => form_params,
@@ -906,42 +834,40 @@ module DaytonaApiClient
906
834
 
907
835
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
908
836
  if @api_client.config.debugging
909
- @api_client.config.logger.debug "API called: OrganizationsApi#get_organization_otel_config\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
837
+ @api_client.config.logger.debug "API called: OrganizationsApi#get_organization_usage_overview\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
910
838
  end
911
839
  return data, status_code, headers
912
840
  end
913
841
 
914
- # Get organization OTEL config by sandbox auth token
915
- # @param auth_token [String] Sandbox Auth Token
842
+ # Leave organization
843
+ # @param organization_id [String] Organization ID
916
844
  # @param [Hash] opts the optional parameters
917
- # @return [OtelConfig]
918
- def get_organization_otel_config_by_sandbox_auth_token(auth_token, opts = {})
919
- data, _status_code, _headers = get_organization_otel_config_by_sandbox_auth_token_with_http_info(auth_token, opts)
920
- data
845
+ # @return [nil]
846
+ def leave_organization(organization_id, opts = {})
847
+ leave_organization_with_http_info(organization_id, opts)
848
+ nil
921
849
  end
922
850
 
923
- # Get organization OTEL config by sandbox auth token
924
- # @param auth_token [String] Sandbox Auth Token
851
+ # Leave organization
852
+ # @param organization_id [String] Organization ID
925
853
  # @param [Hash] opts the optional parameters
926
- # @return [Array<(OtelConfig, Integer, Hash)>] OtelConfig data, response status code and response headers
927
- def get_organization_otel_config_by_sandbox_auth_token_with_http_info(auth_token, opts = {})
854
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
855
+ def leave_organization_with_http_info(organization_id, opts = {})
928
856
  if @api_client.config.debugging
929
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization_otel_config_by_sandbox_auth_token ...'
857
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.leave_organization ...'
930
858
  end
931
- # verify the required parameter 'auth_token' is set
932
- if @api_client.config.client_side_validation && auth_token.nil?
933
- fail ArgumentError, "Missing the required parameter 'auth_token' when calling OrganizationsApi.get_organization_otel_config_by_sandbox_auth_token"
859
+ # verify the required parameter 'organization_id' is set
860
+ if @api_client.config.client_side_validation && organization_id.nil?
861
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.leave_organization"
934
862
  end
935
863
  # resource path
936
- local_var_path = '/organizations/otel-config/by-sandbox-auth-token/{authToken}'.sub('{' + 'authToken' + '}', CGI.escape(auth_token.to_s))
864
+ local_var_path = '/organizations/{organizationId}/leave'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
937
865
 
938
866
  # query parameters
939
867
  query_params = opts[:query_params] || {}
940
868
 
941
869
  # header parameters
942
870
  header_params = opts[:header_params] || {}
943
- # HTTP header 'Accept' (if needed)
944
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
945
871
 
946
872
  # form parameters
947
873
  form_params = opts[:form_params] || {}
@@ -950,13 +876,13 @@ module DaytonaApiClient
950
876
  post_body = opts[:debug_body]
951
877
 
952
878
  # return_type
953
- return_type = opts[:debug_return_type] || 'OtelConfig'
879
+ return_type = opts[:debug_return_type]
954
880
 
955
881
  # auth_names
956
882
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
957
883
 
958
884
  new_options = opts.merge(
959
- :operation => :"OrganizationsApi.get_organization_otel_config_by_sandbox_auth_token",
885
+ :operation => :"OrganizationsApi.leave_organization",
960
886
  :header_params => header_params,
961
887
  :query_params => query_params,
962
888
  :form_params => form_params,
@@ -965,36 +891,36 @@ module DaytonaApiClient
965
891
  :return_type => return_type
966
892
  )
967
893
 
968
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
894
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
969
895
  if @api_client.config.debugging
970
- @api_client.config.logger.debug "API called: OrganizationsApi#get_organization_otel_config_by_sandbox_auth_token\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
896
+ @api_client.config.logger.debug "API called: OrganizationsApi#leave_organization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
971
897
  end
972
898
  return data, status_code, headers
973
899
  end
974
900
 
975
- # Get organization current usage overview
901
+ # List pending organization invitations
976
902
  # @param organization_id [String] Organization ID
977
903
  # @param [Hash] opts the optional parameters
978
- # @return [OrganizationUsageOverview]
979
- def get_organization_usage_overview(organization_id, opts = {})
980
- data, _status_code, _headers = get_organization_usage_overview_with_http_info(organization_id, opts)
904
+ # @return [Array<OrganizationInvitation>]
905
+ def list_organization_invitations(organization_id, opts = {})
906
+ data, _status_code, _headers = list_organization_invitations_with_http_info(organization_id, opts)
981
907
  data
982
908
  end
983
909
 
984
- # Get organization current usage overview
910
+ # List pending organization invitations
985
911
  # @param organization_id [String] Organization ID
986
912
  # @param [Hash] opts the optional parameters
987
- # @return [Array<(OrganizationUsageOverview, Integer, Hash)>] OrganizationUsageOverview data, response status code and response headers
988
- def get_organization_usage_overview_with_http_info(organization_id, opts = {})
913
+ # @return [Array<(Array<OrganizationInvitation>, Integer, Hash)>] Array<OrganizationInvitation> data, response status code and response headers
914
+ def list_organization_invitations_with_http_info(organization_id, opts = {})
989
915
  if @api_client.config.debugging
990
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_organization_usage_overview ...'
916
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_invitations ...'
991
917
  end
992
918
  # verify the required parameter 'organization_id' is set
993
919
  if @api_client.config.client_side_validation && organization_id.nil?
994
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.get_organization_usage_overview"
920
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_invitations"
995
921
  end
996
922
  # resource path
997
- local_var_path = '/organizations/{organizationId}/usage'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
923
+ local_var_path = '/organizations/{organizationId}/invitations'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
998
924
 
999
925
  # query parameters
1000
926
  query_params = opts[:query_params] || {}
@@ -1011,13 +937,13 @@ module DaytonaApiClient
1011
937
  post_body = opts[:debug_body]
1012
938
 
1013
939
  # return_type
1014
- return_type = opts[:debug_return_type] || 'OrganizationUsageOverview'
940
+ return_type = opts[:debug_return_type] || 'Array<OrganizationInvitation>'
1015
941
 
1016
942
  # auth_names
1017
943
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1018
944
 
1019
945
  new_options = opts.merge(
1020
- :operation => :"OrganizationsApi.get_organization_usage_overview",
946
+ :operation => :"OrganizationsApi.list_organization_invitations",
1021
947
  :header_params => header_params,
1022
948
  :query_params => query_params,
1023
949
  :form_params => form_params,
@@ -1028,36 +954,28 @@ module DaytonaApiClient
1028
954
 
1029
955
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1030
956
  if @api_client.config.debugging
1031
- @api_client.config.logger.debug "API called: OrganizationsApi#get_organization_usage_overview\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
957
+ @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_invitations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1032
958
  end
1033
959
  return data, status_code, headers
1034
960
  end
1035
961
 
1036
- # Get region by ID
1037
- # @param id [String] Region ID
962
+ # List organization invitations for authenticated user
1038
963
  # @param [Hash] opts the optional parameters
1039
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1040
- # @return [Region]
1041
- def get_region_by_id(id, opts = {})
1042
- data, _status_code, _headers = get_region_by_id_with_http_info(id, opts)
964
+ # @return [Array<OrganizationInvitation>]
965
+ def list_organization_invitations_for_authenticated_user(opts = {})
966
+ data, _status_code, _headers = list_organization_invitations_for_authenticated_user_with_http_info(opts)
1043
967
  data
1044
968
  end
1045
969
 
1046
- # Get region by ID
1047
- # @param id [String] Region ID
970
+ # List organization invitations for authenticated user
1048
971
  # @param [Hash] opts the optional parameters
1049
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1050
- # @return [Array<(Region, Integer, Hash)>] Region data, response status code and response headers
1051
- def get_region_by_id_with_http_info(id, opts = {})
972
+ # @return [Array<(Array<OrganizationInvitation>, Integer, Hash)>] Array<OrganizationInvitation> data, response status code and response headers
973
+ def list_organization_invitations_for_authenticated_user_with_http_info(opts = {})
1052
974
  if @api_client.config.debugging
1053
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.get_region_by_id ...'
1054
- end
1055
- # verify the required parameter 'id' is set
1056
- if @api_client.config.client_side_validation && id.nil?
1057
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.get_region_by_id"
975
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_invitations_for_authenticated_user ...'
1058
976
  end
1059
977
  # resource path
1060
- local_var_path = '/regions/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
978
+ local_var_path = '/organizations/invitations'
1061
979
 
1062
980
  # query parameters
1063
981
  query_params = opts[:query_params] || {}
@@ -1066,7 +984,6 @@ module DaytonaApiClient
1066
984
  header_params = opts[:header_params] || {}
1067
985
  # HTTP header 'Accept' (if needed)
1068
986
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1069
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
1070
987
 
1071
988
  # form parameters
1072
989
  form_params = opts[:form_params] || {}
@@ -1075,13 +992,13 @@ module DaytonaApiClient
1075
992
  post_body = opts[:debug_body]
1076
993
 
1077
994
  # return_type
1078
- return_type = opts[:debug_return_type] || 'Region'
995
+ return_type = opts[:debug_return_type] || 'Array<OrganizationInvitation>'
1079
996
 
1080
997
  # auth_names
1081
998
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1082
999
 
1083
1000
  new_options = opts.merge(
1084
- :operation => :"OrganizationsApi.get_region_by_id",
1001
+ :operation => :"OrganizationsApi.list_organization_invitations_for_authenticated_user",
1085
1002
  :header_params => header_params,
1086
1003
  :query_params => query_params,
1087
1004
  :form_params => form_params,
@@ -1092,40 +1009,42 @@ module DaytonaApiClient
1092
1009
 
1093
1010
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1094
1011
  if @api_client.config.debugging
1095
- @api_client.config.logger.debug "API called: OrganizationsApi#get_region_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1012
+ @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_invitations_for_authenticated_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1096
1013
  end
1097
1014
  return data, status_code, headers
1098
1015
  end
1099
1016
 
1100
- # Leave organization
1017
+ # List organization members
1101
1018
  # @param organization_id [String] Organization ID
1102
1019
  # @param [Hash] opts the optional parameters
1103
- # @return [nil]
1104
- def leave_organization(organization_id, opts = {})
1105
- leave_organization_with_http_info(organization_id, opts)
1106
- nil
1020
+ # @return [Array<OrganizationUser>]
1021
+ def list_organization_members(organization_id, opts = {})
1022
+ data, _status_code, _headers = list_organization_members_with_http_info(organization_id, opts)
1023
+ data
1107
1024
  end
1108
1025
 
1109
- # Leave organization
1026
+ # List organization members
1110
1027
  # @param organization_id [String] Organization ID
1111
1028
  # @param [Hash] opts the optional parameters
1112
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1113
- def leave_organization_with_http_info(organization_id, opts = {})
1029
+ # @return [Array<(Array<OrganizationUser>, Integer, Hash)>] Array<OrganizationUser> data, response status code and response headers
1030
+ def list_organization_members_with_http_info(organization_id, opts = {})
1114
1031
  if @api_client.config.debugging
1115
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.leave_organization ...'
1032
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_members ...'
1116
1033
  end
1117
1034
  # verify the required parameter 'organization_id' is set
1118
1035
  if @api_client.config.client_side_validation && organization_id.nil?
1119
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.leave_organization"
1036
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_members"
1120
1037
  end
1121
1038
  # resource path
1122
- local_var_path = '/organizations/{organizationId}/leave'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1039
+ local_var_path = '/organizations/{organizationId}/users'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1123
1040
 
1124
1041
  # query parameters
1125
1042
  query_params = opts[:query_params] || {}
1126
1043
 
1127
1044
  # header parameters
1128
1045
  header_params = opts[:header_params] || {}
1046
+ # HTTP header 'Accept' (if needed)
1047
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1129
1048
 
1130
1049
  # form parameters
1131
1050
  form_params = opts[:form_params] || {}
@@ -1134,13 +1053,13 @@ module DaytonaApiClient
1134
1053
  post_body = opts[:debug_body]
1135
1054
 
1136
1055
  # return_type
1137
- return_type = opts[:debug_return_type]
1056
+ return_type = opts[:debug_return_type] || 'Array<OrganizationUser>'
1138
1057
 
1139
1058
  # auth_names
1140
1059
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1141
1060
 
1142
1061
  new_options = opts.merge(
1143
- :operation => :"OrganizationsApi.leave_organization",
1062
+ :operation => :"OrganizationsApi.list_organization_members",
1144
1063
  :header_params => header_params,
1145
1064
  :query_params => query_params,
1146
1065
  :form_params => form_params,
@@ -1149,32 +1068,36 @@ module DaytonaApiClient
1149
1068
  :return_type => return_type
1150
1069
  )
1151
1070
 
1152
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1071
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1153
1072
  if @api_client.config.debugging
1154
- @api_client.config.logger.debug "API called: OrganizationsApi#leave_organization\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1073
+ @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_members\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1155
1074
  end
1156
1075
  return data, status_code, headers
1157
1076
  end
1158
1077
 
1159
- # List all available regions for the organization
1078
+ # List organization roles
1079
+ # @param organization_id [String] Organization ID
1160
1080
  # @param [Hash] opts the optional parameters
1161
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1162
- # @return [Array<Region>]
1163
- def list_available_regions(opts = {})
1164
- data, _status_code, _headers = list_available_regions_with_http_info(opts)
1081
+ # @return [Array<OrganizationRole>]
1082
+ def list_organization_roles(organization_id, opts = {})
1083
+ data, _status_code, _headers = list_organization_roles_with_http_info(organization_id, opts)
1165
1084
  data
1166
1085
  end
1167
1086
 
1168
- # List all available regions for the organization
1087
+ # List organization roles
1088
+ # @param organization_id [String] Organization ID
1169
1089
  # @param [Hash] opts the optional parameters
1170
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1171
- # @return [Array<(Array<Region>, Integer, Hash)>] Array<Region> data, response status code and response headers
1172
- def list_available_regions_with_http_info(opts = {})
1090
+ # @return [Array<(Array<OrganizationRole>, Integer, Hash)>] Array<OrganizationRole> data, response status code and response headers
1091
+ def list_organization_roles_with_http_info(organization_id, opts = {})
1173
1092
  if @api_client.config.debugging
1174
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_available_regions ...'
1093
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_roles ...'
1094
+ end
1095
+ # verify the required parameter 'organization_id' is set
1096
+ if @api_client.config.client_side_validation && organization_id.nil?
1097
+ fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_roles"
1175
1098
  end
1176
1099
  # resource path
1177
- local_var_path = '/regions'
1100
+ local_var_path = '/organizations/{organizationId}/roles'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1178
1101
 
1179
1102
  # query parameters
1180
1103
  query_params = opts[:query_params] || {}
@@ -1183,7 +1106,6 @@ module DaytonaApiClient
1183
1106
  header_params = opts[:header_params] || {}
1184
1107
  # HTTP header 'Accept' (if needed)
1185
1108
  header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1186
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
1187
1109
 
1188
1110
  # form parameters
1189
1111
  form_params = opts[:form_params] || {}
@@ -1192,13 +1114,13 @@ module DaytonaApiClient
1192
1114
  post_body = opts[:debug_body]
1193
1115
 
1194
1116
  # return_type
1195
- return_type = opts[:debug_return_type] || 'Array<Region>'
1117
+ return_type = opts[:debug_return_type] || 'Array<OrganizationRole>'
1196
1118
 
1197
1119
  # auth_names
1198
1120
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1199
1121
 
1200
1122
  new_options = opts.merge(
1201
- :operation => :"OrganizationsApi.list_available_regions",
1123
+ :operation => :"OrganizationsApi.list_organization_roles",
1202
1124
  :header_params => header_params,
1203
1125
  :query_params => query_params,
1204
1126
  :form_params => form_params,
@@ -1209,34 +1131,28 @@ module DaytonaApiClient
1209
1131
 
1210
1132
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1211
1133
  if @api_client.config.debugging
1212
- @api_client.config.logger.debug "API called: OrganizationsApi#list_available_regions\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1134
+ @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1213
1135
  end
1214
1136
  return data, status_code, headers
1215
1137
  end
1216
1138
 
1217
- # List pending organization invitations
1218
- # @param organization_id [String] Organization ID
1139
+ # List organizations
1219
1140
  # @param [Hash] opts the optional parameters
1220
- # @return [Array<OrganizationInvitation>]
1221
- def list_organization_invitations(organization_id, opts = {})
1222
- data, _status_code, _headers = list_organization_invitations_with_http_info(organization_id, opts)
1141
+ # @return [Array<Organization>]
1142
+ def list_organizations(opts = {})
1143
+ data, _status_code, _headers = list_organizations_with_http_info(opts)
1223
1144
  data
1224
1145
  end
1225
1146
 
1226
- # List pending organization invitations
1227
- # @param organization_id [String] Organization ID
1147
+ # List organizations
1228
1148
  # @param [Hash] opts the optional parameters
1229
- # @return [Array<(Array<OrganizationInvitation>, Integer, Hash)>] Array<OrganizationInvitation> data, response status code and response headers
1230
- def list_organization_invitations_with_http_info(organization_id, opts = {})
1149
+ # @return [Array<(Array<Organization>, Integer, Hash)>] Array<Organization> data, response status code and response headers
1150
+ def list_organizations_with_http_info(opts = {})
1231
1151
  if @api_client.config.debugging
1232
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_invitations ...'
1233
- end
1234
- # verify the required parameter 'organization_id' is set
1235
- if @api_client.config.client_side_validation && organization_id.nil?
1236
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_invitations"
1152
+ @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organizations ...'
1237
1153
  end
1238
1154
  # resource path
1239
- local_var_path = '/organizations/{organizationId}/invitations'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1155
+ local_var_path = '/organizations'
1240
1156
 
1241
1157
  # query parameters
1242
1158
  query_params = opts[:query_params] || {}
@@ -1253,13 +1169,13 @@ module DaytonaApiClient
1253
1169
  post_body = opts[:debug_body]
1254
1170
 
1255
1171
  # return_type
1256
- return_type = opts[:debug_return_type] || 'Array<OrganizationInvitation>'
1172
+ return_type = opts[:debug_return_type] || 'Array<Organization>'
1257
1173
 
1258
1174
  # auth_names
1259
1175
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1260
1176
 
1261
1177
  new_options = opts.merge(
1262
- :operation => :"OrganizationsApi.list_organization_invitations",
1178
+ :operation => :"OrganizationsApi.list_organizations",
1263
1179
  :header_params => header_params,
1264
1180
  :query_params => query_params,
1265
1181
  :form_params => form_params,
@@ -1270,507 +1186,13 @@ module DaytonaApiClient
1270
1186
 
1271
1187
  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1272
1188
  if @api_client.config.debugging
1273
- @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_invitations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1189
+ @api_client.config.logger.debug "API called: OrganizationsApi#list_organizations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1274
1190
  end
1275
1191
  return data, status_code, headers
1276
1192
  end
1277
1193
 
1278
- # List organization invitations for authenticated user
1279
- # @param [Hash] opts the optional parameters
1280
- # @return [Array<OrganizationInvitation>]
1281
- def list_organization_invitations_for_authenticated_user(opts = {})
1282
- data, _status_code, _headers = list_organization_invitations_for_authenticated_user_with_http_info(opts)
1283
- data
1284
- end
1285
-
1286
- # List organization invitations for authenticated user
1287
- # @param [Hash] opts the optional parameters
1288
- # @return [Array<(Array<OrganizationInvitation>, Integer, Hash)>] Array<OrganizationInvitation> data, response status code and response headers
1289
- def list_organization_invitations_for_authenticated_user_with_http_info(opts = {})
1290
- if @api_client.config.debugging
1291
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_invitations_for_authenticated_user ...'
1292
- end
1293
- # resource path
1294
- local_var_path = '/organizations/invitations'
1295
-
1296
- # query parameters
1297
- query_params = opts[:query_params] || {}
1298
-
1299
- # header parameters
1300
- header_params = opts[:header_params] || {}
1301
- # HTTP header 'Accept' (if needed)
1302
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1303
-
1304
- # form parameters
1305
- form_params = opts[:form_params] || {}
1306
-
1307
- # http body (model)
1308
- post_body = opts[:debug_body]
1309
-
1310
- # return_type
1311
- return_type = opts[:debug_return_type] || 'Array<OrganizationInvitation>'
1312
-
1313
- # auth_names
1314
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1315
-
1316
- new_options = opts.merge(
1317
- :operation => :"OrganizationsApi.list_organization_invitations_for_authenticated_user",
1318
- :header_params => header_params,
1319
- :query_params => query_params,
1320
- :form_params => form_params,
1321
- :body => post_body,
1322
- :auth_names => auth_names,
1323
- :return_type => return_type
1324
- )
1325
-
1326
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1327
- if @api_client.config.debugging
1328
- @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_invitations_for_authenticated_user\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1329
- end
1330
- return data, status_code, headers
1331
- end
1332
-
1333
- # List organization members
1334
- # @param organization_id [String] Organization ID
1335
- # @param [Hash] opts the optional parameters
1336
- # @return [Array<OrganizationUser>]
1337
- def list_organization_members(organization_id, opts = {})
1338
- data, _status_code, _headers = list_organization_members_with_http_info(organization_id, opts)
1339
- data
1340
- end
1341
-
1342
- # List organization members
1343
- # @param organization_id [String] Organization ID
1344
- # @param [Hash] opts the optional parameters
1345
- # @return [Array<(Array<OrganizationUser>, Integer, Hash)>] Array<OrganizationUser> data, response status code and response headers
1346
- def list_organization_members_with_http_info(organization_id, opts = {})
1347
- if @api_client.config.debugging
1348
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_members ...'
1349
- end
1350
- # verify the required parameter 'organization_id' is set
1351
- if @api_client.config.client_side_validation && organization_id.nil?
1352
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_members"
1353
- end
1354
- # resource path
1355
- local_var_path = '/organizations/{organizationId}/users'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1356
-
1357
- # query parameters
1358
- query_params = opts[:query_params] || {}
1359
-
1360
- # header parameters
1361
- header_params = opts[:header_params] || {}
1362
- # HTTP header 'Accept' (if needed)
1363
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1364
-
1365
- # form parameters
1366
- form_params = opts[:form_params] || {}
1367
-
1368
- # http body (model)
1369
- post_body = opts[:debug_body]
1370
-
1371
- # return_type
1372
- return_type = opts[:debug_return_type] || 'Array<OrganizationUser>'
1373
-
1374
- # auth_names
1375
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1376
-
1377
- new_options = opts.merge(
1378
- :operation => :"OrganizationsApi.list_organization_members",
1379
- :header_params => header_params,
1380
- :query_params => query_params,
1381
- :form_params => form_params,
1382
- :body => post_body,
1383
- :auth_names => auth_names,
1384
- :return_type => return_type
1385
- )
1386
-
1387
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1388
- if @api_client.config.debugging
1389
- @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_members\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1390
- end
1391
- return data, status_code, headers
1392
- end
1393
-
1394
- # List organization roles
1395
- # @param organization_id [String] Organization ID
1396
- # @param [Hash] opts the optional parameters
1397
- # @return [Array<OrganizationRole>]
1398
- def list_organization_roles(organization_id, opts = {})
1399
- data, _status_code, _headers = list_organization_roles_with_http_info(organization_id, opts)
1400
- data
1401
- end
1402
-
1403
- # List organization roles
1404
- # @param organization_id [String] Organization ID
1405
- # @param [Hash] opts the optional parameters
1406
- # @return [Array<(Array<OrganizationRole>, Integer, Hash)>] Array<OrganizationRole> data, response status code and response headers
1407
- def list_organization_roles_with_http_info(organization_id, opts = {})
1408
- if @api_client.config.debugging
1409
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organization_roles ...'
1410
- end
1411
- # verify the required parameter 'organization_id' is set
1412
- if @api_client.config.client_side_validation && organization_id.nil?
1413
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.list_organization_roles"
1414
- end
1415
- # resource path
1416
- local_var_path = '/organizations/{organizationId}/roles'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1417
-
1418
- # query parameters
1419
- query_params = opts[:query_params] || {}
1420
-
1421
- # header parameters
1422
- header_params = opts[:header_params] || {}
1423
- # HTTP header 'Accept' (if needed)
1424
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1425
-
1426
- # form parameters
1427
- form_params = opts[:form_params] || {}
1428
-
1429
- # http body (model)
1430
- post_body = opts[:debug_body]
1431
-
1432
- # return_type
1433
- return_type = opts[:debug_return_type] || 'Array<OrganizationRole>'
1434
-
1435
- # auth_names
1436
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1437
-
1438
- new_options = opts.merge(
1439
- :operation => :"OrganizationsApi.list_organization_roles",
1440
- :header_params => header_params,
1441
- :query_params => query_params,
1442
- :form_params => form_params,
1443
- :body => post_body,
1444
- :auth_names => auth_names,
1445
- :return_type => return_type
1446
- )
1447
-
1448
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1449
- if @api_client.config.debugging
1450
- @api_client.config.logger.debug "API called: OrganizationsApi#list_organization_roles\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1451
- end
1452
- return data, status_code, headers
1453
- end
1454
-
1455
- # List organizations
1456
- # @param [Hash] opts the optional parameters
1457
- # @return [Array<Organization>]
1458
- def list_organizations(opts = {})
1459
- data, _status_code, _headers = list_organizations_with_http_info(opts)
1460
- data
1461
- end
1462
-
1463
- # List organizations
1464
- # @param [Hash] opts the optional parameters
1465
- # @return [Array<(Array<Organization>, Integer, Hash)>] Array<Organization> data, response status code and response headers
1466
- def list_organizations_with_http_info(opts = {})
1467
- if @api_client.config.debugging
1468
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.list_organizations ...'
1469
- end
1470
- # resource path
1471
- local_var_path = '/organizations'
1472
-
1473
- # query parameters
1474
- query_params = opts[:query_params] || {}
1475
-
1476
- # header parameters
1477
- header_params = opts[:header_params] || {}
1478
- # HTTP header 'Accept' (if needed)
1479
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1480
-
1481
- # form parameters
1482
- form_params = opts[:form_params] || {}
1483
-
1484
- # http body (model)
1485
- post_body = opts[:debug_body]
1486
-
1487
- # return_type
1488
- return_type = opts[:debug_return_type] || 'Array<Organization>'
1489
-
1490
- # auth_names
1491
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1492
-
1493
- new_options = opts.merge(
1494
- :operation => :"OrganizationsApi.list_organizations",
1495
- :header_params => header_params,
1496
- :query_params => query_params,
1497
- :form_params => form_params,
1498
- :body => post_body,
1499
- :auth_names => auth_names,
1500
- :return_type => return_type
1501
- )
1502
-
1503
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
1504
- if @api_client.config.debugging
1505
- @api_client.config.logger.debug "API called: OrganizationsApi#list_organizations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1506
- end
1507
- return data, status_code, headers
1508
- end
1509
-
1510
- # Regenerate proxy API key for a region
1511
- # @param id [String] Region ID
1512
- # @param [Hash] opts the optional parameters
1513
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1514
- # @return [RegenerateApiKeyResponse]
1515
- def regenerate_proxy_api_key(id, opts = {})
1516
- data, _status_code, _headers = regenerate_proxy_api_key_with_http_info(id, opts)
1517
- data
1518
- end
1519
-
1520
- # Regenerate proxy API key for a region
1521
- # @param id [String] Region ID
1522
- # @param [Hash] opts the optional parameters
1523
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1524
- # @return [Array<(RegenerateApiKeyResponse, Integer, Hash)>] RegenerateApiKeyResponse data, response status code and response headers
1525
- def regenerate_proxy_api_key_with_http_info(id, opts = {})
1526
- if @api_client.config.debugging
1527
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.regenerate_proxy_api_key ...'
1528
- end
1529
- # verify the required parameter 'id' is set
1530
- if @api_client.config.client_side_validation && id.nil?
1531
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.regenerate_proxy_api_key"
1532
- end
1533
- # resource path
1534
- local_var_path = '/regions/{id}/regenerate-proxy-api-key'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
1535
-
1536
- # query parameters
1537
- query_params = opts[:query_params] || {}
1538
-
1539
- # header parameters
1540
- header_params = opts[:header_params] || {}
1541
- # HTTP header 'Accept' (if needed)
1542
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1543
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
1544
-
1545
- # form parameters
1546
- form_params = opts[:form_params] || {}
1547
-
1548
- # http body (model)
1549
- post_body = opts[:debug_body]
1550
-
1551
- # return_type
1552
- return_type = opts[:debug_return_type] || 'RegenerateApiKeyResponse'
1553
-
1554
- # auth_names
1555
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1556
-
1557
- new_options = opts.merge(
1558
- :operation => :"OrganizationsApi.regenerate_proxy_api_key",
1559
- :header_params => header_params,
1560
- :query_params => query_params,
1561
- :form_params => form_params,
1562
- :body => post_body,
1563
- :auth_names => auth_names,
1564
- :return_type => return_type
1565
- )
1566
-
1567
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1568
- if @api_client.config.debugging
1569
- @api_client.config.logger.debug "API called: OrganizationsApi#regenerate_proxy_api_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1570
- end
1571
- return data, status_code, headers
1572
- end
1573
-
1574
- # Regenerate snapshot manager credentials for a region
1575
- # @param id [String] Region ID
1576
- # @param [Hash] opts the optional parameters
1577
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1578
- # @return [SnapshotManagerCredentials]
1579
- def regenerate_snapshot_manager_credentials(id, opts = {})
1580
- data, _status_code, _headers = regenerate_snapshot_manager_credentials_with_http_info(id, opts)
1581
- data
1582
- end
1583
-
1584
- # Regenerate snapshot manager credentials for a region
1585
- # @param id [String] Region ID
1586
- # @param [Hash] opts the optional parameters
1587
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1588
- # @return [Array<(SnapshotManagerCredentials, Integer, Hash)>] SnapshotManagerCredentials data, response status code and response headers
1589
- def regenerate_snapshot_manager_credentials_with_http_info(id, opts = {})
1590
- if @api_client.config.debugging
1591
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.regenerate_snapshot_manager_credentials ...'
1592
- end
1593
- # verify the required parameter 'id' is set
1594
- if @api_client.config.client_side_validation && id.nil?
1595
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.regenerate_snapshot_manager_credentials"
1596
- end
1597
- # resource path
1598
- local_var_path = '/regions/{id}/regenerate-snapshot-manager-credentials'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
1599
-
1600
- # query parameters
1601
- query_params = opts[:query_params] || {}
1602
-
1603
- # header parameters
1604
- header_params = opts[:header_params] || {}
1605
- # HTTP header 'Accept' (if needed)
1606
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1607
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
1608
-
1609
- # form parameters
1610
- form_params = opts[:form_params] || {}
1611
-
1612
- # http body (model)
1613
- post_body = opts[:debug_body]
1614
-
1615
- # return_type
1616
- return_type = opts[:debug_return_type] || 'SnapshotManagerCredentials'
1617
-
1618
- # auth_names
1619
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1620
-
1621
- new_options = opts.merge(
1622
- :operation => :"OrganizationsApi.regenerate_snapshot_manager_credentials",
1623
- :header_params => header_params,
1624
- :query_params => query_params,
1625
- :form_params => form_params,
1626
- :body => post_body,
1627
- :auth_names => auth_names,
1628
- :return_type => return_type
1629
- )
1630
-
1631
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1632
- if @api_client.config.debugging
1633
- @api_client.config.logger.debug "API called: OrganizationsApi#regenerate_snapshot_manager_credentials\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1634
- end
1635
- return data, status_code, headers
1636
- end
1637
-
1638
- # Regenerate SSH gateway API key for a region
1639
- # @param id [String] Region ID
1640
- # @param [Hash] opts the optional parameters
1641
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1642
- # @return [RegenerateApiKeyResponse]
1643
- def regenerate_ssh_gateway_api_key(id, opts = {})
1644
- data, _status_code, _headers = regenerate_ssh_gateway_api_key_with_http_info(id, opts)
1645
- data
1646
- end
1647
-
1648
- # Regenerate SSH gateway API key for a region
1649
- # @param id [String] Region ID
1650
- # @param [Hash] opts the optional parameters
1651
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
1652
- # @return [Array<(RegenerateApiKeyResponse, Integer, Hash)>] RegenerateApiKeyResponse data, response status code and response headers
1653
- def regenerate_ssh_gateway_api_key_with_http_info(id, opts = {})
1654
- if @api_client.config.debugging
1655
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.regenerate_ssh_gateway_api_key ...'
1656
- end
1657
- # verify the required parameter 'id' is set
1658
- if @api_client.config.client_side_validation && id.nil?
1659
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.regenerate_ssh_gateway_api_key"
1660
- end
1661
- # resource path
1662
- local_var_path = '/regions/{id}/regenerate-ssh-gateway-api-key'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
1663
-
1664
- # query parameters
1665
- query_params = opts[:query_params] || {}
1666
-
1667
- # header parameters
1668
- header_params = opts[:header_params] || {}
1669
- # HTTP header 'Accept' (if needed)
1670
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
1671
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
1672
-
1673
- # form parameters
1674
- form_params = opts[:form_params] || {}
1675
-
1676
- # http body (model)
1677
- post_body = opts[:debug_body]
1678
-
1679
- # return_type
1680
- return_type = opts[:debug_return_type] || 'RegenerateApiKeyResponse'
1681
-
1682
- # auth_names
1683
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1684
-
1685
- new_options = opts.merge(
1686
- :operation => :"OrganizationsApi.regenerate_ssh_gateway_api_key",
1687
- :header_params => header_params,
1688
- :query_params => query_params,
1689
- :form_params => form_params,
1690
- :body => post_body,
1691
- :auth_names => auth_names,
1692
- :return_type => return_type
1693
- )
1694
-
1695
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
1696
- if @api_client.config.debugging
1697
- @api_client.config.logger.debug "API called: OrganizationsApi#regenerate_ssh_gateway_api_key\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1698
- end
1699
- return data, status_code, headers
1700
- end
1701
-
1702
- # Set default region for organization
1703
- # @param organization_id [String] Organization ID
1704
- # @param update_organization_default_region [UpdateOrganizationDefaultRegion]
1705
- # @param [Hash] opts the optional parameters
1706
- # @return [nil]
1707
- def set_organization_default_region(organization_id, update_organization_default_region, opts = {})
1708
- set_organization_default_region_with_http_info(organization_id, update_organization_default_region, opts)
1709
- nil
1710
- end
1711
-
1712
- # Set default region for organization
1713
- # @param organization_id [String] Organization ID
1714
- # @param update_organization_default_region [UpdateOrganizationDefaultRegion]
1715
- # @param [Hash] opts the optional parameters
1716
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1717
- def set_organization_default_region_with_http_info(organization_id, update_organization_default_region, opts = {})
1718
- if @api_client.config.debugging
1719
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.set_organization_default_region ...'
1720
- end
1721
- # verify the required parameter 'organization_id' is set
1722
- if @api_client.config.client_side_validation && organization_id.nil?
1723
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.set_organization_default_region"
1724
- end
1725
- # verify the required parameter 'update_organization_default_region' is set
1726
- if @api_client.config.client_side_validation && update_organization_default_region.nil?
1727
- fail ArgumentError, "Missing the required parameter 'update_organization_default_region' when calling OrganizationsApi.set_organization_default_region"
1728
- end
1729
- # resource path
1730
- local_var_path = '/organizations/{organizationId}/default-region'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
1731
-
1732
- # query parameters
1733
- query_params = opts[:query_params] || {}
1734
-
1735
- # header parameters
1736
- header_params = opts[:header_params] || {}
1737
- # HTTP header 'Content-Type'
1738
- content_type = @api_client.select_header_content_type(['application/json'])
1739
- if !content_type.nil?
1740
- header_params['Content-Type'] = content_type
1741
- end
1742
-
1743
- # form parameters
1744
- form_params = opts[:form_params] || {}
1745
-
1746
- # http body (model)
1747
- post_body = opts[:debug_body] || @api_client.object_to_http_body(update_organization_default_region)
1748
-
1749
- # return_type
1750
- return_type = opts[:debug_return_type]
1751
-
1752
- # auth_names
1753
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
1754
-
1755
- new_options = opts.merge(
1756
- :operation => :"OrganizationsApi.set_organization_default_region",
1757
- :header_params => header_params,
1758
- :query_params => query_params,
1759
- :form_params => form_params,
1760
- :body => post_body,
1761
- :auth_names => auth_names,
1762
- :return_type => return_type
1763
- )
1764
-
1765
- data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
1766
- if @api_client.config.debugging
1767
- @api_client.config.logger.debug "API called: OrganizationsApi#set_organization_default_region\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
1768
- end
1769
- return data, status_code, headers
1770
- end
1771
-
1772
- # Suspend organization
1773
- # @param organization_id [String] Organization ID
1194
+ # Suspend organization
1195
+ # @param organization_id [String] Organization ID
1774
1196
  # @param [Hash] opts the optional parameters
1775
1197
  # @option opts [OrganizationSuspension] :organization_suspension
1776
1198
  # @return [nil]
@@ -1803,7 +1225,7 @@ module DaytonaApiClient
1803
1225
  # HTTP header 'Content-Type'
1804
1226
  content_type = @api_client.select_header_content_type(['application/json'])
1805
1227
  if !content_type.nil?
1806
- header_params['Content-Type'] = content_type
1228
+ header_params['Content-Type'] = content_type
1807
1229
  end
1808
1230
 
1809
1231
  # form parameters
@@ -1940,7 +1362,7 @@ module DaytonaApiClient
1940
1362
  # HTTP header 'Content-Type'
1941
1363
  content_type = @api_client.select_header_content_type(['application/json'])
1942
1364
  if !content_type.nil?
1943
- header_params['Content-Type'] = content_type
1365
+ header_params['Content-Type'] = content_type
1944
1366
  end
1945
1367
 
1946
1368
  # form parameters
@@ -1972,72 +1394,6 @@ module DaytonaApiClient
1972
1394
  return data, status_code, headers
1973
1395
  end
1974
1396
 
1975
- # Update experimental configuration
1976
- # @param organization_id [String] Organization ID
1977
- # @param [Hash] opts the optional parameters
1978
- # @option opts [Hash<String, Object>] :request_body Experimental configuration as a JSON object. Set to null to clear the configuration.
1979
- # @return [nil]
1980
- def update_experimental_config(organization_id, opts = {})
1981
- update_experimental_config_with_http_info(organization_id, opts)
1982
- nil
1983
- end
1984
-
1985
- # Update experimental configuration
1986
- # @param organization_id [String] Organization ID
1987
- # @param [Hash] opts the optional parameters
1988
- # @option opts [Hash<String, Object>] :request_body Experimental configuration as a JSON object. Set to null to clear the configuration.
1989
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1990
- def update_experimental_config_with_http_info(organization_id, opts = {})
1991
- if @api_client.config.debugging
1992
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.update_experimental_config ...'
1993
- end
1994
- # verify the required parameter 'organization_id' is set
1995
- if @api_client.config.client_side_validation && organization_id.nil?
1996
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.update_experimental_config"
1997
- end
1998
- # resource path
1999
- local_var_path = '/organizations/{organizationId}/experimental-config'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s))
2000
-
2001
- # query parameters
2002
- query_params = opts[:query_params] || {}
2003
-
2004
- # header parameters
2005
- header_params = opts[:header_params] || {}
2006
- # HTTP header 'Content-Type'
2007
- content_type = @api_client.select_header_content_type(['application/json'])
2008
- if !content_type.nil?
2009
- header_params['Content-Type'] = content_type
2010
- end
2011
-
2012
- # form parameters
2013
- form_params = opts[:form_params] || {}
2014
-
2015
- # http body (model)
2016
- post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:'request_body'])
2017
-
2018
- # return_type
2019
- return_type = opts[:debug_return_type]
2020
-
2021
- # auth_names
2022
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
2023
-
2024
- new_options = opts.merge(
2025
- :operation => :"OrganizationsApi.update_experimental_config",
2026
- :header_params => header_params,
2027
- :query_params => query_params,
2028
- :form_params => form_params,
2029
- :body => post_body,
2030
- :auth_names => auth_names,
2031
- :return_type => return_type
2032
- )
2033
-
2034
- data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
2035
- if @api_client.config.debugging
2036
- @api_client.config.logger.debug "API called: OrganizationsApi#update_experimental_config\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2037
- end
2038
- return data, status_code, headers
2039
- end
2040
-
2041
1397
  # Update organization invitation
2042
1398
  # @param organization_id [String] Organization ID
2043
1399
  # @param invitation_id [String] Invitation ID
@@ -2084,7 +1440,7 @@ module DaytonaApiClient
2084
1440
  # HTTP header 'Content-Type'
2085
1441
  content_type = @api_client.select_header_content_type(['application/json'])
2086
1442
  if !content_type.nil?
2087
- header_params['Content-Type'] = content_type
1443
+ header_params['Content-Type'] = content_type
2088
1444
  end
2089
1445
 
2090
1446
  # form parameters
@@ -2120,17 +1476,17 @@ module DaytonaApiClient
2120
1476
  # @param organization_id [String] Organization ID
2121
1477
  # @param update_organization_quota [UpdateOrganizationQuota]
2122
1478
  # @param [Hash] opts the optional parameters
2123
- # @return [nil]
1479
+ # @return [Organization]
2124
1480
  def update_organization_quota(organization_id, update_organization_quota, opts = {})
2125
- update_organization_quota_with_http_info(organization_id, update_organization_quota, opts)
2126
- nil
1481
+ data, _status_code, _headers = update_organization_quota_with_http_info(organization_id, update_organization_quota, opts)
1482
+ data
2127
1483
  end
2128
1484
 
2129
1485
  # Update organization quota
2130
1486
  # @param organization_id [String] Organization ID
2131
1487
  # @param update_organization_quota [UpdateOrganizationQuota]
2132
1488
  # @param [Hash] opts the optional parameters
2133
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
1489
+ # @return [Array<(Organization, Integer, Hash)>] Organization data, response status code and response headers
2134
1490
  def update_organization_quota_with_http_info(organization_id, update_organization_quota, opts = {})
2135
1491
  if @api_client.config.debugging
2136
1492
  @api_client.config.logger.debug 'Calling API: OrganizationsApi.update_organization_quota ...'
@@ -2151,10 +1507,12 @@ module DaytonaApiClient
2151
1507
 
2152
1508
  # header parameters
2153
1509
  header_params = opts[:header_params] || {}
1510
+ # HTTP header 'Accept' (if needed)
1511
+ header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
2154
1512
  # HTTP header 'Content-Type'
2155
1513
  content_type = @api_client.select_header_content_type(['application/json'])
2156
1514
  if !content_type.nil?
2157
- header_params['Content-Type'] = content_type
1515
+ header_params['Content-Type'] = content_type
2158
1516
  end
2159
1517
 
2160
1518
  # form parameters
@@ -2164,7 +1522,7 @@ module DaytonaApiClient
2164
1522
  post_body = opts[:debug_body] || @api_client.object_to_http_body(update_organization_quota)
2165
1523
 
2166
1524
  # return_type
2167
- return_type = opts[:debug_return_type]
1525
+ return_type = opts[:debug_return_type] || 'Organization'
2168
1526
 
2169
1527
  # auth_names
2170
1528
  auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
@@ -2186,82 +1544,6 @@ module DaytonaApiClient
2186
1544
  return data, status_code, headers
2187
1545
  end
2188
1546
 
2189
- # Update organization region quota
2190
- # @param organization_id [String] Organization ID
2191
- # @param region_id [String] ID of the region where the updated quota will be applied
2192
- # @param update_organization_region_quota [UpdateOrganizationRegionQuota]
2193
- # @param [Hash] opts the optional parameters
2194
- # @return [nil]
2195
- def update_organization_region_quota(organization_id, region_id, update_organization_region_quota, opts = {})
2196
- update_organization_region_quota_with_http_info(organization_id, region_id, update_organization_region_quota, opts)
2197
- nil
2198
- end
2199
-
2200
- # Update organization region quota
2201
- # @param organization_id [String] Organization ID
2202
- # @param region_id [String] ID of the region where the updated quota will be applied
2203
- # @param update_organization_region_quota [UpdateOrganizationRegionQuota]
2204
- # @param [Hash] opts the optional parameters
2205
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
2206
- def update_organization_region_quota_with_http_info(organization_id, region_id, update_organization_region_quota, opts = {})
2207
- if @api_client.config.debugging
2208
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.update_organization_region_quota ...'
2209
- end
2210
- # verify the required parameter 'organization_id' is set
2211
- if @api_client.config.client_side_validation && organization_id.nil?
2212
- fail ArgumentError, "Missing the required parameter 'organization_id' when calling OrganizationsApi.update_organization_region_quota"
2213
- end
2214
- # verify the required parameter 'region_id' is set
2215
- if @api_client.config.client_side_validation && region_id.nil?
2216
- fail ArgumentError, "Missing the required parameter 'region_id' when calling OrganizationsApi.update_organization_region_quota"
2217
- end
2218
- # verify the required parameter 'update_organization_region_quota' is set
2219
- if @api_client.config.client_side_validation && update_organization_region_quota.nil?
2220
- fail ArgumentError, "Missing the required parameter 'update_organization_region_quota' when calling OrganizationsApi.update_organization_region_quota"
2221
- end
2222
- # resource path
2223
- local_var_path = '/organizations/{organizationId}/quota/{regionId}'.sub('{' + 'organizationId' + '}', CGI.escape(organization_id.to_s)).sub('{' + 'regionId' + '}', CGI.escape(region_id.to_s))
2224
-
2225
- # query parameters
2226
- query_params = opts[:query_params] || {}
2227
-
2228
- # header parameters
2229
- header_params = opts[:header_params] || {}
2230
- # HTTP header 'Content-Type'
2231
- content_type = @api_client.select_header_content_type(['application/json'])
2232
- if !content_type.nil?
2233
- header_params['Content-Type'] = content_type
2234
- end
2235
-
2236
- # form parameters
2237
- form_params = opts[:form_params] || {}
2238
-
2239
- # http body (model)
2240
- post_body = opts[:debug_body] || @api_client.object_to_http_body(update_organization_region_quota)
2241
-
2242
- # return_type
2243
- return_type = opts[:debug_return_type]
2244
-
2245
- # auth_names
2246
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
2247
-
2248
- new_options = opts.merge(
2249
- :operation => :"OrganizationsApi.update_organization_region_quota",
2250
- :header_params => header_params,
2251
- :query_params => query_params,
2252
- :form_params => form_params,
2253
- :body => post_body,
2254
- :auth_names => auth_names,
2255
- :return_type => return_type
2256
- )
2257
-
2258
- data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
2259
- if @api_client.config.debugging
2260
- @api_client.config.logger.debug "API called: OrganizationsApi#update_organization_region_quota\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2261
- end
2262
- return data, status_code, headers
2263
- end
2264
-
2265
1547
  # Update organization role
2266
1548
  # @param organization_id [String] Organization ID
2267
1549
  # @param role_id [String] Role ID
@@ -2308,7 +1590,7 @@ module DaytonaApiClient
2308
1590
  # HTTP header 'Content-Type'
2309
1591
  content_type = @api_client.select_header_content_type(['application/json'])
2310
1592
  if !content_type.nil?
2311
- header_params['Content-Type'] = content_type
1593
+ header_params['Content-Type'] = content_type
2312
1594
  end
2313
1595
 
2314
1596
  # form parameters
@@ -2340,79 +1622,6 @@ module DaytonaApiClient
2340
1622
  return data, status_code, headers
2341
1623
  end
2342
1624
 
2343
- # Update region configuration
2344
- # @param id [String] Region ID
2345
- # @param update_region [UpdateRegion]
2346
- # @param [Hash] opts the optional parameters
2347
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
2348
- # @return [nil]
2349
- def update_region(id, update_region, opts = {})
2350
- update_region_with_http_info(id, update_region, opts)
2351
- nil
2352
- end
2353
-
2354
- # Update region configuration
2355
- # @param id [String] Region ID
2356
- # @param update_region [UpdateRegion]
2357
- # @param [Hash] opts the optional parameters
2358
- # @option opts [String] :x_daytona_organization_id Use with JWT to specify the organization ID
2359
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
2360
- def update_region_with_http_info(id, update_region, opts = {})
2361
- if @api_client.config.debugging
2362
- @api_client.config.logger.debug 'Calling API: OrganizationsApi.update_region ...'
2363
- end
2364
- # verify the required parameter 'id' is set
2365
- if @api_client.config.client_side_validation && id.nil?
2366
- fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.update_region"
2367
- end
2368
- # verify the required parameter 'update_region' is set
2369
- if @api_client.config.client_side_validation && update_region.nil?
2370
- fail ArgumentError, "Missing the required parameter 'update_region' when calling OrganizationsApi.update_region"
2371
- end
2372
- # resource path
2373
- local_var_path = '/regions/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
2374
-
2375
- # query parameters
2376
- query_params = opts[:query_params] || {}
2377
-
2378
- # header parameters
2379
- header_params = opts[:header_params] || {}
2380
- # HTTP header 'Content-Type'
2381
- content_type = @api_client.select_header_content_type(['application/json'])
2382
- if !content_type.nil?
2383
- header_params['Content-Type'] = content_type
2384
- end
2385
- header_params[:'X-Daytona-Organization-ID'] = opts[:'x_daytona_organization_id'] if !opts[:'x_daytona_organization_id'].nil?
2386
-
2387
- # form parameters
2388
- form_params = opts[:form_params] || {}
2389
-
2390
- # http body (model)
2391
- post_body = opts[:debug_body] || @api_client.object_to_http_body(update_region)
2392
-
2393
- # return_type
2394
- return_type = opts[:debug_return_type]
2395
-
2396
- # auth_names
2397
- auth_names = opts[:debug_auth_names] || ['bearer', 'oauth2']
2398
-
2399
- new_options = opts.merge(
2400
- :operation => :"OrganizationsApi.update_region",
2401
- :header_params => header_params,
2402
- :query_params => query_params,
2403
- :form_params => form_params,
2404
- :body => post_body,
2405
- :auth_names => auth_names,
2406
- :return_type => return_type
2407
- )
2408
-
2409
- data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
2410
- if @api_client.config.debugging
2411
- @api_client.config.logger.debug "API called: OrganizationsApi#update_region\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2412
- end
2413
- return data, status_code, headers
2414
- end
2415
-
2416
1625
  # Update sandbox default limited network egress
2417
1626
  # @param organization_id [String] Organization ID
2418
1627
  # @param organization_sandbox_default_limited_network_egress [OrganizationSandboxDefaultLimitedNetworkEgress]
@@ -2451,7 +1660,7 @@ module DaytonaApiClient
2451
1660
  # HTTP header 'Content-Type'
2452
1661
  content_type = @api_client.select_header_content_type(['application/json'])
2453
1662
  if !content_type.nil?
2454
- header_params['Content-Type'] = content_type
1663
+ header_params['Content-Type'] = content_type
2455
1664
  end
2456
1665
 
2457
1666
  # form parameters