daytona_api_client 0.202.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 (219) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +9 -0
  3. data/Gemfile.lock +101 -0
  4. data/daytona_api_client.gemspec +4 -4
  5. data/lib/daytona_api_client/api/api_keys_api.rb +2 -2
  6. data/lib/daytona_api_client/api/audit_api.rb +140 -40
  7. data/lib/daytona_api_client/api/config_api.rb +1 -1
  8. data/lib/daytona_api_client/api/docker_registry_api.rb +67 -6
  9. data/lib/daytona_api_client/api/health_api.rb +3 -54
  10. data/lib/daytona_api_client/api/object_storage_api.rb +1 -1
  11. data/lib/daytona_api_client/api/organizations_api.rb +265 -1316
  12. data/lib/daytona_api_client/api/preview_api.rb +8 -202
  13. data/lib/daytona_api_client/api/runners_api.rb +22 -412
  14. data/lib/daytona_api_client/api/sandbox_api.rb +434 -2352
  15. data/lib/daytona_api_client/api/snapshots_api.rb +113 -39
  16. data/lib/daytona_api_client/api/toolbox_api.rb +5108 -0
  17. data/lib/daytona_api_client/api/users_api.rb +239 -2
  18. data/lib/daytona_api_client/api/volumes_api.rb +2 -2
  19. data/lib/daytona_api_client/api/webhooks_api.rb +164 -27
  20. data/lib/daytona_api_client/api/workspace_api.rb +955 -0
  21. data/lib/daytona_api_client/api_client.rb +4 -8
  22. data/lib/daytona_api_client/api_error.rb +1 -1
  23. data/lib/daytona_api_client/configuration.rb +2 -5
  24. data/lib/daytona_api_client/models/account_provider.rb +74 -3
  25. data/lib/daytona_api_client/models/announcement.rb +74 -3
  26. data/lib/daytona_api_client/models/api_key_list.rb +74 -3
  27. data/lib/daytona_api_client/models/api_key_response.rb +74 -3
  28. data/lib/daytona_api_client/models/audit_log.rb +75 -22
  29. data/lib/daytona_api_client/models/build_info.rb +78 -34
  30. data/lib/daytona_api_client/models/{create_runner_response.rb → command.rb} +104 -23
  31. data/lib/daytona_api_client/models/completion_context.rb +244 -0
  32. data/lib/daytona_api_client/models/completion_item.rb +289 -0
  33. data/lib/daytona_api_client/models/{paginated_traces.rb → completion_list.rb} +106 -91
  34. data/lib/daytona_api_client/models/compressed_screenshot_response.rb +256 -0
  35. data/lib/daytona_api_client/models/computer_use_start_response.rb +263 -0
  36. data/lib/daytona_api_client/models/{available_sandbox_class.rb → computer_use_status_response.rb} +97 -86
  37. data/lib/daytona_api_client/models/computer_use_stop_response.rb +263 -0
  38. data/lib/daytona_api_client/models/create_api_key.rb +75 -4
  39. data/lib/daytona_api_client/models/create_audit_log.rb +350 -0
  40. data/lib/daytona_api_client/models/create_build_info.rb +74 -3
  41. data/lib/daytona_api_client/models/create_docker_registry.rb +139 -7
  42. data/lib/daytona_api_client/models/create_linked_account.rb +74 -3
  43. data/lib/daytona_api_client/models/create_organization.rb +78 -34
  44. data/lib/daytona_api_client/models/create_organization_invitation.rb +76 -5
  45. data/lib/daytona_api_client/models/create_organization_quota.rb +78 -26
  46. data/lib/daytona_api_client/models/create_organization_role.rb +74 -3
  47. data/lib/daytona_api_client/models/create_runner.rb +386 -43
  48. data/lib/daytona_api_client/models/create_sandbox.rb +117 -76
  49. data/lib/daytona_api_client/models/{signed_port_preview_url.rb → create_session_request.rb} +93 -103
  50. data/lib/daytona_api_client/models/create_snapshot.rb +88 -61
  51. data/lib/daytona_api_client/models/create_user.rb +77 -15
  52. data/lib/daytona_api_client/models/create_volume.rb +74 -3
  53. data/lib/daytona_api_client/models/create_workspace.rb +411 -0
  54. data/lib/daytona_api_client/models/daytona_configuration.rb +78 -64
  55. data/lib/daytona_api_client/models/display_info_response.rb +238 -0
  56. data/lib/daytona_api_client/models/docker_registry.rb +76 -5
  57. data/lib/daytona_api_client/models/{paginated_jobs.rb → download_files.rb} +94 -100
  58. data/lib/daytona_api_client/models/{create_warm_pool.rb → execute_request.rb} +106 -62
  59. data/lib/daytona_api_client/models/execute_response.rb +263 -0
  60. data/lib/daytona_api_client/models/file_info.rb +417 -0
  61. data/lib/daytona_api_client/models/{secret.rb → file_status.rb} +122 -121
  62. data/lib/daytona_api_client/models/git_add_request.rb +264 -0
  63. data/lib/daytona_api_client/models/{admin_create_organization.rb → git_branch_request.rb} +95 -53
  64. data/lib/daytona_api_client/models/git_checkout_request.rb +261 -0
  65. data/lib/daytona_api_client/models/{toolbox_proxy_url.rb → git_clone_request.rb} +142 -10
  66. data/lib/daytona_api_client/models/{trace_span.rb → git_commit_info.rb} +148 -141
  67. data/lib/daytona_api_client/models/git_commit_request.rb +325 -0
  68. data/lib/daytona_api_client/models/{runner_healthcheck.rb → git_commit_response.rb} +92 -74
  69. data/lib/daytona_api_client/models/{create_secret.rb → git_delete_branch_request.rb} +106 -59
  70. data/lib/daytona_api_client/models/{snapshot_manager_credentials.rb → git_repo_request.rb} +96 -35
  71. data/lib/daytona_api_client/models/git_status.rb +290 -0
  72. data/lib/daytona_api_client/models/health_controller_check200_response.rb +74 -3
  73. data/lib/daytona_api_client/models/health_controller_check200_response_info_value.rb +74 -3
  74. data/lib/daytona_api_client/models/health_controller_check503_response.rb +74 -3
  75. data/lib/daytona_api_client/models/{create_sandbox_snapshot.rb → keyboard_hotkey_request.rb} +93 -34
  76. data/lib/daytona_api_client/models/{create_region_response.rb → keyboard_press_request.rb} +102 -63
  77. data/lib/daytona_api_client/models/keyboard_type_request.rb +246 -0
  78. data/lib/daytona_api_client/models/list_branch_response.rb +237 -0
  79. data/lib/daytona_api_client/models/lsp_completion_params.rb +325 -0
  80. data/lib/daytona_api_client/models/lsp_document_request.rb +290 -0
  81. data/lib/daytona_api_client/models/lsp_location.rb +261 -0
  82. data/lib/daytona_api_client/models/lsp_server_request.rb +263 -0
  83. data/lib/daytona_api_client/models/lsp_symbol.rb +287 -0
  84. data/lib/daytona_api_client/models/match.rb +287 -0
  85. data/lib/daytona_api_client/models/mouse_click_request.rb +283 -0
  86. data/lib/daytona_api_client/models/mouse_click_response.rb +263 -0
  87. data/lib/daytona_api_client/models/mouse_drag_request.rb +327 -0
  88. data/lib/daytona_api_client/models/mouse_drag_response.rb +263 -0
  89. data/lib/daytona_api_client/models/mouse_move_request.rb +263 -0
  90. data/lib/daytona_api_client/models/mouse_move_response.rb +263 -0
  91. data/lib/daytona_api_client/models/mouse_position.rb +263 -0
  92. data/lib/daytona_api_client/models/mouse_scroll_request.rb +300 -0
  93. data/lib/daytona_api_client/models/mouse_scroll_response.rb +236 -0
  94. data/lib/daytona_api_client/models/oidc_config.rb +74 -3
  95. data/lib/daytona_api_client/models/organization.rb +159 -243
  96. data/lib/daytona_api_client/models/organization_invitation.rb +78 -7
  97. data/lib/daytona_api_client/models/organization_role.rb +74 -3
  98. data/lib/daytona_api_client/models/organization_sandbox_default_limited_network_egress.rb +74 -3
  99. data/lib/daytona_api_client/models/organization_suspension.rb +79 -10
  100. data/lib/daytona_api_client/models/organization_usage_overview.rb +220 -21
  101. data/lib/daytona_api_client/models/organization_user.rb +76 -5
  102. data/lib/daytona_api_client/models/paginated_audit_logs.rb +78 -17
  103. data/lib/daytona_api_client/models/{paginated_sandboxes_deprecated.rb → paginated_sandboxes.rb} +76 -5
  104. data/lib/daytona_api_client/models/paginated_snapshots.rb +74 -3
  105. data/lib/daytona_api_client/models/{paginated_logs.rb → paginated_snapshots_dto.rb} +77 -10
  106. data/lib/daytona_api_client/models/port_preview_url.rb +88 -34
  107. data/lib/daytona_api_client/models/position.rb +261 -0
  108. data/lib/daytona_api_client/models/posthog_config.rb +74 -3
  109. data/lib/daytona_api_client/models/process_errors_response.rb +263 -0
  110. data/lib/daytona_api_client/models/process_logs_response.rb +263 -0
  111. data/lib/daytona_api_client/models/process_restart_response.rb +263 -0
  112. data/lib/daytona_api_client/models/process_status_response.rb +263 -0
  113. data/lib/daytona_api_client/models/{update_last_activity.rb → project_dir_response.rb} +83 -13
  114. data/lib/daytona_api_client/models/pty_create_request.rb +288 -0
  115. data/lib/daytona_api_client/models/pty_create_response.rb +236 -0
  116. data/lib/daytona_api_client/models/{metric_data_point.rb → pty_list_response.rb} +95 -49
  117. data/lib/daytona_api_client/models/pty_resize_request.rb +263 -0
  118. data/lib/daytona_api_client/models/pty_session_info.rb +425 -0
  119. data/lib/daytona_api_client/models/range.rb +261 -0
  120. data/lib/daytona_api_client/models/region.rb +78 -181
  121. data/lib/daytona_api_client/models/{regenerate_api_key_response.rb → region_screenshot_response.rb} +113 -22
  122. data/lib/daytona_api_client/models/registry_push_access_dto.rb +74 -3
  123. data/lib/daytona_api_client/models/replace_request.rb +289 -0
  124. data/lib/daytona_api_client/models/{resize_sandbox.rb → replace_result.rb} +95 -84
  125. data/lib/daytona_api_client/models/runner.rb +215 -155
  126. data/lib/daytona_api_client/models/runner_snapshot_dto.rb +91 -3
  127. data/lib/daytona_api_client/models/runner_state.rb +3 -4
  128. data/lib/daytona_api_client/models/sandbox.rb +101 -164
  129. data/lib/daytona_api_client/models/sandbox_class.rb +6 -8
  130. data/lib/daytona_api_client/models/sandbox_desired_state.rb +3 -5
  131. data/lib/daytona_api_client/models/{create_region.rb → sandbox_info.rb} +113 -38
  132. data/lib/daytona_api_client/models/sandbox_labels.rb +74 -3
  133. data/lib/daytona_api_client/models/sandbox_state.rb +3 -10
  134. data/lib/daytona_api_client/models/sandbox_volume.rb +79 -18
  135. data/lib/daytona_api_client/models/screenshot_response.rb +256 -0
  136. data/lib/daytona_api_client/models/{runner_service_health.rb → search_files_response.rb} +94 -59
  137. data/lib/daytona_api_client/models/send_webhook_dto.rb +75 -26
  138. data/lib/daytona_api_client/models/session.rb +251 -0
  139. data/lib/daytona_api_client/models/{list_sandboxes_response.rb → session_execute_request.rb} +110 -34
  140. data/lib/daytona_api_client/models/session_execute_response.rb +239 -0
  141. data/lib/daytona_api_client/models/set_snapshot_general_status_dto.rb +74 -3
  142. data/lib/daytona_api_client/models/snapshot_dto.rb +78 -71
  143. data/lib/daytona_api_client/models/snapshot_state.rb +6 -5
  144. data/lib/daytona_api_client/models/ssh_access_dto.rb +78 -34
  145. data/lib/daytona_api_client/models/ssh_access_validation_dto.rb +98 -7
  146. data/lib/daytona_api_client/models/storage_access_dto.rb +78 -34
  147. data/lib/daytona_api_client/models/update_docker_registry.rb +74 -3
  148. data/lib/daytona_api_client/models/update_organization_invitation.rb +76 -5
  149. data/lib/daytona_api_client/models/update_organization_member_access.rb +76 -5
  150. data/lib/daytona_api_client/models/update_organization_quota.rb +115 -131
  151. data/lib/daytona_api_client/models/update_organization_role.rb +74 -3
  152. data/lib/daytona_api_client/models/update_sandbox_state_dto.rb +80 -29
  153. data/lib/daytona_api_client/models/user.rb +74 -3
  154. data/lib/daytona_api_client/models/{list_secrets_response.rb → user_home_dir_response.rb} +83 -72
  155. data/lib/daytona_api_client/models/user_public_key.rb +74 -3
  156. data/lib/daytona_api_client/models/volume_dto.rb +74 -3
  157. data/lib/daytona_api_client/models/volume_state.rb +3 -4
  158. data/lib/daytona_api_client/models/webhook_app_portal_access.rb +75 -31
  159. data/lib/daytona_api_client/models/{preview_warning.rb → webhook_controller_get_status200_response.rb} +76 -23
  160. data/lib/daytona_api_client/models/webhook_initialization_status.rb +74 -3
  161. data/lib/daytona_api_client/models/windows_response.rb +265 -0
  162. data/lib/daytona_api_client/models/{update_job_status.rb → work_dir_response.rb} +83 -72
  163. data/lib/daytona_api_client/models/{sandbox_list_item.rb → workspace.rb} +339 -193
  164. data/lib/daytona_api_client/version.rb +2 -2
  165. data/lib/daytona_api_client.rb +76 -74
  166. data/project.json +13 -38
  167. metadata +81 -83
  168. data/.gitignore +0 -39
  169. data/.openapi-generator/FILES +0 -163
  170. data/.openapi-generator/VERSION +0 -1
  171. data/.openapi-generator-ignore +0 -31
  172. data/.rspec +0 -2
  173. data/.rubocop.yml +0 -148
  174. data/fix-gemspec.sh +0 -11
  175. data/lib/daytona_api_client/api/admin_api.rb +0 -1615
  176. data/lib/daytona_api_client/api/jobs_api.rb +0 -299
  177. data/lib/daytona_api_client/api/regions_api.rb +0 -77
  178. data/lib/daytona_api_client/api/secret_api.rb +0 -441
  179. data/lib/daytona_api_client/api/warm_pools_api.rb +0 -286
  180. data/lib/daytona_api_client/api_model_base.rb +0 -88
  181. data/lib/daytona_api_client/models/admin_create_runner.rb +0 -326
  182. data/lib/daytona_api_client/models/admin_get_webhook_status200_response.rb +0 -147
  183. data/lib/daytona_api_client/models/create_organization_region_quota.rb +0 -375
  184. data/lib/daytona_api_client/models/date_filter.rb +0 -178
  185. data/lib/daytona_api_client/models/fork_sandbox.rb +0 -148
  186. data/lib/daytona_api_client/models/gpu_type.rb +0 -44
  187. data/lib/daytona_api_client/models/int_filter.rb +0 -222
  188. data/lib/daytona_api_client/models/job.rb +0 -366
  189. data/lib/daytona_api_client/models/job_status.rb +0 -43
  190. data/lib/daytona_api_client/models/job_type.rb +0 -55
  191. data/lib/daytona_api_client/models/log_entry.rb +0 -334
  192. data/lib/daytona_api_client/models/metric_series.rb +0 -194
  193. data/lib/daytona_api_client/models/metrics_response.rb +0 -167
  194. data/lib/daytona_api_client/models/organization_preview_warning.rb +0 -165
  195. data/lib/daytona_api_client/models/otel_config.rb +0 -188
  196. data/lib/daytona_api_client/models/poll_jobs_response.rb +0 -167
  197. data/lib/daytona_api_client/models/rate_limit_config.rb +0 -188
  198. data/lib/daytona_api_client/models/rate_limit_entry.rb +0 -158
  199. data/lib/daytona_api_client/models/region_quota.rb +0 -440
  200. data/lib/daytona_api_client/models/region_type.rb +0 -42
  201. data/lib/daytona_api_client/models/region_usage_overview.rb +0 -518
  202. data/lib/daytona_api_client/models/resolve_sandbox_secrets200_response_inner.rb +0 -176
  203. data/lib/daytona_api_client/models/runner_class.rb +0 -40
  204. data/lib/daytona_api_client/models/runner_full.rb +0 -757
  205. data/lib/daytona_api_client/models/runner_health_metrics.rb +0 -482
  206. data/lib/daytona_api_client/models/sandbox_list_sort_direction.rb +0 -41
  207. data/lib/daytona_api_client/models/sandbox_list_sort_field.rb +0 -45
  208. data/lib/daytona_api_client/models/string_filter.rb +0 -182
  209. data/lib/daytona_api_client/models/trace_summary.rb +0 -310
  210. data/lib/daytona_api_client/models/update_organization_default_region.rb +0 -165
  211. data/lib/daytona_api_client/models/update_organization_region_quota.rb +0 -302
  212. data/lib/daytona_api_client/models/update_region.rb +0 -171
  213. data/lib/daytona_api_client/models/update_sandbox_network_settings.rb +0 -168
  214. data/lib/daytona_api_client/models/update_sandbox_secrets.rb +0 -167
  215. data/lib/daytona_api_client/models/update_secret.rb +0 -170
  216. data/lib/daytona_api_client/models/update_warm_pool.rb +0 -174
  217. data/lib/daytona_api_client/models/url.rb +0 -165
  218. data/lib/daytona_api_client/models/warm_pool.rb +0 -490
  219. data/lib/daytona_api_client/models/webhook_event.rb +0 -46
@@ -1,334 +0,0 @@
1
- =begin
2
- #Daytona
3
-
4
- #Daytona AI platform API Docs
5
-
6
- The version of the OpenAPI document: 1.0
7
- Contact: support@daytona.com
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.21.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module DaytonaApiClient
17
- class LogEntry < ApiModelBase
18
- # Timestamp of the log entry
19
- attr_accessor :timestamp
20
-
21
- # Log message body
22
- attr_accessor :body
23
-
24
- # Severity level text (e.g., INFO, WARN, ERROR)
25
- attr_accessor :severity_text
26
-
27
- # Severity level number
28
- attr_accessor :severity_number
29
-
30
- # Service name that generated the log
31
- attr_accessor :service_name
32
-
33
- # Resource attributes from OTEL
34
- attr_accessor :resource_attributes
35
-
36
- # Log-specific attributes
37
- attr_accessor :log_attributes
38
-
39
- # Associated trace ID if available
40
- attr_accessor :trace_id
41
-
42
- # Associated span ID if available
43
- attr_accessor :span_id
44
-
45
- # Attribute mapping from ruby-style variable name to JSON key.
46
- def self.attribute_map
47
- {
48
- :'timestamp' => :'timestamp',
49
- :'body' => :'body',
50
- :'severity_text' => :'severityText',
51
- :'severity_number' => :'severityNumber',
52
- :'service_name' => :'serviceName',
53
- :'resource_attributes' => :'resourceAttributes',
54
- :'log_attributes' => :'logAttributes',
55
- :'trace_id' => :'traceId',
56
- :'span_id' => :'spanId'
57
- }
58
- end
59
-
60
- # Returns attribute mapping this model knows about
61
- def self.acceptable_attribute_map
62
- attribute_map
63
- end
64
-
65
- # Returns all the JSON keys this model knows about
66
- def self.acceptable_attributes
67
- acceptable_attribute_map.values
68
- end
69
-
70
- # Attribute type mapping.
71
- def self.openapi_types
72
- {
73
- :'timestamp' => :'String',
74
- :'body' => :'String',
75
- :'severity_text' => :'String',
76
- :'severity_number' => :'Float',
77
- :'service_name' => :'String',
78
- :'resource_attributes' => :'Hash<String, String>',
79
- :'log_attributes' => :'Hash<String, String>',
80
- :'trace_id' => :'String',
81
- :'span_id' => :'String'
82
- }
83
- end
84
-
85
- # List of attributes with nullable: true
86
- def self.openapi_nullable
87
- Set.new([
88
- ])
89
- end
90
-
91
- # Initializes the object
92
- # @param [Hash] attributes Model attributes in the form of hash
93
- def initialize(attributes = {})
94
- if (!attributes.is_a?(Hash))
95
- fail ArgumentError, "The input argument (attributes) must be a hash in `DaytonaApiClient::LogEntry` initialize method"
96
- end
97
-
98
- # check to see if the attribute exists and convert string to symbol for hash key
99
- acceptable_attribute_map = self.class.acceptable_attribute_map
100
- attributes = attributes.each_with_object({}) { |(k, v), h|
101
- if (!acceptable_attribute_map.key?(k.to_sym))
102
- fail ArgumentError, "`#{k}` is not a valid attribute in `DaytonaApiClient::LogEntry`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
103
- end
104
- h[k.to_sym] = v
105
- }
106
-
107
- if attributes.key?(:'timestamp')
108
- self.timestamp = attributes[:'timestamp']
109
- else
110
- self.timestamp = nil
111
- end
112
-
113
- if attributes.key?(:'body')
114
- self.body = attributes[:'body']
115
- else
116
- self.body = nil
117
- end
118
-
119
- if attributes.key?(:'severity_text')
120
- self.severity_text = attributes[:'severity_text']
121
- else
122
- self.severity_text = nil
123
- end
124
-
125
- if attributes.key?(:'severity_number')
126
- self.severity_number = attributes[:'severity_number']
127
- end
128
-
129
- if attributes.key?(:'service_name')
130
- self.service_name = attributes[:'service_name']
131
- else
132
- self.service_name = nil
133
- end
134
-
135
- if attributes.key?(:'resource_attributes')
136
- if (value = attributes[:'resource_attributes']).is_a?(Hash)
137
- self.resource_attributes = value
138
- end
139
- else
140
- self.resource_attributes = nil
141
- end
142
-
143
- if attributes.key?(:'log_attributes')
144
- if (value = attributes[:'log_attributes']).is_a?(Hash)
145
- self.log_attributes = value
146
- end
147
- else
148
- self.log_attributes = nil
149
- end
150
-
151
- if attributes.key?(:'trace_id')
152
- self.trace_id = attributes[:'trace_id']
153
- end
154
-
155
- if attributes.key?(:'span_id')
156
- self.span_id = attributes[:'span_id']
157
- end
158
- end
159
-
160
- # Show invalid properties with the reasons. Usually used together with valid?
161
- # @return Array for valid properties with the reasons
162
- def list_invalid_properties
163
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
164
- invalid_properties = Array.new
165
- if @timestamp.nil?
166
- invalid_properties.push('invalid value for "timestamp", timestamp cannot be nil.')
167
- end
168
-
169
- if @body.nil?
170
- invalid_properties.push('invalid value for "body", body cannot be nil.')
171
- end
172
-
173
- if @severity_text.nil?
174
- invalid_properties.push('invalid value for "severity_text", severity_text cannot be nil.')
175
- end
176
-
177
- if @service_name.nil?
178
- invalid_properties.push('invalid value for "service_name", service_name cannot be nil.')
179
- end
180
-
181
- if @resource_attributes.nil?
182
- invalid_properties.push('invalid value for "resource_attributes", resource_attributes cannot be nil.')
183
- end
184
-
185
- if @log_attributes.nil?
186
- invalid_properties.push('invalid value for "log_attributes", log_attributes cannot be nil.')
187
- end
188
-
189
- invalid_properties
190
- end
191
-
192
- # Check to see if the all the properties in the model are valid
193
- # @return true if the model is valid
194
- def valid?
195
- warn '[DEPRECATED] the `valid?` method is obsolete'
196
- return false if @timestamp.nil?
197
- return false if @body.nil?
198
- return false if @severity_text.nil?
199
- return false if @service_name.nil?
200
- return false if @resource_attributes.nil?
201
- return false if @log_attributes.nil?
202
- true
203
- end
204
-
205
- # Custom attribute writer method with validation
206
- # @param [Object] timestamp Value to be assigned
207
- def timestamp=(timestamp)
208
- if timestamp.nil?
209
- fail ArgumentError, 'timestamp cannot be nil'
210
- end
211
-
212
- @timestamp = timestamp
213
- end
214
-
215
- # Custom attribute writer method with validation
216
- # @param [Object] body Value to be assigned
217
- def body=(body)
218
- if body.nil?
219
- fail ArgumentError, 'body cannot be nil'
220
- end
221
-
222
- @body = body
223
- end
224
-
225
- # Custom attribute writer method with validation
226
- # @param [Object] severity_text Value to be assigned
227
- def severity_text=(severity_text)
228
- if severity_text.nil?
229
- fail ArgumentError, 'severity_text cannot be nil'
230
- end
231
-
232
- @severity_text = severity_text
233
- end
234
-
235
- # Custom attribute writer method with validation
236
- # @param [Object] service_name Value to be assigned
237
- def service_name=(service_name)
238
- if service_name.nil?
239
- fail ArgumentError, 'service_name cannot be nil'
240
- end
241
-
242
- @service_name = service_name
243
- end
244
-
245
- # Custom attribute writer method with validation
246
- # @param [Object] resource_attributes Value to be assigned
247
- def resource_attributes=(resource_attributes)
248
- if resource_attributes.nil?
249
- fail ArgumentError, 'resource_attributes cannot be nil'
250
- end
251
-
252
- @resource_attributes = resource_attributes
253
- end
254
-
255
- # Custom attribute writer method with validation
256
- # @param [Object] log_attributes Value to be assigned
257
- def log_attributes=(log_attributes)
258
- if log_attributes.nil?
259
- fail ArgumentError, 'log_attributes cannot be nil'
260
- end
261
-
262
- @log_attributes = log_attributes
263
- end
264
-
265
- # Checks equality by comparing each attribute.
266
- # @param [Object] Object to be compared
267
- def ==(o)
268
- return true if self.equal?(o)
269
- self.class == o.class &&
270
- timestamp == o.timestamp &&
271
- body == o.body &&
272
- severity_text == o.severity_text &&
273
- severity_number == o.severity_number &&
274
- service_name == o.service_name &&
275
- resource_attributes == o.resource_attributes &&
276
- log_attributes == o.log_attributes &&
277
- trace_id == o.trace_id &&
278
- span_id == o.span_id
279
- end
280
-
281
- # @see the `==` method
282
- # @param [Object] Object to be compared
283
- def eql?(o)
284
- self == o
285
- end
286
-
287
- # Calculates hash code according to all attributes.
288
- # @return [Integer] Hash code
289
- def hash
290
- [timestamp, body, severity_text, severity_number, service_name, resource_attributes, log_attributes, trace_id, span_id].hash
291
- end
292
-
293
- # Builds the object from hash
294
- # @param [Hash] attributes Model attributes in the form of hash
295
- # @return [Object] Returns the model itself
296
- def self.build_from_hash(attributes)
297
- return nil unless attributes.is_a?(Hash)
298
- attributes = attributes.transform_keys(&:to_sym)
299
- transformed_hash = {}
300
- openapi_types.each_pair do |key, type|
301
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
302
- transformed_hash["#{key}"] = nil
303
- elsif type =~ /\AArray<(.*)>/i
304
- # check to ensure the input is an array given that the attribute
305
- # is documented as an array but the input is not
306
- if attributes[attribute_map[key]].is_a?(Array)
307
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
308
- end
309
- elsif !attributes[attribute_map[key]].nil?
310
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
311
- end
312
- end
313
- new(transformed_hash)
314
- end
315
-
316
- # Returns the object in the form of hash
317
- # @return [Hash] Returns the object in the form of hash
318
- def to_hash
319
- hash = {}
320
- self.class.attribute_map.each_pair do |attr, param|
321
- value = self.send(attr)
322
- if value.nil?
323
- is_nullable = self.class.openapi_nullable.include?(attr)
324
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
325
- end
326
-
327
- hash[param] = _to_hash(value)
328
- end
329
- hash
330
- end
331
-
332
- end
333
-
334
- end
@@ -1,194 +0,0 @@
1
- =begin
2
- #Daytona
3
-
4
- #Daytona AI platform API Docs
5
-
6
- The version of the OpenAPI document: 1.0
7
- Contact: support@daytona.com
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.21.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module DaytonaApiClient
17
- class MetricSeries < ApiModelBase
18
- # Name of the metric
19
- attr_accessor :metric_name
20
-
21
- # Data points for this metric
22
- attr_accessor :data_points
23
-
24
- # Attribute mapping from ruby-style variable name to JSON key.
25
- def self.attribute_map
26
- {
27
- :'metric_name' => :'metricName',
28
- :'data_points' => :'dataPoints'
29
- }
30
- end
31
-
32
- # Returns attribute mapping this model knows about
33
- def self.acceptable_attribute_map
34
- attribute_map
35
- end
36
-
37
- # Returns all the JSON keys this model knows about
38
- def self.acceptable_attributes
39
- acceptable_attribute_map.values
40
- end
41
-
42
- # Attribute type mapping.
43
- def self.openapi_types
44
- {
45
- :'metric_name' => :'String',
46
- :'data_points' => :'Array<MetricDataPoint>'
47
- }
48
- end
49
-
50
- # List of attributes with nullable: true
51
- def self.openapi_nullable
52
- Set.new([
53
- ])
54
- end
55
-
56
- # Initializes the object
57
- # @param [Hash] attributes Model attributes in the form of hash
58
- def initialize(attributes = {})
59
- if (!attributes.is_a?(Hash))
60
- fail ArgumentError, "The input argument (attributes) must be a hash in `DaytonaApiClient::MetricSeries` initialize method"
61
- end
62
-
63
- # check to see if the attribute exists and convert string to symbol for hash key
64
- acceptable_attribute_map = self.class.acceptable_attribute_map
65
- attributes = attributes.each_with_object({}) { |(k, v), h|
66
- if (!acceptable_attribute_map.key?(k.to_sym))
67
- fail ArgumentError, "`#{k}` is not a valid attribute in `DaytonaApiClient::MetricSeries`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
68
- end
69
- h[k.to_sym] = v
70
- }
71
-
72
- if attributes.key?(:'metric_name')
73
- self.metric_name = attributes[:'metric_name']
74
- else
75
- self.metric_name = nil
76
- end
77
-
78
- if attributes.key?(:'data_points')
79
- if (value = attributes[:'data_points']).is_a?(Array)
80
- self.data_points = value
81
- end
82
- else
83
- self.data_points = nil
84
- end
85
- end
86
-
87
- # Show invalid properties with the reasons. Usually used together with valid?
88
- # @return Array for valid properties with the reasons
89
- def list_invalid_properties
90
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
91
- invalid_properties = Array.new
92
- if @metric_name.nil?
93
- invalid_properties.push('invalid value for "metric_name", metric_name cannot be nil.')
94
- end
95
-
96
- if @data_points.nil?
97
- invalid_properties.push('invalid value for "data_points", data_points cannot be nil.')
98
- end
99
-
100
- invalid_properties
101
- end
102
-
103
- # Check to see if the all the properties in the model are valid
104
- # @return true if the model is valid
105
- def valid?
106
- warn '[DEPRECATED] the `valid?` method is obsolete'
107
- return false if @metric_name.nil?
108
- return false if @data_points.nil?
109
- true
110
- end
111
-
112
- # Custom attribute writer method with validation
113
- # @param [Object] metric_name Value to be assigned
114
- def metric_name=(metric_name)
115
- if metric_name.nil?
116
- fail ArgumentError, 'metric_name cannot be nil'
117
- end
118
-
119
- @metric_name = metric_name
120
- end
121
-
122
- # Custom attribute writer method with validation
123
- # @param [Object] data_points Value to be assigned
124
- def data_points=(data_points)
125
- if data_points.nil?
126
- fail ArgumentError, 'data_points cannot be nil'
127
- end
128
-
129
- @data_points = data_points
130
- end
131
-
132
- # Checks equality by comparing each attribute.
133
- # @param [Object] Object to be compared
134
- def ==(o)
135
- return true if self.equal?(o)
136
- self.class == o.class &&
137
- metric_name == o.metric_name &&
138
- data_points == o.data_points
139
- end
140
-
141
- # @see the `==` method
142
- # @param [Object] Object to be compared
143
- def eql?(o)
144
- self == o
145
- end
146
-
147
- # Calculates hash code according to all attributes.
148
- # @return [Integer] Hash code
149
- def hash
150
- [metric_name, data_points].hash
151
- end
152
-
153
- # Builds the object from hash
154
- # @param [Hash] attributes Model attributes in the form of hash
155
- # @return [Object] Returns the model itself
156
- def self.build_from_hash(attributes)
157
- return nil unless attributes.is_a?(Hash)
158
- attributes = attributes.transform_keys(&:to_sym)
159
- transformed_hash = {}
160
- openapi_types.each_pair do |key, type|
161
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
162
- transformed_hash["#{key}"] = nil
163
- elsif type =~ /\AArray<(.*)>/i
164
- # check to ensure the input is an array given that the attribute
165
- # is documented as an array but the input is not
166
- if attributes[attribute_map[key]].is_a?(Array)
167
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
168
- end
169
- elsif !attributes[attribute_map[key]].nil?
170
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
171
- end
172
- end
173
- new(transformed_hash)
174
- end
175
-
176
- # Returns the object in the form of hash
177
- # @return [Hash] Returns the object in the form of hash
178
- def to_hash
179
- hash = {}
180
- self.class.attribute_map.each_pair do |attr, param|
181
- value = self.send(attr)
182
- if value.nil?
183
- is_nullable = self.class.openapi_nullable.include?(attr)
184
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
185
- end
186
-
187
- hash[param] = _to_hash(value)
188
- end
189
- hash
190
- end
191
-
192
- end
193
-
194
- end
@@ -1,167 +0,0 @@
1
- =begin
2
- #Daytona
3
-
4
- #Daytona AI platform API Docs
5
-
6
- The version of the OpenAPI document: 1.0
7
- Contact: support@daytona.com
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.21.0
10
-
11
- =end
12
-
13
- require 'date'
14
- require 'time'
15
-
16
- module DaytonaApiClient
17
- class MetricsResponse < ApiModelBase
18
- # List of metric series
19
- attr_accessor :series
20
-
21
- # Attribute mapping from ruby-style variable name to JSON key.
22
- def self.attribute_map
23
- {
24
- :'series' => :'series'
25
- }
26
- end
27
-
28
- # Returns attribute mapping this model knows about
29
- def self.acceptable_attribute_map
30
- attribute_map
31
- end
32
-
33
- # Returns all the JSON keys this model knows about
34
- def self.acceptable_attributes
35
- acceptable_attribute_map.values
36
- end
37
-
38
- # Attribute type mapping.
39
- def self.openapi_types
40
- {
41
- :'series' => :'Array<MetricSeries>'
42
- }
43
- end
44
-
45
- # List of attributes with nullable: true
46
- def self.openapi_nullable
47
- Set.new([
48
- ])
49
- end
50
-
51
- # Initializes the object
52
- # @param [Hash] attributes Model attributes in the form of hash
53
- def initialize(attributes = {})
54
- if (!attributes.is_a?(Hash))
55
- fail ArgumentError, "The input argument (attributes) must be a hash in `DaytonaApiClient::MetricsResponse` initialize method"
56
- end
57
-
58
- # check to see if the attribute exists and convert string to symbol for hash key
59
- acceptable_attribute_map = self.class.acceptable_attribute_map
60
- attributes = attributes.each_with_object({}) { |(k, v), h|
61
- if (!acceptable_attribute_map.key?(k.to_sym))
62
- fail ArgumentError, "`#{k}` is not a valid attribute in `DaytonaApiClient::MetricsResponse`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
- end
64
- h[k.to_sym] = v
65
- }
66
-
67
- if attributes.key?(:'series')
68
- if (value = attributes[:'series']).is_a?(Array)
69
- self.series = value
70
- end
71
- else
72
- self.series = nil
73
- end
74
- end
75
-
76
- # Show invalid properties with the reasons. Usually used together with valid?
77
- # @return Array for valid properties with the reasons
78
- def list_invalid_properties
79
- warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
80
- invalid_properties = Array.new
81
- if @series.nil?
82
- invalid_properties.push('invalid value for "series", series cannot be nil.')
83
- end
84
-
85
- invalid_properties
86
- end
87
-
88
- # Check to see if the all the properties in the model are valid
89
- # @return true if the model is valid
90
- def valid?
91
- warn '[DEPRECATED] the `valid?` method is obsolete'
92
- return false if @series.nil?
93
- true
94
- end
95
-
96
- # Custom attribute writer method with validation
97
- # @param [Object] series Value to be assigned
98
- def series=(series)
99
- if series.nil?
100
- fail ArgumentError, 'series cannot be nil'
101
- end
102
-
103
- @series = series
104
- end
105
-
106
- # Checks equality by comparing each attribute.
107
- # @param [Object] Object to be compared
108
- def ==(o)
109
- return true if self.equal?(o)
110
- self.class == o.class &&
111
- series == o.series
112
- end
113
-
114
- # @see the `==` method
115
- # @param [Object] Object to be compared
116
- def eql?(o)
117
- self == o
118
- end
119
-
120
- # Calculates hash code according to all attributes.
121
- # @return [Integer] Hash code
122
- def hash
123
- [series].hash
124
- end
125
-
126
- # Builds the object from hash
127
- # @param [Hash] attributes Model attributes in the form of hash
128
- # @return [Object] Returns the model itself
129
- def self.build_from_hash(attributes)
130
- return nil unless attributes.is_a?(Hash)
131
- attributes = attributes.transform_keys(&:to_sym)
132
- transformed_hash = {}
133
- openapi_types.each_pair do |key, type|
134
- if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
135
- transformed_hash["#{key}"] = nil
136
- elsif type =~ /\AArray<(.*)>/i
137
- # check to ensure the input is an array given that the attribute
138
- # is documented as an array but the input is not
139
- if attributes[attribute_map[key]].is_a?(Array)
140
- transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
141
- end
142
- elsif !attributes[attribute_map[key]].nil?
143
- transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
144
- end
145
- end
146
- new(transformed_hash)
147
- end
148
-
149
- # Returns the object in the form of hash
150
- # @return [Hash] Returns the object in the form of hash
151
- def to_hash
152
- hash = {}
153
- self.class.attribute_map.each_pair do |attr, param|
154
- value = self.send(attr)
155
- if value.nil?
156
- is_nullable = self.class.openapi_nullable.include?(attr)
157
- next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
158
- end
159
-
160
- hash[param] = _to_hash(value)
161
- end
162
- hash
163
- end
164
-
165
- end
166
-
167
- end