ultracart_api 4.0.192 → 4.0.194

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f75a4023c4896f85b9fab94780bc01965ff7ded9785f45ed26f579f62830e944
4
- data.tar.gz: 622da61ea02f6f4f500a44f408945f24333825b2f9049996b4c7ba47ec4e4a3f
3
+ metadata.gz: 62cb34154ee2c02d4fed8962fb74ed0823b03e343c1acaebea18ad44bc59ddc8
4
+ data.tar.gz: 9925e0891e2c77605d2eeee39fa4579b8021a1f59426e6685e70648ca48610b5
5
5
  SHA512:
6
- metadata.gz: 4349dadeec282b50e2be29c393d1d7fb5c0e4ab76eba841a7efdfa8df064552672cb75f8a64c8838129ecfbd50adc12152888bf27255718a0073584fb97e4ee4
7
- data.tar.gz: f2619af246d6b4c947f2c147d756b09b0092268f91aae768e805d75761e0a5b976c4c63fb0acf29afe54309206291ab23699ff73cbdc35d54de5082e90b9492a
6
+ metadata.gz: 5d53b4d9864069679cc278a9fa0a3ebe8ee4729e9ce1b3ac718f95c284302a87a3d6fb177abb91f926ff3e048fa42f126b71cd412817dba651056afb9ae1b426
7
+ data.tar.gz: dfee6303b751ce955b07784ac7b1ff53974d2ad926f14ce1bc8819759bd915db4ab6dd318bf47cd530104e9efa4d41cfcca9794eb5c9298e57669394b931937b
data/README.md CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
7
7
  This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
8
8
 
9
9
  - API version: 2.0.0
10
- - Package version: 4.0.192
10
+ - Package version: 4.0.194
11
11
  - Build package: org.openapitools.codegen.languages.RubyClientCodegen
12
12
  For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
13
13
 
@@ -24,16 +24,16 @@ gem build ultracart_api.gemspec
24
24
  Then either install the gem locally:
25
25
 
26
26
  ```shell
27
- gem install ./ultracart_api-4.0.192.gem
27
+ gem install ./ultracart_api-4.0.194.gem
28
28
  ```
29
29
 
30
- (for development, run `gem install --dev ./ultracart_api-4.0.192.gem` to install the development dependencies)
30
+ (for development, run `gem install --dev ./ultracart_api-4.0.194.gem` to install the development dependencies)
31
31
 
32
32
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
33
33
 
34
34
  Finally add this to the Gemfile:
35
35
 
36
- gem 'ultracart_api', '~> 4.0.192'
36
+ gem 'ultracart_api', '~> 4.0.194'
37
37
 
38
38
  ### Install from Git
39
39
 
@@ -520,6 +520,7 @@ Class | Method | HTTP request | Description
520
520
  *UltracartClient::WebhookApi* | [**update_webhook**](docs/WebhookApi.md#update_webhook) | **PUT** /webhook/webhooks/{webhookOid} | Update a webhook
521
521
  *UltracartClient::WorkflowApi* | [**get_workflow_assignment_groups**](docs/WorkflowApi.md#get_workflow_assignment_groups) | **GET** /workflow/assignment_groups | Retrieve a list of groups that workflow tasks can be assigned to
522
522
  *UltracartClient::WorkflowApi* | [**get_workflow_assignment_users**](docs/WorkflowApi.md#get_workflow_assignment_users) | **GET** /workflow/assignment_users | Retrieve a list of users that workflow tasks can be assigned to
523
+ *UltracartClient::WorkflowApi* | [**get_workflow_me**](docs/WorkflowApi.md#get_workflow_me) | **GET** /workflow/me | Retrieve a user object for myself
523
524
  *UltracartClient::WorkflowApi* | [**get_workflow_task**](docs/WorkflowApi.md#get_workflow_task) | **GET** /workflow/tasks/{task_uuid} | Retrieve a workflow task
524
525
  *UltracartClient::WorkflowApi* | [**get_workflow_task_attachment_upload_url**](docs/WorkflowApi.md#get_workflow_task_attachment_upload_url) | **GET** /workflow/tasks/attachments/{extension} | Get a presigned workflow task attachment upload URL
525
526
  *UltracartClient::WorkflowApi* | [**get_workflow_task_by_object_type**](docs/WorkflowApi.md#get_workflow_task_by_object_type) | **GET** /workflow/tasks/by/{object_type}/{object_id} | Retrieve a workflow task by object type and id
@@ -1328,6 +1329,7 @@ Class | Method | HTTP request | Description
1328
1329
  - [UltracartClient::WorkflowTasksRequest](docs/WorkflowTasksRequest.md)
1329
1330
  - [UltracartClient::WorkflowTasksResponse](docs/WorkflowTasksResponse.md)
1330
1331
  - [UltracartClient::WorkflowUser](docs/WorkflowUser.md)
1332
+ - [UltracartClient::WorkflowUserResponse](docs/WorkflowUserResponse.md)
1331
1333
  - [UltracartClient::WorkflowUsersResponse](docs/WorkflowUsersResponse.md)
1332
1334
 
1333
1335
 
@@ -1404,6 +1406,8 @@ Not every change is committed to every SDK.
1404
1406
 
1405
1407
  | Version | Date | Comments |
1406
1408
  | --: | :-: | --- |
1409
+ | 4.0.194 | 12/15/2023 | bug fix on bad docs breaking yaml schema |
1410
+ | 4.0.193 | 12/12/2023 | webhook - added event ruler property |
1407
1411
  | 4.0.192 | 11/21/2023 | coupons - addl support on tiered amount/percent off items |
1408
1412
  | 4.0.191 | 11/20/2023 | coupon - add item tag support to percent off items and free shipping |
1409
1413
  | 4.0.190 | 11/20/2023 | item.google_product_search.color bugfix for bad length validation: 20 to 100 |
@@ -9,6 +9,7 @@
9
9
  | **discontinued_flag** | **Boolean** | True if the event is discontinued. See the API change log for details on migration details. | [optional] |
10
10
  | **event_description** | **String** | Description of the event | [optional] |
11
11
  | **event_name** | **String** | Event name | [optional] |
12
+ | **event_ruler** | **String** | Optional - Event ruler expression to filter events to. Only events that match this Ruler expression will be transmitted to the webhook. | [optional] |
12
13
  | **expansion** | **String** | The expand string for the notification object. See the individual resource _expand documentation for valid values. | [optional] |
13
14
  | **subscribed** | **Boolean** | True if this is event is subscribed to | [optional] |
14
15
  | **supports_reflow** | **Boolean** | True if the event can be triggered to reflow existing records | [optional] |
@@ -25,6 +26,7 @@ instance = UltracartClient::WebhookEventSubscription.new(
25
26
  discontinued_flag: null,
26
27
  event_description: null,
27
28
  event_name: null,
29
+ event_ruler: null,
28
30
  expansion: null,
29
31
  subscribed: null,
30
32
  supports_reflow: null,
data/docs/WorkflowApi.md CHANGED
@@ -6,6 +6,7 @@ All URIs are relative to *https://secure.ultracart.com/rest/v2*
6
6
  | ------ | ------------ | ----------- |
7
7
  | [**get_workflow_assignment_groups**](WorkflowApi.md#get_workflow_assignment_groups) | **GET** /workflow/assignment_groups | Retrieve a list of groups that workflow tasks can be assigned to |
8
8
  | [**get_workflow_assignment_users**](WorkflowApi.md#get_workflow_assignment_users) | **GET** /workflow/assignment_users | Retrieve a list of users that workflow tasks can be assigned to |
9
+ | [**get_workflow_me**](WorkflowApi.md#get_workflow_me) | **GET** /workflow/me | Retrieve a user object for myself |
9
10
  | [**get_workflow_task**](WorkflowApi.md#get_workflow_task) | **GET** /workflow/tasks/{task_uuid} | Retrieve a workflow task |
10
11
  | [**get_workflow_task_attachment_upload_url**](WorkflowApi.md#get_workflow_task_attachment_upload_url) | **GET** /workflow/tasks/attachments/{extension} | Get a presigned workflow task attachment upload URL |
11
12
  | [**get_workflow_task_by_object_type**](WorkflowApi.md#get_workflow_task_by_object_type) | **GET** /workflow/tasks/by/{object_type}/{object_id} | Retrieve a workflow task by object type and id |
@@ -164,6 +165,74 @@ end
164
165
  - **Accept**: application/json
165
166
 
166
167
 
168
+ ## get_workflow_me
169
+
170
+ > <WorkflowUserResponse> get_workflow_me
171
+
172
+ Retrieve a user object for myself
173
+
174
+ Retrieve a user object for myself
175
+
176
+ ### Examples
177
+
178
+ ```ruby
179
+ require 'time'
180
+ require 'ultracart_api'
181
+ require 'json'
182
+ require 'yaml'
183
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
184
+
185
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
186
+ # As such, this might not be the best way to use this object.
187
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
188
+
189
+ api = UltracartClient::WorkflowApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
190
+
191
+ begin
192
+ # Retrieve a user object for myself
193
+ result = api_instance.get_workflow_me
194
+ p result
195
+ rescue UltracartClient::ApiError => e
196
+ puts "Error when calling WorkflowApi->get_workflow_me: #{e}"
197
+ end
198
+ ```
199
+
200
+ #### Using the get_workflow_me_with_http_info variant
201
+
202
+ This returns an Array which contains the response data, status code and headers.
203
+
204
+ > <Array(<WorkflowUserResponse>, Integer, Hash)> get_workflow_me_with_http_info
205
+
206
+ ```ruby
207
+ begin
208
+ # Retrieve a user object for myself
209
+ data, status_code, headers = api_instance.get_workflow_me_with_http_info
210
+ p status_code # => 2xx
211
+ p headers # => { ... }
212
+ p data # => <WorkflowUserResponse>
213
+ rescue UltracartClient::ApiError => e
214
+ puts "Error when calling WorkflowApi->get_workflow_me_with_http_info: #{e}"
215
+ end
216
+ ```
217
+
218
+ ### Parameters
219
+
220
+ This endpoint does not need any parameter.
221
+
222
+ ### Return type
223
+
224
+ [**WorkflowUserResponse**](WorkflowUserResponse.md)
225
+
226
+ ### Authorization
227
+
228
+ [ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
229
+
230
+ ### HTTP request headers
231
+
232
+ - **Content-Type**: Not defined
233
+ - **Accept**: application/json
234
+
235
+
167
236
  ## get_workflow_task
168
237
 
169
238
  > <WorkflowTaskResponse> get_workflow_task(task_uuid)
@@ -0,0 +1,26 @@
1
+ # UltracartClient::WorkflowUserResponse
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **error** | [**Error**](Error.md) | | [optional] |
8
+ | **metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional] |
9
+ | **success** | **Boolean** | Indicates if API call was successful | [optional] |
10
+ | **user** | [**WorkflowUser**](WorkflowUser.md) | | [optional] |
11
+ | **warning** | [**Warning**](Warning.md) | | [optional] |
12
+
13
+ ## Example
14
+
15
+ ```ruby
16
+ require 'ultracart_api'
17
+
18
+ instance = UltracartClient::WorkflowUserResponse.new(
19
+ error: null,
20
+ metadata: null,
21
+ success: null,
22
+ user: null,
23
+ warning: null
24
+ )
25
+ ```
26
+
@@ -160,6 +160,64 @@ module UltracartClient
160
160
  return data, status_code, headers
161
161
  end
162
162
 
163
+ # Retrieve a user object for myself
164
+ # Retrieve a user object for myself
165
+ # @param [Hash] opts the optional parameters
166
+ # @return [WorkflowUserResponse]
167
+ def get_workflow_me(opts = {})
168
+ data, _status_code, _headers = get_workflow_me_with_http_info(opts)
169
+ data
170
+ end
171
+
172
+ # Retrieve a user object for myself
173
+ # Retrieve a user object for myself
174
+ # @param [Hash] opts the optional parameters
175
+ # @return [Array<(WorkflowUserResponse, Integer, Hash)>] WorkflowUserResponse data, response status code and response headers
176
+ def get_workflow_me_with_http_info(opts = {})
177
+ if @api_client.config.debugging
178
+ @api_client.config.logger.debug 'Calling API: WorkflowApi.get_workflow_me ...'
179
+ end
180
+ # resource path
181
+ local_var_path = '/workflow/me'
182
+
183
+ # query parameters
184
+ query_params = opts[:query_params] || {}
185
+
186
+ # header parameters
187
+ header_params = opts[:header_params] || {}
188
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
189
+ # HTTP header 'Accept' (if needed)
190
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
191
+
192
+ # form parameters
193
+ form_params = opts[:form_params] || {}
194
+
195
+ # http body (model)
196
+ post_body = opts[:debug_body]
197
+
198
+ # return_type
199
+ return_type = opts[:debug_return_type] || 'WorkflowUserResponse'
200
+
201
+ # auth_names
202
+ auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
203
+
204
+ new_options = opts.merge(
205
+ :operation => :"WorkflowApi.get_workflow_me",
206
+ :header_params => header_params,
207
+ :query_params => query_params,
208
+ :form_params => form_params,
209
+ :body => post_body,
210
+ :auth_names => auth_names,
211
+ :return_type => return_type
212
+ )
213
+
214
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
215
+ if @api_client.config.debugging
216
+ @api_client.config.logger.debug "API called: WorkflowApi#get_workflow_me\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
217
+ end
218
+ return data, status_code, headers
219
+ end
220
+
163
221
  # Retrieve a workflow task
164
222
  # Retrieve a workflow task
165
223
  # @param task_uuid [String]
@@ -30,6 +30,9 @@ module UltracartClient
30
30
  # Event name
31
31
  attr_accessor :event_name
32
32
 
33
+ # Optional - Event ruler expression to filter events to. Only events that match this Ruler expression will be transmitted to the webhook.
34
+ attr_accessor :event_ruler
35
+
33
36
  # The expand string for the notification object. See the individual resource _expand documentation for valid values.
34
37
  attr_accessor :expansion
35
38
 
@@ -50,6 +53,7 @@ module UltracartClient
50
53
  :'discontinued_flag' => :'discontinued_flag',
51
54
  :'event_description' => :'event_description',
52
55
  :'event_name' => :'event_name',
56
+ :'event_ruler' => :'event_ruler',
53
57
  :'expansion' => :'expansion',
54
58
  :'subscribed' => :'subscribed',
55
59
  :'supports_reflow' => :'supports_reflow',
@@ -70,6 +74,7 @@ module UltracartClient
70
74
  :'discontinued_flag' => :'Boolean',
71
75
  :'event_description' => :'String',
72
76
  :'event_name' => :'String',
77
+ :'event_ruler' => :'String',
73
78
  :'expansion' => :'String',
74
79
  :'subscribed' => :'Boolean',
75
80
  :'supports_reflow' => :'Boolean',
@@ -118,6 +123,10 @@ module UltracartClient
118
123
  self.event_name = attributes[:'event_name']
119
124
  end
120
125
 
126
+ if attributes.key?(:'event_ruler')
127
+ self.event_ruler = attributes[:'event_ruler']
128
+ end
129
+
121
130
  if attributes.key?(:'expansion')
122
131
  self.expansion = attributes[:'expansion']
123
132
  end
@@ -158,6 +167,7 @@ module UltracartClient
158
167
  discontinued_flag == o.discontinued_flag &&
159
168
  event_description == o.event_description &&
160
169
  event_name == o.event_name &&
170
+ event_ruler == o.event_ruler &&
161
171
  expansion == o.expansion &&
162
172
  subscribed == o.subscribed &&
163
173
  supports_reflow == o.supports_reflow &&
@@ -173,7 +183,7 @@ module UltracartClient
173
183
  # Calculates hash code according to all attributes.
174
184
  # @return [Integer] Hash code
175
185
  def hash
176
- [comments, deprecated_flag, discontinued_flag, event_description, event_name, expansion, subscribed, supports_reflow, webhook_event_oid].hash
186
+ [comments, deprecated_flag, discontinued_flag, event_description, event_name, event_ruler, expansion, subscribed, supports_reflow, webhook_event_oid].hash
177
187
  end
178
188
 
179
189
  # Builds the object from hash
@@ -0,0 +1,256 @@
1
+ =begin
2
+ #UltraCart Rest API V2
3
+
4
+ #UltraCart REST API Version 2
5
+
6
+ The version of the OpenAPI document: 2.0.0
7
+ Contact: support@ultracart.com
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.0.1-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module UltracartClient
17
+ class WorkflowUserResponse
18
+ attr_accessor :error
19
+
20
+ attr_accessor :metadata
21
+
22
+ # Indicates if API call was successful
23
+ attr_accessor :success
24
+
25
+ attr_accessor :user
26
+
27
+ attr_accessor :warning
28
+
29
+ # Attribute mapping from ruby-style variable name to JSON key.
30
+ def self.attribute_map
31
+ {
32
+ :'error' => :'error',
33
+ :'metadata' => :'metadata',
34
+ :'success' => :'success',
35
+ :'user' => :'user',
36
+ :'warning' => :'warning'
37
+ }
38
+ end
39
+
40
+ # Returns all the JSON keys this model knows about
41
+ def self.acceptable_attributes
42
+ attribute_map.values
43
+ end
44
+
45
+ # Attribute type mapping.
46
+ def self.openapi_types
47
+ {
48
+ :'error' => :'Error',
49
+ :'metadata' => :'ResponseMetadata',
50
+ :'success' => :'Boolean',
51
+ :'user' => :'WorkflowUser',
52
+ :'warning' => :'Warning'
53
+ }
54
+ end
55
+
56
+ # List of attributes with nullable: true
57
+ def self.openapi_nullable
58
+ Set.new([
59
+ ])
60
+ end
61
+
62
+ # Initializes the object
63
+ # @param [Hash] attributes Model attributes in the form of hash
64
+ def initialize(attributes = {})
65
+ if (!attributes.is_a?(Hash))
66
+ fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::WorkflowUserResponse` initialize method"
67
+ end
68
+
69
+ # check to see if the attribute exists and convert string to symbol for hash key
70
+ attributes = attributes.each_with_object({}) { |(k, v), h|
71
+ if (!self.class.attribute_map.key?(k.to_sym))
72
+ fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::WorkflowUserResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
73
+ end
74
+ h[k.to_sym] = v
75
+ }
76
+
77
+ if attributes.key?(:'error')
78
+ self.error = attributes[:'error']
79
+ end
80
+
81
+ if attributes.key?(:'metadata')
82
+ self.metadata = attributes[:'metadata']
83
+ end
84
+
85
+ if attributes.key?(:'success')
86
+ self.success = attributes[:'success']
87
+ end
88
+
89
+ if attributes.key?(:'user')
90
+ self.user = attributes[:'user']
91
+ end
92
+
93
+ if attributes.key?(:'warning')
94
+ self.warning = attributes[:'warning']
95
+ end
96
+ end
97
+
98
+ # Show invalid properties with the reasons. Usually used together with valid?
99
+ # @return Array for valid properties with the reasons
100
+ def list_invalid_properties
101
+ invalid_properties = Array.new
102
+ invalid_properties
103
+ end
104
+
105
+ # Check to see if the all the properties in the model are valid
106
+ # @return true if the model is valid
107
+ def valid?
108
+ true
109
+ end
110
+
111
+ # Checks equality by comparing each attribute.
112
+ # @param [Object] Object to be compared
113
+ def ==(o)
114
+ return true if self.equal?(o)
115
+ self.class == o.class &&
116
+ error == o.error &&
117
+ metadata == o.metadata &&
118
+ success == o.success &&
119
+ user == o.user &&
120
+ warning == o.warning
121
+ end
122
+
123
+ # @see the `==` method
124
+ # @param [Object] Object to be compared
125
+ def eql?(o)
126
+ self == o
127
+ end
128
+
129
+ # Calculates hash code according to all attributes.
130
+ # @return [Integer] Hash code
131
+ def hash
132
+ [error, metadata, success, user, warning].hash
133
+ end
134
+
135
+ # Builds the object from hash
136
+ # @param [Hash] attributes Model attributes in the form of hash
137
+ # @return [Object] Returns the model itself
138
+ def self.build_from_hash(attributes)
139
+ new.build_from_hash(attributes)
140
+ end
141
+
142
+ # Builds the object from hash
143
+ # @param [Hash] attributes Model attributes in the form of hash
144
+ # @return [Object] Returns the model itself
145
+ def build_from_hash(attributes)
146
+ return nil unless attributes.is_a?(Hash)
147
+ attributes = attributes.transform_keys(&:to_sym)
148
+ self.class.openapi_types.each_pair do |key, type|
149
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
150
+ self.send("#{key}=", nil)
151
+ elsif type =~ /\AArray<(.*)>/i
152
+ # check to ensure the input is an array given that the attribute
153
+ # is documented as an array but the input is not
154
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
155
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
156
+ end
157
+ elsif !attributes[self.class.attribute_map[key]].nil?
158
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
159
+ end
160
+ end
161
+
162
+ self
163
+ end
164
+
165
+ # Deserializes the data based on type
166
+ # @param string type Data type
167
+ # @param string value Value to be deserialized
168
+ # @return [Object] Deserialized data
169
+ def _deserialize(type, value)
170
+ case type.to_sym
171
+ when :Time
172
+ Time.parse(value)
173
+ when :Date
174
+ Date.parse(value)
175
+ when :String
176
+ value.to_s
177
+ when :Integer
178
+ value.to_i
179
+ when :Float
180
+ value.to_f
181
+ when :Boolean
182
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
183
+ true
184
+ else
185
+ false
186
+ end
187
+ when :Object
188
+ # generic object (usually a Hash), return directly
189
+ value
190
+ when /\AArray<(?<inner_type>.+)>\z/
191
+ inner_type = Regexp.last_match[:inner_type]
192
+ value.map { |v| _deserialize(inner_type, v) }
193
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
194
+ k_type = Regexp.last_match[:k_type]
195
+ v_type = Regexp.last_match[:v_type]
196
+ {}.tap do |hash|
197
+ value.each do |k, v|
198
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
199
+ end
200
+ end
201
+ else # model
202
+ # models (e.g. Pet) or oneOf
203
+ klass = UltracartClient.const_get(type)
204
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
205
+ end
206
+ end
207
+
208
+ # Returns the string representation of the object
209
+ # @return [String] String presentation of the object
210
+ def to_s
211
+ to_hash.to_s
212
+ end
213
+
214
+ # to_body is an alias to to_hash (backward compatibility)
215
+ # @return [Hash] Returns the object in the form of hash
216
+ def to_body
217
+ to_hash
218
+ end
219
+
220
+ # Returns the object in the form of hash
221
+ # @return [Hash] Returns the object in the form of hash
222
+ def to_hash
223
+ hash = {}
224
+ self.class.attribute_map.each_pair do |attr, param|
225
+ value = self.send(attr)
226
+ if value.nil?
227
+ is_nullable = self.class.openapi_nullable.include?(attr)
228
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
229
+ end
230
+
231
+ hash[param] = _to_hash(value)
232
+ end
233
+ hash
234
+ end
235
+
236
+ # Outputs non-array value in the form of hash
237
+ # For object, use to_hash. Otherwise, just return the value
238
+ # @param [Object] value Any valid value
239
+ # @return [Hash] Returns the value in the form of hash
240
+ def _to_hash(value)
241
+ if value.is_a?(Array)
242
+ value.compact.map { |v| _to_hash(v) }
243
+ elsif value.is_a?(Hash)
244
+ {}.tap do |hash|
245
+ value.each { |k, v| hash[k] = _to_hash(v) }
246
+ end
247
+ elsif value.respond_to? :to_hash
248
+ value.to_hash
249
+ else
250
+ value
251
+ end
252
+ end
253
+
254
+ end
255
+
256
+ end
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.1-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '4.0.192'
14
+ VERSION = '4.0.194'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -815,6 +815,7 @@ require 'ultracart_api/models/workflow_task_response'
815
815
  require 'ultracart_api/models/workflow_tasks_request'
816
816
  require 'ultracart_api/models/workflow_tasks_response'
817
817
  require 'ultracart_api/models/workflow_user'
818
+ require 'ultracart_api/models/workflow_user_response'
818
819
  require 'ultracart_api/models/workflow_users_response'
819
820
 
820
821
  # APIs
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ultracart_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.192
4
+ version: 4.0.194
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-21 00:00:00.000000000 Z
11
+ date: 2023-12-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -880,6 +880,7 @@ files:
880
880
  - docs/WorkflowTasksRequest.md
881
881
  - docs/WorkflowTasksResponse.md
882
882
  - docs/WorkflowUser.md
883
+ - docs/WorkflowUserResponse.md
883
884
  - docs/WorkflowUsersResponse.md
884
885
  - git_push.sh
885
886
  - lib/ultracart_api.rb
@@ -1705,6 +1706,7 @@ files:
1705
1706
  - lib/ultracart_api/models/workflow_tasks_request.rb
1706
1707
  - lib/ultracart_api/models/workflow_tasks_response.rb
1707
1708
  - lib/ultracart_api/models/workflow_user.rb
1709
+ - lib/ultracart_api/models/workflow_user_response.rb
1708
1710
  - lib/ultracart_api/models/workflow_users_response.rb
1709
1711
  - lib/ultracart_api/version.rb
1710
1712
  - spec/api_client_spec.rb