ultracart_api 4.1.11 → 4.1.13
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/README.md +8 -2
- data/docs/Conversation.md +4 -0
- data/docs/ConversationApi.md +141 -0
- data/docs/ConversationVirtualAgentCapabilities.md +34 -0
- data/docs/ConversationVirtualAgentCapabilitiesResponse.md +26 -0
- data/docs/ItemRestriction.md +2 -0
- data/lib/ultracart_api/api/conversation_api.rb +127 -0
- data/lib/ultracart_api/models/conversation.rb +21 -1
- data/lib/ultracart_api/models/conversation_virtual_agent_capabilities.rb +291 -0
- data/lib/ultracart_api/models/conversation_virtual_agent_capabilities_response.rb +256 -0
- data/lib/ultracart_api/models/item_restriction.rb +11 -1
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +2 -0
- metadata +6 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a946d9c9a1fc472d1268629bdecc625b9b69254fe4ab711e65e2b6bb46ff81e
|
4
|
+
data.tar.gz: cc195035bc8e94040c3abd2564141c632d6ec2ae3bc6149859305938e6fc763d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 612d6641cbba23242cb36825571989d82f2148fcac953db69e55c114e57e21833dfb19cda0c5dd650c7972def15542ef840c614aa689c4a8655f22308bf7cca6
|
7
|
+
data.tar.gz: b631b15fbe14bc3e330b58d3f8e9cfc3e20c97b6f13a2fba51a1029a9dc417368837f42227b39788cc658b9b4b5f02052f36b556e2f5ca2b6c4f686f4404c063
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ Note: Every method has a sample for every language. See https://github.com/Ultr
|
|
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.1.
|
10
|
+
- Package version: 4.1.13
|
11
11
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
12
12
|
- For more information, please visit [http://www.ultracart.com/api/](http://www.ultracart.com/api/)
|
13
13
|
|
@@ -16,7 +16,7 @@ This SDK is automatically generated by the [OpenAPI Generator](https://openapi-g
|
|
16
16
|
gemfile:
|
17
17
|
|
18
18
|
```shell
|
19
|
-
gem 'ultracart_api', '4.1.
|
19
|
+
gem 'ultracart_api', '4.1.13'
|
20
20
|
```
|
21
21
|
|
22
22
|
install:
|
@@ -188,6 +188,7 @@ Class | Method | HTTP request | Description
|
|
188
188
|
*UltracartClient::ConversationApi* | [**get_pbx_voicemail_mailbox**](docs/ConversationApi.md#get_pbx_voicemail_mailbox) | **GET** /conversation/pbx/voicemail_mailbox/{conversationPbxVoicemailMailboxUuid} | Get pbx voicemailMailbox
|
189
189
|
*UltracartClient::ConversationApi* | [**get_pbx_voicemail_mailboxes**](docs/ConversationApi.md#get_pbx_voicemail_mailboxes) | **GET** /conversation/pbx/voicemail_mailbox | Get pbx voicemailMailboxes
|
190
190
|
*UltracartClient::ConversationApi* | [**get_virtual_agent_budget**](docs/ConversationApi.md#get_virtual_agent_budget) | **GET** /conversation/virtualagent/budget | Get virtual agent budget
|
191
|
+
*UltracartClient::ConversationApi* | [**get_virtual_agent_capabilities**](docs/ConversationApi.md#get_virtual_agent_capabilities) | **GET** /conversation/virtualagent/capabilities | Get virtual agent capabilities
|
191
192
|
*UltracartClient::ConversationApi* | [**insert_conversation_canned_message**](docs/ConversationApi.md#insert_conversation_canned_message) | **POST** /conversation/canned_messages | Insert a canned message
|
192
193
|
*UltracartClient::ConversationApi* | [**insert_conversation_department**](docs/ConversationApi.md#insert_conversation_department) | **POST** /conversation/departments | Insert a department
|
193
194
|
*UltracartClient::ConversationApi* | [**insert_conversation_engagement**](docs/ConversationApi.md#insert_conversation_engagement) | **POST** /conversation/engagements | Insert a engagement
|
@@ -220,6 +221,7 @@ Class | Method | HTTP request | Description
|
|
220
221
|
*UltracartClient::ConversationApi* | [**update_pbx_time_range**](docs/ConversationApi.md#update_pbx_time_range) | **PUT** /conversation/pbx/time_range/{conversationPbxTimeRangeUuid} | Update pbx timeRange
|
221
222
|
*UltracartClient::ConversationApi* | [**update_pbx_voicemail_mailbox**](docs/ConversationApi.md#update_pbx_voicemail_mailbox) | **PUT** /conversation/pbx/voicemail_mailbox/{conversationPbxVoicemailMailboxUuid} | Update pbx voicemailMailbox
|
222
223
|
*UltracartClient::ConversationApi* | [**update_virtual_agent_budget**](docs/ConversationApi.md#update_virtual_agent_budget) | **PUT** /conversation/virtualagent/budget | Update virtual agent budget
|
224
|
+
*UltracartClient::ConversationApi* | [**update_virtual_agent_capabilities**](docs/ConversationApi.md#update_virtual_agent_capabilities) | **PUT** /conversation/virtualagent/capabilities | Update virtual agent capabilities
|
223
225
|
*UltracartClient::CouponApi* | [**delete_coupon**](docs/CouponApi.md#delete_coupon) | **DELETE** /coupon/coupons/{coupon_oid} | Delete a coupon
|
224
226
|
*UltracartClient::CouponApi* | [**delete_coupons_by_code**](docs/CouponApi.md#delete_coupons_by_code) | **DELETE** /coupon/coupons/by_code | Deletes multiple coupons
|
225
227
|
*UltracartClient::CouponApi* | [**delete_coupons_by_oid**](docs/CouponApi.md#delete_coupons_by_oid) | **DELETE** /coupon/coupons/by_oid | Deletes multiple coupons
|
@@ -812,6 +814,8 @@ Class | Method | HTTP request | Description
|
|
812
814
|
- [UltracartClient::ConversationTwilioAccount](docs/ConversationTwilioAccount.md)
|
813
815
|
- [UltracartClient::ConversationVirtualAgentBudget](docs/ConversationVirtualAgentBudget.md)
|
814
816
|
- [UltracartClient::ConversationVirtualAgentBudgetResponse](docs/ConversationVirtualAgentBudgetResponse.md)
|
817
|
+
- [UltracartClient::ConversationVirtualAgentCapabilities](docs/ConversationVirtualAgentCapabilities.md)
|
818
|
+
- [UltracartClient::ConversationVirtualAgentCapabilitiesResponse](docs/ConversationVirtualAgentCapabilitiesResponse.md)
|
815
819
|
- [UltracartClient::ConversationWebchatContext](docs/ConversationWebchatContext.md)
|
816
820
|
- [UltracartClient::ConversationWebchatQueueStatus](docs/ConversationWebchatQueueStatus.md)
|
817
821
|
- [UltracartClient::ConversationWebchatQueueStatusAgent](docs/ConversationWebchatQueueStatusAgent.md)
|
@@ -1526,6 +1530,8 @@ Not every change is committed to every SDK.
|
|
1526
1530
|
|
1527
1531
|
| Version | Date | Comments |
|
1528
1532
|
| --: | :-: | --- |
|
1533
|
+
| 4.1.13 | 05/20/2025 | conversation - virtual agent flag and virtual agent cost |
|
1534
|
+
| 4.1.12 | 05/19/2025 | conversations - AI agent capabilities method |
|
1529
1535
|
| 4.1.11 | 05/19/2025 | conversations - virtual AI budgets |
|
1530
1536
|
| 4.1.10 | 05/06/2025 | conversation - ConversationAgentProfile.user_id added for agent profiles call |
|
1531
1537
|
| 4.1.9 | 05/05/2025 | conversations - method to fetch all agent profiles for admin screens |
|
data/docs/Conversation.md
CHANGED
@@ -22,6 +22,8 @@
|
|
22
22
|
| **sentiment** | [**ConversationSentiment**](ConversationSentiment.md) | | [optional] |
|
23
23
|
| **start_dts** | **String** | Start of the conversation date/time | [optional] |
|
24
24
|
| **unread_messages** | **Boolean** | | [optional] |
|
25
|
+
| **virtual_agent** | **Boolean** | True if a virtual agent answered the conversation | [optional] |
|
26
|
+
| **virtual_agent_cost** | **Float** | The cost of this conversation performed by the virtual agent | [optional] |
|
25
27
|
| **visible** | **Boolean** | | [optional] |
|
26
28
|
|
27
29
|
## Example
|
@@ -48,6 +50,8 @@ instance = UltracartClient::Conversation.new(
|
|
48
50
|
sentiment: null,
|
49
51
|
start_dts: null,
|
50
52
|
unread_messages: null,
|
53
|
+
virtual_agent: null,
|
54
|
+
virtual_agent_cost: null,
|
51
55
|
visible: null
|
52
56
|
)
|
53
57
|
```
|
data/docs/ConversationApi.md
CHANGED
@@ -58,6 +58,7 @@ All URIs are relative to *https://secure.ultracart.com/rest/v2*
|
|
58
58
|
| [**get_pbx_voicemail_mailbox**](ConversationApi.md#get_pbx_voicemail_mailbox) | **GET** /conversation/pbx/voicemail_mailbox/{conversationPbxVoicemailMailboxUuid} | Get pbx voicemailMailbox |
|
59
59
|
| [**get_pbx_voicemail_mailboxes**](ConversationApi.md#get_pbx_voicemail_mailboxes) | **GET** /conversation/pbx/voicemail_mailbox | Get pbx voicemailMailboxes |
|
60
60
|
| [**get_virtual_agent_budget**](ConversationApi.md#get_virtual_agent_budget) | **GET** /conversation/virtualagent/budget | Get virtual agent budget |
|
61
|
+
| [**get_virtual_agent_capabilities**](ConversationApi.md#get_virtual_agent_capabilities) | **GET** /conversation/virtualagent/capabilities | Get virtual agent capabilities |
|
61
62
|
| [**insert_conversation_canned_message**](ConversationApi.md#insert_conversation_canned_message) | **POST** /conversation/canned_messages | Insert a canned message |
|
62
63
|
| [**insert_conversation_department**](ConversationApi.md#insert_conversation_department) | **POST** /conversation/departments | Insert a department |
|
63
64
|
| [**insert_conversation_engagement**](ConversationApi.md#insert_conversation_engagement) | **POST** /conversation/engagements | Insert a engagement |
|
@@ -90,6 +91,7 @@ All URIs are relative to *https://secure.ultracart.com/rest/v2*
|
|
90
91
|
| [**update_pbx_time_range**](ConversationApi.md#update_pbx_time_range) | **PUT** /conversation/pbx/time_range/{conversationPbxTimeRangeUuid} | Update pbx timeRange |
|
91
92
|
| [**update_pbx_voicemail_mailbox**](ConversationApi.md#update_pbx_voicemail_mailbox) | **PUT** /conversation/pbx/voicemail_mailbox/{conversationPbxVoicemailMailboxUuid} | Update pbx voicemailMailbox |
|
92
93
|
| [**update_virtual_agent_budget**](ConversationApi.md#update_virtual_agent_budget) | **PUT** /conversation/virtualagent/budget | Update virtual agent budget |
|
94
|
+
| [**update_virtual_agent_capabilities**](ConversationApi.md#update_virtual_agent_capabilities) | **PUT** /conversation/virtualagent/capabilities | Update virtual agent capabilities |
|
93
95
|
|
94
96
|
|
95
97
|
## delete_conversation_canned_message
|
@@ -3879,6 +3881,74 @@ This endpoint does not need any parameter.
|
|
3879
3881
|
- **Accept**: application/json
|
3880
3882
|
|
3881
3883
|
|
3884
|
+
## get_virtual_agent_capabilities
|
3885
|
+
|
3886
|
+
> <ConversationVirtualAgentCapabilitiesResponse> get_virtual_agent_capabilities
|
3887
|
+
|
3888
|
+
Get virtual agent capabilities
|
3889
|
+
|
3890
|
+
Retrieve virtual agent capabilities
|
3891
|
+
|
3892
|
+
### Examples
|
3893
|
+
|
3894
|
+
```ruby
|
3895
|
+
require 'time'
|
3896
|
+
require 'ultracart_api'
|
3897
|
+
require 'json'
|
3898
|
+
require 'yaml'
|
3899
|
+
require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
|
3900
|
+
|
3901
|
+
# This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
|
3902
|
+
# As such, this might not be the best way to use this object.
|
3903
|
+
# Please see https://github.com/UltraCart/sdk_samples for working examples.
|
3904
|
+
|
3905
|
+
api = UltracartClient::ConversationApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
|
3906
|
+
|
3907
|
+
begin
|
3908
|
+
# Get virtual agent capabilities
|
3909
|
+
result = api_instance.get_virtual_agent_capabilities
|
3910
|
+
p result
|
3911
|
+
rescue UltracartClient::ApiError => e
|
3912
|
+
puts "Error when calling ConversationApi->get_virtual_agent_capabilities: #{e}"
|
3913
|
+
end
|
3914
|
+
```
|
3915
|
+
|
3916
|
+
#### Using the get_virtual_agent_capabilities_with_http_info variant
|
3917
|
+
|
3918
|
+
This returns an Array which contains the response data, status code and headers.
|
3919
|
+
|
3920
|
+
> <Array(<ConversationVirtualAgentCapabilitiesResponse>, Integer, Hash)> get_virtual_agent_capabilities_with_http_info
|
3921
|
+
|
3922
|
+
```ruby
|
3923
|
+
begin
|
3924
|
+
# Get virtual agent capabilities
|
3925
|
+
data, status_code, headers = api_instance.get_virtual_agent_capabilities_with_http_info
|
3926
|
+
p status_code # => 2xx
|
3927
|
+
p headers # => { ... }
|
3928
|
+
p data # => <ConversationVirtualAgentCapabilitiesResponse>
|
3929
|
+
rescue UltracartClient::ApiError => e
|
3930
|
+
puts "Error when calling ConversationApi->get_virtual_agent_capabilities_with_http_info: #{e}"
|
3931
|
+
end
|
3932
|
+
```
|
3933
|
+
|
3934
|
+
### Parameters
|
3935
|
+
|
3936
|
+
This endpoint does not need any parameter.
|
3937
|
+
|
3938
|
+
### Return type
|
3939
|
+
|
3940
|
+
[**ConversationVirtualAgentCapabilitiesResponse**](ConversationVirtualAgentCapabilitiesResponse.md)
|
3941
|
+
|
3942
|
+
### Authorization
|
3943
|
+
|
3944
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
3945
|
+
|
3946
|
+
### HTTP request headers
|
3947
|
+
|
3948
|
+
- **Content-Type**: Not defined
|
3949
|
+
- **Accept**: application/json
|
3950
|
+
|
3951
|
+
|
3882
3952
|
## insert_conversation_canned_message
|
3883
3953
|
|
3884
3954
|
> <ConversationCannedMessageResponse> insert_conversation_canned_message(canned_message)
|
@@ -6172,3 +6242,74 @@ end
|
|
6172
6242
|
- **Content-Type**: application/json
|
6173
6243
|
- **Accept**: application/json
|
6174
6244
|
|
6245
|
+
|
6246
|
+
## update_virtual_agent_capabilities
|
6247
|
+
|
6248
|
+
> <ConversationVirtualAgentCapabilitiesResponse> update_virtual_agent_capabilities(virtual_agent_capabilities)
|
6249
|
+
|
6250
|
+
Update virtual agent capabilities
|
6251
|
+
|
6252
|
+
Update virtual agent capabilities
|
6253
|
+
|
6254
|
+
### Examples
|
6255
|
+
|
6256
|
+
```ruby
|
6257
|
+
require 'time'
|
6258
|
+
require 'ultracart_api'
|
6259
|
+
require 'json'
|
6260
|
+
require 'yaml'
|
6261
|
+
require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
|
6262
|
+
|
6263
|
+
# This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
|
6264
|
+
# As such, this might not be the best way to use this object.
|
6265
|
+
# Please see https://github.com/UltraCart/sdk_samples for working examples.
|
6266
|
+
|
6267
|
+
api = UltracartClient::ConversationApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
|
6268
|
+
virtual_agent_capabilities = UltracartClient::ConversationVirtualAgentCapabilities.new # ConversationVirtualAgentCapabilities | Virtual Agent Capabilities
|
6269
|
+
|
6270
|
+
begin
|
6271
|
+
# Update virtual agent capabilities
|
6272
|
+
result = api_instance.update_virtual_agent_capabilities(virtual_agent_capabilities)
|
6273
|
+
p result
|
6274
|
+
rescue UltracartClient::ApiError => e
|
6275
|
+
puts "Error when calling ConversationApi->update_virtual_agent_capabilities: #{e}"
|
6276
|
+
end
|
6277
|
+
```
|
6278
|
+
|
6279
|
+
#### Using the update_virtual_agent_capabilities_with_http_info variant
|
6280
|
+
|
6281
|
+
This returns an Array which contains the response data, status code and headers.
|
6282
|
+
|
6283
|
+
> <Array(<ConversationVirtualAgentCapabilitiesResponse>, Integer, Hash)> update_virtual_agent_capabilities_with_http_info(virtual_agent_capabilities)
|
6284
|
+
|
6285
|
+
```ruby
|
6286
|
+
begin
|
6287
|
+
# Update virtual agent capabilities
|
6288
|
+
data, status_code, headers = api_instance.update_virtual_agent_capabilities_with_http_info(virtual_agent_capabilities)
|
6289
|
+
p status_code # => 2xx
|
6290
|
+
p headers # => { ... }
|
6291
|
+
p data # => <ConversationVirtualAgentCapabilitiesResponse>
|
6292
|
+
rescue UltracartClient::ApiError => e
|
6293
|
+
puts "Error when calling ConversationApi->update_virtual_agent_capabilities_with_http_info: #{e}"
|
6294
|
+
end
|
6295
|
+
```
|
6296
|
+
|
6297
|
+
### Parameters
|
6298
|
+
|
6299
|
+
| Name | Type | Description | Notes |
|
6300
|
+
| ---- | ---- | ----------- | ----- |
|
6301
|
+
| **virtual_agent_capabilities** | [**ConversationVirtualAgentCapabilities**](ConversationVirtualAgentCapabilities.md) | Virtual Agent Capabilities | |
|
6302
|
+
|
6303
|
+
### Return type
|
6304
|
+
|
6305
|
+
[**ConversationVirtualAgentCapabilitiesResponse**](ConversationVirtualAgentCapabilitiesResponse.md)
|
6306
|
+
|
6307
|
+
### Authorization
|
6308
|
+
|
6309
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
6310
|
+
|
6311
|
+
### HTTP request headers
|
6312
|
+
|
6313
|
+
- **Content-Type**: application/json
|
6314
|
+
- **Accept**: application/json
|
6315
|
+
|
@@ -0,0 +1,34 @@
|
|
1
|
+
# UltracartClient::ConversationVirtualAgentCapabilities
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **cancel_subscription** | **Boolean** | | [optional] |
|
8
|
+
| **delay_subscription** | **Boolean** | | [optional] |
|
9
|
+
| **lookup_order_information** | **Boolean** | | [optional] |
|
10
|
+
| **lookup_subscription_information** | **Boolean** | | [optional] |
|
11
|
+
| **open_support_ticket** | **Boolean** | | [optional] |
|
12
|
+
| **pause_subscription** | **Boolean** | | [optional] |
|
13
|
+
| **resume_subscription** | **Boolean** | | [optional] |
|
14
|
+
| **transfer_chat_to_live_agent** | **Boolean** | | [optional] |
|
15
|
+
| **update_subscription_credit_card** | **Boolean** | | [optional] |
|
16
|
+
|
17
|
+
## Example
|
18
|
+
|
19
|
+
```ruby
|
20
|
+
require 'ultracart_api'
|
21
|
+
|
22
|
+
instance = UltracartClient::ConversationVirtualAgentCapabilities.new(
|
23
|
+
cancel_subscription: null,
|
24
|
+
delay_subscription: null,
|
25
|
+
lookup_order_information: null,
|
26
|
+
lookup_subscription_information: null,
|
27
|
+
open_support_ticket: null,
|
28
|
+
pause_subscription: null,
|
29
|
+
resume_subscription: null,
|
30
|
+
transfer_chat_to_live_agent: null,
|
31
|
+
update_subscription_credit_card: null
|
32
|
+
)
|
33
|
+
```
|
34
|
+
|
@@ -0,0 +1,26 @@
|
|
1
|
+
# UltracartClient::ConversationVirtualAgentCapabilitiesResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **capabilities** | [**ConversationVirtualAgentCapabilities**](ConversationVirtualAgentCapabilities.md) | | [optional] |
|
8
|
+
| **error** | [**Error**](Error.md) | | [optional] |
|
9
|
+
| **metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [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::ConversationVirtualAgentCapabilitiesResponse.new(
|
19
|
+
capabilities: null,
|
20
|
+
error: null,
|
21
|
+
metadata: null,
|
22
|
+
success: null,
|
23
|
+
warning: null
|
24
|
+
)
|
25
|
+
```
|
26
|
+
|
data/docs/ItemRestriction.md
CHANGED
@@ -6,6 +6,7 @@
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
7
7
|
| **exclude_coupon** | **Boolean** | Exclude coupons | [optional] |
|
8
8
|
| **exclude_from_free_promotion** | **Boolean** | Exclude from free promotion | [optional] |
|
9
|
+
| **exclude_from_loyalty** | **Boolean** | Exclude from loyalty. Must be set to true or false to save. Null is ignored for backwards SDK compatibility | [optional] |
|
9
10
|
| **items** | [**Array<ItemRestrictionItem>**](ItemRestrictionItem.md) | Items | [optional] |
|
10
11
|
| **maximum_quantity** | **Integer** | Maximum quantity | [optional] |
|
11
12
|
| **minimum_quantity** | **Integer** | Minimum quantity (defaults to 1) | [optional] |
|
@@ -21,6 +22,7 @@ require 'ultracart_api'
|
|
21
22
|
instance = UltracartClient::ItemRestriction.new(
|
22
23
|
exclude_coupon: null,
|
23
24
|
exclude_from_free_promotion: null,
|
25
|
+
exclude_from_loyalty: null,
|
24
26
|
items: null,
|
25
27
|
maximum_quantity: null,
|
26
28
|
minimum_quantity: null,
|
@@ -3407,6 +3407,64 @@ module UltracartClient
|
|
3407
3407
|
return data, status_code, headers
|
3408
3408
|
end
|
3409
3409
|
|
3410
|
+
# Get virtual agent capabilities
|
3411
|
+
# Retrieve virtual agent capabilities
|
3412
|
+
# @param [Hash] opts the optional parameters
|
3413
|
+
# @return [ConversationVirtualAgentCapabilitiesResponse]
|
3414
|
+
def get_virtual_agent_capabilities(opts = {})
|
3415
|
+
data, _status_code, _headers = get_virtual_agent_capabilities_with_http_info(opts)
|
3416
|
+
data
|
3417
|
+
end
|
3418
|
+
|
3419
|
+
# Get virtual agent capabilities
|
3420
|
+
# Retrieve virtual agent capabilities
|
3421
|
+
# @param [Hash] opts the optional parameters
|
3422
|
+
# @return [Array<(ConversationVirtualAgentCapabilitiesResponse, Integer, Hash)>] ConversationVirtualAgentCapabilitiesResponse data, response status code and response headers
|
3423
|
+
def get_virtual_agent_capabilities_with_http_info(opts = {})
|
3424
|
+
if @api_client.config.debugging
|
3425
|
+
@api_client.config.logger.debug 'Calling API: ConversationApi.get_virtual_agent_capabilities ...'
|
3426
|
+
end
|
3427
|
+
# resource path
|
3428
|
+
local_var_path = '/conversation/virtualagent/capabilities'
|
3429
|
+
|
3430
|
+
# query parameters
|
3431
|
+
query_params = opts[:query_params] || {}
|
3432
|
+
|
3433
|
+
# header parameters
|
3434
|
+
header_params = opts[:header_params] || {}
|
3435
|
+
header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
|
3436
|
+
# HTTP header 'Accept' (if needed)
|
3437
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
3438
|
+
|
3439
|
+
# form parameters
|
3440
|
+
form_params = opts[:form_params] || {}
|
3441
|
+
|
3442
|
+
# http body (model)
|
3443
|
+
post_body = opts[:debug_body]
|
3444
|
+
|
3445
|
+
# return_type
|
3446
|
+
return_type = opts[:debug_return_type] || 'ConversationVirtualAgentCapabilitiesResponse'
|
3447
|
+
|
3448
|
+
# auth_names
|
3449
|
+
auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
|
3450
|
+
|
3451
|
+
new_options = opts.merge(
|
3452
|
+
:operation => :"ConversationApi.get_virtual_agent_capabilities",
|
3453
|
+
:header_params => header_params,
|
3454
|
+
:query_params => query_params,
|
3455
|
+
:form_params => form_params,
|
3456
|
+
:body => post_body,
|
3457
|
+
:auth_names => auth_names,
|
3458
|
+
:return_type => return_type
|
3459
|
+
)
|
3460
|
+
|
3461
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
3462
|
+
if @api_client.config.debugging
|
3463
|
+
@api_client.config.logger.debug "API called: ConversationApi#get_virtual_agent_capabilities\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
3464
|
+
end
|
3465
|
+
return data, status_code, headers
|
3466
|
+
end
|
3467
|
+
|
3410
3468
|
# Insert a canned message
|
3411
3469
|
# Insert a canned message
|
3412
3470
|
# @param canned_message [ConversationCannedMessage] Canned message
|
@@ -5664,5 +5722,74 @@ module UltracartClient
|
|
5664
5722
|
end
|
5665
5723
|
return data, status_code, headers
|
5666
5724
|
end
|
5725
|
+
|
5726
|
+
# Update virtual agent capabilities
|
5727
|
+
# Update virtual agent capabilities
|
5728
|
+
# @param virtual_agent_capabilities [ConversationVirtualAgentCapabilities] Virtual Agent Capabilities
|
5729
|
+
# @param [Hash] opts the optional parameters
|
5730
|
+
# @return [ConversationVirtualAgentCapabilitiesResponse]
|
5731
|
+
def update_virtual_agent_capabilities(virtual_agent_capabilities, opts = {})
|
5732
|
+
data, _status_code, _headers = update_virtual_agent_capabilities_with_http_info(virtual_agent_capabilities, opts)
|
5733
|
+
data
|
5734
|
+
end
|
5735
|
+
|
5736
|
+
# Update virtual agent capabilities
|
5737
|
+
# Update virtual agent capabilities
|
5738
|
+
# @param virtual_agent_capabilities [ConversationVirtualAgentCapabilities] Virtual Agent Capabilities
|
5739
|
+
# @param [Hash] opts the optional parameters
|
5740
|
+
# @return [Array<(ConversationVirtualAgentCapabilitiesResponse, Integer, Hash)>] ConversationVirtualAgentCapabilitiesResponse data, response status code and response headers
|
5741
|
+
def update_virtual_agent_capabilities_with_http_info(virtual_agent_capabilities, opts = {})
|
5742
|
+
if @api_client.config.debugging
|
5743
|
+
@api_client.config.logger.debug 'Calling API: ConversationApi.update_virtual_agent_capabilities ...'
|
5744
|
+
end
|
5745
|
+
# verify the required parameter 'virtual_agent_capabilities' is set
|
5746
|
+
if @api_client.config.client_side_validation && virtual_agent_capabilities.nil?
|
5747
|
+
fail ArgumentError, "Missing the required parameter 'virtual_agent_capabilities' when calling ConversationApi.update_virtual_agent_capabilities"
|
5748
|
+
end
|
5749
|
+
# resource path
|
5750
|
+
local_var_path = '/conversation/virtualagent/capabilities'
|
5751
|
+
|
5752
|
+
# query parameters
|
5753
|
+
query_params = opts[:query_params] || {}
|
5754
|
+
|
5755
|
+
# header parameters
|
5756
|
+
header_params = opts[:header_params] || {}
|
5757
|
+
header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
|
5758
|
+
# HTTP header 'Accept' (if needed)
|
5759
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
5760
|
+
# HTTP header 'Content-Type'
|
5761
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
5762
|
+
if !content_type.nil?
|
5763
|
+
header_params['Content-Type'] = content_type
|
5764
|
+
end
|
5765
|
+
|
5766
|
+
# form parameters
|
5767
|
+
form_params = opts[:form_params] || {}
|
5768
|
+
|
5769
|
+
# http body (model)
|
5770
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(virtual_agent_capabilities)
|
5771
|
+
|
5772
|
+
# return_type
|
5773
|
+
return_type = opts[:debug_return_type] || 'ConversationVirtualAgentCapabilitiesResponse'
|
5774
|
+
|
5775
|
+
# auth_names
|
5776
|
+
auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
|
5777
|
+
|
5778
|
+
new_options = opts.merge(
|
5779
|
+
:operation => :"ConversationApi.update_virtual_agent_capabilities",
|
5780
|
+
:header_params => header_params,
|
5781
|
+
:query_params => query_params,
|
5782
|
+
:form_params => form_params,
|
5783
|
+
:body => post_body,
|
5784
|
+
:auth_names => auth_names,
|
5785
|
+
:return_type => return_type
|
5786
|
+
)
|
5787
|
+
|
5788
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
5789
|
+
if @api_client.config.debugging
|
5790
|
+
@api_client.config.logger.debug "API called: ConversationApi#update_virtual_agent_capabilities\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
5791
|
+
end
|
5792
|
+
return data, status_code, headers
|
5793
|
+
end
|
5667
5794
|
end
|
5668
5795
|
end
|
@@ -57,6 +57,12 @@ module UltracartClient
|
|
57
57
|
|
58
58
|
attr_accessor :unread_messages
|
59
59
|
|
60
|
+
# True if a virtual agent answered the conversation
|
61
|
+
attr_accessor :virtual_agent
|
62
|
+
|
63
|
+
# The cost of this conversation performed by the virtual agent
|
64
|
+
attr_accessor :virtual_agent_cost
|
65
|
+
|
60
66
|
attr_accessor :visible
|
61
67
|
|
62
68
|
class EnumAttributeValidator
|
@@ -102,6 +108,8 @@ module UltracartClient
|
|
102
108
|
:'sentiment' => :'sentiment',
|
103
109
|
:'start_dts' => :'start_dts',
|
104
110
|
:'unread_messages' => :'unread_messages',
|
111
|
+
:'virtual_agent' => :'virtual_agent',
|
112
|
+
:'virtual_agent_cost' => :'virtual_agent_cost',
|
105
113
|
:'visible' => :'visible'
|
106
114
|
}
|
107
115
|
end
|
@@ -132,6 +140,8 @@ module UltracartClient
|
|
132
140
|
:'sentiment' => :'ConversationSentiment',
|
133
141
|
:'start_dts' => :'String',
|
134
142
|
:'unread_messages' => :'Boolean',
|
143
|
+
:'virtual_agent' => :'Boolean',
|
144
|
+
:'virtual_agent_cost' => :'Float',
|
135
145
|
:'visible' => :'Boolean'
|
136
146
|
}
|
137
147
|
end
|
@@ -233,6 +243,14 @@ module UltracartClient
|
|
233
243
|
self.unread_messages = attributes[:'unread_messages']
|
234
244
|
end
|
235
245
|
|
246
|
+
if attributes.key?(:'virtual_agent')
|
247
|
+
self.virtual_agent = attributes[:'virtual_agent']
|
248
|
+
end
|
249
|
+
|
250
|
+
if attributes.key?(:'virtual_agent_cost')
|
251
|
+
self.virtual_agent_cost = attributes[:'virtual_agent_cost']
|
252
|
+
end
|
253
|
+
|
236
254
|
if attributes.key?(:'visible')
|
237
255
|
self.visible = attributes[:'visible']
|
238
256
|
end
|
@@ -286,6 +304,8 @@ module UltracartClient
|
|
286
304
|
sentiment == o.sentiment &&
|
287
305
|
start_dts == o.start_dts &&
|
288
306
|
unread_messages == o.unread_messages &&
|
307
|
+
virtual_agent == o.virtual_agent &&
|
308
|
+
virtual_agent_cost == o.virtual_agent_cost &&
|
289
309
|
visible == o.visible
|
290
310
|
end
|
291
311
|
|
@@ -298,7 +318,7 @@ module UltracartClient
|
|
298
318
|
# Calculates hash code according to all attributes.
|
299
319
|
# @return [Integer] Hash code
|
300
320
|
def hash
|
301
|
-
[base_language_iso_code, closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, messages, participants, sentiment, start_dts, unread_messages, visible].hash
|
321
|
+
[base_language_iso_code, closed, conversation_arn, conversation_uuid, customer_first_message_unresponded_to_dts, last_conversation_message_body, last_conversation_participant_arn, last_conversation_participant_name, last_interactive_message_dts, last_message_dts, medium, merchant_id, message_count, messages, participants, sentiment, start_dts, unread_messages, virtual_agent, virtual_agent_cost, visible].hash
|
302
322
|
end
|
303
323
|
|
304
324
|
# Builds the object from hash
|
@@ -0,0 +1,291 @@
|
|
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 ConversationVirtualAgentCapabilities
|
18
|
+
attr_accessor :cancel_subscription
|
19
|
+
|
20
|
+
attr_accessor :delay_subscription
|
21
|
+
|
22
|
+
attr_accessor :lookup_order_information
|
23
|
+
|
24
|
+
attr_accessor :lookup_subscription_information
|
25
|
+
|
26
|
+
attr_accessor :open_support_ticket
|
27
|
+
|
28
|
+
attr_accessor :pause_subscription
|
29
|
+
|
30
|
+
attr_accessor :resume_subscription
|
31
|
+
|
32
|
+
attr_accessor :transfer_chat_to_live_agent
|
33
|
+
|
34
|
+
attr_accessor :update_subscription_credit_card
|
35
|
+
|
36
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
37
|
+
def self.attribute_map
|
38
|
+
{
|
39
|
+
:'cancel_subscription' => :'cancel_subscription',
|
40
|
+
:'delay_subscription' => :'delay_subscription',
|
41
|
+
:'lookup_order_information' => :'lookup_order_information',
|
42
|
+
:'lookup_subscription_information' => :'lookup_subscription_information',
|
43
|
+
:'open_support_ticket' => :'open_support_ticket',
|
44
|
+
:'pause_subscription' => :'pause_subscription',
|
45
|
+
:'resume_subscription' => :'resume_subscription',
|
46
|
+
:'transfer_chat_to_live_agent' => :'transfer_chat_to_live_agent',
|
47
|
+
:'update_subscription_credit_card' => :'update_subscription_credit_card'
|
48
|
+
}
|
49
|
+
end
|
50
|
+
|
51
|
+
# Returns all the JSON keys this model knows about
|
52
|
+
def self.acceptable_attributes
|
53
|
+
attribute_map.values
|
54
|
+
end
|
55
|
+
|
56
|
+
# Attribute type mapping.
|
57
|
+
def self.openapi_types
|
58
|
+
{
|
59
|
+
:'cancel_subscription' => :'Boolean',
|
60
|
+
:'delay_subscription' => :'Boolean',
|
61
|
+
:'lookup_order_information' => :'Boolean',
|
62
|
+
:'lookup_subscription_information' => :'Boolean',
|
63
|
+
:'open_support_ticket' => :'Boolean',
|
64
|
+
:'pause_subscription' => :'Boolean',
|
65
|
+
:'resume_subscription' => :'Boolean',
|
66
|
+
:'transfer_chat_to_live_agent' => :'Boolean',
|
67
|
+
:'update_subscription_credit_card' => :'Boolean'
|
68
|
+
}
|
69
|
+
end
|
70
|
+
|
71
|
+
# List of attributes with nullable: true
|
72
|
+
def self.openapi_nullable
|
73
|
+
Set.new([
|
74
|
+
])
|
75
|
+
end
|
76
|
+
|
77
|
+
# Initializes the object
|
78
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
79
|
+
def initialize(attributes = {})
|
80
|
+
if (!attributes.is_a?(Hash))
|
81
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::ConversationVirtualAgentCapabilities` initialize method"
|
82
|
+
end
|
83
|
+
|
84
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
85
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
86
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
87
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::ConversationVirtualAgentCapabilities`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
88
|
+
end
|
89
|
+
h[k.to_sym] = v
|
90
|
+
}
|
91
|
+
|
92
|
+
if attributes.key?(:'cancel_subscription')
|
93
|
+
self.cancel_subscription = attributes[:'cancel_subscription']
|
94
|
+
end
|
95
|
+
|
96
|
+
if attributes.key?(:'delay_subscription')
|
97
|
+
self.delay_subscription = attributes[:'delay_subscription']
|
98
|
+
end
|
99
|
+
|
100
|
+
if attributes.key?(:'lookup_order_information')
|
101
|
+
self.lookup_order_information = attributes[:'lookup_order_information']
|
102
|
+
end
|
103
|
+
|
104
|
+
if attributes.key?(:'lookup_subscription_information')
|
105
|
+
self.lookup_subscription_information = attributes[:'lookup_subscription_information']
|
106
|
+
end
|
107
|
+
|
108
|
+
if attributes.key?(:'open_support_ticket')
|
109
|
+
self.open_support_ticket = attributes[:'open_support_ticket']
|
110
|
+
end
|
111
|
+
|
112
|
+
if attributes.key?(:'pause_subscription')
|
113
|
+
self.pause_subscription = attributes[:'pause_subscription']
|
114
|
+
end
|
115
|
+
|
116
|
+
if attributes.key?(:'resume_subscription')
|
117
|
+
self.resume_subscription = attributes[:'resume_subscription']
|
118
|
+
end
|
119
|
+
|
120
|
+
if attributes.key?(:'transfer_chat_to_live_agent')
|
121
|
+
self.transfer_chat_to_live_agent = attributes[:'transfer_chat_to_live_agent']
|
122
|
+
end
|
123
|
+
|
124
|
+
if attributes.key?(:'update_subscription_credit_card')
|
125
|
+
self.update_subscription_credit_card = attributes[:'update_subscription_credit_card']
|
126
|
+
end
|
127
|
+
end
|
128
|
+
|
129
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
130
|
+
# @return Array for valid properties with the reasons
|
131
|
+
def list_invalid_properties
|
132
|
+
invalid_properties = Array.new
|
133
|
+
invalid_properties
|
134
|
+
end
|
135
|
+
|
136
|
+
# Check to see if the all the properties in the model are valid
|
137
|
+
# @return true if the model is valid
|
138
|
+
def valid?
|
139
|
+
true
|
140
|
+
end
|
141
|
+
|
142
|
+
# Checks equality by comparing each attribute.
|
143
|
+
# @param [Object] Object to be compared
|
144
|
+
def ==(o)
|
145
|
+
return true if self.equal?(o)
|
146
|
+
self.class == o.class &&
|
147
|
+
cancel_subscription == o.cancel_subscription &&
|
148
|
+
delay_subscription == o.delay_subscription &&
|
149
|
+
lookup_order_information == o.lookup_order_information &&
|
150
|
+
lookup_subscription_information == o.lookup_subscription_information &&
|
151
|
+
open_support_ticket == o.open_support_ticket &&
|
152
|
+
pause_subscription == o.pause_subscription &&
|
153
|
+
resume_subscription == o.resume_subscription &&
|
154
|
+
transfer_chat_to_live_agent == o.transfer_chat_to_live_agent &&
|
155
|
+
update_subscription_credit_card == o.update_subscription_credit_card
|
156
|
+
end
|
157
|
+
|
158
|
+
# @see the `==` method
|
159
|
+
# @param [Object] Object to be compared
|
160
|
+
def eql?(o)
|
161
|
+
self == o
|
162
|
+
end
|
163
|
+
|
164
|
+
# Calculates hash code according to all attributes.
|
165
|
+
# @return [Integer] Hash code
|
166
|
+
def hash
|
167
|
+
[cancel_subscription, delay_subscription, lookup_order_information, lookup_subscription_information, open_support_ticket, pause_subscription, resume_subscription, transfer_chat_to_live_agent, update_subscription_credit_card].hash
|
168
|
+
end
|
169
|
+
|
170
|
+
# Builds the object from hash
|
171
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
172
|
+
# @return [Object] Returns the model itself
|
173
|
+
def self.build_from_hash(attributes)
|
174
|
+
new.build_from_hash(attributes)
|
175
|
+
end
|
176
|
+
|
177
|
+
# Builds the object from hash
|
178
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
179
|
+
# @return [Object] Returns the model itself
|
180
|
+
def build_from_hash(attributes)
|
181
|
+
return nil unless attributes.is_a?(Hash)
|
182
|
+
attributes = attributes.transform_keys(&:to_sym)
|
183
|
+
self.class.openapi_types.each_pair do |key, type|
|
184
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
185
|
+
self.send("#{key}=", nil)
|
186
|
+
elsif type =~ /\AArray<(.*)>/i
|
187
|
+
# check to ensure the input is an array given that the attribute
|
188
|
+
# is documented as an array but the input is not
|
189
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
190
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
191
|
+
end
|
192
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
193
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
194
|
+
end
|
195
|
+
end
|
196
|
+
|
197
|
+
self
|
198
|
+
end
|
199
|
+
|
200
|
+
# Deserializes the data based on type
|
201
|
+
# @param string type Data type
|
202
|
+
# @param string value Value to be deserialized
|
203
|
+
# @return [Object] Deserialized data
|
204
|
+
def _deserialize(type, value)
|
205
|
+
case type.to_sym
|
206
|
+
when :Time
|
207
|
+
Time.parse(value)
|
208
|
+
when :Date
|
209
|
+
Date.parse(value)
|
210
|
+
when :String
|
211
|
+
value.to_s
|
212
|
+
when :Integer
|
213
|
+
value.to_i
|
214
|
+
when :Float
|
215
|
+
value.to_f
|
216
|
+
when :Boolean
|
217
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
218
|
+
true
|
219
|
+
else
|
220
|
+
false
|
221
|
+
end
|
222
|
+
when :Object
|
223
|
+
# generic object (usually a Hash), return directly
|
224
|
+
value
|
225
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
226
|
+
inner_type = Regexp.last_match[:inner_type]
|
227
|
+
value.map { |v| _deserialize(inner_type, v) }
|
228
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
229
|
+
k_type = Regexp.last_match[:k_type]
|
230
|
+
v_type = Regexp.last_match[:v_type]
|
231
|
+
{}.tap do |hash|
|
232
|
+
value.each do |k, v|
|
233
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
234
|
+
end
|
235
|
+
end
|
236
|
+
else # model
|
237
|
+
# models (e.g. Pet) or oneOf
|
238
|
+
klass = UltracartClient.const_get(type)
|
239
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
240
|
+
end
|
241
|
+
end
|
242
|
+
|
243
|
+
# Returns the string representation of the object
|
244
|
+
# @return [String] String presentation of the object
|
245
|
+
def to_s
|
246
|
+
to_hash.to_s
|
247
|
+
end
|
248
|
+
|
249
|
+
# to_body is an alias to to_hash (backward compatibility)
|
250
|
+
# @return [Hash] Returns the object in the form of hash
|
251
|
+
def to_body
|
252
|
+
to_hash
|
253
|
+
end
|
254
|
+
|
255
|
+
# Returns the object in the form of hash
|
256
|
+
# @return [Hash] Returns the object in the form of hash
|
257
|
+
def to_hash
|
258
|
+
hash = {}
|
259
|
+
self.class.attribute_map.each_pair do |attr, param|
|
260
|
+
value = self.send(attr)
|
261
|
+
if value.nil?
|
262
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
263
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
264
|
+
end
|
265
|
+
|
266
|
+
hash[param] = _to_hash(value)
|
267
|
+
end
|
268
|
+
hash
|
269
|
+
end
|
270
|
+
|
271
|
+
# Outputs non-array value in the form of hash
|
272
|
+
# For object, use to_hash. Otherwise, just return the value
|
273
|
+
# @param [Object] value Any valid value
|
274
|
+
# @return [Hash] Returns the value in the form of hash
|
275
|
+
def _to_hash(value)
|
276
|
+
if value.is_a?(Array)
|
277
|
+
value.compact.map { |v| _to_hash(v) }
|
278
|
+
elsif value.is_a?(Hash)
|
279
|
+
{}.tap do |hash|
|
280
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
281
|
+
end
|
282
|
+
elsif value.respond_to? :to_hash
|
283
|
+
value.to_hash
|
284
|
+
else
|
285
|
+
value
|
286
|
+
end
|
287
|
+
end
|
288
|
+
|
289
|
+
end
|
290
|
+
|
291
|
+
end
|
@@ -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 ConversationVirtualAgentCapabilitiesResponse
|
18
|
+
attr_accessor :capabilities
|
19
|
+
|
20
|
+
attr_accessor :error
|
21
|
+
|
22
|
+
attr_accessor :metadata
|
23
|
+
|
24
|
+
# Indicates if API call was successful
|
25
|
+
attr_accessor :success
|
26
|
+
|
27
|
+
attr_accessor :warning
|
28
|
+
|
29
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
30
|
+
def self.attribute_map
|
31
|
+
{
|
32
|
+
:'capabilities' => :'capabilities',
|
33
|
+
:'error' => :'error',
|
34
|
+
:'metadata' => :'metadata',
|
35
|
+
:'success' => :'success',
|
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
|
+
:'capabilities' => :'ConversationVirtualAgentCapabilities',
|
49
|
+
:'error' => :'Error',
|
50
|
+
:'metadata' => :'ResponseMetadata',
|
51
|
+
:'success' => :'Boolean',
|
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::ConversationVirtualAgentCapabilitiesResponse` 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::ConversationVirtualAgentCapabilitiesResponse`. 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?(:'capabilities')
|
78
|
+
self.capabilities = attributes[:'capabilities']
|
79
|
+
end
|
80
|
+
|
81
|
+
if attributes.key?(:'error')
|
82
|
+
self.error = attributes[:'error']
|
83
|
+
end
|
84
|
+
|
85
|
+
if attributes.key?(:'metadata')
|
86
|
+
self.metadata = attributes[:'metadata']
|
87
|
+
end
|
88
|
+
|
89
|
+
if attributes.key?(:'success')
|
90
|
+
self.success = attributes[:'success']
|
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
|
+
capabilities == o.capabilities &&
|
117
|
+
error == o.error &&
|
118
|
+
metadata == o.metadata &&
|
119
|
+
success == o.success &&
|
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
|
+
[capabilities, error, metadata, success, 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
|
@@ -21,6 +21,9 @@ module UltracartClient
|
|
21
21
|
# Exclude from free promotion
|
22
22
|
attr_accessor :exclude_from_free_promotion
|
23
23
|
|
24
|
+
# Exclude from loyalty. Must be set to true or false to save. Null is ignored for backwards SDK compatibility
|
25
|
+
attr_accessor :exclude_from_loyalty
|
26
|
+
|
24
27
|
# Items
|
25
28
|
attr_accessor :items
|
26
29
|
|
@@ -44,6 +47,7 @@ module UltracartClient
|
|
44
47
|
{
|
45
48
|
:'exclude_coupon' => :'exclude_coupon',
|
46
49
|
:'exclude_from_free_promotion' => :'exclude_from_free_promotion',
|
50
|
+
:'exclude_from_loyalty' => :'exclude_from_loyalty',
|
47
51
|
:'items' => :'items',
|
48
52
|
:'maximum_quantity' => :'maximum_quantity',
|
49
53
|
:'minimum_quantity' => :'minimum_quantity',
|
@@ -63,6 +67,7 @@ module UltracartClient
|
|
63
67
|
{
|
64
68
|
:'exclude_coupon' => :'Boolean',
|
65
69
|
:'exclude_from_free_promotion' => :'Boolean',
|
70
|
+
:'exclude_from_loyalty' => :'Boolean',
|
66
71
|
:'items' => :'Array<ItemRestrictionItem>',
|
67
72
|
:'maximum_quantity' => :'Integer',
|
68
73
|
:'minimum_quantity' => :'Integer',
|
@@ -101,6 +106,10 @@ module UltracartClient
|
|
101
106
|
self.exclude_from_free_promotion = attributes[:'exclude_from_free_promotion']
|
102
107
|
end
|
103
108
|
|
109
|
+
if attributes.key?(:'exclude_from_loyalty')
|
110
|
+
self.exclude_from_loyalty = attributes[:'exclude_from_loyalty']
|
111
|
+
end
|
112
|
+
|
104
113
|
if attributes.key?(:'items')
|
105
114
|
if (value = attributes[:'items']).is_a?(Array)
|
106
115
|
self.items = value
|
@@ -148,6 +157,7 @@ module UltracartClient
|
|
148
157
|
self.class == o.class &&
|
149
158
|
exclude_coupon == o.exclude_coupon &&
|
150
159
|
exclude_from_free_promotion == o.exclude_from_free_promotion &&
|
160
|
+
exclude_from_loyalty == o.exclude_from_loyalty &&
|
151
161
|
items == o.items &&
|
152
162
|
maximum_quantity == o.maximum_quantity &&
|
153
163
|
minimum_quantity == o.minimum_quantity &&
|
@@ -165,7 +175,7 @@ module UltracartClient
|
|
165
175
|
# Calculates hash code according to all attributes.
|
166
176
|
# @return [Integer] Hash code
|
167
177
|
def hash
|
168
|
-
[exclude_coupon, exclude_from_free_promotion, items, maximum_quantity, minimum_quantity, multiple_quantity, one_per_customer, purchase_separately].hash
|
178
|
+
[exclude_coupon, exclude_from_free_promotion, exclude_from_loyalty, items, maximum_quantity, minimum_quantity, multiple_quantity, one_per_customer, purchase_separately].hash
|
169
179
|
end
|
170
180
|
|
171
181
|
# Builds the object from hash
|
data/lib/ultracart_api.rb
CHANGED
@@ -239,6 +239,8 @@ require 'ultracart_api/models/conversation_summary'
|
|
239
239
|
require 'ultracart_api/models/conversation_twilio_account'
|
240
240
|
require 'ultracart_api/models/conversation_virtual_agent_budget'
|
241
241
|
require 'ultracart_api/models/conversation_virtual_agent_budget_response'
|
242
|
+
require 'ultracart_api/models/conversation_virtual_agent_capabilities'
|
243
|
+
require 'ultracart_api/models/conversation_virtual_agent_capabilities_response'
|
242
244
|
require 'ultracart_api/models/conversation_webchat_context'
|
243
245
|
require 'ultracart_api/models/conversation_webchat_queue_status'
|
244
246
|
require 'ultracart_api/models/conversation_webchat_queue_status_agent'
|
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.1.
|
4
|
+
version: 4.1.13
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- UltraCart
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2025-05-
|
11
|
+
date: 2025-05-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -289,6 +289,8 @@ files:
|
|
289
289
|
- docs/ConversationTwilioAccount.md
|
290
290
|
- docs/ConversationVirtualAgentBudget.md
|
291
291
|
- docs/ConversationVirtualAgentBudgetResponse.md
|
292
|
+
- docs/ConversationVirtualAgentCapabilities.md
|
293
|
+
- docs/ConversationVirtualAgentCapabilitiesResponse.md
|
292
294
|
- docs/ConversationWebchatContext.md
|
293
295
|
- docs/ConversationWebchatQueueStatus.md
|
294
296
|
- docs/ConversationWebchatQueueStatusAgent.md
|
@@ -1191,6 +1193,8 @@ files:
|
|
1191
1193
|
- lib/ultracart_api/models/conversation_twilio_account.rb
|
1192
1194
|
- lib/ultracart_api/models/conversation_virtual_agent_budget.rb
|
1193
1195
|
- lib/ultracart_api/models/conversation_virtual_agent_budget_response.rb
|
1196
|
+
- lib/ultracart_api/models/conversation_virtual_agent_capabilities.rb
|
1197
|
+
- lib/ultracart_api/models/conversation_virtual_agent_capabilities_response.rb
|
1194
1198
|
- lib/ultracart_api/models/conversation_webchat_context.rb
|
1195
1199
|
- lib/ultracart_api/models/conversation_webchat_queue_status.rb
|
1196
1200
|
- lib/ultracart_api/models/conversation_webchat_queue_status_agent.rb
|