ilovevideoeditor-sdk 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 (120) hide show
  1. checksums.yaml +7 -0
  2. data/lib/generated/ilovevideoeditor-sdk/api/api_keys_api.rb +204 -0
  3. data/lib/generated/ilovevideoeditor-sdk/api/assets_api.rb +632 -0
  4. data/lib/generated/ilovevideoeditor-sdk/api/billing_api.rb +428 -0
  5. data/lib/generated/ilovevideoeditor-sdk/api/health_api.rb +134 -0
  6. data/lib/generated/ilovevideoeditor-sdk/api/integrations_api.rb +587 -0
  7. data/lib/generated/ilovevideoeditor-sdk/api/projects_api.rb +614 -0
  8. data/lib/generated/ilovevideoeditor-sdk/api/render_api.rb +656 -0
  9. data/lib/generated/ilovevideoeditor-sdk/api/renditions_api.rb +420 -0
  10. data/lib/generated/ilovevideoeditor-sdk/api/templates_api.rb +217 -0
  11. data/lib/generated/ilovevideoeditor-sdk/api/tools_api.rb +220 -0
  12. data/lib/generated/ilovevideoeditor-sdk/api/webhooks_api.rb +204 -0
  13. data/lib/generated/ilovevideoeditor-sdk/api/workflows_api.rb +854 -0
  14. data/lib/generated/ilovevideoeditor-sdk/api_client.rb +397 -0
  15. data/lib/generated/ilovevideoeditor-sdk/api_error.rb +58 -0
  16. data/lib/generated/ilovevideoeditor-sdk/api_model_base.rb +88 -0
  17. data/lib/generated/ilovevideoeditor-sdk/configuration.rb +316 -0
  18. data/lib/generated/ilovevideoeditor-sdk/models/api_key.rb +246 -0
  19. data/lib/generated/ilovevideoeditor-sdk/models/api_key_with_secret.rb +191 -0
  20. data/lib/generated/ilovevideoeditor-sdk/models/asset.rb +404 -0
  21. data/lib/generated/ilovevideoeditor-sdk/models/asset_create.rb +303 -0
  22. data/lib/generated/ilovevideoeditor-sdk/models/asset_upload_url_response.rb +295 -0
  23. data/lib/generated/ilovevideoeditor-sdk/models/batch_delete_projects_request.rb +184 -0
  24. data/lib/generated/ilovevideoeditor-sdk/models/batch_delete_result.rb +175 -0
  25. data/lib/generated/ilovevideoeditor-sdk/models/billing_prices.rb +158 -0
  26. data/lib/generated/ilovevideoeditor-sdk/models/billing_prices_tiers.rb +168 -0
  27. data/lib/generated/ilovevideoeditor-sdk/models/billing_subscription.rb +254 -0
  28. data/lib/generated/ilovevideoeditor-sdk/models/cancel_render200_response.rb +225 -0
  29. data/lib/generated/ilovevideoeditor-sdk/models/create_api_key_request.rb +147 -0
  30. data/lib/generated/ilovevideoeditor-sdk/models/create_asset201_response.rb +164 -0
  31. data/lib/generated/ilovevideoeditor-sdk/models/create_checkout_session200_response.rb +164 -0
  32. data/lib/generated/ilovevideoeditor-sdk/models/create_checkout_session_request.rb +220 -0
  33. data/lib/generated/ilovevideoeditor-sdk/models/create_integration201_response.rb +164 -0
  34. data/lib/generated/ilovevideoeditor-sdk/models/create_project200_response.rb +164 -0
  35. data/lib/generated/ilovevideoeditor-sdk/models/create_workflow201_response.rb +164 -0
  36. data/lib/generated/ilovevideoeditor-sdk/models/create_workflow_request.rb +208 -0
  37. data/lib/generated/ilovevideoeditor-sdk/models/credit_balance.rb +219 -0
  38. data/lib/generated/ilovevideoeditor-sdk/models/credit_balance_summary.rb +174 -0
  39. data/lib/generated/ilovevideoeditor-sdk/models/credit_balance_usage.rb +156 -0
  40. data/lib/generated/ilovevideoeditor-sdk/models/delete_project200_response.rb +190 -0
  41. data/lib/generated/ilovevideoeditor-sdk/models/destination.rb +331 -0
  42. data/lib/generated/ilovevideoeditor-sdk/models/destination_input.rb +304 -0
  43. data/lib/generated/ilovevideoeditor-sdk/models/error.rb +182 -0
  44. data/lib/generated/ilovevideoeditor-sdk/models/estimate_render_cost_request.rb +164 -0
  45. data/lib/generated/ilovevideoeditor-sdk/models/get_asset_signed_url200_response.rb +164 -0
  46. data/lib/generated/ilovevideoeditor-sdk/models/get_asset_upload_url_request.rb +214 -0
  47. data/lib/generated/ilovevideoeditor-sdk/models/get_destination200_response.rb +164 -0
  48. data/lib/generated/ilovevideoeditor-sdk/models/get_project200_response.rb +173 -0
  49. data/lib/generated/ilovevideoeditor-sdk/models/get_project_stats200_response.rb +164 -0
  50. data/lib/generated/ilovevideoeditor-sdk/models/get_render_download_url200_response.rb +190 -0
  51. data/lib/generated/ilovevideoeditor-sdk/models/get_rendition200_response.rb +164 -0
  52. data/lib/generated/ilovevideoeditor-sdk/models/get_subscription200_response.rb +164 -0
  53. data/lib/generated/ilovevideoeditor-sdk/models/get_template200_response.rb +164 -0
  54. data/lib/generated/ilovevideoeditor-sdk/models/get_usage200_response.rb +166 -0
  55. data/lib/generated/ilovevideoeditor-sdk/models/get_workflow200_response.rb +175 -0
  56. data/lib/generated/ilovevideoeditor-sdk/models/get_workflow_run200_response.rb +175 -0
  57. data/lib/generated/ilovevideoeditor-sdk/models/health_check200_response.rb +147 -0
  58. data/lib/generated/ilovevideoeditor-sdk/models/health_check_detailed200_response.rb +199 -0
  59. data/lib/generated/ilovevideoeditor-sdk/models/health_check_detailed200_response_services.rb +156 -0
  60. data/lib/generated/ilovevideoeditor-sdk/models/list_api_keys200_response.rb +166 -0
  61. data/lib/generated/ilovevideoeditor-sdk/models/list_assets200_response.rb +185 -0
  62. data/lib/generated/ilovevideoeditor-sdk/models/list_integrations200_response.rb +166 -0
  63. data/lib/generated/ilovevideoeditor-sdk/models/list_invoices200_response.rb +158 -0
  64. data/lib/generated/ilovevideoeditor-sdk/models/list_projects200_response.rb +185 -0
  65. data/lib/generated/ilovevideoeditor-sdk/models/list_renditions200_response.rb +185 -0
  66. data/lib/generated/ilovevideoeditor-sdk/models/list_templates200_response.rb +166 -0
  67. data/lib/generated/ilovevideoeditor-sdk/models/list_webhook_subscriptions200_response.rb +166 -0
  68. data/lib/generated/ilovevideoeditor-sdk/models/list_workflow_runs200_response.rb +185 -0
  69. data/lib/generated/ilovevideoeditor-sdk/models/list_workflow_step_types200_response.rb +166 -0
  70. data/lib/generated/ilovevideoeditor-sdk/models/list_workflows200_response.rb +185 -0
  71. data/lib/generated/ilovevideoeditor-sdk/models/project.rb +329 -0
  72. data/lib/generated/ilovevideoeditor-sdk/models/project_create.rb +218 -0
  73. data/lib/generated/ilovevideoeditor-sdk/models/project_update.rb +239 -0
  74. data/lib/generated/ilovevideoeditor-sdk/models/queue_render200_response.rb +199 -0
  75. data/lib/generated/ilovevideoeditor-sdk/models/queue_render_request.rb +182 -0
  76. data/lib/generated/ilovevideoeditor-sdk/models/refresh_render_url200_response.rb +190 -0
  77. data/lib/generated/ilovevideoeditor-sdk/models/render_cost_estimate.rb +254 -0
  78. data/lib/generated/ilovevideoeditor-sdk/models/render_cost_estimate_resolution.rb +165 -0
  79. data/lib/generated/ilovevideoeditor-sdk/models/render_cost_estimate_tier.rb +165 -0
  80. data/lib/generated/ilovevideoeditor-sdk/models/render_job.rb +271 -0
  81. data/lib/generated/ilovevideoeditor-sdk/models/render_job_progress.rb +165 -0
  82. data/lib/generated/ilovevideoeditor-sdk/models/render_list_item.rb +356 -0
  83. data/lib/generated/ilovevideoeditor-sdk/models/render_template_request.rb +167 -0
  84. data/lib/generated/ilovevideoeditor-sdk/models/render_webhook_payload.rb +357 -0
  85. data/lib/generated/ilovevideoeditor-sdk/models/rendition.rb +335 -0
  86. data/lib/generated/ilovevideoeditor-sdk/models/rendition_cancel_result.rb +236 -0
  87. data/lib/generated/ilovevideoeditor-sdk/models/rendition_output.rb +233 -0
  88. data/lib/generated/ilovevideoeditor-sdk/models/rendition_stats.rb +192 -0
  89. data/lib/generated/ilovevideoeditor-sdk/models/run_workflow202_response.rb +164 -0
  90. data/lib/generated/ilovevideoeditor-sdk/models/run_workflow_request.rb +149 -0
  91. data/lib/generated/ilovevideoeditor-sdk/models/service_health.rb +208 -0
  92. data/lib/generated/ilovevideoeditor-sdk/models/template.rb +324 -0
  93. data/lib/generated/ilovevideoeditor-sdk/models/template_summary.rb +322 -0
  94. data/lib/generated/ilovevideoeditor-sdk/models/test_integration200_response.rb +174 -0
  95. data/lib/generated/ilovevideoeditor-sdk/models/tier_info.rb +214 -0
  96. data/lib/generated/ilovevideoeditor-sdk/models/tier_info_credits.rb +165 -0
  97. data/lib/generated/ilovevideoeditor-sdk/models/tool_job_request.rb +242 -0
  98. data/lib/generated/ilovevideoeditor-sdk/models/tool_job_request_dimensions.rb +208 -0
  99. data/lib/generated/ilovevideoeditor-sdk/models/tool_job_status.rb +310 -0
  100. data/lib/generated/ilovevideoeditor-sdk/models/track_render_bandwidth200_response.rb +164 -0
  101. data/lib/generated/ilovevideoeditor-sdk/models/update_workflow_request.rb +174 -0
  102. data/lib/generated/ilovevideoeditor-sdk/models/upload_asset200_response.rb +164 -0
  103. data/lib/generated/ilovevideoeditor-sdk/models/usage_log.rb +302 -0
  104. data/lib/generated/ilovevideoeditor-sdk/models/video_json.rb +243 -0
  105. data/lib/generated/ilovevideoeditor-sdk/models/video_json_destination.rb +227 -0
  106. data/lib/generated/ilovevideoeditor-sdk/models/webhook_subscription.rb +283 -0
  107. data/lib/generated/ilovevideoeditor-sdk/models/webhook_subscription_create.rb +204 -0
  108. data/lib/generated/ilovevideoeditor-sdk/models/workflow.rb +356 -0
  109. data/lib/generated/ilovevideoeditor-sdk/models/workflow_definition.rb +262 -0
  110. data/lib/generated/ilovevideoeditor-sdk/models/workflow_run.rb +372 -0
  111. data/lib/generated/ilovevideoeditor-sdk/models/workflow_run_step.rb +409 -0
  112. data/lib/generated/ilovevideoeditor-sdk/models/workflow_step.rb +262 -0
  113. data/lib/generated/ilovevideoeditor-sdk/models/workflow_variable.rb +242 -0
  114. data/lib/generated/ilovevideoeditor-sdk/models/workspace_integration.rb +398 -0
  115. data/lib/generated/ilovevideoeditor-sdk/models/workspace_integration_input.rb +260 -0
  116. data/lib/generated/ilovevideoeditor-sdk/version.rb +15 -0
  117. data/lib/generated/ilovevideoeditor-sdk.rb +150 -0
  118. data/lib/ilovevideoeditor/client.rb +106 -0
  119. data/lib/ilovevideoeditor-sdk.rb +2 -0
  120. metadata +181 -0
@@ -0,0 +1,236 @@
1
+ =begin
2
+ #iLoveVideoEditor API
3
+
4
+ #Cloud video rendering API for iLoveVideoEditor. Submit a `VideoJSON` payload, queue a render job, and download the resulting MP4. **Authentication** - **API Key** (`x-api-key` header) — accepted by render pipeline and tool endpoints. - **Bearer Token** (`Authorization: Bearer <jwt>`) — required for user-scoped project, asset, billing, and webhook endpoints. - Many endpoints accept either form of authentication. **SDKs** Official typed SDKs are available for JavaScript/TypeScript, PHP, Python, Ruby, and Go. See https://ilovevideoeditor.com/docs/sdks **Outbound Webhooks** Render lifecycle events (`render.completed`, `render.failed`) are delivered to your endpoints as signed HTTP POST requests. See the `Webhooks` tag and the root-level `x-webhook-docs` extension for the payload format (`RenderWebhookPayload`), signature headers, HMAC verification, and the retry policy.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.22.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module ILoveVideoEditor
17
+ class RenditionCancelResult < ApiModelBase
18
+ attr_accessor :id
19
+
20
+ attr_accessor :job_id
21
+
22
+ attr_accessor :status
23
+
24
+ attr_accessor :refunded
25
+
26
+ attr_accessor :error
27
+
28
+ # Attribute mapping from ruby-style variable name to JSON key.
29
+ def self.attribute_map
30
+ {
31
+ :'id' => :'id',
32
+ :'job_id' => :'jobId',
33
+ :'status' => :'status',
34
+ :'refunded' => :'refunded',
35
+ :'error' => :'error'
36
+ }
37
+ end
38
+
39
+ # Returns attribute mapping this model knows about
40
+ def self.acceptable_attribute_map
41
+ attribute_map
42
+ end
43
+
44
+ # Returns all the JSON keys this model knows about
45
+ def self.acceptable_attributes
46
+ acceptable_attribute_map.values
47
+ end
48
+
49
+ # Attribute type mapping.
50
+ def self.openapi_types
51
+ {
52
+ :'id' => :'String',
53
+ :'job_id' => :'String',
54
+ :'status' => :'String',
55
+ :'refunded' => :'Float',
56
+ :'error' => :'String'
57
+ }
58
+ end
59
+
60
+ # List of attributes with nullable: true
61
+ def self.openapi_nullable
62
+ Set.new([
63
+ :'job_id',
64
+ :'error'
65
+ ])
66
+ end
67
+
68
+ # Initializes the object
69
+ # @param [Hash] attributes Model attributes in the form of hash
70
+ def initialize(attributes = {})
71
+ if (!attributes.is_a?(Hash))
72
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ILoveVideoEditor::RenditionCancelResult` initialize method"
73
+ end
74
+
75
+ # check to see if the attribute exists and convert string to symbol for hash key
76
+ acceptable_attribute_map = self.class.acceptable_attribute_map
77
+ attributes = attributes.each_with_object({}) { |(k, v), h|
78
+ if (!acceptable_attribute_map.key?(k.to_sym))
79
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ILoveVideoEditor::RenditionCancelResult`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
80
+ end
81
+ h[k.to_sym] = v
82
+ }
83
+
84
+ if attributes.key?(:'id')
85
+ self.id = attributes[:'id']
86
+ else
87
+ self.id = nil
88
+ end
89
+
90
+ if attributes.key?(:'job_id')
91
+ self.job_id = attributes[:'job_id']
92
+ end
93
+
94
+ if attributes.key?(:'status')
95
+ self.status = attributes[:'status']
96
+ else
97
+ self.status = nil
98
+ end
99
+
100
+ if attributes.key?(:'refunded')
101
+ self.refunded = attributes[:'refunded']
102
+ else
103
+ self.refunded = nil
104
+ end
105
+
106
+ if attributes.key?(:'error')
107
+ self.error = attributes[:'error']
108
+ end
109
+ end
110
+
111
+ # Show invalid properties with the reasons. Usually used together with valid?
112
+ # @return Array for valid properties with the reasons
113
+ def list_invalid_properties
114
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
115
+ invalid_properties = Array.new
116
+ if @id.nil?
117
+ invalid_properties.push('invalid value for "id", id cannot be nil.')
118
+ end
119
+
120
+ if @status.nil?
121
+ invalid_properties.push('invalid value for "status", status cannot be nil.')
122
+ end
123
+
124
+ if @refunded.nil?
125
+ invalid_properties.push('invalid value for "refunded", refunded cannot be nil.')
126
+ end
127
+
128
+ invalid_properties
129
+ end
130
+
131
+ # Check to see if the all the properties in the model are valid
132
+ # @return true if the model is valid
133
+ def valid?
134
+ warn '[DEPRECATED] the `valid?` method is obsolete'
135
+ return false if @id.nil?
136
+ return false if @status.nil?
137
+ return false if @refunded.nil?
138
+ true
139
+ end
140
+
141
+ # Custom attribute writer method with validation
142
+ # @param [Object] id Value to be assigned
143
+ def id=(id)
144
+ if id.nil?
145
+ fail ArgumentError, 'id cannot be nil'
146
+ end
147
+
148
+ @id = id
149
+ end
150
+
151
+ # Custom attribute writer method with validation
152
+ # @param [Object] status Value to be assigned
153
+ def status=(status)
154
+ if status.nil?
155
+ fail ArgumentError, 'status cannot be nil'
156
+ end
157
+
158
+ @status = status
159
+ end
160
+
161
+ # Custom attribute writer method with validation
162
+ # @param [Object] refunded Value to be assigned
163
+ def refunded=(refunded)
164
+ if refunded.nil?
165
+ fail ArgumentError, 'refunded cannot be nil'
166
+ end
167
+
168
+ @refunded = refunded
169
+ end
170
+
171
+ # Checks equality by comparing each attribute.
172
+ # @param [Object] Object to be compared
173
+ def ==(o)
174
+ return true if self.equal?(o)
175
+ self.class == o.class &&
176
+ id == o.id &&
177
+ job_id == o.job_id &&
178
+ status == o.status &&
179
+ refunded == o.refunded &&
180
+ error == o.error
181
+ end
182
+
183
+ # @see the `==` method
184
+ # @param [Object] Object to be compared
185
+ def eql?(o)
186
+ self == o
187
+ end
188
+
189
+ # Calculates hash code according to all attributes.
190
+ # @return [Integer] Hash code
191
+ def hash
192
+ [id, job_id, status, refunded, error].hash
193
+ end
194
+
195
+ # Builds the object from hash
196
+ # @param [Hash] attributes Model attributes in the form of hash
197
+ # @return [Object] Returns the model itself
198
+ def self.build_from_hash(attributes)
199
+ return nil unless attributes.is_a?(Hash)
200
+ attributes = attributes.transform_keys(&:to_sym)
201
+ transformed_hash = {}
202
+ openapi_types.each_pair do |key, type|
203
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
204
+ transformed_hash["#{key}"] = nil
205
+ elsif type =~ /\AArray<(.*)>/i
206
+ # check to ensure the input is an array given that the attribute
207
+ # is documented as an array but the input is not
208
+ if attributes[attribute_map[key]].is_a?(Array)
209
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
210
+ end
211
+ elsif !attributes[attribute_map[key]].nil?
212
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
213
+ end
214
+ end
215
+ new(transformed_hash)
216
+ end
217
+
218
+ # Returns the object in the form of hash
219
+ # @return [Hash] Returns the object in the form of hash
220
+ def to_hash
221
+ hash = {}
222
+ self.class.attribute_map.each_pair do |attr, param|
223
+ value = self.send(attr)
224
+ if value.nil?
225
+ is_nullable = self.class.openapi_nullable.include?(attr)
226
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
227
+ end
228
+
229
+ hash[param] = _to_hash(value)
230
+ end
231
+ hash
232
+ end
233
+
234
+ end
235
+
236
+ end
@@ -0,0 +1,233 @@
1
+ =begin
2
+ #iLoveVideoEditor API
3
+
4
+ #Cloud video rendering API for iLoveVideoEditor. Submit a `VideoJSON` payload, queue a render job, and download the resulting MP4. **Authentication** - **API Key** (`x-api-key` header) — accepted by render pipeline and tool endpoints. - **Bearer Token** (`Authorization: Bearer <jwt>`) — required for user-scoped project, asset, billing, and webhook endpoints. - Many endpoints accept either form of authentication. **SDKs** Official typed SDKs are available for JavaScript/TypeScript, PHP, Python, Ruby, and Go. See https://ilovevideoeditor.com/docs/sdks **Outbound Webhooks** Render lifecycle events (`render.completed`, `render.failed`) are delivered to your endpoints as signed HTTP POST requests. See the `Webhooks` tag and the root-level `x-webhook-docs` extension for the payload format (`RenderWebhookPayload`), signature headers, HMAC verification, and the retry policy.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.22.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module ILoveVideoEditor
17
+ class RenditionOutput < ApiModelBase
18
+ attr_accessor :id
19
+
20
+ attr_accessor :integration_id
21
+
22
+ attr_accessor :provider
23
+
24
+ attr_accessor :output_key
25
+
26
+ attr_accessor :output_url
27
+
28
+ attr_accessor :output_size_bytes
29
+
30
+ attr_accessor :status
31
+
32
+ attr_accessor :error
33
+
34
+ attr_accessor :created_at
35
+
36
+ attr_accessor :updated_at
37
+
38
+ # Attribute mapping from ruby-style variable name to JSON key.
39
+ def self.attribute_map
40
+ {
41
+ :'id' => :'id',
42
+ :'integration_id' => :'integration_id',
43
+ :'provider' => :'provider',
44
+ :'output_key' => :'output_key',
45
+ :'output_url' => :'output_url',
46
+ :'output_size_bytes' => :'output_size_bytes',
47
+ :'status' => :'status',
48
+ :'error' => :'error',
49
+ :'created_at' => :'created_at',
50
+ :'updated_at' => :'updated_at'
51
+ }
52
+ end
53
+
54
+ # Returns attribute mapping this model knows about
55
+ def self.acceptable_attribute_map
56
+ attribute_map
57
+ end
58
+
59
+ # Returns all the JSON keys this model knows about
60
+ def self.acceptable_attributes
61
+ acceptable_attribute_map.values
62
+ end
63
+
64
+ # Attribute type mapping.
65
+ def self.openapi_types
66
+ {
67
+ :'id' => :'String',
68
+ :'integration_id' => :'String',
69
+ :'provider' => :'String',
70
+ :'output_key' => :'String',
71
+ :'output_url' => :'String',
72
+ :'output_size_bytes' => :'Integer',
73
+ :'status' => :'String',
74
+ :'error' => :'String',
75
+ :'created_at' => :'Time',
76
+ :'updated_at' => :'Time'
77
+ }
78
+ end
79
+
80
+ # List of attributes with nullable: true
81
+ def self.openapi_nullable
82
+ Set.new([
83
+ :'integration_id',
84
+ :'output_key',
85
+ :'output_url',
86
+ :'output_size_bytes',
87
+ :'error',
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 `ILoveVideoEditor::RenditionOutput` 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 `ILoveVideoEditor::RenditionOutput`. 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?(:'id')
108
+ self.id = attributes[:'id']
109
+ end
110
+
111
+ if attributes.key?(:'integration_id')
112
+ self.integration_id = attributes[:'integration_id']
113
+ end
114
+
115
+ if attributes.key?(:'provider')
116
+ self.provider = attributes[:'provider']
117
+ end
118
+
119
+ if attributes.key?(:'output_key')
120
+ self.output_key = attributes[:'output_key']
121
+ end
122
+
123
+ if attributes.key?(:'output_url')
124
+ self.output_url = attributes[:'output_url']
125
+ end
126
+
127
+ if attributes.key?(:'output_size_bytes')
128
+ self.output_size_bytes = attributes[:'output_size_bytes']
129
+ end
130
+
131
+ if attributes.key?(:'status')
132
+ self.status = attributes[:'status']
133
+ end
134
+
135
+ if attributes.key?(:'error')
136
+ self.error = attributes[:'error']
137
+ end
138
+
139
+ if attributes.key?(:'created_at')
140
+ self.created_at = attributes[:'created_at']
141
+ end
142
+
143
+ if attributes.key?(:'updated_at')
144
+ self.updated_at = attributes[:'updated_at']
145
+ end
146
+ end
147
+
148
+ # Show invalid properties with the reasons. Usually used together with valid?
149
+ # @return Array for valid properties with the reasons
150
+ def list_invalid_properties
151
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
152
+ invalid_properties = Array.new
153
+ invalid_properties
154
+ end
155
+
156
+ # Check to see if the all the properties in the model are valid
157
+ # @return true if the model is valid
158
+ def valid?
159
+ warn '[DEPRECATED] the `valid?` method is obsolete'
160
+ true
161
+ end
162
+
163
+ # Checks equality by comparing each attribute.
164
+ # @param [Object] Object to be compared
165
+ def ==(o)
166
+ return true if self.equal?(o)
167
+ self.class == o.class &&
168
+ id == o.id &&
169
+ integration_id == o.integration_id &&
170
+ provider == o.provider &&
171
+ output_key == o.output_key &&
172
+ output_url == o.output_url &&
173
+ output_size_bytes == o.output_size_bytes &&
174
+ status == o.status &&
175
+ error == o.error &&
176
+ created_at == o.created_at &&
177
+ updated_at == o.updated_at
178
+ end
179
+
180
+ # @see the `==` method
181
+ # @param [Object] Object to be compared
182
+ def eql?(o)
183
+ self == o
184
+ end
185
+
186
+ # Calculates hash code according to all attributes.
187
+ # @return [Integer] Hash code
188
+ def hash
189
+ [id, integration_id, provider, output_key, output_url, output_size_bytes, status, error, created_at, updated_at].hash
190
+ end
191
+
192
+ # Builds the object from hash
193
+ # @param [Hash] attributes Model attributes in the form of hash
194
+ # @return [Object] Returns the model itself
195
+ def self.build_from_hash(attributes)
196
+ return nil unless attributes.is_a?(Hash)
197
+ attributes = attributes.transform_keys(&:to_sym)
198
+ transformed_hash = {}
199
+ openapi_types.each_pair do |key, type|
200
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
201
+ transformed_hash["#{key}"] = nil
202
+ elsif type =~ /\AArray<(.*)>/i
203
+ # check to ensure the input is an array given that the attribute
204
+ # is documented as an array but the input is not
205
+ if attributes[attribute_map[key]].is_a?(Array)
206
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
207
+ end
208
+ elsif !attributes[attribute_map[key]].nil?
209
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
210
+ end
211
+ end
212
+ new(transformed_hash)
213
+ end
214
+
215
+ # Returns the object in the form of hash
216
+ # @return [Hash] Returns the object in the form of hash
217
+ def to_hash
218
+ hash = {}
219
+ self.class.attribute_map.each_pair do |attr, param|
220
+ value = self.send(attr)
221
+ if value.nil?
222
+ is_nullable = self.class.openapi_nullable.include?(attr)
223
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
224
+ end
225
+
226
+ hash[param] = _to_hash(value)
227
+ end
228
+ hash
229
+ end
230
+
231
+ end
232
+
233
+ end
@@ -0,0 +1,192 @@
1
+ =begin
2
+ #iLoveVideoEditor API
3
+
4
+ #Cloud video rendering API for iLoveVideoEditor. Submit a `VideoJSON` payload, queue a render job, and download the resulting MP4. **Authentication** - **API Key** (`x-api-key` header) — accepted by render pipeline and tool endpoints. - **Bearer Token** (`Authorization: Bearer <jwt>`) — required for user-scoped project, asset, billing, and webhook endpoints. - Many endpoints accept either form of authentication. **SDKs** Official typed SDKs are available for JavaScript/TypeScript, PHP, Python, Ruby, and Go. See https://ilovevideoeditor.com/docs/sdks **Outbound Webhooks** Render lifecycle events (`render.completed`, `render.failed`) are delivered to your endpoints as signed HTTP POST requests. See the `Webhooks` tag and the root-level `x-webhook-docs` extension for the payload format (`RenderWebhookPayload`), signature headers, HMAC verification, and the retry policy.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.22.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module ILoveVideoEditor
17
+ class RenditionStats < ApiModelBase
18
+ attr_accessor :total
19
+
20
+ attr_accessor :completed
21
+
22
+ attr_accessor :failed
23
+
24
+ attr_accessor :processing
25
+
26
+ attr_accessor :queued
27
+
28
+ attr_accessor :rendering
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ def self.attribute_map
32
+ {
33
+ :'total' => :'total',
34
+ :'completed' => :'completed',
35
+ :'failed' => :'failed',
36
+ :'processing' => :'processing',
37
+ :'queued' => :'queued',
38
+ :'rendering' => :'rendering'
39
+ }
40
+ end
41
+
42
+ # Returns attribute mapping this model knows about
43
+ def self.acceptable_attribute_map
44
+ attribute_map
45
+ end
46
+
47
+ # Returns all the JSON keys this model knows about
48
+ def self.acceptable_attributes
49
+ acceptable_attribute_map.values
50
+ end
51
+
52
+ # Attribute type mapping.
53
+ def self.openapi_types
54
+ {
55
+ :'total' => :'Integer',
56
+ :'completed' => :'Integer',
57
+ :'failed' => :'Integer',
58
+ :'processing' => :'Integer',
59
+ :'queued' => :'Integer',
60
+ :'rendering' => :'Integer'
61
+ }
62
+ end
63
+
64
+ # List of attributes with nullable: true
65
+ def self.openapi_nullable
66
+ Set.new([
67
+ ])
68
+ end
69
+
70
+ # Initializes the object
71
+ # @param [Hash] attributes Model attributes in the form of hash
72
+ def initialize(attributes = {})
73
+ if (!attributes.is_a?(Hash))
74
+ fail ArgumentError, "The input argument (attributes) must be a hash in `ILoveVideoEditor::RenditionStats` initialize method"
75
+ end
76
+
77
+ # check to see if the attribute exists and convert string to symbol for hash key
78
+ acceptable_attribute_map = self.class.acceptable_attribute_map
79
+ attributes = attributes.each_with_object({}) { |(k, v), h|
80
+ if (!acceptable_attribute_map.key?(k.to_sym))
81
+ fail ArgumentError, "`#{k}` is not a valid attribute in `ILoveVideoEditor::RenditionStats`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
82
+ end
83
+ h[k.to_sym] = v
84
+ }
85
+
86
+ if attributes.key?(:'total')
87
+ self.total = attributes[:'total']
88
+ end
89
+
90
+ if attributes.key?(:'completed')
91
+ self.completed = attributes[:'completed']
92
+ end
93
+
94
+ if attributes.key?(:'failed')
95
+ self.failed = attributes[:'failed']
96
+ end
97
+
98
+ if attributes.key?(:'processing')
99
+ self.processing = attributes[:'processing']
100
+ end
101
+
102
+ if attributes.key?(:'queued')
103
+ self.queued = attributes[:'queued']
104
+ end
105
+
106
+ if attributes.key?(:'rendering')
107
+ self.rendering = attributes[:'rendering']
108
+ end
109
+ end
110
+
111
+ # Show invalid properties with the reasons. Usually used together with valid?
112
+ # @return Array for valid properties with the reasons
113
+ def list_invalid_properties
114
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
115
+ invalid_properties = Array.new
116
+ invalid_properties
117
+ end
118
+
119
+ # Check to see if the all the properties in the model are valid
120
+ # @return true if the model is valid
121
+ def valid?
122
+ warn '[DEPRECATED] the `valid?` method is obsolete'
123
+ true
124
+ end
125
+
126
+ # Checks equality by comparing each attribute.
127
+ # @param [Object] Object to be compared
128
+ def ==(o)
129
+ return true if self.equal?(o)
130
+ self.class == o.class &&
131
+ total == o.total &&
132
+ completed == o.completed &&
133
+ failed == o.failed &&
134
+ processing == o.processing &&
135
+ queued == o.queued &&
136
+ rendering == o.rendering
137
+ end
138
+
139
+ # @see the `==` method
140
+ # @param [Object] Object to be compared
141
+ def eql?(o)
142
+ self == o
143
+ end
144
+
145
+ # Calculates hash code according to all attributes.
146
+ # @return [Integer] Hash code
147
+ def hash
148
+ [total, completed, failed, processing, queued, rendering].hash
149
+ end
150
+
151
+ # Builds the object from hash
152
+ # @param [Hash] attributes Model attributes in the form of hash
153
+ # @return [Object] Returns the model itself
154
+ def self.build_from_hash(attributes)
155
+ return nil unless attributes.is_a?(Hash)
156
+ attributes = attributes.transform_keys(&:to_sym)
157
+ transformed_hash = {}
158
+ openapi_types.each_pair do |key, type|
159
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
160
+ transformed_hash["#{key}"] = nil
161
+ elsif type =~ /\AArray<(.*)>/i
162
+ # check to ensure the input is an array given that the attribute
163
+ # is documented as an array but the input is not
164
+ if attributes[attribute_map[key]].is_a?(Array)
165
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
166
+ end
167
+ elsif !attributes[attribute_map[key]].nil?
168
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
169
+ end
170
+ end
171
+ new(transformed_hash)
172
+ end
173
+
174
+ # Returns the object in the form of hash
175
+ # @return [Hash] Returns the object in the form of hash
176
+ def to_hash
177
+ hash = {}
178
+ self.class.attribute_map.each_pair do |attr, param|
179
+ value = self.send(attr)
180
+ if value.nil?
181
+ is_nullable = self.class.openapi_nullable.include?(attr)
182
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
183
+ end
184
+
185
+ hash[param] = _to_hash(value)
186
+ end
187
+ hash
188
+ end
189
+
190
+ end
191
+
192
+ end