ultracart_api 4.0.204 → 4.0.205
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +7 -4
- data/docs/WorkflowApi.md +69 -0
- data/docs/WorkflowTaskOpenCountResponse.md +26 -0
- data/docs/WorkflowUsersResponse.md +2 -0
- data/lib/ultracart_api/api/workflow_api.rb +58 -0
- data/lib/ultracart_api/models/workflow_task_open_count_response.rb +257 -0
- data/lib/ultracart_api/models/workflow_users_response.rb +11 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +1 -0
- metadata +3 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2c97ffce8e30d6e1cd3674d587a4141c7621a5cb74ac0eb63bcaff320a3eb75b
|
4
|
+
data.tar.gz: bb257658c5852df73047f5620743da7e74b0f61e058923438976856a910882e6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d3919d841c4dc6c2b115afe2e6ce9636908d88aeada0f84019ccc41e82d1261b5d8c1bbe57f01f156c1b65ffbb4a6cf0d00a8474e7c2318300e29581e2e2ece5
|
7
|
+
data.tar.gz: c6cd847a966df100e03531c3b4044afb603971faa76430d905e39ab9eaae752b9784484ccecc1aa13312839cabee6b9a1673486f3ce0e57279d590cc836e619b
|
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.
|
10
|
+
- Package version: 4.0.205
|
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.
|
27
|
+
gem install ./ultracart_api-4.0.205.gem
|
28
28
|
```
|
29
29
|
|
30
|
-
(for development, run `gem install --dev ./ultracart_api-4.0.
|
30
|
+
(for development, run `gem install --dev ./ultracart_api-4.0.205.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.
|
36
|
+
gem 'ultracart_api', '~> 4.0.205'
|
37
37
|
|
38
38
|
### Install from Git
|
39
39
|
|
@@ -570,6 +570,7 @@ Class | Method | HTTP request | Description
|
|
570
570
|
*UltracartClient::WorkflowApi* | [**get_workflow_task**](docs/WorkflowApi.md#get_workflow_task) | **GET** /workflow/tasks/{task_uuid} | Retrieve a workflow task
|
571
571
|
*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
|
572
572
|
*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
|
573
|
+
*UltracartClient::WorkflowApi* | [**get_workflow_task_open_count**](docs/WorkflowApi.md#get_workflow_task_open_count) | **GET** /workflow/tasks/open_count | Retrieve workflow task open count
|
573
574
|
*UltracartClient::WorkflowApi* | [**get_workflow_task_tags**](docs/WorkflowApi.md#get_workflow_task_tags) | **GET** /workflow/tasks/tags | Get a list of existing workflow task tags
|
574
575
|
*UltracartClient::WorkflowApi* | [**get_workflow_tasks**](docs/WorkflowApi.md#get_workflow_tasks) | **POST** /workflow/tasks/search | Search workflow tasks
|
575
576
|
*UltracartClient::WorkflowApi* | [**insert_workflow_task**](docs/WorkflowApi.md#insert_workflow_task) | **POST** /workflow/tasks | Insert a workflow task
|
@@ -1410,6 +1411,7 @@ Class | Method | HTTP request | Description
|
|
1410
1411
|
- [UltracartClient::WorkflowNote](docs/WorkflowNote.md)
|
1411
1412
|
- [UltracartClient::WorkflowTask](docs/WorkflowTask.md)
|
1412
1413
|
- [UltracartClient::WorkflowTaskHistory](docs/WorkflowTaskHistory.md)
|
1414
|
+
- [UltracartClient::WorkflowTaskOpenCountResponse](docs/WorkflowTaskOpenCountResponse.md)
|
1413
1415
|
- [UltracartClient::WorkflowTaskResponse](docs/WorkflowTaskResponse.md)
|
1414
1416
|
- [UltracartClient::WorkflowTaskTagsResponse](docs/WorkflowTaskTagsResponse.md)
|
1415
1417
|
- [UltracartClient::WorkflowTasksRequest](docs/WorkflowTasksRequest.md)
|
@@ -1492,6 +1494,7 @@ Not every change is committed to every SDK.
|
|
1492
1494
|
|
1493
1495
|
| Version | Date | Comments |
|
1494
1496
|
| --: | :-: | --- |
|
1497
|
+
| 4.0.205 | 03/19/2024 | workflow task - method to obtain open task count |
|
1495
1498
|
| 4.0.204 | 03/19/2024 | workflow task - addl status values, expiration_dts, and system task type |
|
1496
1499
|
| 4.0.203 | 03/15/2024 | workflow - getWorkflowAgentWebsocketAuthorization method added |
|
1497
1500
|
| 4.0.202 | 03/08/2024 | added getWorkflowTaskTags method |
|
data/docs/WorkflowApi.md
CHANGED
@@ -11,6 +11,7 @@ All URIs are relative to *https://secure.ultracart.com/rest/v2*
|
|
11
11
|
| [**get_workflow_task**](WorkflowApi.md#get_workflow_task) | **GET** /workflow/tasks/{task_uuid} | Retrieve a workflow task |
|
12
12
|
| [**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 |
|
13
13
|
| [**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 |
|
14
|
+
| [**get_workflow_task_open_count**](WorkflowApi.md#get_workflow_task_open_count) | **GET** /workflow/tasks/open_count | Retrieve workflow task open count |
|
14
15
|
| [**get_workflow_task_tags**](WorkflowApi.md#get_workflow_task_tags) | **GET** /workflow/tasks/tags | Get a list of existing workflow task tags |
|
15
16
|
| [**get_workflow_tasks**](WorkflowApi.md#get_workflow_tasks) | **POST** /workflow/tasks/search | Search workflow tasks |
|
16
17
|
| [**insert_workflow_task**](WorkflowApi.md#insert_workflow_task) | **POST** /workflow/tasks | Insert a workflow task |
|
@@ -518,6 +519,74 @@ end
|
|
518
519
|
- **Accept**: application/json
|
519
520
|
|
520
521
|
|
522
|
+
## get_workflow_task_open_count
|
523
|
+
|
524
|
+
> <WorkflowTaskOpenCountResponse> get_workflow_task_open_count
|
525
|
+
|
526
|
+
Retrieve workflow task open count
|
527
|
+
|
528
|
+
Retrieve workflow task open count
|
529
|
+
|
530
|
+
### Examples
|
531
|
+
|
532
|
+
```ruby
|
533
|
+
require 'time'
|
534
|
+
require 'ultracart_api'
|
535
|
+
require 'json'
|
536
|
+
require 'yaml'
|
537
|
+
require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
|
538
|
+
|
539
|
+
# This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
|
540
|
+
# As such, this might not be the best way to use this object.
|
541
|
+
# Please see https://github.com/UltraCart/sdk_samples for working examples.
|
542
|
+
|
543
|
+
api = UltracartClient::WorkflowApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
|
544
|
+
|
545
|
+
begin
|
546
|
+
# Retrieve workflow task open count
|
547
|
+
result = api_instance.get_workflow_task_open_count
|
548
|
+
p result
|
549
|
+
rescue UltracartClient::ApiError => e
|
550
|
+
puts "Error when calling WorkflowApi->get_workflow_task_open_count: #{e}"
|
551
|
+
end
|
552
|
+
```
|
553
|
+
|
554
|
+
#### Using the get_workflow_task_open_count_with_http_info variant
|
555
|
+
|
556
|
+
This returns an Array which contains the response data, status code and headers.
|
557
|
+
|
558
|
+
> <Array(<WorkflowTaskOpenCountResponse>, Integer, Hash)> get_workflow_task_open_count_with_http_info
|
559
|
+
|
560
|
+
```ruby
|
561
|
+
begin
|
562
|
+
# Retrieve workflow task open count
|
563
|
+
data, status_code, headers = api_instance.get_workflow_task_open_count_with_http_info
|
564
|
+
p status_code # => 2xx
|
565
|
+
p headers # => { ... }
|
566
|
+
p data # => <WorkflowTaskOpenCountResponse>
|
567
|
+
rescue UltracartClient::ApiError => e
|
568
|
+
puts "Error when calling WorkflowApi->get_workflow_task_open_count_with_http_info: #{e}"
|
569
|
+
end
|
570
|
+
```
|
571
|
+
|
572
|
+
### Parameters
|
573
|
+
|
574
|
+
This endpoint does not need any parameter.
|
575
|
+
|
576
|
+
### Return type
|
577
|
+
|
578
|
+
[**WorkflowTaskOpenCountResponse**](WorkflowTaskOpenCountResponse.md)
|
579
|
+
|
580
|
+
### Authorization
|
581
|
+
|
582
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
583
|
+
|
584
|
+
### HTTP request headers
|
585
|
+
|
586
|
+
- **Content-Type**: Not defined
|
587
|
+
- **Accept**: application/json
|
588
|
+
|
589
|
+
|
521
590
|
## get_workflow_task_tags
|
522
591
|
|
523
592
|
> <WorkflowTaskTagsResponse> get_workflow_task_tags
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# UltracartClient::WorkflowTaskOpenCountResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **error** | [**Error**](Error.md) | | [optional] |
|
8
|
+
| **metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional] |
|
9
|
+
| **open_count** | **Integer** | Open Task Count | [optional] |
|
10
|
+
| **success** | **Boolean** | Indicates if API call was successful | [optional] |
|
11
|
+
| **warning** | [**Warning**](Warning.md) | | [optional] |
|
12
|
+
|
13
|
+
## Example
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
require 'ultracart_api'
|
17
|
+
|
18
|
+
instance = UltracartClient::WorkflowTaskOpenCountResponse.new(
|
19
|
+
error: null,
|
20
|
+
metadata: null,
|
21
|
+
open_count: null,
|
22
|
+
success: null,
|
23
|
+
warning: null
|
24
|
+
)
|
25
|
+
```
|
26
|
+
|
@@ -6,6 +6,7 @@
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **error** | [**Error**](Error.md) | | [optional] |
|
8
8
|
| **metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional] |
|
9
|
+
| **my_user_id** | **Integer** | User ID of myself | [optional] |
|
9
10
|
| **success** | **Boolean** | Indicates if API call was successful | [optional] |
|
10
11
|
| **users** | [**Array<WorkflowUser>**](WorkflowUser.md) | users | [optional] |
|
11
12
|
| **warning** | [**Warning**](Warning.md) | | [optional] |
|
@@ -18,6 +19,7 @@ require 'ultracart_api'
|
|
18
19
|
instance = UltracartClient::WorkflowUsersResponse.new(
|
19
20
|
error: null,
|
20
21
|
metadata: null,
|
22
|
+
my_user_id: null,
|
21
23
|
success: null,
|
22
24
|
users: null,
|
23
25
|
warning: null
|
@@ -474,6 +474,64 @@ module UltracartClient
|
|
474
474
|
return data, status_code, headers
|
475
475
|
end
|
476
476
|
|
477
|
+
# Retrieve workflow task open count
|
478
|
+
# Retrieve workflow task open count
|
479
|
+
# @param [Hash] opts the optional parameters
|
480
|
+
# @return [WorkflowTaskOpenCountResponse]
|
481
|
+
def get_workflow_task_open_count(opts = {})
|
482
|
+
data, _status_code, _headers = get_workflow_task_open_count_with_http_info(opts)
|
483
|
+
data
|
484
|
+
end
|
485
|
+
|
486
|
+
# Retrieve workflow task open count
|
487
|
+
# Retrieve workflow task open count
|
488
|
+
# @param [Hash] opts the optional parameters
|
489
|
+
# @return [Array<(WorkflowTaskOpenCountResponse, Integer, Hash)>] WorkflowTaskOpenCountResponse data, response status code and response headers
|
490
|
+
def get_workflow_task_open_count_with_http_info(opts = {})
|
491
|
+
if @api_client.config.debugging
|
492
|
+
@api_client.config.logger.debug 'Calling API: WorkflowApi.get_workflow_task_open_count ...'
|
493
|
+
end
|
494
|
+
# resource path
|
495
|
+
local_var_path = '/workflow/tasks/open_count'
|
496
|
+
|
497
|
+
# query parameters
|
498
|
+
query_params = opts[:query_params] || {}
|
499
|
+
|
500
|
+
# header parameters
|
501
|
+
header_params = opts[:header_params] || {}
|
502
|
+
header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
|
503
|
+
# HTTP header 'Accept' (if needed)
|
504
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
505
|
+
|
506
|
+
# form parameters
|
507
|
+
form_params = opts[:form_params] || {}
|
508
|
+
|
509
|
+
# http body (model)
|
510
|
+
post_body = opts[:debug_body]
|
511
|
+
|
512
|
+
# return_type
|
513
|
+
return_type = opts[:debug_return_type] || 'WorkflowTaskOpenCountResponse'
|
514
|
+
|
515
|
+
# auth_names
|
516
|
+
auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
|
517
|
+
|
518
|
+
new_options = opts.merge(
|
519
|
+
:operation => :"WorkflowApi.get_workflow_task_open_count",
|
520
|
+
:header_params => header_params,
|
521
|
+
:query_params => query_params,
|
522
|
+
:form_params => form_params,
|
523
|
+
:body => post_body,
|
524
|
+
:auth_names => auth_names,
|
525
|
+
:return_type => return_type
|
526
|
+
)
|
527
|
+
|
528
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
529
|
+
if @api_client.config.debugging
|
530
|
+
@api_client.config.logger.debug "API called: WorkflowApi#get_workflow_task_open_count\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
531
|
+
end
|
532
|
+
return data, status_code, headers
|
533
|
+
end
|
534
|
+
|
477
535
|
# Get a list of existing workflow task tags
|
478
536
|
# Retrieves a unique list of all the existing workflow task tags.
|
479
537
|
# @param [Hash] opts the optional parameters
|
@@ -0,0 +1,257 @@
|
|
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 WorkflowTaskOpenCountResponse
|
18
|
+
attr_accessor :error
|
19
|
+
|
20
|
+
attr_accessor :metadata
|
21
|
+
|
22
|
+
# Open Task Count
|
23
|
+
attr_accessor :open_count
|
24
|
+
|
25
|
+
# Indicates if API call was successful
|
26
|
+
attr_accessor :success
|
27
|
+
|
28
|
+
attr_accessor :warning
|
29
|
+
|
30
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
31
|
+
def self.attribute_map
|
32
|
+
{
|
33
|
+
:'error' => :'error',
|
34
|
+
:'metadata' => :'metadata',
|
35
|
+
:'open_count' => :'open_count',
|
36
|
+
:'success' => :'success',
|
37
|
+
:'warning' => :'warning'
|
38
|
+
}
|
39
|
+
end
|
40
|
+
|
41
|
+
# Returns all the JSON keys this model knows about
|
42
|
+
def self.acceptable_attributes
|
43
|
+
attribute_map.values
|
44
|
+
end
|
45
|
+
|
46
|
+
# Attribute type mapping.
|
47
|
+
def self.openapi_types
|
48
|
+
{
|
49
|
+
:'error' => :'Error',
|
50
|
+
:'metadata' => :'ResponseMetadata',
|
51
|
+
:'open_count' => :'Integer',
|
52
|
+
:'success' => :'Boolean',
|
53
|
+
:'warning' => :'Warning'
|
54
|
+
}
|
55
|
+
end
|
56
|
+
|
57
|
+
# List of attributes with nullable: true
|
58
|
+
def self.openapi_nullable
|
59
|
+
Set.new([
|
60
|
+
])
|
61
|
+
end
|
62
|
+
|
63
|
+
# Initializes the object
|
64
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
65
|
+
def initialize(attributes = {})
|
66
|
+
if (!attributes.is_a?(Hash))
|
67
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::WorkflowTaskOpenCountResponse` initialize method"
|
68
|
+
end
|
69
|
+
|
70
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
71
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
72
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
73
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::WorkflowTaskOpenCountResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
74
|
+
end
|
75
|
+
h[k.to_sym] = v
|
76
|
+
}
|
77
|
+
|
78
|
+
if attributes.key?(:'error')
|
79
|
+
self.error = attributes[:'error']
|
80
|
+
end
|
81
|
+
|
82
|
+
if attributes.key?(:'metadata')
|
83
|
+
self.metadata = attributes[:'metadata']
|
84
|
+
end
|
85
|
+
|
86
|
+
if attributes.key?(:'open_count')
|
87
|
+
self.open_count = attributes[:'open_count']
|
88
|
+
end
|
89
|
+
|
90
|
+
if attributes.key?(:'success')
|
91
|
+
self.success = attributes[:'success']
|
92
|
+
end
|
93
|
+
|
94
|
+
if attributes.key?(:'warning')
|
95
|
+
self.warning = attributes[:'warning']
|
96
|
+
end
|
97
|
+
end
|
98
|
+
|
99
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
100
|
+
# @return Array for valid properties with the reasons
|
101
|
+
def list_invalid_properties
|
102
|
+
invalid_properties = Array.new
|
103
|
+
invalid_properties
|
104
|
+
end
|
105
|
+
|
106
|
+
# Check to see if the all the properties in the model are valid
|
107
|
+
# @return true if the model is valid
|
108
|
+
def valid?
|
109
|
+
true
|
110
|
+
end
|
111
|
+
|
112
|
+
# Checks equality by comparing each attribute.
|
113
|
+
# @param [Object] Object to be compared
|
114
|
+
def ==(o)
|
115
|
+
return true if self.equal?(o)
|
116
|
+
self.class == o.class &&
|
117
|
+
error == o.error &&
|
118
|
+
metadata == o.metadata &&
|
119
|
+
open_count == o.open_count &&
|
120
|
+
success == o.success &&
|
121
|
+
warning == o.warning
|
122
|
+
end
|
123
|
+
|
124
|
+
# @see the `==` method
|
125
|
+
# @param [Object] Object to be compared
|
126
|
+
def eql?(o)
|
127
|
+
self == o
|
128
|
+
end
|
129
|
+
|
130
|
+
# Calculates hash code according to all attributes.
|
131
|
+
# @return [Integer] Hash code
|
132
|
+
def hash
|
133
|
+
[error, metadata, open_count, success, warning].hash
|
134
|
+
end
|
135
|
+
|
136
|
+
# Builds the object from hash
|
137
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
138
|
+
# @return [Object] Returns the model itself
|
139
|
+
def self.build_from_hash(attributes)
|
140
|
+
new.build_from_hash(attributes)
|
141
|
+
end
|
142
|
+
|
143
|
+
# Builds the object from hash
|
144
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
145
|
+
# @return [Object] Returns the model itself
|
146
|
+
def build_from_hash(attributes)
|
147
|
+
return nil unless attributes.is_a?(Hash)
|
148
|
+
attributes = attributes.transform_keys(&:to_sym)
|
149
|
+
self.class.openapi_types.each_pair do |key, type|
|
150
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
151
|
+
self.send("#{key}=", nil)
|
152
|
+
elsif type =~ /\AArray<(.*)>/i
|
153
|
+
# check to ensure the input is an array given that the attribute
|
154
|
+
# is documented as an array but the input is not
|
155
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
156
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
157
|
+
end
|
158
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
159
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
160
|
+
end
|
161
|
+
end
|
162
|
+
|
163
|
+
self
|
164
|
+
end
|
165
|
+
|
166
|
+
# Deserializes the data based on type
|
167
|
+
# @param string type Data type
|
168
|
+
# @param string value Value to be deserialized
|
169
|
+
# @return [Object] Deserialized data
|
170
|
+
def _deserialize(type, value)
|
171
|
+
case type.to_sym
|
172
|
+
when :Time
|
173
|
+
Time.parse(value)
|
174
|
+
when :Date
|
175
|
+
Date.parse(value)
|
176
|
+
when :String
|
177
|
+
value.to_s
|
178
|
+
when :Integer
|
179
|
+
value.to_i
|
180
|
+
when :Float
|
181
|
+
value.to_f
|
182
|
+
when :Boolean
|
183
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
184
|
+
true
|
185
|
+
else
|
186
|
+
false
|
187
|
+
end
|
188
|
+
when :Object
|
189
|
+
# generic object (usually a Hash), return directly
|
190
|
+
value
|
191
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
192
|
+
inner_type = Regexp.last_match[:inner_type]
|
193
|
+
value.map { |v| _deserialize(inner_type, v) }
|
194
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
195
|
+
k_type = Regexp.last_match[:k_type]
|
196
|
+
v_type = Regexp.last_match[:v_type]
|
197
|
+
{}.tap do |hash|
|
198
|
+
value.each do |k, v|
|
199
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
200
|
+
end
|
201
|
+
end
|
202
|
+
else # model
|
203
|
+
# models (e.g. Pet) or oneOf
|
204
|
+
klass = UltracartClient.const_get(type)
|
205
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
206
|
+
end
|
207
|
+
end
|
208
|
+
|
209
|
+
# Returns the string representation of the object
|
210
|
+
# @return [String] String presentation of the object
|
211
|
+
def to_s
|
212
|
+
to_hash.to_s
|
213
|
+
end
|
214
|
+
|
215
|
+
# to_body is an alias to to_hash (backward compatibility)
|
216
|
+
# @return [Hash] Returns the object in the form of hash
|
217
|
+
def to_body
|
218
|
+
to_hash
|
219
|
+
end
|
220
|
+
|
221
|
+
# Returns the object in the form of hash
|
222
|
+
# @return [Hash] Returns the object in the form of hash
|
223
|
+
def to_hash
|
224
|
+
hash = {}
|
225
|
+
self.class.attribute_map.each_pair do |attr, param|
|
226
|
+
value = self.send(attr)
|
227
|
+
if value.nil?
|
228
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
229
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
230
|
+
end
|
231
|
+
|
232
|
+
hash[param] = _to_hash(value)
|
233
|
+
end
|
234
|
+
hash
|
235
|
+
end
|
236
|
+
|
237
|
+
# Outputs non-array value in the form of hash
|
238
|
+
# For object, use to_hash. Otherwise, just return the value
|
239
|
+
# @param [Object] value Any valid value
|
240
|
+
# @return [Hash] Returns the value in the form of hash
|
241
|
+
def _to_hash(value)
|
242
|
+
if value.is_a?(Array)
|
243
|
+
value.compact.map { |v| _to_hash(v) }
|
244
|
+
elsif value.is_a?(Hash)
|
245
|
+
{}.tap do |hash|
|
246
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
247
|
+
end
|
248
|
+
elsif value.respond_to? :to_hash
|
249
|
+
value.to_hash
|
250
|
+
else
|
251
|
+
value
|
252
|
+
end
|
253
|
+
end
|
254
|
+
|
255
|
+
end
|
256
|
+
|
257
|
+
end
|
@@ -19,6 +19,9 @@ module UltracartClient
|
|
19
19
|
|
20
20
|
attr_accessor :metadata
|
21
21
|
|
22
|
+
# User ID of myself
|
23
|
+
attr_accessor :my_user_id
|
24
|
+
|
22
25
|
# Indicates if API call was successful
|
23
26
|
attr_accessor :success
|
24
27
|
|
@@ -32,6 +35,7 @@ module UltracartClient
|
|
32
35
|
{
|
33
36
|
:'error' => :'error',
|
34
37
|
:'metadata' => :'metadata',
|
38
|
+
:'my_user_id' => :'my_user_id',
|
35
39
|
:'success' => :'success',
|
36
40
|
:'users' => :'users',
|
37
41
|
:'warning' => :'warning'
|
@@ -48,6 +52,7 @@ module UltracartClient
|
|
48
52
|
{
|
49
53
|
:'error' => :'Error',
|
50
54
|
:'metadata' => :'ResponseMetadata',
|
55
|
+
:'my_user_id' => :'Integer',
|
51
56
|
:'success' => :'Boolean',
|
52
57
|
:'users' => :'Array<WorkflowUser>',
|
53
58
|
:'warning' => :'Warning'
|
@@ -83,6 +88,10 @@ module UltracartClient
|
|
83
88
|
self.metadata = attributes[:'metadata']
|
84
89
|
end
|
85
90
|
|
91
|
+
if attributes.key?(:'my_user_id')
|
92
|
+
self.my_user_id = attributes[:'my_user_id']
|
93
|
+
end
|
94
|
+
|
86
95
|
if attributes.key?(:'success')
|
87
96
|
self.success = attributes[:'success']
|
88
97
|
end
|
@@ -118,6 +127,7 @@ module UltracartClient
|
|
118
127
|
self.class == o.class &&
|
119
128
|
error == o.error &&
|
120
129
|
metadata == o.metadata &&
|
130
|
+
my_user_id == o.my_user_id &&
|
121
131
|
success == o.success &&
|
122
132
|
users == o.users &&
|
123
133
|
warning == o.warning
|
@@ -132,7 +142,7 @@ module UltracartClient
|
|
132
142
|
# Calculates hash code according to all attributes.
|
133
143
|
# @return [Integer] Hash code
|
134
144
|
def hash
|
135
|
-
[error, metadata, success, users, warning].hash
|
145
|
+
[error, metadata, my_user_id, success, users, warning].hash
|
136
146
|
end
|
137
147
|
|
138
148
|
# Builds the object from hash
|
data/lib/ultracart_api.rb
CHANGED
@@ -849,6 +849,7 @@ require 'ultracart_api/models/workflow_groups_response'
|
|
849
849
|
require 'ultracart_api/models/workflow_note'
|
850
850
|
require 'ultracart_api/models/workflow_task'
|
851
851
|
require 'ultracart_api/models/workflow_task_history'
|
852
|
+
require 'ultracart_api/models/workflow_task_open_count_response'
|
852
853
|
require 'ultracart_api/models/workflow_task_response'
|
853
854
|
require 'ultracart_api/models/workflow_task_tags_response'
|
854
855
|
require 'ultracart_api/models/workflow_tasks_request'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ultracart_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0.
|
4
|
+
version: 4.0.205
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
@@ -914,6 +914,7 @@ files:
|
|
914
914
|
- docs/WorkflowNote.md
|
915
915
|
- docs/WorkflowTask.md
|
916
916
|
- docs/WorkflowTaskHistory.md
|
917
|
+
- docs/WorkflowTaskOpenCountResponse.md
|
917
918
|
- docs/WorkflowTaskResponse.md
|
918
919
|
- docs/WorkflowTaskTagsResponse.md
|
919
920
|
- docs/WorkflowTasksRequest.md
|
@@ -1779,6 +1780,7 @@ files:
|
|
1779
1780
|
- lib/ultracart_api/models/workflow_note.rb
|
1780
1781
|
- lib/ultracart_api/models/workflow_task.rb
|
1781
1782
|
- lib/ultracart_api/models/workflow_task_history.rb
|
1783
|
+
- lib/ultracart_api/models/workflow_task_open_count_response.rb
|
1782
1784
|
- lib/ultracart_api/models/workflow_task_response.rb
|
1783
1785
|
- lib/ultracart_api/models/workflow_task_tags_response.rb
|
1784
1786
|
- lib/ultracart_api/models/workflow_tasks_request.rb
|