ultracart_api 3.10.20 → 3.10.23
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +16 -4
- data/docs/AutoOrder.md +1 -0
- data/docs/AutoOrderManagement.md +8 -0
- data/docs/ConversationAgentAuth.md +13 -0
- data/docs/ConversationAgentAuthResponse.md +5 -3
- data/docs/ConversationApi.md +53 -2
- data/docs/ConversationEventQueuePosition.md +7 -0
- data/docs/ConversationMessage.md +1 -0
- data/docs/ConversationMessageTransportStatus.md +9 -0
- data/docs/ConversationMultimediaUploadUrl.md +9 -0
- data/docs/ConversationMultimediaUploadUrlResponse.md +12 -0
- data/docs/ConversationResponse.md +12 -0
- data/docs/ConversationStartRequest.md +1 -0
- data/docs/ConversationStartResponse.md +1 -2
- data/docs/ConversationWebsocketMessage.md +16 -0
- data/lib/ultracart_api/api/conversation_api.rb +58 -3
- data/lib/ultracart_api/models/auto_order.rb +10 -1
- data/lib/ultracart_api/models/auto_order_management.rb +185 -0
- data/lib/ultracart_api/models/conversation_agent_auth.rb +231 -0
- data/lib/ultracart_api/models/conversation_agent_auth_response.rb +38 -19
- data/lib/ultracart_api/models/conversation_event_queue_position.rb +175 -0
- data/lib/ultracart_api/models/conversation_message.rb +15 -4
- data/lib/ultracart_api/models/conversation_message_transport_status.rb +193 -0
- data/lib/ultracart_api/models/conversation_multimedia_upload_url.rb +193 -0
- data/lib/ultracart_api/models/conversation_multimedia_upload_url_response.rb +221 -0
- data/lib/ultracart_api/models/conversation_response.rb +221 -0
- data/lib/ultracart_api/models/conversation_start_request.rb +13 -4
- data/lib/ultracart_api/models/conversation_start_response.rb +7 -16
- data/lib/ultracart_api/models/conversation_websocket_message.rb +305 -0
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +8 -0
- metadata +18 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4af8b1802f29835912c31dbf47b4a6aace7bde8fe41ba6dc168301bdfc1d32c
|
4
|
+
data.tar.gz: 5c6db27fba9988151c4f8cdb2b2629471c7f3415573bb7f001573a5fea7d52da
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 809ed5a47539b0946f910a7b7a7351ee19b95860cece13d8d2dcef63123da38eb58ed555f407767ee3997ddaf04fe0b2bd658b20f73409ac16e60efde550a859
|
7
|
+
data.tar.gz: 42d8b1dc51470d12018937c5723c314db08eab31da54b3ec9e313e60f733e9c230424e3265cfcf2b6b114fcb6518bfa35a18936cf3211949c0e3500326b3dc5b
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
|
|
7
7
|
This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
|
8
8
|
|
9
9
|
- API version: 2.0.0
|
10
|
-
- Package version: 3.10.
|
10
|
+
- Package version: 3.10.23
|
11
11
|
- Build package: io.swagger.codegen.languages.RubyClientCodegen
|
12
12
|
For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
|
13
13
|
|
@@ -24,15 +24,15 @@ gem build ultracart_api.gemspec
|
|
24
24
|
Then either install the gem locally:
|
25
25
|
|
26
26
|
```shell
|
27
|
-
gem install ./ultracart_api-3.10.
|
27
|
+
gem install ./ultracart_api-3.10.23.gem
|
28
28
|
```
|
29
|
-
(for development, run `gem install --dev ./ultracart_api-3.10.
|
29
|
+
(for development, run `gem install --dev ./ultracart_api-3.10.23.gem` to install the development dependencies)
|
30
30
|
|
31
31
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
32
32
|
|
33
33
|
Finally add this to the Gemfile:
|
34
34
|
|
35
|
-
gem 'ultracart_api', '~> 3.10.
|
35
|
+
gem 'ultracart_api', '~> 3.10.23'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -127,6 +127,7 @@ Class | Method | HTTP request | Description
|
|
127
127
|
*UltracartClient::CheckoutApi* | [**validate_cart**](docs/CheckoutApi.md#validate_cart) | **POST** /checkout/cart/validate | Validate
|
128
128
|
*UltracartClient::ConversationApi* | [**get_agent_websocket_authorization**](docs/ConversationApi.md#get_agent_websocket_authorization) | **PUT** /conversation/agent/auth | Get agent websocket authorization
|
129
129
|
*UltracartClient::ConversationApi* | [**get_conversation**](docs/ConversationApi.md#get_conversation) | **GET** /conversation/conversations/{conversation_uuid} | Retrieve a conversation
|
130
|
+
*UltracartClient::ConversationApi* | [**get_conversation_multimedia_upload_url**](docs/ConversationApi.md#get_conversation_multimedia_upload_url) | **GET** /conversation/upload_url/{extension} | Get a presigned conersation multimedia upload URL
|
130
131
|
*UltracartClient::ConversationApi* | [**get_conversations**](docs/ConversationApi.md#get_conversations) | **GET** /conversation/conversations | Retrieve a list of conversation summaries newest to oldest
|
131
132
|
*UltracartClient::ConversationApi* | [**join_conversation**](docs/ConversationApi.md#join_conversation) | **PUT** /conversation/conversations/{conversation_uuid}/join | Join a conversation
|
132
133
|
*UltracartClient::ConversationApi* | [**leave_conversation**](docs/ConversationApi.md#leave_conversation) | **DELETE** /conversation/conversations/{conversation_uuid}/leave | Leave a conversation
|
@@ -465,6 +466,7 @@ Class | Method | HTTP request | Description
|
|
465
466
|
- [UltracartClient::AutoOrderItemOption](docs/AutoOrderItemOption.md)
|
466
467
|
- [UltracartClient::AutoOrderItemSimpleSchedule](docs/AutoOrderItemSimpleSchedule.md)
|
467
468
|
- [UltracartClient::AutoOrderLog](docs/AutoOrderLog.md)
|
469
|
+
- [UltracartClient::AutoOrderManagement](docs/AutoOrderManagement.md)
|
468
470
|
- [UltracartClient::AutoOrderQuery](docs/AutoOrderQuery.md)
|
469
471
|
- [UltracartClient::AutoOrderQueryBatch](docs/AutoOrderQueryBatch.md)
|
470
472
|
- [UltracartClient::AutoOrderResponse](docs/AutoOrderResponse.md)
|
@@ -555,12 +557,19 @@ Class | Method | HTTP request | Description
|
|
555
557
|
- [UltracartClient::CheckoutStateProvinceResponse](docs/CheckoutStateProvinceResponse.md)
|
556
558
|
- [UltracartClient::CityStateZip](docs/CityStateZip.md)
|
557
559
|
- [UltracartClient::Conversation](docs/Conversation.md)
|
560
|
+
- [UltracartClient::ConversationAgentAuth](docs/ConversationAgentAuth.md)
|
558
561
|
- [UltracartClient::ConversationAgentAuthResponse](docs/ConversationAgentAuthResponse.md)
|
562
|
+
- [UltracartClient::ConversationEventQueuePosition](docs/ConversationEventQueuePosition.md)
|
559
563
|
- [UltracartClient::ConversationMessage](docs/ConversationMessage.md)
|
564
|
+
- [UltracartClient::ConversationMessageTransportStatus](docs/ConversationMessageTransportStatus.md)
|
565
|
+
- [UltracartClient::ConversationMultimediaUploadUrl](docs/ConversationMultimediaUploadUrl.md)
|
566
|
+
- [UltracartClient::ConversationMultimediaUploadUrlResponse](docs/ConversationMultimediaUploadUrlResponse.md)
|
560
567
|
- [UltracartClient::ConversationParticipant](docs/ConversationParticipant.md)
|
568
|
+
- [UltracartClient::ConversationResponse](docs/ConversationResponse.md)
|
561
569
|
- [UltracartClient::ConversationStartRequest](docs/ConversationStartRequest.md)
|
562
570
|
- [UltracartClient::ConversationStartResponse](docs/ConversationStartResponse.md)
|
563
571
|
- [UltracartClient::ConversationSummary](docs/ConversationSummary.md)
|
572
|
+
- [UltracartClient::ConversationWebsocketMessage](docs/ConversationWebsocketMessage.md)
|
564
573
|
- [UltracartClient::ConversationsResponse](docs/ConversationsResponse.md)
|
565
574
|
- [UltracartClient::CountriesResponse](docs/CountriesResponse.md)
|
566
575
|
- [UltracartClient::Country](docs/Country.md)
|
@@ -1150,6 +1159,9 @@ Not every change is committed to every SDK.
|
|
1150
1159
|
|
1151
1160
|
| Version | Date | Comments |
|
1152
1161
|
| --: | :-: | --- |
|
1162
|
+
| 3.10.23 | 07/25/2022 | conversations - add a websocket message model |
|
1163
|
+
| 3.10.22 | 07/20/2022 | conversation participant name added |
|
1164
|
+
| 3.10.21 | 07/18/2022 | twilio dev |
|
1153
1165
|
| 3.10.20 | 07/14/2022 | Add channel storefront_oid to the customer activity record |
|
1154
1166
|
| 3.10.19 | 07/11/2022 | Customer API - mergeCustomer method |
|
1155
1167
|
| 3.10.18 | 06/23/2022 | removed unneeded consumes declarations on several api calls (yaml fix) |
|
data/docs/AutoOrder.md
CHANGED
@@ -18,6 +18,7 @@ Name | Type | Description | Notes
|
|
18
18
|
**failure_reason** | **String** | The reason this auto order failed during the last rebill attempt | [optional]
|
19
19
|
**items** | [**Array<AutoOrderItem>**](AutoOrderItem.md) | The items that are setup to rebill | [optional]
|
20
20
|
**logs** | [**Array<AutoOrderLog>**](AutoOrderLog.md) | Logs associated with this auto order | [optional]
|
21
|
+
**management** | [**AutoOrderManagement**](AutoOrderManagement.md) | | [optional]
|
21
22
|
**next_attempt** | **String** | The next time that the auto order will be attempted for processing | [optional]
|
22
23
|
**original_order** | [**Order**](Order.md) | | [optional]
|
23
24
|
**original_order_id** | **String** | The original order id that this auto order is associated with. | [optional]
|
@@ -0,0 +1,8 @@
|
|
1
|
+
# UltracartClient::AutoOrderManagement
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**update_billing_url** | **String** | URL where the customer can go to update their billing information. | [optional]
|
7
|
+
|
8
|
+
|
@@ -0,0 +1,13 @@
|
|
1
|
+
# UltracartClient::ConversationAgentAuth
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**conversation_participant_arn** | **String** | | [optional]
|
7
|
+
**conversation_participant_name** | **String** | | [optional]
|
8
|
+
**jwt** | **String** | | [optional]
|
9
|
+
**merchant_id** | **String** | | [optional]
|
10
|
+
**twilio_phone_numbers** | **Array<String>** | | [optional]
|
11
|
+
**websocket_url** | **String** | | [optional]
|
12
|
+
|
13
|
+
|
@@ -3,8 +3,10 @@
|
|
3
3
|
## Properties
|
4
4
|
Name | Type | Description | Notes
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
|
-
**
|
7
|
-
**
|
8
|
-
**
|
6
|
+
**agent_auth** | [**ConversationAgentAuth**](ConversationAgentAuth.md) | | [optional]
|
7
|
+
**error** | [**Error**](Error.md) | | [optional]
|
8
|
+
**metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional]
|
9
|
+
**success** | **BOOLEAN** | Indicates if API call was successful | [optional]
|
10
|
+
**warning** | [**Warning**](Warning.md) | | [optional]
|
9
11
|
|
10
12
|
|
data/docs/ConversationApi.md
CHANGED
@@ -6,6 +6,7 @@ Method | HTTP request | Description
|
|
6
6
|
------------- | ------------- | -------------
|
7
7
|
[**get_agent_websocket_authorization**](ConversationApi.md#get_agent_websocket_authorization) | **PUT** /conversation/agent/auth | Get agent websocket authorization
|
8
8
|
[**get_conversation**](ConversationApi.md#get_conversation) | **GET** /conversation/conversations/{conversation_uuid} | Retrieve a conversation
|
9
|
+
[**get_conversation_multimedia_upload_url**](ConversationApi.md#get_conversation_multimedia_upload_url) | **GET** /conversation/upload_url/{extension} | Get a presigned conersation multimedia upload URL
|
9
10
|
[**get_conversations**](ConversationApi.md#get_conversations) | **GET** /conversation/conversations | Retrieve a list of conversation summaries newest to oldest
|
10
11
|
[**join_conversation**](ConversationApi.md#join_conversation) | **PUT** /conversation/conversations/{conversation_uuid}/join | Join a conversation
|
11
12
|
[**leave_conversation**](ConversationApi.md#leave_conversation) | **DELETE** /conversation/conversations/{conversation_uuid}/leave | Leave a conversation
|
@@ -58,7 +59,7 @@ This endpoint does not need any parameter.
|
|
58
59
|
|
59
60
|
|
60
61
|
# **get_conversation**
|
61
|
-
>
|
62
|
+
> ConversationResponse get_conversation(conversation_uuid)
|
62
63
|
|
63
64
|
Retrieve a conversation
|
64
65
|
|
@@ -94,7 +95,57 @@ Name | Type | Description | Notes
|
|
94
95
|
|
95
96
|
### Return type
|
96
97
|
|
97
|
-
[**
|
98
|
+
[**ConversationResponse**](ConversationResponse.md)
|
99
|
+
|
100
|
+
### Authorization
|
101
|
+
|
102
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
103
|
+
|
104
|
+
### HTTP request headers
|
105
|
+
|
106
|
+
- **Content-Type**: application/json
|
107
|
+
- **Accept**: application/json
|
108
|
+
|
109
|
+
|
110
|
+
|
111
|
+
# **get_conversation_multimedia_upload_url**
|
112
|
+
> ConversationMultimediaUploadUrlResponse get_conversation_multimedia_upload_url(extension)
|
113
|
+
|
114
|
+
Get a presigned conersation multimedia upload URL
|
115
|
+
|
116
|
+
Get a presigned conersation multimedia upload URL
|
117
|
+
|
118
|
+
### Example
|
119
|
+
```ruby
|
120
|
+
# load the gem
|
121
|
+
require 'ultracart_api'
|
122
|
+
|
123
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
124
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
125
|
+
api_instance = UltracartClient::ConversationApi.new_using_api_key(simple_key, false, false)
|
126
|
+
|
127
|
+
|
128
|
+
extension = 'extension_example' # String |
|
129
|
+
|
130
|
+
|
131
|
+
begin
|
132
|
+
#Get a presigned conersation multimedia upload URL
|
133
|
+
result = api_instance.get_conversation_multimedia_upload_url(extension)
|
134
|
+
p result
|
135
|
+
rescue UltracartClient::ApiError => e
|
136
|
+
puts "Exception when calling ConversationApi->get_conversation_multimedia_upload_url: #{e}"
|
137
|
+
end
|
138
|
+
```
|
139
|
+
|
140
|
+
### Parameters
|
141
|
+
|
142
|
+
Name | Type | Description | Notes
|
143
|
+
------------- | ------------- | ------------- | -------------
|
144
|
+
**extension** | **String**| |
|
145
|
+
|
146
|
+
### Return type
|
147
|
+
|
148
|
+
[**ConversationMultimediaUploadUrlResponse**](ConversationMultimediaUploadUrlResponse.md)
|
98
149
|
|
99
150
|
### Authorization
|
100
151
|
|
data/docs/ConversationMessage.md
CHANGED
@@ -8,5 +8,6 @@ Name | Type | Description | Notes
|
|
8
8
|
**body** | **String** | | [optional]
|
9
9
|
**media_urls** | **Array<String>** | | [optional]
|
10
10
|
**message_dts** | **String** | Message date/time | [optional]
|
11
|
+
**transport_statuses** | [**Array<ConversationMessageTransportStatus>**](ConversationMessageTransportStatus.md) | | [optional]
|
11
12
|
|
12
13
|
|
@@ -0,0 +1,9 @@
|
|
1
|
+
# UltracartClient::ConversationMessageTransportStatus
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**conversation_participant_arn** | **String** | | [optional]
|
7
|
+
**status** | **String** | | [optional]
|
8
|
+
|
9
|
+
|
@@ -0,0 +1,12 @@
|
|
1
|
+
# UltracartClient::ConversationMultimediaUploadUrlResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**conversation_multimedia_upload_url** | [**ConversationMultimediaUploadUrl**](ConversationMultimediaUploadUrl.md) | | [optional]
|
7
|
+
**error** | [**Error**](Error.md) | | [optional]
|
8
|
+
**metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional]
|
9
|
+
**success** | **BOOLEAN** | Indicates if API call was successful | [optional]
|
10
|
+
**warning** | [**Warning**](Warning.md) | | [optional]
|
11
|
+
|
12
|
+
|
@@ -0,0 +1,12 @@
|
|
1
|
+
# UltracartClient::ConversationResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**conversation** | [**Conversation**](Conversation.md) | | [optional]
|
7
|
+
**error** | [**Error**](Error.md) | | [optional]
|
8
|
+
**metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional]
|
9
|
+
**success** | **BOOLEAN** | Indicates if API call was successful | [optional]
|
10
|
+
**warning** | [**Warning**](Warning.md) | | [optional]
|
11
|
+
|
12
|
+
|
@@ -5,5 +5,6 @@ Name | Type | Description | Notes
|
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
6
|
**add_conversation_participant_arns** | **Array<String>** | | [optional]
|
7
7
|
**conversation_arn** | **String** | | [optional]
|
8
|
+
**conversation_webchat_queue_uuid** | **String** | | [optional]
|
8
9
|
|
9
10
|
|
@@ -3,7 +3,6 @@
|
|
3
3
|
## Properties
|
4
4
|
Name | Type | Description | Notes
|
5
5
|
------------ | ------------- | ------------- | -------------
|
6
|
-
**
|
7
|
-
**conversation_uuid** | **String** | | [optional]
|
6
|
+
**conversation** | [**Conversation**](Conversation.md) | | [optional]
|
8
7
|
|
9
8
|
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# UltracartClient::ConversationWebsocketMessage
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**conversation_uuid** | **String** | Conversation UUID if the websocket message is tied to a specific conversation | [optional]
|
7
|
+
**event_conversation_closed** | [**Conversation**](Conversation.md) | | [optional]
|
8
|
+
**event_new_conversation** | [**Conversation**](Conversation.md) | | [optional]
|
9
|
+
**event_new_message** | [**ConversationMessage**](ConversationMessage.md) | | [optional]
|
10
|
+
**event_queue_position** | [**ConversationEventQueuePosition**](ConversationEventQueuePosition.md) | | [optional]
|
11
|
+
**event_type** | **String** | Type of event | [optional]
|
12
|
+
**event_updated_message** | [**ConversationMessage**](ConversationMessage.md) | | [optional]
|
13
|
+
**message** | [**ConversationMessage**](ConversationMessage.md) | | [optional]
|
14
|
+
**type** | **String** | Type of message | [optional]
|
15
|
+
|
16
|
+
|
@@ -85,7 +85,7 @@ module UltracartClient
|
|
85
85
|
# Retrieve a conversation including the participants and messages
|
86
86
|
# @param conversation_uuid
|
87
87
|
# @param [Hash] opts the optional parameters
|
88
|
-
# @return [
|
88
|
+
# @return [ConversationResponse]
|
89
89
|
def get_conversation(conversation_uuid, opts = {})
|
90
90
|
data, _status_code, _headers = get_conversation_with_http_info(conversation_uuid, opts)
|
91
91
|
data
|
@@ -95,7 +95,7 @@ module UltracartClient
|
|
95
95
|
# Retrieve a conversation including the participants and messages
|
96
96
|
# @param conversation_uuid
|
97
97
|
# @param [Hash] opts the optional parameters
|
98
|
-
# @return [Array<(
|
98
|
+
# @return [Array<(ConversationResponse, Fixnum, Hash)>] ConversationResponse data, response status code and response headers
|
99
99
|
def get_conversation_with_http_info(conversation_uuid, opts = {})
|
100
100
|
if @api_client.config.debugging
|
101
101
|
@api_client.config.logger.debug 'Calling API: ConversationApi.get_conversation ...'
|
@@ -130,12 +130,67 @@ module UltracartClient
|
|
130
130
|
:form_params => form_params,
|
131
131
|
:body => post_body,
|
132
132
|
:auth_names => auth_names,
|
133
|
-
:return_type => '
|
133
|
+
:return_type => 'ConversationResponse')
|
134
134
|
if @api_client.config.debugging
|
135
135
|
@api_client.config.logger.debug "API called: ConversationApi#get_conversation\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
136
136
|
end
|
137
137
|
return data, status_code, headers
|
138
138
|
end
|
139
|
+
# Get a presigned conersation multimedia upload URL
|
140
|
+
# Get a presigned conersation multimedia upload URL
|
141
|
+
# @param extension
|
142
|
+
# @param [Hash] opts the optional parameters
|
143
|
+
# @return [ConversationMultimediaUploadUrlResponse]
|
144
|
+
def get_conversation_multimedia_upload_url(extension, opts = {})
|
145
|
+
data, _status_code, _headers = get_conversation_multimedia_upload_url_with_http_info(extension, opts)
|
146
|
+
data
|
147
|
+
end
|
148
|
+
|
149
|
+
# Get a presigned conersation multimedia upload URL
|
150
|
+
# Get a presigned conersation multimedia upload URL
|
151
|
+
# @param extension
|
152
|
+
# @param [Hash] opts the optional parameters
|
153
|
+
# @return [Array<(ConversationMultimediaUploadUrlResponse, Fixnum, Hash)>] ConversationMultimediaUploadUrlResponse data, response status code and response headers
|
154
|
+
def get_conversation_multimedia_upload_url_with_http_info(extension, opts = {})
|
155
|
+
if @api_client.config.debugging
|
156
|
+
@api_client.config.logger.debug 'Calling API: ConversationApi.get_conversation_multimedia_upload_url ...'
|
157
|
+
end
|
158
|
+
# verify the required parameter 'extension' is set
|
159
|
+
if @api_client.config.client_side_validation && extension.nil?
|
160
|
+
fail ArgumentError, "Missing the required parameter 'extension' when calling ConversationApi.get_conversation_multimedia_upload_url"
|
161
|
+
end
|
162
|
+
# resource path
|
163
|
+
local_var_path = '/conversation/upload_url/{extension}'.sub('{' + 'extension' + '}', extension.to_s)
|
164
|
+
|
165
|
+
# query parameters
|
166
|
+
query_params = {}
|
167
|
+
|
168
|
+
# header parameters
|
169
|
+
header_params = {}
|
170
|
+
header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
|
171
|
+
# HTTP header 'Accept' (if needed)
|
172
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
173
|
+
# HTTP header 'Content-Type'
|
174
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
175
|
+
|
176
|
+
# form parameters
|
177
|
+
form_params = {}
|
178
|
+
|
179
|
+
# http body (model)
|
180
|
+
post_body = nil
|
181
|
+
auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
|
182
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
183
|
+
:header_params => header_params,
|
184
|
+
:query_params => query_params,
|
185
|
+
:form_params => form_params,
|
186
|
+
:body => post_body,
|
187
|
+
:auth_names => auth_names,
|
188
|
+
:return_type => 'ConversationMultimediaUploadUrlResponse')
|
189
|
+
if @api_client.config.debugging
|
190
|
+
@api_client.config.logger.debug "API called: ConversationApi#get_conversation_multimedia_upload_url\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
191
|
+
end
|
192
|
+
return data, status_code, headers
|
193
|
+
end
|
139
194
|
# Retrieve a list of conversation summaries newest to oldest
|
140
195
|
# Retrieve a list of conversation summaries that are ordered newest to oldest, include the most recent message and whether its been read.
|
141
196
|
# @param [Hash] opts the optional parameters
|
@@ -59,6 +59,8 @@ module UltracartClient
|
|
59
59
|
# Logs associated with this auto order
|
60
60
|
attr_accessor :logs
|
61
61
|
|
62
|
+
attr_accessor :management
|
63
|
+
|
62
64
|
# The next time that the auto order will be attempted for processing
|
63
65
|
attr_accessor :next_attempt
|
64
66
|
|
@@ -119,6 +121,7 @@ module UltracartClient
|
|
119
121
|
:'failure_reason' => :'failure_reason',
|
120
122
|
:'items' => :'items',
|
121
123
|
:'logs' => :'logs',
|
124
|
+
:'management' => :'management',
|
122
125
|
:'next_attempt' => :'next_attempt',
|
123
126
|
:'original_order' => :'original_order',
|
124
127
|
:'original_order_id' => :'original_order_id',
|
@@ -147,6 +150,7 @@ module UltracartClient
|
|
147
150
|
:'failure_reason' => :'String',
|
148
151
|
:'items' => :'Array<AutoOrderItem>',
|
149
152
|
:'logs' => :'Array<AutoOrderLog>',
|
153
|
+
:'management' => :'AutoOrderManagement',
|
150
154
|
:'next_attempt' => :'String',
|
151
155
|
:'original_order' => :'Order',
|
152
156
|
:'original_order_id' => :'String',
|
@@ -229,6 +233,10 @@ module UltracartClient
|
|
229
233
|
end
|
230
234
|
end
|
231
235
|
|
236
|
+
if attributes.has_key?(:'management')
|
237
|
+
self.management = attributes[:'management']
|
238
|
+
end
|
239
|
+
|
232
240
|
if attributes.has_key?(:'next_attempt')
|
233
241
|
self.next_attempt = attributes[:'next_attempt']
|
234
242
|
end
|
@@ -305,6 +313,7 @@ module UltracartClient
|
|
305
313
|
failure_reason == o.failure_reason &&
|
306
314
|
items == o.items &&
|
307
315
|
logs == o.logs &&
|
316
|
+
management == o.management &&
|
308
317
|
next_attempt == o.next_attempt &&
|
309
318
|
original_order == o.original_order &&
|
310
319
|
original_order_id == o.original_order_id &&
|
@@ -323,7 +332,7 @@ module UltracartClient
|
|
323
332
|
# Calculates hash code according to all attributes.
|
324
333
|
# @return [Fixnum] Hash code
|
325
334
|
def hash
|
326
|
-
[auto_order_code, auto_order_oid, cancel_after_next_x_orders, cancel_downgrade, cancel_reason, cancel_upgrade, canceled_by_user, canceled_dts, completed, credit_card_attempt, disabled_dts, enabled, failure_reason, items, logs, next_attempt, original_order, original_order_id, override_affiliate_id, rebill_orders, rotating_transaction_gateway_code, status].hash
|
335
|
+
[auto_order_code, auto_order_oid, cancel_after_next_x_orders, cancel_downgrade, cancel_reason, cancel_upgrade, canceled_by_user, canceled_dts, completed, credit_card_attempt, disabled_dts, enabled, failure_reason, items, logs, management, next_attempt, original_order, original_order_id, override_affiliate_id, rebill_orders, rotating_transaction_gateway_code, status].hash
|
327
336
|
end
|
328
337
|
|
329
338
|
# Builds the object from hash
|
@@ -0,0 +1,185 @@
|
|
1
|
+
=begin
|
2
|
+
#UltraCart Rest API V2
|
3
|
+
|
4
|
+
#UltraCart REST API Version 2
|
5
|
+
|
6
|
+
OpenAPI spec version: 2.0.0
|
7
|
+
Contact: support@ultracart.com
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 2.4.15-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module UltracartClient
|
16
|
+
class AutoOrderManagement
|
17
|
+
# URL where the customer can go to update their billing information.
|
18
|
+
attr_accessor :update_billing_url
|
19
|
+
|
20
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
21
|
+
def self.attribute_map
|
22
|
+
{
|
23
|
+
:'update_billing_url' => :'update_billing_url'
|
24
|
+
}
|
25
|
+
end
|
26
|
+
|
27
|
+
# Attribute type mapping.
|
28
|
+
def self.swagger_types
|
29
|
+
{
|
30
|
+
:'update_billing_url' => :'String'
|
31
|
+
}
|
32
|
+
end
|
33
|
+
|
34
|
+
# Initializes the object
|
35
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
36
|
+
def initialize(attributes = {})
|
37
|
+
return unless attributes.is_a?(Hash)
|
38
|
+
|
39
|
+
# convert string to symbol for hash key
|
40
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
41
|
+
|
42
|
+
if attributes.has_key?(:'update_billing_url')
|
43
|
+
self.update_billing_url = attributes[:'update_billing_url']
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
48
|
+
# @return Array for valid properties with the reasons
|
49
|
+
def list_invalid_properties
|
50
|
+
invalid_properties = Array.new
|
51
|
+
invalid_properties
|
52
|
+
end
|
53
|
+
|
54
|
+
# Check to see if the all the properties in the model are valid
|
55
|
+
# @return true if the model is valid
|
56
|
+
def valid?
|
57
|
+
true
|
58
|
+
end
|
59
|
+
|
60
|
+
# Checks equality by comparing each attribute.
|
61
|
+
# @param [Object] Object to be compared
|
62
|
+
def ==(o)
|
63
|
+
return true if self.equal?(o)
|
64
|
+
self.class == o.class &&
|
65
|
+
update_billing_url == o.update_billing_url
|
66
|
+
end
|
67
|
+
|
68
|
+
# @see the `==` method
|
69
|
+
# @param [Object] Object to be compared
|
70
|
+
def eql?(o)
|
71
|
+
self == o
|
72
|
+
end
|
73
|
+
|
74
|
+
# Calculates hash code according to all attributes.
|
75
|
+
# @return [Fixnum] Hash code
|
76
|
+
def hash
|
77
|
+
[update_billing_url].hash
|
78
|
+
end
|
79
|
+
|
80
|
+
# Builds the object from hash
|
81
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
82
|
+
# @return [Object] Returns the model itself
|
83
|
+
def build_from_hash(attributes)
|
84
|
+
return nil unless attributes.is_a?(Hash)
|
85
|
+
self.class.swagger_types.each_pair do |key, type|
|
86
|
+
if type =~ /\AArray<(.*)>/i
|
87
|
+
# check to ensure the input is an array given that the attribute
|
88
|
+
# is documented as an array but the input is not
|
89
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
90
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
91
|
+
end
|
92
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
93
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
94
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
95
|
+
end
|
96
|
+
|
97
|
+
self
|
98
|
+
end
|
99
|
+
|
100
|
+
# Deserializes the data based on type
|
101
|
+
# @param string type Data type
|
102
|
+
# @param string value Value to be deserialized
|
103
|
+
# @return [Object] Deserialized data
|
104
|
+
def _deserialize(type, value)
|
105
|
+
case type.to_sym
|
106
|
+
when :DateTime
|
107
|
+
DateTime.parse(value)
|
108
|
+
when :Date
|
109
|
+
Date.parse(value)
|
110
|
+
when :String
|
111
|
+
value.to_s
|
112
|
+
when :Integer
|
113
|
+
value.to_i
|
114
|
+
when :Float
|
115
|
+
value.to_f
|
116
|
+
when :BOOLEAN
|
117
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
118
|
+
true
|
119
|
+
else
|
120
|
+
false
|
121
|
+
end
|
122
|
+
when :Object
|
123
|
+
# generic object (usually a Hash), return directly
|
124
|
+
value
|
125
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
126
|
+
inner_type = Regexp.last_match[:inner_type]
|
127
|
+
value.map { |v| _deserialize(inner_type, v) }
|
128
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
129
|
+
k_type = Regexp.last_match[:k_type]
|
130
|
+
v_type = Regexp.last_match[:v_type]
|
131
|
+
{}.tap do |hash|
|
132
|
+
value.each do |k, v|
|
133
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
134
|
+
end
|
135
|
+
end
|
136
|
+
else # model
|
137
|
+
temp_model = UltracartClient.const_get(type).new
|
138
|
+
temp_model.build_from_hash(value)
|
139
|
+
end
|
140
|
+
end
|
141
|
+
|
142
|
+
# Returns the string representation of the object
|
143
|
+
# @return [String] String presentation of the object
|
144
|
+
def to_s
|
145
|
+
to_hash.to_s
|
146
|
+
end
|
147
|
+
|
148
|
+
# to_body is an alias to to_hash (backward compatibility)
|
149
|
+
# @return [Hash] Returns the object in the form of hash
|
150
|
+
def to_body
|
151
|
+
to_hash
|
152
|
+
end
|
153
|
+
|
154
|
+
# Returns the object in the form of hash
|
155
|
+
# @return [Hash] Returns the object in the form of hash
|
156
|
+
def to_hash
|
157
|
+
hash = {}
|
158
|
+
self.class.attribute_map.each_pair do |attr, param|
|
159
|
+
value = self.send(attr)
|
160
|
+
next if value.nil?
|
161
|
+
hash[param] = _to_hash(value)
|
162
|
+
end
|
163
|
+
hash
|
164
|
+
end
|
165
|
+
|
166
|
+
# Outputs non-array value in the form of hash
|
167
|
+
# For object, use to_hash. Otherwise, just return the value
|
168
|
+
# @param [Object] value Any valid value
|
169
|
+
# @return [Hash] Returns the value in the form of hash
|
170
|
+
def _to_hash(value)
|
171
|
+
if value.is_a?(Array)
|
172
|
+
value.compact.map { |v| _to_hash(v) }
|
173
|
+
elsif value.is_a?(Hash)
|
174
|
+
{}.tap do |hash|
|
175
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
176
|
+
end
|
177
|
+
elsif value.respond_to? :to_hash
|
178
|
+
value.to_hash
|
179
|
+
else
|
180
|
+
value
|
181
|
+
end
|
182
|
+
end
|
183
|
+
|
184
|
+
end
|
185
|
+
end
|