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
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ittybit
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- ''
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-06
|
11
|
+
date: 2025-07-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: async-http-faraday
|
@@ -103,8 +103,6 @@ files:
|
|
103
103
|
- lib/ittybit/automations/types/automations_update_request_trigger.rb
|
104
104
|
- lib/ittybit/automations/types/automations_update_request_trigger_conditions_item.rb
|
105
105
|
- lib/ittybit/files/client.rb
|
106
|
-
- lib/ittybit/files/types/files_delete_response.rb
|
107
|
-
- lib/ittybit/files/types/files_delete_response_data.rb
|
108
106
|
- lib/ittybit/media/client.rb
|
109
107
|
- lib/ittybit/signatures/client.rb
|
110
108
|
- lib/ittybit/signatures/types/signatures_create_request_method.rb
|
@@ -118,11 +116,9 @@ files:
|
|
118
116
|
- lib/ittybit/types/automation_response.rb
|
119
117
|
- lib/ittybit/types/automation_status.rb
|
120
118
|
- lib/ittybit/types/automation_trigger.rb
|
121
|
-
- lib/ittybit/types/
|
119
|
+
- lib/ittybit/types/confirmation.rb
|
122
120
|
- lib/ittybit/types/confirmation_response.rb
|
123
|
-
- lib/ittybit/types/confirmation_response_data.rb
|
124
121
|
- lib/ittybit/types/error.rb
|
125
|
-
- lib/ittybit/types/error_response.rb
|
126
122
|
- lib/ittybit/types/file.rb
|
127
123
|
- lib/ittybit/types/file_kind.rb
|
128
124
|
- lib/ittybit/types/file_list_response.rb
|
@@ -138,10 +134,11 @@ files:
|
|
138
134
|
- lib/ittybit/types/media_source.rb
|
139
135
|
- lib/ittybit/types/media_source_kind.rb
|
140
136
|
- lib/ittybit/types/media_source_object.rb
|
137
|
+
- lib/ittybit/types/media_source_orientation.rb
|
141
138
|
- lib/ittybit/types/media_source_status.rb
|
142
|
-
- lib/ittybit/types/media_urls.rb
|
143
139
|
- lib/ittybit/types/meta.rb
|
144
140
|
- lib/ittybit/types/meta_list.rb
|
141
|
+
- lib/ittybit/types/meta_list_type.rb
|
145
142
|
- lib/ittybit/types/signature.rb
|
146
143
|
- lib/ittybit/types/signature_response.rb
|
147
144
|
- lib/ittybit/types/task.rb
|
@@ -1,89 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require_relative "files_delete_response_data"
|
4
|
-
require_relative "../../types/meta"
|
5
|
-
require_relative "../../types/links"
|
6
|
-
require "ostruct"
|
7
|
-
require "json"
|
8
|
-
|
9
|
-
module Ittybit
|
10
|
-
class Files
|
11
|
-
class FilesDeleteResponse
|
12
|
-
# @return [Ittybit::Files::FilesDeleteResponseData] Contains a confirmation message
|
13
|
-
attr_reader :data
|
14
|
-
# @return [Ittybit::META]
|
15
|
-
attr_reader :meta
|
16
|
-
# @return [Ittybit::Links]
|
17
|
-
attr_reader :links
|
18
|
-
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
19
|
-
attr_reader :additional_properties
|
20
|
-
# @return [Object]
|
21
|
-
attr_reader :_field_set
|
22
|
-
protected :_field_set
|
23
|
-
|
24
|
-
OMIT = Object.new
|
25
|
-
|
26
|
-
# @param data [Ittybit::Files::FilesDeleteResponseData] Contains a confirmation message
|
27
|
-
# @param meta [Ittybit::META]
|
28
|
-
# @param links [Ittybit::Links]
|
29
|
-
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
30
|
-
# @return [Ittybit::Files::FilesDeleteResponse]
|
31
|
-
def initialize(data: OMIT, meta: OMIT, links: OMIT, additional_properties: nil)
|
32
|
-
@data = data if data != OMIT
|
33
|
-
@meta = meta if meta != OMIT
|
34
|
-
@links = links if links != OMIT
|
35
|
-
@additional_properties = additional_properties
|
36
|
-
@_field_set = { "data": data, "meta": meta, "links": links }.reject do |_k, v|
|
37
|
-
v == OMIT
|
38
|
-
end
|
39
|
-
end
|
40
|
-
|
41
|
-
# Deserialize a JSON object to an instance of FilesDeleteResponse
|
42
|
-
#
|
43
|
-
# @param json_object [String]
|
44
|
-
# @return [Ittybit::Files::FilesDeleteResponse]
|
45
|
-
def self.from_json(json_object:)
|
46
|
-
struct = JSON.parse(json_object, object_class: OpenStruct)
|
47
|
-
parsed_json = JSON.parse(json_object)
|
48
|
-
if parsed_json["data"].nil?
|
49
|
-
data = nil
|
50
|
-
else
|
51
|
-
data = parsed_json["data"].to_json
|
52
|
-
data = Ittybit::Files::FilesDeleteResponseData.from_json(json_object: data)
|
53
|
-
end
|
54
|
-
meta = parsed_json["meta"]
|
55
|
-
if parsed_json["links"].nil?
|
56
|
-
links = nil
|
57
|
-
else
|
58
|
-
links = parsed_json["links"].to_json
|
59
|
-
links = Ittybit::Links.from_json(json_object: links)
|
60
|
-
end
|
61
|
-
new(
|
62
|
-
data: data,
|
63
|
-
meta: meta,
|
64
|
-
links: links,
|
65
|
-
additional_properties: struct
|
66
|
-
)
|
67
|
-
end
|
68
|
-
|
69
|
-
# Serialize an instance of FilesDeleteResponse to a JSON object
|
70
|
-
#
|
71
|
-
# @return [String]
|
72
|
-
def to_json(*_args)
|
73
|
-
@_field_set&.to_json
|
74
|
-
end
|
75
|
-
|
76
|
-
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
77
|
-
# hash and check each fields type against the current object's property
|
78
|
-
# definitions.
|
79
|
-
#
|
80
|
-
# @param obj [Object]
|
81
|
-
# @return [Void]
|
82
|
-
def self.validate_raw(obj:)
|
83
|
-
obj.data.nil? || Ittybit::Files::FilesDeleteResponseData.validate_raw(obj: obj.data)
|
84
|
-
obj.meta&.is_a?(Object) != false || raise("Passed value for field obj.meta is not the expected type, validation failed.")
|
85
|
-
obj.links.nil? || Ittybit::Links.validate_raw(obj: obj.links)
|
86
|
-
end
|
87
|
-
end
|
88
|
-
end
|
89
|
-
end
|
@@ -1,60 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require "ostruct"
|
4
|
-
require "json"
|
5
|
-
|
6
|
-
module Ittybit
|
7
|
-
class Files
|
8
|
-
# Contains a confirmation message
|
9
|
-
class FilesDeleteResponseData
|
10
|
-
# @return [String] Confirmation message
|
11
|
-
attr_reader :message
|
12
|
-
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
13
|
-
attr_reader :additional_properties
|
14
|
-
# @return [Object]
|
15
|
-
attr_reader :_field_set
|
16
|
-
protected :_field_set
|
17
|
-
|
18
|
-
OMIT = Object.new
|
19
|
-
|
20
|
-
# @param message [String] Confirmation message
|
21
|
-
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
22
|
-
# @return [Ittybit::Files::FilesDeleteResponseData]
|
23
|
-
def initialize(message: OMIT, additional_properties: nil)
|
24
|
-
@message = message if message != OMIT
|
25
|
-
@additional_properties = additional_properties
|
26
|
-
@_field_set = { "message": message }.reject do |_k, v|
|
27
|
-
v == OMIT
|
28
|
-
end
|
29
|
-
end
|
30
|
-
|
31
|
-
# Deserialize a JSON object to an instance of FilesDeleteResponseData
|
32
|
-
#
|
33
|
-
# @param json_object [String]
|
34
|
-
# @return [Ittybit::Files::FilesDeleteResponseData]
|
35
|
-
def self.from_json(json_object:)
|
36
|
-
struct = JSON.parse(json_object, object_class: OpenStruct)
|
37
|
-
parsed_json = JSON.parse(json_object)
|
38
|
-
message = parsed_json["message"]
|
39
|
-
new(message: message, additional_properties: struct)
|
40
|
-
end
|
41
|
-
|
42
|
-
# Serialize an instance of FilesDeleteResponseData to a JSON object
|
43
|
-
#
|
44
|
-
# @return [String]
|
45
|
-
def to_json(*_args)
|
46
|
-
@_field_set&.to_json
|
47
|
-
end
|
48
|
-
|
49
|
-
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
50
|
-
# hash and check each fields type against the current object's property
|
51
|
-
# definitions.
|
52
|
-
#
|
53
|
-
# @param obj [Object]
|
54
|
-
# @return [Void]
|
55
|
-
def self.validate_raw(obj:)
|
56
|
-
obj.message&.is_a?(String) != false || raise("Passed value for field obj.message is not the expected type, validation failed.")
|
57
|
-
end
|
58
|
-
end
|
59
|
-
end
|
60
|
-
end
|
@@ -1,65 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require "ostruct"
|
4
|
-
require "json"
|
5
|
-
|
6
|
-
module Ittybit
|
7
|
-
class AutomationTriggerConditionsItem
|
8
|
-
# @return [String] The property to check (e.g., file.type, file.size)
|
9
|
-
attr_reader :prop
|
10
|
-
# @return [String] The value the property must match
|
11
|
-
attr_reader :value
|
12
|
-
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
13
|
-
attr_reader :additional_properties
|
14
|
-
# @return [Object]
|
15
|
-
attr_reader :_field_set
|
16
|
-
protected :_field_set
|
17
|
-
|
18
|
-
OMIT = Object.new
|
19
|
-
|
20
|
-
# @param prop [String] The property to check (e.g., file.type, file.size)
|
21
|
-
# @param value [String] The value the property must match
|
22
|
-
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
23
|
-
# @return [Ittybit::AutomationTriggerConditionsItem]
|
24
|
-
def initialize(prop:, value:, additional_properties: nil)
|
25
|
-
@prop = prop
|
26
|
-
@value = value
|
27
|
-
@additional_properties = additional_properties
|
28
|
-
@_field_set = { "prop": prop, "value": value }
|
29
|
-
end
|
30
|
-
|
31
|
-
# Deserialize a JSON object to an instance of AutomationTriggerConditionsItem
|
32
|
-
#
|
33
|
-
# @param json_object [String]
|
34
|
-
# @return [Ittybit::AutomationTriggerConditionsItem]
|
35
|
-
def self.from_json(json_object:)
|
36
|
-
struct = JSON.parse(json_object, object_class: OpenStruct)
|
37
|
-
parsed_json = JSON.parse(json_object)
|
38
|
-
prop = parsed_json["prop"]
|
39
|
-
value = parsed_json["value"]
|
40
|
-
new(
|
41
|
-
prop: prop,
|
42
|
-
value: value,
|
43
|
-
additional_properties: struct
|
44
|
-
)
|
45
|
-
end
|
46
|
-
|
47
|
-
# Serialize an instance of AutomationTriggerConditionsItem to a JSON object
|
48
|
-
#
|
49
|
-
# @return [String]
|
50
|
-
def to_json(*_args)
|
51
|
-
@_field_set&.to_json
|
52
|
-
end
|
53
|
-
|
54
|
-
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
55
|
-
# hash and check each fields type against the current object's property
|
56
|
-
# definitions.
|
57
|
-
#
|
58
|
-
# @param obj [Object]
|
59
|
-
# @return [Void]
|
60
|
-
def self.validate_raw(obj:)
|
61
|
-
obj.prop.is_a?(String) != false || raise("Passed value for field obj.prop is not the expected type, validation failed.")
|
62
|
-
obj.value.is_a?(String) != false || raise("Passed value for field obj.value is not the expected type, validation failed.")
|
63
|
-
end
|
64
|
-
end
|
65
|
-
end
|
@@ -1,74 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require_relative "meta"
|
4
|
-
require_relative "error"
|
5
|
-
require "ostruct"
|
6
|
-
require "json"
|
7
|
-
|
8
|
-
module Ittybit
|
9
|
-
class ErrorResponse
|
10
|
-
# @return [Ittybit::META]
|
11
|
-
attr_reader :meta
|
12
|
-
# @return [Ittybit::Error]
|
13
|
-
attr_reader :error
|
14
|
-
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
15
|
-
attr_reader :additional_properties
|
16
|
-
# @return [Object]
|
17
|
-
attr_reader :_field_set
|
18
|
-
protected :_field_set
|
19
|
-
|
20
|
-
OMIT = Object.new
|
21
|
-
|
22
|
-
# @param meta [Ittybit::META]
|
23
|
-
# @param error [Ittybit::Error]
|
24
|
-
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
25
|
-
# @return [Ittybit::ErrorResponse]
|
26
|
-
def initialize(meta: OMIT, error: OMIT, additional_properties: nil)
|
27
|
-
@meta = meta if meta != OMIT
|
28
|
-
@error = error if error != OMIT
|
29
|
-
@additional_properties = additional_properties
|
30
|
-
@_field_set = { "meta": meta, "error": error }.reject do |_k, v|
|
31
|
-
v == OMIT
|
32
|
-
end
|
33
|
-
end
|
34
|
-
|
35
|
-
# Deserialize a JSON object to an instance of ErrorResponse
|
36
|
-
#
|
37
|
-
# @param json_object [String]
|
38
|
-
# @return [Ittybit::ErrorResponse]
|
39
|
-
def self.from_json(json_object:)
|
40
|
-
struct = JSON.parse(json_object, object_class: OpenStruct)
|
41
|
-
parsed_json = JSON.parse(json_object)
|
42
|
-
meta = parsed_json["meta"]
|
43
|
-
if parsed_json["error"].nil?
|
44
|
-
error = nil
|
45
|
-
else
|
46
|
-
error = parsed_json["error"].to_json
|
47
|
-
error = Ittybit::Error.from_json(json_object: error)
|
48
|
-
end
|
49
|
-
new(
|
50
|
-
meta: meta,
|
51
|
-
error: error,
|
52
|
-
additional_properties: struct
|
53
|
-
)
|
54
|
-
end
|
55
|
-
|
56
|
-
# Serialize an instance of ErrorResponse to a JSON object
|
57
|
-
#
|
58
|
-
# @return [String]
|
59
|
-
def to_json(*_args)
|
60
|
-
@_field_set&.to_json
|
61
|
-
end
|
62
|
-
|
63
|
-
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
64
|
-
# hash and check each fields type against the current object's property
|
65
|
-
# definitions.
|
66
|
-
#
|
67
|
-
# @param obj [Object]
|
68
|
-
# @return [Void]
|
69
|
-
def self.validate_raw(obj:)
|
70
|
-
obj.meta&.is_a?(Object) != false || raise("Passed value for field obj.meta is not the expected type, validation failed.")
|
71
|
-
obj.error.nil? || Ittybit::Error.validate_raw(obj: obj.error)
|
72
|
-
end
|
73
|
-
end
|
74
|
-
end
|
@@ -1,70 +0,0 @@
|
|
1
|
-
# frozen_string_literal: true
|
2
|
-
|
3
|
-
require "ostruct"
|
4
|
-
require "json"
|
5
|
-
|
6
|
-
module Ittybit
|
7
|
-
# URLs for the media item.
|
8
|
-
class MediaUrls
|
9
|
-
# @return [String] URL of the original source file.
|
10
|
-
attr_reader :original
|
11
|
-
# @return [String] Example URL for a file with the ref value "example_ref". Any key with a-z, 0-9,
|
12
|
-
# _, or - is possible, but keys must start with a letter.
|
13
|
-
attr_reader :example_ref
|
14
|
-
# @return [OpenStruct] Additional properties unmapped to the current class definition
|
15
|
-
attr_reader :additional_properties
|
16
|
-
# @return [Object]
|
17
|
-
attr_reader :_field_set
|
18
|
-
protected :_field_set
|
19
|
-
|
20
|
-
OMIT = Object.new
|
21
|
-
|
22
|
-
# @param original [String] URL of the original source file.
|
23
|
-
# @param example_ref [String] Example URL for a file with the ref value "example_ref". Any key with a-z, 0-9,
|
24
|
-
# _, or - is possible, but keys must start with a letter.
|
25
|
-
# @param additional_properties [OpenStruct] Additional properties unmapped to the current class definition
|
26
|
-
# @return [Ittybit::MediaUrls]
|
27
|
-
def initialize(original: OMIT, example_ref: OMIT, additional_properties: nil)
|
28
|
-
@original = original if original != OMIT
|
29
|
-
@example_ref = example_ref if example_ref != OMIT
|
30
|
-
@additional_properties = additional_properties
|
31
|
-
@_field_set = { "original": original, "example_ref": example_ref }.reject do |_k, v|
|
32
|
-
v == OMIT
|
33
|
-
end
|
34
|
-
end
|
35
|
-
|
36
|
-
# Deserialize a JSON object to an instance of MediaUrls
|
37
|
-
#
|
38
|
-
# @param json_object [String]
|
39
|
-
# @return [Ittybit::MediaUrls]
|
40
|
-
def self.from_json(json_object:)
|
41
|
-
struct = JSON.parse(json_object, object_class: OpenStruct)
|
42
|
-
parsed_json = JSON.parse(json_object)
|
43
|
-
original = parsed_json["original"]
|
44
|
-
example_ref = parsed_json["example_ref"]
|
45
|
-
new(
|
46
|
-
original: original,
|
47
|
-
example_ref: example_ref,
|
48
|
-
additional_properties: struct
|
49
|
-
)
|
50
|
-
end
|
51
|
-
|
52
|
-
# Serialize an instance of MediaUrls to a JSON object
|
53
|
-
#
|
54
|
-
# @return [String]
|
55
|
-
def to_json(*_args)
|
56
|
-
@_field_set&.to_json
|
57
|
-
end
|
58
|
-
|
59
|
-
# Leveraged for Union-type generation, validate_raw attempts to parse the given
|
60
|
-
# hash and check each fields type against the current object's property
|
61
|
-
# definitions.
|
62
|
-
#
|
63
|
-
# @param obj [Object]
|
64
|
-
# @return [Void]
|
65
|
-
def self.validate_raw(obj:)
|
66
|
-
obj.original&.is_a?(String) != false || raise("Passed value for field obj.original is not the expected type, validation failed.")
|
67
|
-
obj.example_ref&.is_a?(String) != false || raise("Passed value for field obj.example_ref is not the expected type, validation failed.")
|
68
|
-
end
|
69
|
-
end
|
70
|
-
end
|