ittybit 0.7.5.2 → 0.7.6
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.
- checksums.yaml +4 -4
- data/lib/ittybit/automations/client.rb +14 -6
- data/lib/ittybit/files/client.rb +67 -77
- data/lib/ittybit/media/client.rb +78 -34
- data/lib/ittybit/signatures/client.rb +20 -24
- data/lib/ittybit/signatures/types/signatures_create_request_method.rb +0 -3
- data/lib/ittybit/types/automation.rb +17 -27
- data/lib/ittybit/types/automation_list_response.rb +15 -2
- data/lib/ittybit/types/automation_response.rb +15 -2
- data/lib/ittybit/types/automation_status.rb +0 -1
- data/lib/ittybit/types/automation_trigger.rb +11 -16
- data/lib/ittybit/types/{confirmation_response_data.rb → confirmation.rb} +11 -9
- data/lib/ittybit/types/confirmation_response.rb +20 -7
- data/lib/ittybit/types/file.rb +64 -68
- data/lib/ittybit/types/file_kind.rb +0 -1
- data/lib/ittybit/types/file_list_response.rb +15 -2
- data/lib/ittybit/types/file_object.rb +0 -1
- data/lib/ittybit/types/file_response.rb +15 -2
- data/lib/ittybit/types/file_status.rb +0 -1
- data/lib/ittybit/types/links.rb +4 -4
- data/lib/ittybit/types/links_list.rb +17 -32
- data/lib/ittybit/types/media.rb +34 -56
- data/lib/ittybit/types/media_kind.rb +0 -1
- data/lib/ittybit/types/media_list_response.rb +15 -2
- data/lib/ittybit/types/media_response.rb +15 -2
- data/lib/ittybit/types/media_source.rb +52 -53
- data/lib/ittybit/types/media_source_kind.rb +0 -1
- data/lib/ittybit/types/media_source_object.rb +0 -1
- data/lib/ittybit/types/media_source_orientation.rb +9 -0
- data/lib/ittybit/types/media_source_status.rb +0 -1
- data/lib/ittybit/types/meta_list.rb +40 -15
- data/lib/ittybit/types/meta_list_type.rb +8 -0
- data/lib/ittybit/types/signature.rb +14 -14
- data/lib/ittybit/types/signature_response.rb +15 -2
- data/lib/ittybit/types/task.rb +30 -50
- data/lib/ittybit/types/task_list_response.rb +15 -2
- data/lib/ittybit/types/task_response.rb +15 -2
- data/lib/ittybit/types/task_status.rb +0 -1
- data/lib/ittybit/types/task_summary.rb +20 -20
- data/lib/ittybit/types/task_summary_kind.rb +9 -13
- data/lib/ittybit/types/task_summary_status.rb +0 -1
- data/lib/ittybit/types/workflow_task_step.rb +61 -29
- data/lib/ittybit/types/workflow_task_step_kind.rb +9 -13
- data/lib/requests.rb +2 -2
- data/lib/types_export.rb +3 -6
- metadata +5 -8
- data/lib/ittybit/files/types/files_delete_response.rb +0 -89
- data/lib/ittybit/files/types/files_delete_response_data.rb +0 -60
- data/lib/ittybit/types/automation_trigger_conditions_item.rb +0 -65
- data/lib/ittybit/types/error_response.rb +0 -74
- data/lib/ittybit/types/media_urls.rb +0 -70
data/lib/ittybit/types/task.rb
CHANGED
@@ -9,39 +9,34 @@ require "json"
|
|
9
9
|
|
10
10
|
module Ittybit
|
11
11
|
class Task
|
12
|
-
# @return [String]
|
12
|
+
# @return [String]
|
13
13
|
attr_reader :id
|
14
|
-
# @return [String]
|
14
|
+
# @return [String]
|
15
15
|
attr_reader :object
|
16
|
-
# @return [Ittybit::TASK_KIND]
|
16
|
+
# @return [Ittybit::TASK_KIND]
|
17
17
|
attr_reader :kind
|
18
|
-
# @return [Hash{String => Object}]
|
19
|
-
# on the task kind and preceding steps.
|
18
|
+
# @return [Hash{String => Object}]
|
20
19
|
attr_reader :input
|
21
|
-
# @return [Hash{String => Object}]
|
20
|
+
# @return [Hash{String => Object}]
|
22
21
|
attr_reader :options
|
23
|
-
# @return [Hash{String => Object}]
|
24
|
-
# intelligence data). Structure varies.
|
22
|
+
# @return [Hash{String => Object}]
|
25
23
|
attr_reader :output
|
26
|
-
# @return [Ittybit::TaskStatus]
|
24
|
+
# @return [Ittybit::TaskStatus]
|
27
25
|
attr_reader :status
|
28
|
-
# @return [Integer]
|
26
|
+
# @return [Integer]
|
29
27
|
attr_reader :progress
|
30
|
-
# @return [String]
|
28
|
+
# @return [String]
|
31
29
|
attr_reader :error
|
32
|
-
# @return [String]
|
30
|
+
# @return [String]
|
33
31
|
attr_reader :created_by
|
34
|
-
# @return [DateTime]
|
32
|
+
# @return [DateTime]
|
35
33
|
attr_reader :created
|
36
|
-
# @return [DateTime]
|
34
|
+
# @return [DateTime]
|
37
35
|
attr_reader :updated
|
38
|
-
# @return [String]
|
36
|
+
# @return [String]
|
39
37
|
attr_reader :parent_id
|
40
|
-
# @return [Array<
|
38
|
+
# @return [Array<Object>]
|
41
39
|
attr_reader :workflow
|
42
|
-
# @return [Array<Ittybit::Task>] Array representing subsequent tasks (e.g., in an automation). Structure may
|
43
|
-
# vary.
|
44
|
-
attr_reader :next_
|
45
40
|
# @return [Ittybit::TaskResults]
|
46
41
|
attr_reader :results
|
47
42
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
@@ -52,29 +47,25 @@ module Ittybit
|
|
52
47
|
|
53
48
|
OMIT = Object.new
|
54
49
|
|
55
|
-
# @param id [String]
|
56
|
-
# @param object [String]
|
57
|
-
# @param kind [Ittybit::TASK_KIND]
|
58
|
-
# @param input [Hash{String => Object}]
|
59
|
-
#
|
60
|
-
# @param
|
61
|
-
# @param
|
62
|
-
#
|
63
|
-
# @param
|
64
|
-
# @param
|
65
|
-
# @param
|
66
|
-
# @param
|
67
|
-
# @param
|
68
|
-
# @param
|
69
|
-
# @param parent_id [String] ID of the parent task if this is part of a workflow.
|
70
|
-
# @param workflow [Array<Ittybit::Task>] Array of nested task objects representing the steps within this workflow task.
|
71
|
-
# @param next_ [Array<Ittybit::Task>] Array representing subsequent tasks (e.g., in an automation). Structure may
|
72
|
-
# vary.
|
50
|
+
# @param id [String]
|
51
|
+
# @param object [String]
|
52
|
+
# @param kind [Ittybit::TASK_KIND]
|
53
|
+
# @param input [Hash{String => Object}]
|
54
|
+
# @param options [Hash{String => Object}]
|
55
|
+
# @param output [Hash{String => Object}]
|
56
|
+
# @param status [Ittybit::TaskStatus]
|
57
|
+
# @param progress [Integer]
|
58
|
+
# @param error [String]
|
59
|
+
# @param created_by [String]
|
60
|
+
# @param created [DateTime]
|
61
|
+
# @param updated [DateTime]
|
62
|
+
# @param parent_id [String]
|
63
|
+
# @param workflow [Array<Object>]
|
73
64
|
# @param results [Ittybit::TaskResults]
|
74
65
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
75
66
|
# @return [Ittybit::Task]
|
76
67
|
def initialize(id:, object:, kind:, status:, created:, updated:, input: OMIT, options: OMIT, output: OMIT, progress: OMIT, error: OMIT,
|
77
|
-
created_by: OMIT, parent_id: OMIT, workflow: OMIT,
|
68
|
+
created_by: OMIT, parent_id: OMIT, workflow: OMIT, results: OMIT, additional_properties: nil)
|
78
69
|
@id = id
|
79
70
|
@object = object
|
80
71
|
@kind = kind
|
@@ -89,7 +80,6 @@ module Ittybit
|
|
89
80
|
@updated = updated
|
90
81
|
@parent_id = parent_id if parent_id != OMIT
|
91
82
|
@workflow = workflow if workflow != OMIT
|
92
|
-
@next_ = next_ if next_ != OMIT
|
93
83
|
@results = results if results != OMIT
|
94
84
|
@additional_properties = additional_properties
|
95
85
|
@_field_set = {
|
@@ -107,7 +97,6 @@ module Ittybit
|
|
107
97
|
"updated": updated,
|
108
98
|
"parent_id": parent_id,
|
109
99
|
"workflow": workflow,
|
110
|
-
"next": next_,
|
111
100
|
"results": results
|
112
101
|
}.reject do |_k, v|
|
113
102
|
v == OMIT
|
@@ -134,14 +123,7 @@ module Ittybit
|
|
134
123
|
created = (DateTime.parse(parsed_json["created"]) unless parsed_json["created"].nil?)
|
135
124
|
updated = (DateTime.parse(parsed_json["updated"]) unless parsed_json["updated"].nil?)
|
136
125
|
parent_id = parsed_json["parent_id"]
|
137
|
-
workflow = parsed_json["workflow"]
|
138
|
-
item = item.to_json
|
139
|
-
Ittybit::Task.from_json(json_object: item)
|
140
|
-
end
|
141
|
-
next_ = parsed_json["next"]&.map do |item|
|
142
|
-
item = item.to_json
|
143
|
-
Ittybit::Task.from_json(json_object: item)
|
144
|
-
end
|
126
|
+
workflow = parsed_json["workflow"]
|
145
127
|
if parsed_json["results"].nil?
|
146
128
|
results = nil
|
147
129
|
else
|
@@ -163,7 +145,6 @@ module Ittybit
|
|
163
145
|
updated: updated,
|
164
146
|
parent_id: parent_id,
|
165
147
|
workflow: workflow,
|
166
|
-
next_: next_,
|
167
148
|
results: results,
|
168
149
|
additional_properties: struct
|
169
150
|
)
|
@@ -197,7 +178,6 @@ module Ittybit
|
|
197
178
|
obj.updated.is_a?(DateTime) != false || raise("Passed value for field obj.updated is not the expected type, validation failed.")
|
198
179
|
obj.parent_id&.is_a?(String) != false || raise("Passed value for field obj.parent_id is not the expected type, validation failed.")
|
199
180
|
obj.workflow&.is_a?(Array) != false || raise("Passed value for field obj.workflow is not the expected type, validation failed.")
|
200
|
-
obj.next_&.is_a?(Array) != false || raise("Passed value for field obj.next_ is not the expected type, validation failed.")
|
201
181
|
obj.results.nil? || Ittybit::TaskResults.validate_raw(obj: obj.results)
|
202
182
|
end
|
203
183
|
end
|
@@ -2,6 +2,7 @@
|
|
2
2
|
|
3
3
|
require_relative "meta_list"
|
4
4
|
require_relative "task"
|
5
|
+
require_relative "error"
|
5
6
|
require_relative "links_list"
|
6
7
|
require "ostruct"
|
7
8
|
require "json"
|
@@ -12,6 +13,8 @@ module Ittybit
|
|
12
13
|
attr_reader :meta
|
13
14
|
# @return [Array<Ittybit::Task>]
|
14
15
|
attr_reader :data
|
16
|
+
# @return [Ittybit::Error]
|
17
|
+
attr_reader :error
|
15
18
|
# @return [Ittybit::LinksList]
|
16
19
|
attr_reader :links
|
17
20
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
@@ -24,15 +27,17 @@ module Ittybit
|
|
24
27
|
|
25
28
|
# @param meta [Ittybit::MetaList]
|
26
29
|
# @param data [Array<Ittybit::Task>]
|
30
|
+
# @param error [Ittybit::Error]
|
27
31
|
# @param links [Ittybit::LinksList]
|
28
32
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
29
33
|
# @return [Ittybit::TaskListResponse]
|
30
|
-
def initialize(meta: OMIT, data: OMIT, links: OMIT, additional_properties: nil)
|
34
|
+
def initialize(meta: OMIT, data: OMIT, error: OMIT, links: OMIT, additional_properties: nil)
|
31
35
|
@meta = meta if meta != OMIT
|
32
36
|
@data = data if data != OMIT
|
37
|
+
@error = error if error != OMIT
|
33
38
|
@links = links if links != OMIT
|
34
39
|
@additional_properties = additional_properties
|
35
|
-
@_field_set = { "meta": meta, "data": data, "links": links }.reject do |_k, v|
|
40
|
+
@_field_set = { "meta": meta, "data": data, "error": error, "links": links }.reject do |_k, v|
|
36
41
|
v == OMIT
|
37
42
|
end
|
38
43
|
end
|
@@ -54,6 +59,12 @@ module Ittybit
|
|
54
59
|
item = item.to_json
|
55
60
|
Ittybit::Task.from_json(json_object: item)
|
56
61
|
end
|
62
|
+
if parsed_json["error"].nil?
|
63
|
+
error = nil
|
64
|
+
else
|
65
|
+
error = parsed_json["error"].to_json
|
66
|
+
error = Ittybit::Error.from_json(json_object: error)
|
67
|
+
end
|
57
68
|
if parsed_json["links"].nil?
|
58
69
|
links = nil
|
59
70
|
else
|
@@ -63,6 +74,7 @@ module Ittybit
|
|
63
74
|
new(
|
64
75
|
meta: meta,
|
65
76
|
data: data,
|
77
|
+
error: error,
|
66
78
|
links: links,
|
67
79
|
additional_properties: struct
|
68
80
|
)
|
@@ -84,6 +96,7 @@ module Ittybit
|
|
84
96
|
def self.validate_raw(obj:)
|
85
97
|
obj.meta.nil? || Ittybit::MetaList.validate_raw(obj: obj.meta)
|
86
98
|
obj.data&.is_a?(Array) != false || raise("Passed value for field obj.data is not the expected type, validation failed.")
|
99
|
+
obj.error.nil? || Ittybit::Error.validate_raw(obj: obj.error)
|
87
100
|
obj.links.nil? || Ittybit::LinksList.validate_raw(obj: obj.links)
|
88
101
|
end
|
89
102
|
end
|
@@ -2,6 +2,7 @@
|
|
2
2
|
|
3
3
|
require_relative "meta"
|
4
4
|
require_relative "task"
|
5
|
+
require_relative "error"
|
5
6
|
require_relative "links"
|
6
7
|
require "ostruct"
|
7
8
|
require "json"
|
@@ -12,6 +13,8 @@ module Ittybit
|
|
12
13
|
attr_reader :meta
|
13
14
|
# @return [Ittybit::Task]
|
14
15
|
attr_reader :data
|
16
|
+
# @return [Ittybit::Error]
|
17
|
+
attr_reader :error
|
15
18
|
# @return [Ittybit::Links]
|
16
19
|
attr_reader :links
|
17
20
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
@@ -24,15 +27,17 @@ module Ittybit
|
|
24
27
|
|
25
28
|
# @param meta [Ittybit::META]
|
26
29
|
# @param data [Ittybit::Task]
|
30
|
+
# @param error [Ittybit::Error]
|
27
31
|
# @param links [Ittybit::Links]
|
28
32
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
29
33
|
# @return [Ittybit::TaskResponse]
|
30
|
-
def initialize(meta: OMIT, data: OMIT, links: OMIT, additional_properties: nil)
|
34
|
+
def initialize(meta: OMIT, data: OMIT, error: OMIT, links: OMIT, additional_properties: nil)
|
31
35
|
@meta = meta if meta != OMIT
|
32
36
|
@data = data if data != OMIT
|
37
|
+
@error = error if error != OMIT
|
33
38
|
@links = links if links != OMIT
|
34
39
|
@additional_properties = additional_properties
|
35
|
-
@_field_set = { "meta": meta, "data": data, "links": links }.reject do |_k, v|
|
40
|
+
@_field_set = { "meta": meta, "data": data, "error": error, "links": links }.reject do |_k, v|
|
36
41
|
v == OMIT
|
37
42
|
end
|
38
43
|
end
|
@@ -51,6 +56,12 @@ module Ittybit
|
|
51
56
|
data = parsed_json["data"].to_json
|
52
57
|
data = Ittybit::Task.from_json(json_object: data)
|
53
58
|
end
|
59
|
+
if parsed_json["error"].nil?
|
60
|
+
error = nil
|
61
|
+
else
|
62
|
+
error = parsed_json["error"].to_json
|
63
|
+
error = Ittybit::Error.from_json(json_object: error)
|
64
|
+
end
|
54
65
|
if parsed_json["links"].nil?
|
55
66
|
links = nil
|
56
67
|
else
|
@@ -60,6 +71,7 @@ module Ittybit
|
|
60
71
|
new(
|
61
72
|
meta: meta,
|
62
73
|
data: data,
|
74
|
+
error: error,
|
63
75
|
links: links,
|
64
76
|
additional_properties: struct
|
65
77
|
)
|
@@ -81,6 +93,7 @@ module Ittybit
|
|
81
93
|
def self.validate_raw(obj:)
|
82
94
|
obj.meta&.is_a?(Object) != false || raise("Passed value for field obj.meta is not the expected type, validation failed.")
|
83
95
|
obj.data.nil? || Ittybit::Task.validate_raw(obj: obj.data)
|
96
|
+
obj.error.nil? || Ittybit::Error.validate_raw(obj: obj.error)
|
84
97
|
obj.links.nil? || Ittybit::Links.validate_raw(obj: obj.links)
|
85
98
|
end
|
86
99
|
end
|
@@ -8,25 +8,25 @@ require "json"
|
|
8
8
|
|
9
9
|
module Ittybit
|
10
10
|
class TaskSummary
|
11
|
-
# @return [String]
|
11
|
+
# @return [String]
|
12
12
|
attr_reader :id
|
13
|
-
# @return [String]
|
13
|
+
# @return [String]
|
14
14
|
attr_reader :object
|
15
|
-
# @return [Ittybit::TaskSummaryKind]
|
15
|
+
# @return [Ittybit::TaskSummaryKind]
|
16
16
|
attr_reader :kind
|
17
|
-
# @return [Ittybit::TaskSummaryStatus]
|
17
|
+
# @return [Ittybit::TaskSummaryStatus]
|
18
18
|
attr_reader :status
|
19
|
-
# @return [Integer]
|
19
|
+
# @return [Integer]
|
20
20
|
attr_reader :progress
|
21
|
-
# @return [String]
|
21
|
+
# @return [String]
|
22
22
|
attr_reader :error
|
23
|
-
# @return [String]
|
23
|
+
# @return [String]
|
24
24
|
attr_reader :created_by
|
25
|
-
# @return [DateTime]
|
25
|
+
# @return [DateTime]
|
26
26
|
attr_reader :created
|
27
|
-
# @return [DateTime]
|
27
|
+
# @return [DateTime]
|
28
28
|
attr_reader :updated
|
29
|
-
# @return [String]
|
29
|
+
# @return [String]
|
30
30
|
attr_reader :parent_id
|
31
31
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
32
32
|
attr_reader :additional_properties
|
@@ -36,16 +36,16 @@ module Ittybit
|
|
36
36
|
|
37
37
|
OMIT = Object.new
|
38
38
|
|
39
|
-
# @param id [String]
|
40
|
-
# @param object [String]
|
41
|
-
# @param kind [Ittybit::TaskSummaryKind]
|
42
|
-
# @param status [Ittybit::TaskSummaryStatus]
|
43
|
-
# @param progress [Integer]
|
44
|
-
# @param error [String]
|
45
|
-
# @param created_by [String]
|
46
|
-
# @param created [DateTime]
|
47
|
-
# @param updated [DateTime]
|
48
|
-
# @param parent_id [String]
|
39
|
+
# @param id [String]
|
40
|
+
# @param object [String]
|
41
|
+
# @param kind [Ittybit::TaskSummaryKind]
|
42
|
+
# @param status [Ittybit::TaskSummaryStatus]
|
43
|
+
# @param progress [Integer]
|
44
|
+
# @param error [String]
|
45
|
+
# @param created_by [String]
|
46
|
+
# @param created [DateTime]
|
47
|
+
# @param updated [DateTime]
|
48
|
+
# @param parent_id [String]
|
49
49
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
50
50
|
# @return [Ittybit::TaskSummary]
|
51
51
|
def initialize(id:, object:, kind:, status:, created:, updated:, progress: OMIT, error: OMIT, created_by: OMIT,
|
@@ -1,25 +1,21 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
module Ittybit
|
4
|
-
# The type of operation the task performs.
|
5
4
|
class TaskSummaryKind
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
OUTLINE = "outline"
|
5
|
+
VIDEO = "video"
|
6
|
+
IMAGE = "image"
|
7
|
+
AUDIO = "audio"
|
10
8
|
CHAPTERS = "chapters"
|
11
9
|
SUBTITLES = "subtitles"
|
12
10
|
THUMBNAILS = "thumbnails"
|
11
|
+
SPEECH = "speech"
|
12
|
+
DESCRIPTION = "description"
|
13
13
|
NSFW = "nsfw"
|
14
|
-
|
15
|
-
|
16
|
-
VIDEO = "video"
|
17
|
-
IMAGE = "image"
|
18
|
-
AUDIO = "audio"
|
14
|
+
PROMPT = "prompt"
|
15
|
+
OUTLINE = "outline"
|
19
16
|
HTTP = "http"
|
17
|
+
INGEST = "ingest"
|
18
|
+
WORKFLOW = "workflow"
|
20
19
|
CONDITIONS = "conditions"
|
21
|
-
STORE = "store"
|
22
|
-
PROMPT = "prompt"
|
23
|
-
TAGS = "tags"
|
24
20
|
end
|
25
21
|
end
|
@@ -6,20 +6,28 @@ require "json"
|
|
6
6
|
|
7
7
|
module Ittybit
|
8
8
|
class WorkflowTaskStep
|
9
|
-
# @return [Ittybit::WorkflowTaskStepKind]
|
9
|
+
# @return [Ittybit::WorkflowTaskStepKind]
|
10
10
|
attr_reader :kind
|
11
|
-
# @return [String]
|
12
|
-
attr_reader :
|
13
|
-
# @return [String]
|
11
|
+
# @return [String]
|
12
|
+
attr_reader :ref
|
13
|
+
# @return [String]
|
14
14
|
attr_reader :format
|
15
|
-
# @return [
|
15
|
+
# @return [Float]
|
16
|
+
attr_reader :start
|
17
|
+
# @return [Float]
|
18
|
+
attr_reader :end_
|
19
|
+
# @return [Integer]
|
16
20
|
attr_reader :width
|
17
|
-
# @return [Integer]
|
21
|
+
# @return [Integer]
|
18
22
|
attr_reader :height
|
19
|
-
# @return [String]
|
20
|
-
attr_reader :
|
21
|
-
# @return [
|
23
|
+
# @return [String]
|
24
|
+
attr_reader :fit
|
25
|
+
# @return [String]
|
26
|
+
attr_reader :background
|
27
|
+
# @return [Integer]
|
22
28
|
attr_reader :quality
|
29
|
+
# @return [Array<Object>]
|
30
|
+
attr_reader :next_
|
23
31
|
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
24
32
|
attr_reader :additional_properties
|
25
33
|
# @return [Object]
|
@@ -28,33 +36,45 @@ module Ittybit
|
|
28
36
|
|
29
37
|
OMIT = Object.new
|
30
38
|
|
31
|
-
# @param kind [Ittybit::WorkflowTaskStepKind]
|
32
|
-
# @param
|
33
|
-
# @param format [String]
|
34
|
-
# @param
|
35
|
-
# @param
|
36
|
-
# @param
|
37
|
-
# @param
|
39
|
+
# @param kind [Ittybit::WorkflowTaskStepKind]
|
40
|
+
# @param ref [String]
|
41
|
+
# @param format [String]
|
42
|
+
# @param start [Float]
|
43
|
+
# @param end_ [Float]
|
44
|
+
# @param width [Integer]
|
45
|
+
# @param height [Integer]
|
46
|
+
# @param fit [String]
|
47
|
+
# @param background [String]
|
48
|
+
# @param quality [Integer]
|
49
|
+
# @param next_ [Array<Object>]
|
38
50
|
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
39
51
|
# @return [Ittybit::WorkflowTaskStep]
|
40
|
-
def initialize(kind:,
|
41
|
-
additional_properties: nil)
|
52
|
+
def initialize(kind:, ref: OMIT, format: OMIT, start: OMIT, end_: OMIT, width: OMIT, height: OMIT, fit: OMIT,
|
53
|
+
background: OMIT, quality: OMIT, next_: OMIT, additional_properties: nil)
|
42
54
|
@kind = kind
|
43
|
-
@
|
55
|
+
@ref = ref if ref != OMIT
|
44
56
|
@format = format if format != OMIT
|
57
|
+
@start = start if start != OMIT
|
58
|
+
@end_ = end_ if end_ != OMIT
|
45
59
|
@width = width if width != OMIT
|
46
60
|
@height = height if height != OMIT
|
47
|
-
@
|
61
|
+
@fit = fit if fit != OMIT
|
62
|
+
@background = background if background != OMIT
|
48
63
|
@quality = quality if quality != OMIT
|
64
|
+
@next_ = next_ if next_ != OMIT
|
49
65
|
@additional_properties = additional_properties
|
50
66
|
@_field_set = {
|
51
67
|
"kind": kind,
|
52
|
-
"
|
68
|
+
"ref": ref,
|
53
69
|
"format": format,
|
70
|
+
"start": start,
|
71
|
+
"end": end_,
|
54
72
|
"width": width,
|
55
73
|
"height": height,
|
56
|
-
"
|
57
|
-
"
|
74
|
+
"fit": fit,
|
75
|
+
"background": background,
|
76
|
+
"quality": quality,
|
77
|
+
"next": next_
|
58
78
|
}.reject do |_k, v|
|
59
79
|
v == OMIT
|
60
80
|
end
|
@@ -68,20 +88,28 @@ module Ittybit
|
|
68
88
|
struct = JSON.parse(json_object, object_class: OpenStruct)
|
69
89
|
parsed_json = JSON.parse(json_object)
|
70
90
|
kind = parsed_json["kind"]
|
71
|
-
|
91
|
+
ref = parsed_json["ref"]
|
72
92
|
format = parsed_json["format"]
|
93
|
+
start = parsed_json["start"]
|
94
|
+
end_ = parsed_json["end"]
|
73
95
|
width = parsed_json["width"]
|
74
96
|
height = parsed_json["height"]
|
75
|
-
|
97
|
+
fit = parsed_json["fit"]
|
98
|
+
background = parsed_json["background"]
|
76
99
|
quality = parsed_json["quality"]
|
100
|
+
next_ = parsed_json["next"]
|
77
101
|
new(
|
78
102
|
kind: kind,
|
79
|
-
|
103
|
+
ref: ref,
|
80
104
|
format: format,
|
105
|
+
start: start,
|
106
|
+
end_: end_,
|
81
107
|
width: width,
|
82
108
|
height: height,
|
83
|
-
|
109
|
+
fit: fit,
|
110
|
+
background: background,
|
84
111
|
quality: quality,
|
112
|
+
next_: next_,
|
85
113
|
additional_properties: struct
|
86
114
|
)
|
87
115
|
end
|
@@ -101,12 +129,16 @@ module Ittybit
|
|
101
129
|
# @return [Void]
|
102
130
|
def self.validate_raw(obj:)
|
103
131
|
obj.kind.is_a?(Ittybit::WorkflowTaskStepKind) != false || raise("Passed value for field obj.kind is not the expected type, validation failed.")
|
104
|
-
obj.
|
132
|
+
obj.ref&.is_a?(String) != false || raise("Passed value for field obj.ref is not the expected type, validation failed.")
|
105
133
|
obj.format&.is_a?(String) != false || raise("Passed value for field obj.format is not the expected type, validation failed.")
|
134
|
+
obj.start&.is_a?(Float) != false || raise("Passed value for field obj.start is not the expected type, validation failed.")
|
135
|
+
obj.end_&.is_a?(Float) != false || raise("Passed value for field obj.end_ is not the expected type, validation failed.")
|
106
136
|
obj.width&.is_a?(Integer) != false || raise("Passed value for field obj.width is not the expected type, validation failed.")
|
107
137
|
obj.height&.is_a?(Integer) != false || raise("Passed value for field obj.height is not the expected type, validation failed.")
|
108
|
-
obj.
|
138
|
+
obj.fit&.is_a?(String) != false || raise("Passed value for field obj.fit is not the expected type, validation failed.")
|
139
|
+
obj.background&.is_a?(String) != false || raise("Passed value for field obj.background is not the expected type, validation failed.")
|
109
140
|
obj.quality&.is_a?(Integer) != false || raise("Passed value for field obj.quality is not the expected type, validation failed.")
|
141
|
+
obj.next_&.is_a?(Array) != false || raise("Passed value for field obj.next_ is not the expected type, validation failed.")
|
110
142
|
end
|
111
143
|
end
|
112
144
|
end
|
@@ -1,25 +1,21 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
module Ittybit
|
4
|
-
# The type of operation the task performs.
|
5
4
|
class WorkflowTaskStepKind
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
OUTLINE = "outline"
|
5
|
+
VIDEO = "video"
|
6
|
+
IMAGE = "image"
|
7
|
+
AUDIO = "audio"
|
10
8
|
CHAPTERS = "chapters"
|
11
9
|
SUBTITLES = "subtitles"
|
12
10
|
THUMBNAILS = "thumbnails"
|
11
|
+
SPEECH = "speech"
|
12
|
+
DESCRIPTION = "description"
|
13
13
|
NSFW = "nsfw"
|
14
|
-
|
15
|
-
|
16
|
-
VIDEO = "video"
|
17
|
-
IMAGE = "image"
|
18
|
-
AUDIO = "audio"
|
14
|
+
PROMPT = "prompt"
|
15
|
+
OUTLINE = "outline"
|
19
16
|
HTTP = "http"
|
17
|
+
INGEST = "ingest"
|
18
|
+
WORKFLOW = "workflow"
|
20
19
|
CONDITIONS = "conditions"
|
21
|
-
STORE = "store"
|
22
|
-
PROMPT = "prompt"
|
23
|
-
TAGS = "tags"
|
24
20
|
end
|
25
21
|
end
|
data/lib/requests.rb
CHANGED
@@ -46,7 +46,7 @@ module Ittybit
|
|
46
46
|
|
47
47
|
# @return [Hash{String => String}]
|
48
48
|
def get_headers
|
49
|
-
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "ittybit", "X-Fern-SDK-Version": "0.7.
|
49
|
+
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "ittybit", "X-Fern-SDK-Version": "0.7.6" }
|
50
50
|
headers["Authorization"] = ((@token.is_a? Method) ? @token.call : @token) unless @token.nil?
|
51
51
|
headers
|
52
52
|
end
|
@@ -93,7 +93,7 @@ module Ittybit
|
|
93
93
|
|
94
94
|
# @return [Hash{String => String}]
|
95
95
|
def get_headers
|
96
|
-
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "ittybit", "X-Fern-SDK-Version": "0.7.
|
96
|
+
headers = { "X-Fern-Language": "Ruby", "X-Fern-SDK-Name": "ittybit", "X-Fern-SDK-Version": "0.7.6" }
|
97
97
|
headers["Authorization"] = ((@token.is_a? Method) ? @token.call : @token) unless @token.nil?
|
98
98
|
headers
|
99
99
|
end
|
data/lib/types_export.rb
CHANGED
@@ -2,18 +2,16 @@
|
|
2
2
|
|
3
3
|
require_relative "ittybit/automations/types/automations_update_request_trigger_conditions_item"
|
4
4
|
require_relative "ittybit/automations/types/automations_update_request_trigger"
|
5
|
-
require_relative "ittybit/files/types/files_delete_response_data"
|
6
|
-
require_relative "ittybit/files/types/files_delete_response"
|
7
5
|
require_relative "ittybit/tasks/types/tasks_list_request_status"
|
8
6
|
require_relative "ittybit/tasks/types/tasks_list_request_kind"
|
9
7
|
require_relative "ittybit/tasks/types/tasks_create_request_kind"
|
10
8
|
require_relative "ittybit/signatures/types/signatures_create_request_method"
|
11
9
|
require_relative "ittybit/types/meta"
|
10
|
+
require_relative "ittybit/types/meta_list_type"
|
12
11
|
require_relative "ittybit/types/meta_list"
|
13
12
|
require_relative "ittybit/types/links"
|
14
13
|
require_relative "ittybit/types/links_list"
|
15
14
|
require_relative "ittybit/types/error"
|
16
|
-
require_relative "ittybit/types/automation_trigger_conditions_item"
|
17
15
|
require_relative "ittybit/types/automation_trigger"
|
18
16
|
require_relative "ittybit/types/automation_status"
|
19
17
|
require_relative "ittybit/types/automation"
|
@@ -25,10 +23,10 @@ require_relative "ittybit/types/file_status"
|
|
25
23
|
require_relative "ittybit/types/file"
|
26
24
|
require_relative "ittybit/types/media_source_object"
|
27
25
|
require_relative "ittybit/types/media_source_kind"
|
26
|
+
require_relative "ittybit/types/media_source_orientation"
|
28
27
|
require_relative "ittybit/types/media_source_status"
|
29
28
|
require_relative "ittybit/types/media_source"
|
30
29
|
require_relative "ittybit/types/media_kind"
|
31
|
-
require_relative "ittybit/types/media_urls"
|
32
30
|
require_relative "ittybit/types/media"
|
33
31
|
require_relative "ittybit/types/task_kind"
|
34
32
|
require_relative "ittybit/types/task_status"
|
@@ -38,6 +36,7 @@ require_relative "ittybit/types/task_summary_kind"
|
|
38
36
|
require_relative "ittybit/types/task_summary_status"
|
39
37
|
require_relative "ittybit/types/task_summary"
|
40
38
|
require_relative "ittybit/types/signature"
|
39
|
+
require_relative "ittybit/types/confirmation"
|
41
40
|
require_relative "ittybit/types/task_response"
|
42
41
|
require_relative "ittybit/types/automation_response"
|
43
42
|
require_relative "ittybit/types/automation_list_response"
|
@@ -47,7 +46,5 @@ require_relative "ittybit/types/media_response"
|
|
47
46
|
require_relative "ittybit/types/media_list_response"
|
48
47
|
require_relative "ittybit/types/task_list_response"
|
49
48
|
require_relative "ittybit/types/signature_response"
|
50
|
-
require_relative "ittybit/types/confirmation_response_data"
|
51
49
|
require_relative "ittybit/types/confirmation_response"
|
52
|
-
require_relative "ittybit/types/error_response"
|
53
50
|
require_relative "ittybit/types/api_response_base"
|