ultracart_api 4.1.6 → 4.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: ed8c71b6e4bad744845429cdd519ad937699ac4684eb127332c7c69b4d3245ce
4
- data.tar.gz: e63ba4ff933c97f8dd0b3d9cc98e7cca19f2fe0e4169066e448524fc2f777053
3
+ metadata.gz: a789bd43b52d5866664c1837873821b6f3a262dfa9bf0030d3a47fe0b9fb4cbc
4
+ data.tar.gz: cf9e7b5917b35d33d1d3fe95c651c4a4736be131ab9a92bdaf0582ddef2063c4
5
5
  SHA512:
6
- metadata.gz: 0146a01bde61c58a2dd303c057f3aafab80c4a953df104fca9bf40ee6cbf7f1b69884f49cfca99c708eeb46e14562e69ca05d7f06449178375c42eccb8fc9b73
7
- data.tar.gz: 5e01eb34847239d3e5b4acdae31ca2dfc4e4ff9c041ffa0415819e7266e9d3e82780cb368dee46e25b6d3e9774bd643ed0c545782f35be4fa4a407da903a557a
6
+ metadata.gz: 4ccc90aa708f24774678dd2bef2725df0efffea428b0ed043d3b13403266a4a96b569c850b37a56508b938dcb58fd5386953cc3bbc5bb8ce31c3b0c8159f1225
7
+ data.tar.gz: '0263095e6d985b10576a63b409f63812843675d8253f55e542fecd485a628908e199981684e1dac35ff70b8b06220d73b5056f2de5317fcefd602bc630083148'
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.6
10
+ - Package version: 4.1.8
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.6'
19
+ gem 'ultracart_api', '4.1.8'
20
20
  ```
21
21
 
22
22
  install:
@@ -102,6 +102,7 @@ Class | Method | HTTP request | Description
102
102
  *UltracartClient::ChannelPartnerApi* | [**estimate_tax_for_channel_partner_order**](docs/ChannelPartnerApi.md#estimate_tax_for_channel_partner_order) | **POST** /channel_partner/estimate_tax | Estimate tax for channel partner order
103
103
  *UltracartClient::ChannelPartnerApi* | [**get_channel_partner_order**](docs/ChannelPartnerApi.md#get_channel_partner_order) | **GET** /channel_partner/orders/{order_id} | Retrieve a channel partner order
104
104
  *UltracartClient::ChannelPartnerApi* | [**get_channel_partner_order_by_channel_partner_order_id**](docs/ChannelPartnerApi.md#get_channel_partner_order_by_channel_partner_order_id) | **GET** /channel_partner/orders/by_channel_partner_order_id/{order_id} | Retrieve a channel partner order by the channel partner order id
105
+ *UltracartClient::ChannelPartnerApi* | [**get_channel_partner_reason_codes**](docs/ChannelPartnerApi.md#get_channel_partner_reason_codes) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/reason_codes | Retrieve reject and refund reason codes.
105
106
  *UltracartClient::ChannelPartnerApi* | [**get_channel_partner_ship_to_preference**](docs/ChannelPartnerApi.md#get_channel_partner_ship_to_preference) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/ship_to_preferences/{channel_partner_ship_to_preference_oid} | Retrieve the ship to preference associated with the channel partner and the specific id.
106
107
  *UltracartClient::ChannelPartnerApi* | [**get_channel_partner_ship_to_preferences**](docs/ChannelPartnerApi.md#get_channel_partner_ship_to_preferences) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/ship_to_preferences | Retrieve the ship to preferences associated with the channel partner.
107
108
  *UltracartClient::ChannelPartnerApi* | [**get_channel_partners**](docs/ChannelPartnerApi.md#get_channel_partners) | **GET** /channel_partner/channel_partners | Retrieve the channel partners configured on the account.
@@ -689,6 +690,7 @@ Class | Method | HTTP request | Description
689
690
  - [UltracartClient::CartUpsellAfter](docs/CartUpsellAfter.md)
690
691
  - [UltracartClient::CartValidationRequest](docs/CartValidationRequest.md)
691
692
  - [UltracartClient::CartValidationResponse](docs/CartValidationResponse.md)
693
+ - [UltracartClient::ChanelPartnerReasonCodesResponse](docs/ChanelPartnerReasonCodesResponse.md)
692
694
  - [UltracartClient::ChannelPartner](docs/ChannelPartner.md)
693
695
  - [UltracartClient::ChannelPartnerCancelResponse](docs/ChannelPartnerCancelResponse.md)
694
696
  - [UltracartClient::ChannelPartnerEstimateShippingResponse](docs/ChannelPartnerEstimateShippingResponse.md)
@@ -1518,6 +1520,8 @@ Not every change is committed to every SDK.
1518
1520
 
1519
1521
  | Version | Date | Comments |
1520
1522
  | --: | :-: | --- |
1523
+ | 4.1.8 | 04/22/2025 | order property fields for created_by and created_dts |
1524
+ | 4.1.7 | 04/21/2025 | conversation agent additional fields |
1521
1525
  | 4.1.6 | 04/16/2025 | added channel partner order item properties |
1522
1526
  | 4.1.5 | 03/28/2025 | added paypal fastlane constants for payments |
1523
1527
  | 4.1.4 | 03/07/2025 | updated github readme.md |
@@ -0,0 +1,38 @@
1
+ # UltracartClient::ChanelPartnerReasonCodesResponse
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **error** | [**Error**](Error.md) | | [optional] |
8
+ | **item_level_refund_reason_required** | **Boolean** | True if the item level refund reason is required | [optional] |
9
+ | **item_level_refund_reasons** | [**Array<OrderReason>**](OrderReason.md) | Reason codes available at the item level. | [optional] |
10
+ | **item_level_return_reasons** | [**Array<OrderReason>**](OrderReason.md) | Return codes available at the item level. | [optional] |
11
+ | **metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional] |
12
+ | **order_level_refund_reason_required** | **Boolean** | True if the order level refund reason is required | [optional] |
13
+ | **order_level_refund_reasons** | [**Array<OrderReason>**](OrderReason.md) | Reason codes available at the order level. | [optional] |
14
+ | **order_level_reject_reason_required** | **Boolean** | True if the order level reject reason is required | [optional] |
15
+ | **order_level_reject_reasons** | [**Array<OrderReason>**](OrderReason.md) | Reject codes available at the order level. | [optional] |
16
+ | **success** | **Boolean** | Indicates if API call was successful | [optional] |
17
+ | **warning** | [**Warning**](Warning.md) | | [optional] |
18
+
19
+ ## Example
20
+
21
+ ```ruby
22
+ require 'ultracart_api'
23
+
24
+ instance = UltracartClient::ChanelPartnerReasonCodesResponse.new(
25
+ error: null,
26
+ item_level_refund_reason_required: null,
27
+ item_level_refund_reasons: null,
28
+ item_level_return_reasons: null,
29
+ metadata: null,
30
+ order_level_refund_reason_required: null,
31
+ order_level_refund_reasons: null,
32
+ order_level_reject_reason_required: null,
33
+ order_level_reject_reasons: null,
34
+ success: null,
35
+ warning: null
36
+ )
37
+ ```
38
+
@@ -11,6 +11,7 @@ All URIs are relative to *https://secure.ultracart.com/rest/v2*
11
11
  | [**estimate_tax_for_channel_partner_order**](ChannelPartnerApi.md#estimate_tax_for_channel_partner_order) | **POST** /channel_partner/estimate_tax | Estimate tax for channel partner order |
12
12
  | [**get_channel_partner_order**](ChannelPartnerApi.md#get_channel_partner_order) | **GET** /channel_partner/orders/{order_id} | Retrieve a channel partner order |
13
13
  | [**get_channel_partner_order_by_channel_partner_order_id**](ChannelPartnerApi.md#get_channel_partner_order_by_channel_partner_order_id) | **GET** /channel_partner/orders/by_channel_partner_order_id/{order_id} | Retrieve a channel partner order by the channel partner order id |
14
+ | [**get_channel_partner_reason_codes**](ChannelPartnerApi.md#get_channel_partner_reason_codes) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/reason_codes | Retrieve reject and refund reason codes. |
14
15
  | [**get_channel_partner_ship_to_preference**](ChannelPartnerApi.md#get_channel_partner_ship_to_preference) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/ship_to_preferences/{channel_partner_ship_to_preference_oid} | Retrieve the ship to preference associated with the channel partner and the specific id. |
15
16
  | [**get_channel_partner_ship_to_preferences**](ChannelPartnerApi.md#get_channel_partner_ship_to_preferences) | **GET** /channel_partner/channel_partners/{channel_partner_oid}/ship_to_preferences | Retrieve the ship to preferences associated with the channel partner. |
16
17
  | [**get_channel_partners**](ChannelPartnerApi.md#get_channel_partners) | **GET** /channel_partner/channel_partners | Retrieve the channel partners configured on the account. |
@@ -526,6 +527,77 @@ end
526
527
  - **Accept**: application/json
527
528
 
528
529
 
530
+ ## get_channel_partner_reason_codes
531
+
532
+ > <ChanelPartnerReasonCodesResponse> get_channel_partner_reason_codes(channel_partner_oid)
533
+
534
+ Retrieve reject and refund reason codes.
535
+
536
+ Retrieve reject and refund reason codes.
537
+
538
+ ### Examples
539
+
540
+ ```ruby
541
+ require 'time'
542
+ require 'ultracart_api'
543
+ require 'json'
544
+ require 'yaml'
545
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
546
+
547
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
548
+ # As such, this might not be the best way to use this object.
549
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
550
+
551
+ api = UltracartClient::ChannelPartnerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
552
+ channel_partner_oid = 56 # Integer |
553
+
554
+ begin
555
+ # Retrieve reject and refund reason codes.
556
+ result = api_instance.get_channel_partner_reason_codes(channel_partner_oid)
557
+ p result
558
+ rescue UltracartClient::ApiError => e
559
+ puts "Error when calling ChannelPartnerApi->get_channel_partner_reason_codes: #{e}"
560
+ end
561
+ ```
562
+
563
+ #### Using the get_channel_partner_reason_codes_with_http_info variant
564
+
565
+ This returns an Array which contains the response data, status code and headers.
566
+
567
+ > <Array(<ChanelPartnerReasonCodesResponse>, Integer, Hash)> get_channel_partner_reason_codes_with_http_info(channel_partner_oid)
568
+
569
+ ```ruby
570
+ begin
571
+ # Retrieve reject and refund reason codes.
572
+ data, status_code, headers = api_instance.get_channel_partner_reason_codes_with_http_info(channel_partner_oid)
573
+ p status_code # => 2xx
574
+ p headers # => { ... }
575
+ p data # => <ChanelPartnerReasonCodesResponse>
576
+ rescue UltracartClient::ApiError => e
577
+ puts "Error when calling ChannelPartnerApi->get_channel_partner_reason_codes_with_http_info: #{e}"
578
+ end
579
+ ```
580
+
581
+ ### Parameters
582
+
583
+ | Name | Type | Description | Notes |
584
+ | ---- | ---- | ----------- | ----- |
585
+ | **channel_partner_oid** | **Integer** | | |
586
+
587
+ ### Return type
588
+
589
+ [**ChanelPartnerReasonCodesResponse**](ChanelPartnerReasonCodesResponse.md)
590
+
591
+ ### Authorization
592
+
593
+ [ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
594
+
595
+ ### HTTP request headers
596
+
597
+ - **Content-Type**: Not defined
598
+ - **Accept**: application/json
599
+
600
+
529
601
  ## get_channel_partner_ship_to_preference
530
602
 
531
603
  > <ChannelPartnerShipToPreferenceResponse> get_channel_partner_ship_to_preference(channel_partner_oid, channel_partner_ship_to_preference_oid)
@@ -4,6 +4,10 @@
4
4
 
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
+ | **ai** | **Boolean** | AI powered chat bot | [optional] |
8
+ | **ai_chat_instructions** | **String** | Additional instructions for this AI when handle web chats | [optional] |
9
+ | **ai_persona** | **String** | Persona of this AI agent | [optional] |
10
+ | **ai_sms_instructions** | **String** | Additional instructions for this AI when handle SMS messages | [optional] |
7
11
  | **chat_limit** | **Integer** | The number of engagement chats that can be pushed on them at any given time. | [optional] |
8
12
  | **default_language_iso_code** | **String** | The default language the agent is chatting in | [optional] |
9
13
  | **default_status** | **String** | Default status when the agent loads conversations app. | [optional] |
@@ -18,6 +22,10 @@
18
22
  require 'ultracart_api'
19
23
 
20
24
  instance = UltracartClient::ConversationAgentProfile.new(
25
+ ai: null,
26
+ ai_chat_instructions: null,
27
+ ai_persona: null,
28
+ ai_sms_instructions: null,
21
29
  chat_limit: null,
22
30
  default_language_iso_code: null,
23
31
  default_status: null,
@@ -4,6 +4,8 @@
4
4
 
5
5
  | Name | Type | Description | Notes |
6
6
  | ---- | ---- | ----------- | ----- |
7
+ | **created_by** | **String** | Created by user | [optional] |
8
+ | **created_dts** | **String** | The date/time that the property was created by the user | [optional] |
7
9
  | **display** | **Boolean** | True if this property is displayed to the customer | [optional] |
8
10
  | **expiration_dts** | **String** | The date/time that the property expires and is deleted | [optional] |
9
11
  | **name** | **String** | Name | [optional] |
@@ -15,6 +17,8 @@
15
17
  require 'ultracart_api'
16
18
 
17
19
  instance = UltracartClient::OrderProperty.new(
20
+ created_by: null,
21
+ created_dts: null,
18
22
  display: null,
19
23
  expiration_dts: null,
20
24
  name: null,
@@ -502,6 +502,70 @@ module UltracartClient
502
502
  return data, status_code, headers
503
503
  end
504
504
 
505
+ # Retrieve reject and refund reason codes.
506
+ # Retrieve reject and refund reason codes.
507
+ # @param channel_partner_oid [Integer]
508
+ # @param [Hash] opts the optional parameters
509
+ # @return [ChanelPartnerReasonCodesResponse]
510
+ def get_channel_partner_reason_codes(channel_partner_oid, opts = {})
511
+ data, _status_code, _headers = get_channel_partner_reason_codes_with_http_info(channel_partner_oid, opts)
512
+ data
513
+ end
514
+
515
+ # Retrieve reject and refund reason codes.
516
+ # Retrieve reject and refund reason codes.
517
+ # @param channel_partner_oid [Integer]
518
+ # @param [Hash] opts the optional parameters
519
+ # @return [Array<(ChanelPartnerReasonCodesResponse, Integer, Hash)>] ChanelPartnerReasonCodesResponse data, response status code and response headers
520
+ def get_channel_partner_reason_codes_with_http_info(channel_partner_oid, opts = {})
521
+ if @api_client.config.debugging
522
+ @api_client.config.logger.debug 'Calling API: ChannelPartnerApi.get_channel_partner_reason_codes ...'
523
+ end
524
+ # verify the required parameter 'channel_partner_oid' is set
525
+ if @api_client.config.client_side_validation && channel_partner_oid.nil?
526
+ fail ArgumentError, "Missing the required parameter 'channel_partner_oid' when calling ChannelPartnerApi.get_channel_partner_reason_codes"
527
+ end
528
+ # resource path
529
+ local_var_path = '/channel_partner/channel_partners/{channel_partner_oid}/reason_codes'.sub('{' + 'channel_partner_oid' + '}', CGI.escape(channel_partner_oid.to_s))
530
+
531
+ # query parameters
532
+ query_params = opts[:query_params] || {}
533
+
534
+ # header parameters
535
+ header_params = opts[:header_params] || {}
536
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
537
+ # HTTP header 'Accept' (if needed)
538
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
539
+
540
+ # form parameters
541
+ form_params = opts[:form_params] || {}
542
+
543
+ # http body (model)
544
+ post_body = opts[:debug_body]
545
+
546
+ # return_type
547
+ return_type = opts[:debug_return_type] || 'ChanelPartnerReasonCodesResponse'
548
+
549
+ # auth_names
550
+ auth_names = opts[:debug_auth_names] || ['ultraCartOauth', 'ultraCartSimpleApiKey']
551
+
552
+ new_options = opts.merge(
553
+ :operation => :"ChannelPartnerApi.get_channel_partner_reason_codes",
554
+ :header_params => header_params,
555
+ :query_params => query_params,
556
+ :form_params => form_params,
557
+ :body => post_body,
558
+ :auth_names => auth_names,
559
+ :return_type => return_type
560
+ )
561
+
562
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
563
+ if @api_client.config.debugging
564
+ @api_client.config.logger.debug "API called: ChannelPartnerApi#get_channel_partner_reason_codes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
565
+ end
566
+ return data, status_code, headers
567
+ end
568
+
505
569
  # Retrieve the ship to preference associated with the channel partner and the specific id.
506
570
  # Retrieve the ship to preference associated with the channel partner and the specific id.
507
571
  # @param channel_partner_oid [Integer]
@@ -0,0 +1,325 @@
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 ChanelPartnerReasonCodesResponse
18
+ attr_accessor :error
19
+
20
+ # True if the item level refund reason is required
21
+ attr_accessor :item_level_refund_reason_required
22
+
23
+ # Reason codes available at the item level.
24
+ attr_accessor :item_level_refund_reasons
25
+
26
+ # Return codes available at the item level.
27
+ attr_accessor :item_level_return_reasons
28
+
29
+ attr_accessor :metadata
30
+
31
+ # True if the order level refund reason is required
32
+ attr_accessor :order_level_refund_reason_required
33
+
34
+ # Reason codes available at the order level.
35
+ attr_accessor :order_level_refund_reasons
36
+
37
+ # True if the order level reject reason is required
38
+ attr_accessor :order_level_reject_reason_required
39
+
40
+ # Reject codes available at the order level.
41
+ attr_accessor :order_level_reject_reasons
42
+
43
+ # Indicates if API call was successful
44
+ attr_accessor :success
45
+
46
+ attr_accessor :warning
47
+
48
+ # Attribute mapping from ruby-style variable name to JSON key.
49
+ def self.attribute_map
50
+ {
51
+ :'error' => :'error',
52
+ :'item_level_refund_reason_required' => :'item_level_refund_reason_required',
53
+ :'item_level_refund_reasons' => :'item_level_refund_reasons',
54
+ :'item_level_return_reasons' => :'item_level_return_reasons',
55
+ :'metadata' => :'metadata',
56
+ :'order_level_refund_reason_required' => :'order_level_refund_reason_required',
57
+ :'order_level_refund_reasons' => :'order_level_refund_reasons',
58
+ :'order_level_reject_reason_required' => :'order_level_reject_reason_required',
59
+ :'order_level_reject_reasons' => :'order_level_reject_reasons',
60
+ :'success' => :'success',
61
+ :'warning' => :'warning'
62
+ }
63
+ end
64
+
65
+ # Returns all the JSON keys this model knows about
66
+ def self.acceptable_attributes
67
+ attribute_map.values
68
+ end
69
+
70
+ # Attribute type mapping.
71
+ def self.openapi_types
72
+ {
73
+ :'error' => :'Error',
74
+ :'item_level_refund_reason_required' => :'Boolean',
75
+ :'item_level_refund_reasons' => :'Array<OrderReason>',
76
+ :'item_level_return_reasons' => :'Array<OrderReason>',
77
+ :'metadata' => :'ResponseMetadata',
78
+ :'order_level_refund_reason_required' => :'Boolean',
79
+ :'order_level_refund_reasons' => :'Array<OrderReason>',
80
+ :'order_level_reject_reason_required' => :'Boolean',
81
+ :'order_level_reject_reasons' => :'Array<OrderReason>',
82
+ :'success' => :'Boolean',
83
+ :'warning' => :'Warning'
84
+ }
85
+ end
86
+
87
+ # List of attributes with nullable: true
88
+ def self.openapi_nullable
89
+ Set.new([
90
+ ])
91
+ end
92
+
93
+ # Initializes the object
94
+ # @param [Hash] attributes Model attributes in the form of hash
95
+ def initialize(attributes = {})
96
+ if (!attributes.is_a?(Hash))
97
+ fail ArgumentError, "The input argument (attributes) must be a hash in `UltracartClient::ChanelPartnerReasonCodesResponse` initialize method"
98
+ end
99
+
100
+ # check to see if the attribute exists and convert string to symbol for hash key
101
+ attributes = attributes.each_with_object({}) { |(k, v), h|
102
+ if (!self.class.attribute_map.key?(k.to_sym))
103
+ fail ArgumentError, "`#{k}` is not a valid attribute in `UltracartClient::ChanelPartnerReasonCodesResponse`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
104
+ end
105
+ h[k.to_sym] = v
106
+ }
107
+
108
+ if attributes.key?(:'error')
109
+ self.error = attributes[:'error']
110
+ end
111
+
112
+ if attributes.key?(:'item_level_refund_reason_required')
113
+ self.item_level_refund_reason_required = attributes[:'item_level_refund_reason_required']
114
+ end
115
+
116
+ if attributes.key?(:'item_level_refund_reasons')
117
+ if (value = attributes[:'item_level_refund_reasons']).is_a?(Array)
118
+ self.item_level_refund_reasons = value
119
+ end
120
+ end
121
+
122
+ if attributes.key?(:'item_level_return_reasons')
123
+ if (value = attributes[:'item_level_return_reasons']).is_a?(Array)
124
+ self.item_level_return_reasons = value
125
+ end
126
+ end
127
+
128
+ if attributes.key?(:'metadata')
129
+ self.metadata = attributes[:'metadata']
130
+ end
131
+
132
+ if attributes.key?(:'order_level_refund_reason_required')
133
+ self.order_level_refund_reason_required = attributes[:'order_level_refund_reason_required']
134
+ end
135
+
136
+ if attributes.key?(:'order_level_refund_reasons')
137
+ if (value = attributes[:'order_level_refund_reasons']).is_a?(Array)
138
+ self.order_level_refund_reasons = value
139
+ end
140
+ end
141
+
142
+ if attributes.key?(:'order_level_reject_reason_required')
143
+ self.order_level_reject_reason_required = attributes[:'order_level_reject_reason_required']
144
+ end
145
+
146
+ if attributes.key?(:'order_level_reject_reasons')
147
+ if (value = attributes[:'order_level_reject_reasons']).is_a?(Array)
148
+ self.order_level_reject_reasons = value
149
+ end
150
+ end
151
+
152
+ if attributes.key?(:'success')
153
+ self.success = attributes[:'success']
154
+ end
155
+
156
+ if attributes.key?(:'warning')
157
+ self.warning = attributes[:'warning']
158
+ end
159
+ end
160
+
161
+ # Show invalid properties with the reasons. Usually used together with valid?
162
+ # @return Array for valid properties with the reasons
163
+ def list_invalid_properties
164
+ invalid_properties = Array.new
165
+ invalid_properties
166
+ end
167
+
168
+ # Check to see if the all the properties in the model are valid
169
+ # @return true if the model is valid
170
+ def valid?
171
+ true
172
+ end
173
+
174
+ # Checks equality by comparing each attribute.
175
+ # @param [Object] Object to be compared
176
+ def ==(o)
177
+ return true if self.equal?(o)
178
+ self.class == o.class &&
179
+ error == o.error &&
180
+ item_level_refund_reason_required == o.item_level_refund_reason_required &&
181
+ item_level_refund_reasons == o.item_level_refund_reasons &&
182
+ item_level_return_reasons == o.item_level_return_reasons &&
183
+ metadata == o.metadata &&
184
+ order_level_refund_reason_required == o.order_level_refund_reason_required &&
185
+ order_level_refund_reasons == o.order_level_refund_reasons &&
186
+ order_level_reject_reason_required == o.order_level_reject_reason_required &&
187
+ order_level_reject_reasons == o.order_level_reject_reasons &&
188
+ success == o.success &&
189
+ warning == o.warning
190
+ end
191
+
192
+ # @see the `==` method
193
+ # @param [Object] Object to be compared
194
+ def eql?(o)
195
+ self == o
196
+ end
197
+
198
+ # Calculates hash code according to all attributes.
199
+ # @return [Integer] Hash code
200
+ def hash
201
+ [error, item_level_refund_reason_required, item_level_refund_reasons, item_level_return_reasons, metadata, order_level_refund_reason_required, order_level_refund_reasons, order_level_reject_reason_required, order_level_reject_reasons, success, warning].hash
202
+ end
203
+
204
+ # Builds the object from hash
205
+ # @param [Hash] attributes Model attributes in the form of hash
206
+ # @return [Object] Returns the model itself
207
+ def self.build_from_hash(attributes)
208
+ new.build_from_hash(attributes)
209
+ end
210
+
211
+ # Builds the object from hash
212
+ # @param [Hash] attributes Model attributes in the form of hash
213
+ # @return [Object] Returns the model itself
214
+ def build_from_hash(attributes)
215
+ return nil unless attributes.is_a?(Hash)
216
+ attributes = attributes.transform_keys(&:to_sym)
217
+ self.class.openapi_types.each_pair do |key, type|
218
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
219
+ self.send("#{key}=", nil)
220
+ elsif type =~ /\AArray<(.*)>/i
221
+ # check to ensure the input is an array given that the attribute
222
+ # is documented as an array but the input is not
223
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
224
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
225
+ end
226
+ elsif !attributes[self.class.attribute_map[key]].nil?
227
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
228
+ end
229
+ end
230
+
231
+ self
232
+ end
233
+
234
+ # Deserializes the data based on type
235
+ # @param string type Data type
236
+ # @param string value Value to be deserialized
237
+ # @return [Object] Deserialized data
238
+ def _deserialize(type, value)
239
+ case type.to_sym
240
+ when :Time
241
+ Time.parse(value)
242
+ when :Date
243
+ Date.parse(value)
244
+ when :String
245
+ value.to_s
246
+ when :Integer
247
+ value.to_i
248
+ when :Float
249
+ value.to_f
250
+ when :Boolean
251
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
252
+ true
253
+ else
254
+ false
255
+ end
256
+ when :Object
257
+ # generic object (usually a Hash), return directly
258
+ value
259
+ when /\AArray<(?<inner_type>.+)>\z/
260
+ inner_type = Regexp.last_match[:inner_type]
261
+ value.map { |v| _deserialize(inner_type, v) }
262
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
263
+ k_type = Regexp.last_match[:k_type]
264
+ v_type = Regexp.last_match[:v_type]
265
+ {}.tap do |hash|
266
+ value.each do |k, v|
267
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
268
+ end
269
+ end
270
+ else # model
271
+ # models (e.g. Pet) or oneOf
272
+ klass = UltracartClient.const_get(type)
273
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
274
+ end
275
+ end
276
+
277
+ # Returns the string representation of the object
278
+ # @return [String] String presentation of the object
279
+ def to_s
280
+ to_hash.to_s
281
+ end
282
+
283
+ # to_body is an alias to to_hash (backward compatibility)
284
+ # @return [Hash] Returns the object in the form of hash
285
+ def to_body
286
+ to_hash
287
+ end
288
+
289
+ # Returns the object in the form of hash
290
+ # @return [Hash] Returns the object in the form of hash
291
+ def to_hash
292
+ hash = {}
293
+ self.class.attribute_map.each_pair do |attr, param|
294
+ value = self.send(attr)
295
+ if value.nil?
296
+ is_nullable = self.class.openapi_nullable.include?(attr)
297
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
298
+ end
299
+
300
+ hash[param] = _to_hash(value)
301
+ end
302
+ hash
303
+ end
304
+
305
+ # Outputs non-array value in the form of hash
306
+ # For object, use to_hash. Otherwise, just return the value
307
+ # @param [Object] value Any valid value
308
+ # @return [Hash] Returns the value in the form of hash
309
+ def _to_hash(value)
310
+ if value.is_a?(Array)
311
+ value.compact.map { |v| _to_hash(v) }
312
+ elsif value.is_a?(Hash)
313
+ {}.tap do |hash|
314
+ value.each { |k, v| hash[k] = _to_hash(v) }
315
+ end
316
+ elsif value.respond_to? :to_hash
317
+ value.to_hash
318
+ else
319
+ value
320
+ end
321
+ end
322
+
323
+ end
324
+
325
+ end
@@ -15,6 +15,18 @@ require 'time'
15
15
 
16
16
  module UltracartClient
17
17
  class ConversationAgentProfile
18
+ # AI powered chat bot
19
+ attr_accessor :ai
20
+
21
+ # Additional instructions for this AI when handle web chats
22
+ attr_accessor :ai_chat_instructions
23
+
24
+ # Persona of this AI agent
25
+ attr_accessor :ai_persona
26
+
27
+ # Additional instructions for this AI when handle SMS messages
28
+ attr_accessor :ai_sms_instructions
29
+
18
30
  # The number of engagement chats that can be pushed on them at any given time.
19
31
  attr_accessor :chat_limit
20
32
 
@@ -61,6 +73,10 @@ module UltracartClient
61
73
  # Attribute mapping from ruby-style variable name to JSON key.
62
74
  def self.attribute_map
63
75
  {
76
+ :'ai' => :'ai',
77
+ :'ai_chat_instructions' => :'ai_chat_instructions',
78
+ :'ai_persona' => :'ai_persona',
79
+ :'ai_sms_instructions' => :'ai_sms_instructions',
64
80
  :'chat_limit' => :'chat_limit',
65
81
  :'default_language_iso_code' => :'default_language_iso_code',
66
82
  :'default_status' => :'default_status',
@@ -79,6 +95,10 @@ module UltracartClient
79
95
  # Attribute type mapping.
80
96
  def self.openapi_types
81
97
  {
98
+ :'ai' => :'Boolean',
99
+ :'ai_chat_instructions' => :'String',
100
+ :'ai_persona' => :'String',
101
+ :'ai_sms_instructions' => :'String',
82
102
  :'chat_limit' => :'Integer',
83
103
  :'default_language_iso_code' => :'String',
84
104
  :'default_status' => :'String',
@@ -110,6 +130,22 @@ module UltracartClient
110
130
  h[k.to_sym] = v
111
131
  }
112
132
 
133
+ if attributes.key?(:'ai')
134
+ self.ai = attributes[:'ai']
135
+ end
136
+
137
+ if attributes.key?(:'ai_chat_instructions')
138
+ self.ai_chat_instructions = attributes[:'ai_chat_instructions']
139
+ end
140
+
141
+ if attributes.key?(:'ai_persona')
142
+ self.ai_persona = attributes[:'ai_persona']
143
+ end
144
+
145
+ if attributes.key?(:'ai_sms_instructions')
146
+ self.ai_sms_instructions = attributes[:'ai_sms_instructions']
147
+ end
148
+
113
149
  if attributes.key?(:'chat_limit')
114
150
  self.chat_limit = attributes[:'chat_limit']
115
151
  end
@@ -169,6 +205,10 @@ module UltracartClient
169
205
  def ==(o)
170
206
  return true if self.equal?(o)
171
207
  self.class == o.class &&
208
+ ai == o.ai &&
209
+ ai_chat_instructions == o.ai_chat_instructions &&
210
+ ai_persona == o.ai_persona &&
211
+ ai_sms_instructions == o.ai_sms_instructions &&
172
212
  chat_limit == o.chat_limit &&
173
213
  default_language_iso_code == o.default_language_iso_code &&
174
214
  default_status == o.default_status &&
@@ -187,7 +227,7 @@ module UltracartClient
187
227
  # Calculates hash code according to all attributes.
188
228
  # @return [Integer] Hash code
189
229
  def hash
190
- [chat_limit, default_language_iso_code, default_status, display_name, name, profile_image_upload_key, profile_image_url].hash
230
+ [ai, ai_chat_instructions, ai_persona, ai_sms_instructions, chat_limit, default_language_iso_code, default_status, display_name, name, profile_image_upload_key, profile_image_url].hash
191
231
  end
192
232
 
193
233
  # Builds the object from hash
@@ -15,6 +15,12 @@ require 'time'
15
15
 
16
16
  module UltracartClient
17
17
  class OrderProperty
18
+ # Created by user
19
+ attr_accessor :created_by
20
+
21
+ # The date/time that the property was created by the user
22
+ attr_accessor :created_dts
23
+
18
24
  # True if this property is displayed to the customer
19
25
  attr_accessor :display
20
26
 
@@ -30,6 +36,8 @@ module UltracartClient
30
36
  # Attribute mapping from ruby-style variable name to JSON key.
31
37
  def self.attribute_map
32
38
  {
39
+ :'created_by' => :'created_by',
40
+ :'created_dts' => :'created_dts',
33
41
  :'display' => :'display',
34
42
  :'expiration_dts' => :'expiration_dts',
35
43
  :'name' => :'name',
@@ -45,6 +53,8 @@ module UltracartClient
45
53
  # Attribute type mapping.
46
54
  def self.openapi_types
47
55
  {
56
+ :'created_by' => :'String',
57
+ :'created_dts' => :'String',
48
58
  :'display' => :'Boolean',
49
59
  :'expiration_dts' => :'String',
50
60
  :'name' => :'String',
@@ -73,6 +83,14 @@ module UltracartClient
73
83
  h[k.to_sym] = v
74
84
  }
75
85
 
86
+ if attributes.key?(:'created_by')
87
+ self.created_by = attributes[:'created_by']
88
+ end
89
+
90
+ if attributes.key?(:'created_dts')
91
+ self.created_dts = attributes[:'created_dts']
92
+ end
93
+
76
94
  if attributes.key?(:'display')
77
95
  self.display = attributes[:'display']
78
96
  end
@@ -94,6 +112,10 @@ module UltracartClient
94
112
  # @return Array for valid properties with the reasons
95
113
  def list_invalid_properties
96
114
  invalid_properties = Array.new
115
+ if !@created_by.nil? && @created_by.to_s.length > 20
116
+ invalid_properties.push('invalid value for "created_by", the character length must be smaller than or equal to 20.')
117
+ end
118
+
97
119
  if !@name.nil? && @name.to_s.length > 100
98
120
  invalid_properties.push('invalid value for "name", the character length must be smaller than or equal to 100.')
99
121
  end
@@ -108,11 +130,22 @@ module UltracartClient
108
130
  # Check to see if the all the properties in the model are valid
109
131
  # @return true if the model is valid
110
132
  def valid?
133
+ return false if !@created_by.nil? && @created_by.to_s.length > 20
111
134
  return false if !@name.nil? && @name.to_s.length > 100
112
135
  return false if !@value.nil? && @value.to_s.length > 1500
113
136
  true
114
137
  end
115
138
 
139
+ # Custom attribute writer method with validation
140
+ # @param [Object] created_by Value to be assigned
141
+ def created_by=(created_by)
142
+ if !created_by.nil? && created_by.to_s.length > 20
143
+ fail ArgumentError, 'invalid value for "created_by", the character length must be smaller than or equal to 20.'
144
+ end
145
+
146
+ @created_by = created_by
147
+ end
148
+
116
149
  # Custom attribute writer method with validation
117
150
  # @param [Object] name Value to be assigned
118
151
  def name=(name)
@@ -138,6 +171,8 @@ module UltracartClient
138
171
  def ==(o)
139
172
  return true if self.equal?(o)
140
173
  self.class == o.class &&
174
+ created_by == o.created_by &&
175
+ created_dts == o.created_dts &&
141
176
  display == o.display &&
142
177
  expiration_dts == o.expiration_dts &&
143
178
  name == o.name &&
@@ -153,7 +188,7 @@ module UltracartClient
153
188
  # Calculates hash code according to all attributes.
154
189
  # @return [Integer] Hash code
155
190
  def hash
156
- [display, expiration_dts, name, value].hash
191
+ [created_by, created_dts, display, expiration_dts, name, value].hash
157
192
  end
158
193
 
159
194
  # Builds the object from hash
@@ -11,5 +11,5 @@ OpenAPI Generator version: 6.0.1-SNAPSHOT
11
11
  =end
12
12
 
13
13
  module UltracartClient
14
- VERSION = '4.1.6'
14
+ VERSION = '4.1.8'
15
15
  end
data/lib/ultracart_api.rb CHANGED
@@ -120,6 +120,7 @@ require 'ultracart_api/models/cart_taxes'
120
120
  require 'ultracart_api/models/cart_upsell_after'
121
121
  require 'ultracart_api/models/cart_validation_request'
122
122
  require 'ultracart_api/models/cart_validation_response'
123
+ require 'ultracart_api/models/chanel_partner_reason_codes_response'
123
124
  require 'ultracart_api/models/channel_partner'
124
125
  require 'ultracart_api/models/channel_partner_cancel_response'
125
126
  require 'ultracart_api/models/channel_partner_estimate_shipping_response'
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.6
4
+ version: 4.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - UltraCart
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-04-16 00:00:00.000000000 Z
11
+ date: 2025-04-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -166,6 +166,7 @@ files:
166
166
  - docs/CartUpsellAfter.md
167
167
  - docs/CartValidationRequest.md
168
168
  - docs/CartValidationResponse.md
169
+ - docs/ChanelPartnerReasonCodesResponse.md
169
170
  - docs/ChannelPartner.md
170
171
  - docs/ChannelPartnerApi.md
171
172
  - docs/ChannelPartnerCancelResponse.md
@@ -1068,6 +1069,7 @@ files:
1068
1069
  - lib/ultracart_api/models/cart_upsell_after.rb
1069
1070
  - lib/ultracart_api/models/cart_validation_request.rb
1070
1071
  - lib/ultracart_api/models/cart_validation_response.rb
1072
+ - lib/ultracart_api/models/chanel_partner_reason_codes_response.rb
1071
1073
  - lib/ultracart_api/models/channel_partner.rb
1072
1074
  - lib/ultracart_api/models/channel_partner_cancel_response.rb
1073
1075
  - lib/ultracart_api/models/channel_partner_estimate_shipping_response.rb