appnigma-sdk 2.0.0 → 2.2.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +14 -0
- data/README.md +592 -26
- data/exe/appnigma +8 -0
- data/lib/appnigma/actions.rb +33 -0
- data/lib/appnigma/checks.rb +13 -0
- data/lib/appnigma/client.rb +30 -13
- data/lib/appnigma/command.rb +154 -0
- data/lib/appnigma/command_files.rb +46 -0
- data/lib/appnigma/connect_fields.rb +83 -0
- data/lib/appnigma/connections.rb +72 -3
- data/lib/appnigma/constants.rb +57 -0
- data/lib/appnigma/end_customers.rb +29 -0
- data/lib/appnigma/errors.rb +44 -6
- data/lib/appnigma/features.rb +19 -0
- data/lib/appnigma/files.rb +26 -0
- data/lib/appnigma/generated/api/default_api.rb +2149 -380
- data/lib/appnigma/generated/api_client.rb +1 -1
- data/lib/appnigma/generated/api_error.rb +1 -1
- data/lib/appnigma/generated/api_model_base.rb +1 -1
- data/lib/appnigma/generated/configuration.rb +1 -1
- data/lib/appnigma/generated/models/action_entry.rb +1 -1
- data/lib/appnigma/generated/models/check_logic_input.rb +276 -0
- data/lib/appnigma/generated/models/check_logic_output.rb +193 -0
- data/lib/appnigma/generated/models/client_event.rb +309 -0
- data/lib/appnigma/generated/models/client_event_delivery.rb +306 -0
- data/lib/appnigma/generated/models/client_event_type.rb +44 -0
- data/lib/appnigma/generated/models/client_webhook.rb +346 -0
- data/lib/appnigma/generated/models/connect_end_customer_input.rb +243 -0
- data/lib/appnigma/generated/models/connect_end_customer_output.rb +294 -0
- data/lib/appnigma/generated/models/connect_field.rb +308 -0
- data/lib/appnigma/generated/models/connection_status.rb +1 -1
- data/lib/appnigma/generated/models/create_connection_link_input.rb +1 -1
- data/lib/appnigma/generated/models/create_connection_link_output.rb +1 -1
- data/lib/appnigma/generated/models/create_logic_input.rb +273 -0
- data/lib/appnigma/generated/models/create_logic_input_trigger.rb +104 -0
- data/lib/appnigma/generated/models/create_logic_input_trigger_any_of.rb +257 -0
- data/lib/appnigma/generated/models/create_logic_input_trigger_any_of1.rb +238 -0
- data/lib/appnigma/generated/models/create_logic_output.rb +230 -0
- data/lib/appnigma/generated/models/create_portal_link_input.rb +2 -18
- data/lib/appnigma/generated/models/create_portal_link_output.rb +1 -1
- data/lib/appnigma/generated/models/create_webhook_input.rb +187 -0
- data/lib/appnigma/generated/models/create_webhook_output.rb +204 -0
- data/lib/appnigma/generated/models/crm_company.rb +1 -1
- data/lib/appnigma/generated/models/crm_company_get_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_company_list_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_company_write_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_contact.rb +1 -1
- data/lib/appnigma/generated/models/crm_contact_get_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_contact_list_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_contact_write_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_create_input.rb +1 -1
- data/lib/appnigma/generated/models/crm_custom_field.rb +1 -1
- data/lib/appnigma/generated/models/crm_deal.rb +1 -1
- data/lib/appnigma/generated/models/crm_deal_create_input.rb +1 -1
- data/lib/appnigma/generated/models/crm_deal_get_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_deal_list_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_deal_write_output.rb +1 -1
- data/lib/appnigma/generated/models/crm_email.rb +1 -1
- data/lib/appnigma/generated/models/crm_get_input.rb +1 -1
- data/lib/appnigma/generated/models/crm_labelled.rb +1 -1
- data/lib/appnigma/generated/models/crm_list_input.rb +1 -1
- data/lib/appnigma/generated/models/crm_phone.rb +1 -1
- data/lib/appnigma/generated/models/crm_update_input.rb +1 -1
- data/lib/appnigma/generated/models/delete_end_customer_input.rb +178 -0
- data/lib/appnigma/generated/models/delete_end_customer_output.rb +286 -0
- data/lib/appnigma/generated/models/delete_end_customer_output_connections_inner.rb +238 -0
- data/lib/appnigma/generated/models/delete_end_customer_output_logic_folder.rb +255 -0
- data/lib/appnigma/generated/models/delete_end_customer_output_steps_inner.rb +257 -0
- data/lib/appnigma/generated/models/delete_webhook_input.rb +189 -0
- data/lib/appnigma/generated/models/delete_webhook_output.rb +228 -0
- data/lib/appnigma/generated/models/discard_logic_input.rb +292 -0
- data/lib/appnigma/generated/models/discard_logic_output.rb +254 -0
- data/lib/appnigma/generated/models/disconnect_connection_input.rb +216 -0
- data/lib/appnigma/generated/models/disconnect_connection_output.rb +294 -0
- data/lib/appnigma/generated/models/edit_logic_input.rb +368 -0
- data/lib/appnigma/generated/models/edit_logic_output.rb +298 -0
- data/lib/appnigma/generated/models/encrypted_fields.rb +357 -0
- data/lib/appnigma/generated/models/end_customer.rb +17 -3
- data/lib/appnigma/generated/models/end_customer_connection.rb +1 -1
- data/lib/appnigma/generated/models/function_entry.rb +1 -1
- data/lib/appnigma/generated/models/function_owner.rb +1 -1
- data/lib/appnigma/generated/models/function_owner_one_of.rb +1 -1
- data/lib/appnigma/generated/models/function_owner_one_of1.rb +1 -1
- data/lib/appnigma/generated/models/get_alerts_output.rb +180 -0
- data/lib/appnigma/generated/models/get_connect_key_output.rb +256 -0
- data/lib/appnigma/generated/models/get_connection_input.rb +1 -1
- data/lib/appnigma/generated/models/get_connection_output.rb +34 -7
- data/lib/appnigma/generated/models/get_guide_output.rb +1 -1
- data/lib/appnigma/generated/models/get_logic_go_live_status_input.rb +247 -0
- data/lib/appnigma/generated/models/get_logic_go_live_status_output.rb +296 -0
- data/lib/appnigma/generated/models/get_logic_input.rb +247 -0
- data/lib/appnigma/generated/models/get_logic_output.rb +240 -0
- data/lib/appnigma/generated/models/get_logic_output_file.rb +204 -0
- data/lib/appnigma/generated/models/get_platform_input.rb +188 -0
- data/lib/appnigma/generated/models/get_platform_output.rb +326 -0
- data/lib/appnigma/generated/models/get_sync_output.rb +207 -0
- data/lib/appnigma/generated/models/go_live_logic_input.rb +316 -0
- data/lib/appnigma/generated/models/go_live_logic_output.rb +281 -0
- data/lib/appnigma/generated/models/json_value.rb +1 -1
- data/lib/appnigma/generated/models/list_actions_output.rb +1 -1
- data/lib/appnigma/generated/models/list_connections_output.rb +3 -3
- data/lib/appnigma/generated/models/list_events_input.rb +302 -0
- data/lib/appnigma/generated/models/list_events_output.rb +193 -0
- data/lib/appnigma/generated/models/list_features_output.rb +179 -0
- data/lib/appnigma/generated/models/list_features_output_features_inner.rb +229 -0
- data/lib/appnigma/generated/models/list_functions_output.rb +1 -1
- data/lib/appnigma/generated/models/list_logic_input.rb +162 -0
- data/lib/appnigma/generated/models/list_logic_output.rb +209 -0
- data/lib/appnigma/generated/models/list_logic_runs_input.rb +275 -0
- data/lib/appnigma/generated/models/list_logic_runs_output.rb +193 -0
- data/lib/appnigma/generated/models/list_platforms_output.rb +1 -1
- data/lib/appnigma/generated/models/list_record_changes_input.rb +375 -0
- data/lib/appnigma/generated/models/list_record_changes_output.rb +193 -0
- data/lib/appnigma/generated/models/list_webhooks_output.rb +180 -0
- data/lib/appnigma/generated/models/logic_check_problem.rb +203 -0
- data/lib/appnigma/generated/models/logic_conditional.rb +3 -3
- data/lib/appnigma/generated/models/logic_draft.rb +257 -0
- data/lib/appnigma/generated/models/logic_entry.rb +441 -0
- data/lib/appnigma/generated/models/logic_entry_failure.rb +205 -0
- data/lib/appnigma/generated/models/logic_folder_problem.rb +218 -0
- data/lib/appnigma/generated/models/logic_run.rb +483 -0
- data/lib/appnigma/generated/models/logic_test_call.rb +269 -0
- data/lib/appnigma/generated/models/platform_entry.rb +63 -6
- data/lib/appnigma/generated/models/platform_entry_coverage_inner.rb +1 -1
- data/lib/appnigma/generated/models/platform_request_input.rb +1 -1
- data/lib/appnigma/generated/models/platform_request_input_body.rb +1 -1
- data/lib/appnigma/generated/models/platform_request_output.rb +1 -1
- data/lib/appnigma/generated/models/ran_as.rb +1 -1
- data/lib/appnigma/generated/models/record_change.rb +231 -0
- data/lib/appnigma/generated/models/record_change_record.rb +105 -0
- data/lib/appnigma/generated/models/run_action_input.rb +1 -1
- data/lib/appnigma/generated/models/run_action_output.rb +1 -1
- data/lib/appnigma/generated/models/run_input.rb +1 -1
- data/lib/appnigma/generated/models/run_output.rb +1 -1
- data/lib/appnigma/generated/models/sdk_error.rb +1 -1
- data/lib/appnigma/generated/models/sdk_error_error.rb +3 -3
- data/lib/appnigma/generated/models/sdk_error_error_details.rb +81 -6
- data/lib/appnigma/generated/models/sdk_problem.rb +1 -1
- data/lib/appnigma/generated/models/set_alerts_input.rb +197 -0
- data/lib/appnigma/generated/models/set_alerts_output.rb +180 -0
- data/lib/appnigma/generated/models/set_sync_input.rb +177 -0
- data/lib/appnigma/generated/models/set_sync_output.rb +207 -0
- data/lib/appnigma/generated/models/switch_logic_off_input.rb +200 -0
- data/lib/appnigma/generated/models/switch_logic_off_output.rb +315 -0
- data/lib/appnigma/generated/models/switch_logic_on_input.rb +200 -0
- data/lib/appnigma/generated/models/switch_logic_on_output.rb +315 -0
- data/lib/appnigma/generated/models/sync_health.rb +231 -0
- data/lib/appnigma/generated/models/test_logic_input.rb +355 -0
- data/lib/appnigma/generated/models/test_logic_output.rb +418 -0
- data/lib/appnigma/generated/models/test_logic_output_error.rb +231 -0
- data/lib/appnigma/generated/models/update_logic_input.rb +359 -0
- data/lib/appnigma/generated/models/update_logic_output.rb +205 -0
- data/lib/appnigma/generated/version.rb +1 -1
- data/lib/appnigma/generated.rb +77 -1
- data/lib/appnigma/logic.rb +176 -0
- data/lib/appnigma/names.rb +4 -4
- data/lib/appnigma/platforms.rb +11 -1
- data/lib/appnigma/portal.rb +8 -5
- data/lib/appnigma/records.rb +46 -0
- data/lib/appnigma/schema_type.rb +149 -0
- data/lib/appnigma/sync.rb +30 -0
- data/lib/appnigma/types_printer.rb +154 -0
- data/lib/appnigma/verify_webhook.rb +107 -0
- data/lib/appnigma/version.rb +2 -2
- data/lib/appnigma/webhooks.rb +79 -0
- data/lib/appnigma.rb +1 -0
- metadata +95 -3
|
@@ -0,0 +1,359 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Appnigma SDK API
|
|
3
|
+
|
|
4
|
+
#The routes a customer's product calls through an Appnigma SDK. Every answer carries a request id in X-Request-Id; quote it when you write to support.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 5.4.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.26.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Appnigma::Generated
|
|
17
|
+
class UpdateLogicInput < ApiModelBase
|
|
18
|
+
# Whose logic: an end customer's, or, null or left out, your own. Your own id for the end customer: it must be 1 to 255 characters, with no control characters and not only spaces. Stored exactly as sent: ids that differ only in case or spaces are different end customers.
|
|
19
|
+
attr_accessor :end_customer_id
|
|
20
|
+
|
|
21
|
+
# The platform key, such as hubspot.
|
|
22
|
+
attr_accessor :platform
|
|
23
|
+
|
|
24
|
+
# The logic's name, the same as its file name.
|
|
25
|
+
attr_accessor :name
|
|
26
|
+
|
|
27
|
+
# The whole file, as it should be kept.
|
|
28
|
+
attr_accessor :source
|
|
29
|
+
|
|
30
|
+
# The draft's revision this save was made on, from getLogic or the last save; 0 for the first save of a logic on main.
|
|
31
|
+
attr_accessor :revision
|
|
32
|
+
|
|
33
|
+
# With revision 0: the sha of the file on main the change began from, from getLogic.
|
|
34
|
+
attr_accessor :base_sha
|
|
35
|
+
|
|
36
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
37
|
+
def self.attribute_map
|
|
38
|
+
{
|
|
39
|
+
:'end_customer_id' => :'endCustomerId',
|
|
40
|
+
:'platform' => :'platform',
|
|
41
|
+
:'name' => :'name',
|
|
42
|
+
:'source' => :'source',
|
|
43
|
+
:'revision' => :'revision',
|
|
44
|
+
:'base_sha' => :'baseSha'
|
|
45
|
+
}
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
# Returns attribute mapping this model knows about
|
|
49
|
+
def self.acceptable_attribute_map
|
|
50
|
+
attribute_map
|
|
51
|
+
end
|
|
52
|
+
|
|
53
|
+
# Returns all the JSON keys this model knows about
|
|
54
|
+
def self.acceptable_attributes
|
|
55
|
+
acceptable_attribute_map.values
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
# Attribute type mapping.
|
|
59
|
+
def self.openapi_types
|
|
60
|
+
{
|
|
61
|
+
:'end_customer_id' => :'String',
|
|
62
|
+
:'platform' => :'String',
|
|
63
|
+
:'name' => :'String',
|
|
64
|
+
:'source' => :'String',
|
|
65
|
+
:'revision' => :'Integer',
|
|
66
|
+
:'base_sha' => :'String'
|
|
67
|
+
}
|
|
68
|
+
end
|
|
69
|
+
|
|
70
|
+
# List of attributes with nullable: true
|
|
71
|
+
def self.openapi_nullable
|
|
72
|
+
Set.new([
|
|
73
|
+
:'end_customer_id',
|
|
74
|
+
])
|
|
75
|
+
end
|
|
76
|
+
|
|
77
|
+
# Returns attribute type mapping
|
|
78
|
+
def self.acceptable_openapi_types
|
|
79
|
+
openapi_types
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# Returns the nullable attributes
|
|
83
|
+
def self.acceptable_openapi_nullable
|
|
84
|
+
openapi_nullable
|
|
85
|
+
end
|
|
86
|
+
|
|
87
|
+
# Initializes the object
|
|
88
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
89
|
+
def initialize(attributes = {})
|
|
90
|
+
if (!attributes.is_a?(Hash))
|
|
91
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Appnigma::Generated::UpdateLogicInput` initialize method"
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
95
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
96
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
97
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
98
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Appnigma::Generated::UpdateLogicInput`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
99
|
+
end
|
|
100
|
+
h[k.to_sym] = v
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
if attributes.key?(:'end_customer_id')
|
|
104
|
+
self.end_customer_id = attributes[:'end_customer_id']
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
if attributes.key?(:'platform')
|
|
108
|
+
self.platform = attributes[:'platform']
|
|
109
|
+
else
|
|
110
|
+
self.platform = nil
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
if attributes.key?(:'name')
|
|
114
|
+
self.name = attributes[:'name']
|
|
115
|
+
else
|
|
116
|
+
self.name = nil
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
if attributes.key?(:'source')
|
|
120
|
+
self.source = attributes[:'source']
|
|
121
|
+
else
|
|
122
|
+
self.source = nil
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
if attributes.key?(:'revision')
|
|
126
|
+
self.revision = attributes[:'revision']
|
|
127
|
+
else
|
|
128
|
+
self.revision = nil
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
if attributes.key?(:'base_sha')
|
|
132
|
+
self.base_sha = attributes[:'base_sha']
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
|
|
136
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
137
|
+
# @return Array for valid properties with the reasons
|
|
138
|
+
def list_invalid_properties
|
|
139
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
140
|
+
invalid_properties = Array.new
|
|
141
|
+
if @platform.nil?
|
|
142
|
+
invalid_properties.push('invalid value for "platform", platform cannot be nil.')
|
|
143
|
+
end
|
|
144
|
+
|
|
145
|
+
pattern = Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
146
|
+
if @platform !~ pattern
|
|
147
|
+
invalid_properties.push("invalid value for \"platform\", must conform to the pattern #{pattern}.")
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
if @name.nil?
|
|
151
|
+
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
|
152
|
+
end
|
|
153
|
+
|
|
154
|
+
if @name.to_s.length > 64
|
|
155
|
+
invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 64.')
|
|
156
|
+
end
|
|
157
|
+
|
|
158
|
+
pattern = Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
159
|
+
if @name !~ pattern
|
|
160
|
+
invalid_properties.push("invalid value for \"name\", must conform to the pattern #{pattern}.")
|
|
161
|
+
end
|
|
162
|
+
|
|
163
|
+
if @source.nil?
|
|
164
|
+
invalid_properties.push('invalid value for "source", source cannot be nil.')
|
|
165
|
+
end
|
|
166
|
+
|
|
167
|
+
if @source.to_s.length > 50000
|
|
168
|
+
invalid_properties.push('invalid value for "source", the character length must be smaller than or equal to 50000.')
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
if @revision.nil?
|
|
172
|
+
invalid_properties.push('invalid value for "revision", revision cannot be nil.')
|
|
173
|
+
end
|
|
174
|
+
|
|
175
|
+
if @revision > 9007199254740991
|
|
176
|
+
invalid_properties.push('invalid value for "revision", must be smaller than or equal to 9007199254740991.')
|
|
177
|
+
end
|
|
178
|
+
|
|
179
|
+
if @revision < 0
|
|
180
|
+
invalid_properties.push('invalid value for "revision", must be greater than or equal to 0.')
|
|
181
|
+
end
|
|
182
|
+
|
|
183
|
+
pattern = Regexp.new(/^[0-9a-f]{40}$/)
|
|
184
|
+
if !@base_sha.nil? && @base_sha !~ pattern
|
|
185
|
+
invalid_properties.push("invalid value for \"base_sha\", must conform to the pattern #{pattern}.")
|
|
186
|
+
end
|
|
187
|
+
|
|
188
|
+
invalid_properties
|
|
189
|
+
end
|
|
190
|
+
|
|
191
|
+
# Check to see if the all the properties in the model are valid
|
|
192
|
+
# @return true if the model is valid
|
|
193
|
+
def valid?
|
|
194
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
195
|
+
return false if @platform.nil?
|
|
196
|
+
return false if @platform !~ Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
197
|
+
return false if @name.nil?
|
|
198
|
+
return false if @name.to_s.length > 64
|
|
199
|
+
return false if @name !~ Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
200
|
+
return false if @source.nil?
|
|
201
|
+
return false if @source.to_s.length > 50000
|
|
202
|
+
return false if @revision.nil?
|
|
203
|
+
return false if @revision > 9007199254740991
|
|
204
|
+
return false if @revision < 0
|
|
205
|
+
return false if !@base_sha.nil? && @base_sha !~ Regexp.new(/^[0-9a-f]{40}$/)
|
|
206
|
+
true
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
# Custom attribute writer method with validation
|
|
210
|
+
# @param [Object] platform Value to be assigned
|
|
211
|
+
def platform=(platform)
|
|
212
|
+
if platform.nil?
|
|
213
|
+
fail ArgumentError, 'platform cannot be nil'
|
|
214
|
+
end
|
|
215
|
+
|
|
216
|
+
pattern = Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
217
|
+
if platform !~ pattern
|
|
218
|
+
fail ArgumentError, "invalid value for \"platform\", must conform to the pattern #{pattern}."
|
|
219
|
+
end
|
|
220
|
+
|
|
221
|
+
@platform = platform
|
|
222
|
+
end
|
|
223
|
+
|
|
224
|
+
# Custom attribute writer method with validation
|
|
225
|
+
# @param [Object] name Value to be assigned
|
|
226
|
+
def name=(name)
|
|
227
|
+
if name.nil?
|
|
228
|
+
fail ArgumentError, 'name cannot be nil'
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
if name.to_s.length > 64
|
|
232
|
+
fail ArgumentError, 'invalid value for "name", the character length must be smaller than or equal to 64.'
|
|
233
|
+
end
|
|
234
|
+
|
|
235
|
+
pattern = Regexp.new(/^[a-z0-9]+(?:-[a-z0-9]+)*$/)
|
|
236
|
+
if name !~ pattern
|
|
237
|
+
fail ArgumentError, "invalid value for \"name\", must conform to the pattern #{pattern}."
|
|
238
|
+
end
|
|
239
|
+
|
|
240
|
+
@name = name
|
|
241
|
+
end
|
|
242
|
+
|
|
243
|
+
# Custom attribute writer method with validation
|
|
244
|
+
# @param [Object] source Value to be assigned
|
|
245
|
+
def source=(source)
|
|
246
|
+
if source.nil?
|
|
247
|
+
fail ArgumentError, 'source cannot be nil'
|
|
248
|
+
end
|
|
249
|
+
|
|
250
|
+
if source.to_s.length > 50000
|
|
251
|
+
fail ArgumentError, 'invalid value for "source", the character length must be smaller than or equal to 50000.'
|
|
252
|
+
end
|
|
253
|
+
|
|
254
|
+
@source = source
|
|
255
|
+
end
|
|
256
|
+
|
|
257
|
+
# Custom attribute writer method with validation
|
|
258
|
+
# @param [Object] revision Value to be assigned
|
|
259
|
+
def revision=(revision)
|
|
260
|
+
if revision.nil?
|
|
261
|
+
fail ArgumentError, 'revision cannot be nil'
|
|
262
|
+
end
|
|
263
|
+
|
|
264
|
+
if revision > 9007199254740991
|
|
265
|
+
fail ArgumentError, 'invalid value for "revision", must be smaller than or equal to 9007199254740991.'
|
|
266
|
+
end
|
|
267
|
+
|
|
268
|
+
if revision < 0
|
|
269
|
+
fail ArgumentError, 'invalid value for "revision", must be greater than or equal to 0.'
|
|
270
|
+
end
|
|
271
|
+
|
|
272
|
+
@revision = revision
|
|
273
|
+
end
|
|
274
|
+
|
|
275
|
+
# Custom attribute writer method with validation
|
|
276
|
+
# @param [Object] base_sha Value to be assigned
|
|
277
|
+
def base_sha=(base_sha)
|
|
278
|
+
if base_sha.nil?
|
|
279
|
+
fail ArgumentError, 'base_sha cannot be nil'
|
|
280
|
+
end
|
|
281
|
+
|
|
282
|
+
pattern = Regexp.new(/^[0-9a-f]{40}$/)
|
|
283
|
+
if base_sha !~ pattern
|
|
284
|
+
fail ArgumentError, "invalid value for \"base_sha\", must conform to the pattern #{pattern}."
|
|
285
|
+
end
|
|
286
|
+
|
|
287
|
+
@base_sha = base_sha
|
|
288
|
+
end
|
|
289
|
+
|
|
290
|
+
# Checks equality by comparing each attribute.
|
|
291
|
+
# @param [Object] Object to be compared
|
|
292
|
+
def ==(o)
|
|
293
|
+
return true if self.equal?(o)
|
|
294
|
+
self.class == o.class &&
|
|
295
|
+
end_customer_id == o.end_customer_id &&
|
|
296
|
+
platform == o.platform &&
|
|
297
|
+
name == o.name &&
|
|
298
|
+
source == o.source &&
|
|
299
|
+
revision == o.revision &&
|
|
300
|
+
base_sha == o.base_sha
|
|
301
|
+
end
|
|
302
|
+
|
|
303
|
+
# @see the `==` method
|
|
304
|
+
# @param [Object] Object to be compared
|
|
305
|
+
def eql?(o)
|
|
306
|
+
self == o
|
|
307
|
+
end
|
|
308
|
+
|
|
309
|
+
# Calculates hash code according to all attributes.
|
|
310
|
+
# @return [Integer] Hash code
|
|
311
|
+
def hash
|
|
312
|
+
[end_customer_id, platform, name, source, revision, base_sha].hash
|
|
313
|
+
end
|
|
314
|
+
|
|
315
|
+
# Builds the object from hash
|
|
316
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
317
|
+
# @return [Object] Returns the model itself
|
|
318
|
+
def self.build_from_hash(attributes)
|
|
319
|
+
return nil unless attributes.is_a?(Hash)
|
|
320
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
321
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
322
|
+
map = acceptable_attribute_map
|
|
323
|
+
transformed_hash = {}
|
|
324
|
+
acceptable_openapi_types.each_pair do |key, type|
|
|
325
|
+
if attributes.key?(map[key]) && attributes[map[key]].nil?
|
|
326
|
+
transformed_hash["#{key}"] = nil
|
|
327
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
328
|
+
# check to ensure the input is an array given that the attribute
|
|
329
|
+
# is documented as an array but the input is not
|
|
330
|
+
if attributes[map[key]].is_a?(Array)
|
|
331
|
+
transformed_hash["#{key}"] = attributes[map[key]].map { |v| _deserialize($1, v) }
|
|
332
|
+
end
|
|
333
|
+
elsif !attributes[map[key]].nil?
|
|
334
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[map[key]])
|
|
335
|
+
end
|
|
336
|
+
end
|
|
337
|
+
new(transformed_hash)
|
|
338
|
+
end
|
|
339
|
+
|
|
340
|
+
# Returns the object in the form of hash
|
|
341
|
+
# @return [Hash] Returns the object in the form of hash
|
|
342
|
+
def to_hash
|
|
343
|
+
hash = {}
|
|
344
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
345
|
+
self.class.acceptable_attribute_map.each_pair do |attr, param|
|
|
346
|
+
value = self.send(attr)
|
|
347
|
+
if value.nil?
|
|
348
|
+
is_nullable = self.class.acceptable_openapi_nullable.include?(attr)
|
|
349
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
350
|
+
end
|
|
351
|
+
|
|
352
|
+
hash[param] = _to_hash(value)
|
|
353
|
+
end
|
|
354
|
+
hash
|
|
355
|
+
end
|
|
356
|
+
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
end
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Appnigma SDK API
|
|
3
|
+
|
|
4
|
+
#The routes a customer's product calls through an Appnigma SDK. Every answer carries a request id in X-Request-Id; quote it when you write to support.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 5.4.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.26.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
require 'time'
|
|
15
|
+
|
|
16
|
+
module Appnigma::Generated
|
|
17
|
+
class UpdateLogicOutput < ApiModelBase
|
|
18
|
+
# The draft's revision now; send it with the next save
|
|
19
|
+
attr_accessor :revision
|
|
20
|
+
|
|
21
|
+
# ISO 8601, in UTC
|
|
22
|
+
attr_accessor :updated_at
|
|
23
|
+
|
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
25
|
+
def self.attribute_map
|
|
26
|
+
{
|
|
27
|
+
:'revision' => :'revision',
|
|
28
|
+
:'updated_at' => :'updatedAt'
|
|
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
|
+
:'revision' => :'Integer',
|
|
46
|
+
:'updated_at' => :'String'
|
|
47
|
+
}
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# List of attributes with nullable: true
|
|
51
|
+
def self.openapi_nullable
|
|
52
|
+
Set.new([
|
|
53
|
+
])
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# Returns attribute type mapping
|
|
57
|
+
def self.acceptable_openapi_types
|
|
58
|
+
openapi_types
|
|
59
|
+
end
|
|
60
|
+
|
|
61
|
+
# Returns the nullable attributes
|
|
62
|
+
def self.acceptable_openapi_nullable
|
|
63
|
+
openapi_nullable
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
# Initializes the object
|
|
67
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
68
|
+
def initialize(attributes = {})
|
|
69
|
+
if (!attributes.is_a?(Hash))
|
|
70
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Appnigma::Generated::UpdateLogicOutput` initialize method"
|
|
71
|
+
end
|
|
72
|
+
|
|
73
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
|
74
|
+
acceptable_attribute_map = self.class.acceptable_attribute_map
|
|
75
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
|
76
|
+
if (!acceptable_attribute_map.key?(k.to_sym))
|
|
77
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Appnigma::Generated::UpdateLogicOutput`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
|
|
78
|
+
end
|
|
79
|
+
h[k.to_sym] = v
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
if attributes.key?(:'revision')
|
|
83
|
+
self.revision = attributes[:'revision']
|
|
84
|
+
else
|
|
85
|
+
self.revision = nil
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
if attributes.key?(:'updated_at')
|
|
89
|
+
self.updated_at = attributes[:'updated_at']
|
|
90
|
+
else
|
|
91
|
+
self.updated_at = nil
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
|
|
95
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
96
|
+
# @return Array for valid properties with the reasons
|
|
97
|
+
def list_invalid_properties
|
|
98
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
|
99
|
+
invalid_properties = Array.new
|
|
100
|
+
if @revision.nil?
|
|
101
|
+
invalid_properties.push('invalid value for "revision", revision cannot be nil.')
|
|
102
|
+
end
|
|
103
|
+
|
|
104
|
+
if @updated_at.nil?
|
|
105
|
+
invalid_properties.push('invalid value for "updated_at", updated_at cannot be nil.')
|
|
106
|
+
end
|
|
107
|
+
|
|
108
|
+
invalid_properties
|
|
109
|
+
end
|
|
110
|
+
|
|
111
|
+
# Check to see if the all the properties in the model are valid
|
|
112
|
+
# @return true if the model is valid
|
|
113
|
+
def valid?
|
|
114
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
|
115
|
+
return false if @revision.nil?
|
|
116
|
+
return false if @updated_at.nil?
|
|
117
|
+
true
|
|
118
|
+
end
|
|
119
|
+
|
|
120
|
+
# Custom attribute writer method with validation
|
|
121
|
+
# @param [Object] revision Value to be assigned
|
|
122
|
+
def revision=(revision)
|
|
123
|
+
if revision.nil?
|
|
124
|
+
fail ArgumentError, 'revision cannot be nil'
|
|
125
|
+
end
|
|
126
|
+
|
|
127
|
+
@revision = revision
|
|
128
|
+
end
|
|
129
|
+
|
|
130
|
+
# Custom attribute writer method with validation
|
|
131
|
+
# @param [Object] updated_at Value to be assigned
|
|
132
|
+
def updated_at=(updated_at)
|
|
133
|
+
if updated_at.nil?
|
|
134
|
+
fail ArgumentError, 'updated_at cannot be nil'
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
@updated_at = updated_at
|
|
138
|
+
end
|
|
139
|
+
|
|
140
|
+
# Checks equality by comparing each attribute.
|
|
141
|
+
# @param [Object] Object to be compared
|
|
142
|
+
def ==(o)
|
|
143
|
+
return true if self.equal?(o)
|
|
144
|
+
self.class == o.class &&
|
|
145
|
+
revision == o.revision &&
|
|
146
|
+
updated_at == o.updated_at
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# @see the `==` method
|
|
150
|
+
# @param [Object] Object to be compared
|
|
151
|
+
def eql?(o)
|
|
152
|
+
self == o
|
|
153
|
+
end
|
|
154
|
+
|
|
155
|
+
# Calculates hash code according to all attributes.
|
|
156
|
+
# @return [Integer] Hash code
|
|
157
|
+
def hash
|
|
158
|
+
[revision, updated_at].hash
|
|
159
|
+
end
|
|
160
|
+
|
|
161
|
+
# Builds the object from hash
|
|
162
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
163
|
+
# @return [Object] Returns the model itself
|
|
164
|
+
def self.build_from_hash(attributes)
|
|
165
|
+
return nil unless attributes.is_a?(Hash)
|
|
166
|
+
attributes = attributes.transform_keys(&:to_sym)
|
|
167
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
168
|
+
map = acceptable_attribute_map
|
|
169
|
+
transformed_hash = {}
|
|
170
|
+
acceptable_openapi_types.each_pair do |key, type|
|
|
171
|
+
if attributes.key?(map[key]) && attributes[map[key]].nil?
|
|
172
|
+
transformed_hash["#{key}"] = nil
|
|
173
|
+
elsif type =~ /\AArray<(.*)>/i
|
|
174
|
+
# check to ensure the input is an array given that the attribute
|
|
175
|
+
# is documented as an array but the input is not
|
|
176
|
+
if attributes[map[key]].is_a?(Array)
|
|
177
|
+
transformed_hash["#{key}"] = attributes[map[key]].map { |v| _deserialize($1, v) }
|
|
178
|
+
end
|
|
179
|
+
elsif !attributes[map[key]].nil?
|
|
180
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[map[key]])
|
|
181
|
+
end
|
|
182
|
+
end
|
|
183
|
+
new(transformed_hash)
|
|
184
|
+
end
|
|
185
|
+
|
|
186
|
+
# Returns the object in the form of hash
|
|
187
|
+
# @return [Hash] Returns the object in the form of hash
|
|
188
|
+
def to_hash
|
|
189
|
+
hash = {}
|
|
190
|
+
# include attributes inherited from allOf parents (the nearest declaration wins)
|
|
191
|
+
self.class.acceptable_attribute_map.each_pair do |attr, param|
|
|
192
|
+
value = self.send(attr)
|
|
193
|
+
if value.nil?
|
|
194
|
+
is_nullable = self.class.acceptable_openapi_nullable.include?(attr)
|
|
195
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
196
|
+
end
|
|
197
|
+
|
|
198
|
+
hash[param] = _to_hash(value)
|
|
199
|
+
end
|
|
200
|
+
hash
|
|
201
|
+
end
|
|
202
|
+
|
|
203
|
+
end
|
|
204
|
+
|
|
205
|
+
end
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
#The routes a customer's product calls through an Appnigma SDK. Every answer carries a request id in X-Request-Id; quote it when you write to support.
|
|
5
5
|
|
|
6
|
-
The version of the OpenAPI document: 4.0
|
|
6
|
+
The version of the OpenAPI document: 5.4.0
|
|
7
7
|
|
|
8
8
|
Generated by: https://openapi-generator.tech
|
|
9
9
|
Generator version: 7.26.0
|