ultracart_api 3.0.76 → 3.1.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +23 -18
  3. data/docs/AffiliateApi.md +8 -22
  4. data/docs/AutoOrderApi.md +44 -100
  5. data/docs/ChargebackApi.md +20 -55
  6. data/docs/CheckoutApi.md +78 -295
  7. data/docs/CouponApi.md +80 -211
  8. data/docs/CouponTieredAmountOffItem.md +1 -1
  9. data/docs/CouponTieredPercentOffItems.md +1 -1
  10. data/docs/CustomerApi.md +199 -110
  11. data/docs/EmailPlanAdditional.md +1 -0
  12. data/docs/EmailVerifyTokenRequest.md +9 -0
  13. data/docs/EmailVerifyTokenResponse.md +12 -0
  14. data/docs/EmailVerifyTokenValidateRequest.md +8 -0
  15. data/docs/EmailVerifyTokenValidateResponse.md +11 -0
  16. data/docs/FulfillmentApi.md +21 -55
  17. data/docs/ItemApi.md +36 -99
  18. data/docs/OauthApi.md +8 -32
  19. data/docs/OrderApi.md +84 -223
  20. data/docs/ScreenRecording.md +2 -1
  21. data/docs/StorefrontApi.md +429 -2077
  22. data/docs/TaxApi.md +121 -308
  23. data/docs/UserApi.md +46 -121
  24. data/docs/WebhookApi.md +32 -88
  25. data/lib/ultracart_api.rb +4 -0
  26. data/lib/ultracart_api/api/affiliate_api.rb +13 -0
  27. data/lib/ultracart_api/api/auto_order_api.rb +21 -8
  28. data/lib/ultracart_api/api/chargeback_api.rb +13 -0
  29. data/lib/ultracart_api/api/checkout_api.rb +15 -2
  30. data/lib/ultracart_api/api/coupon_api.rb +15 -2
  31. data/lib/ultracart_api/api/customer_api.rb +181 -0
  32. data/lib/ultracart_api/api/fulfillment_api.rb +13 -0
  33. data/lib/ultracart_api/api/item_api.rb +13 -0
  34. data/lib/ultracart_api/api/oauth_api.rb +13 -0
  35. data/lib/ultracart_api/api/order_api.rb +15 -2
  36. data/lib/ultracart_api/api/storefront_api.rb +13 -0
  37. data/lib/ultracart_api/api/tax_api.rb +13 -0
  38. data/lib/ultracart_api/api/user_api.rb +13 -0
  39. data/lib/ultracart_api/api/webhook_api.rb +13 -0
  40. data/lib/ultracart_api/models/coupon_tiered_amount_off_item.rb +1 -1
  41. data/lib/ultracart_api/models/coupon_tiered_percent_off_items.rb +1 -1
  42. data/lib/ultracart_api/models/email_plan_additional.rb +10 -1
  43. data/lib/ultracart_api/models/email_verify_token_request.rb +195 -0
  44. data/lib/ultracart_api/models/email_verify_token_response.rb +222 -0
  45. data/lib/ultracart_api/models/email_verify_token_validate_request.rb +185 -0
  46. data/lib/ultracart_api/models/email_verify_token_validate_response.rb +212 -0
  47. data/lib/ultracart_api/models/screen_recording.rb +12 -1
  48. data/lib/ultracart_api/version.rb +1 -1
  49. metadata +10 -2
@@ -19,7 +19,20 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
- # Retrieve an auto order
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::AutoOrderApi.new(api_client)
33
+ end
34
+
35
+ # Retrieve an auto order by oid
23
36
  # Retrieves a single auto order using the specified auto order oid.
24
37
  # @param auto_order_oid The auto order oid to retrieve.
25
38
  # @param [Hash] opts the optional parameters
@@ -30,7 +43,7 @@ module UltracartClient
30
43
  data
31
44
  end
32
45
 
33
- # Retrieve an auto order
46
+ # Retrieve an auto order by oid
34
47
  # Retrieves a single auto order using the specified auto order oid.
35
48
  # @param auto_order_oid The auto order oid to retrieve.
36
49
  # @param [Hash] opts the optional parameters
@@ -77,7 +90,7 @@ module UltracartClient
77
90
  end
78
91
  return data, status_code, headers
79
92
  end
80
- # Retrieve an auto order
93
+ # Retrieve an auto order by code
81
94
  # Retrieves a single auto order using the specified reference (original) order id.
82
95
  # @param auto_order_code The auto order oid to retrieve.
83
96
  # @param [Hash] opts the optional parameters
@@ -88,7 +101,7 @@ module UltracartClient
88
101
  data
89
102
  end
90
103
 
91
- # Retrieve an auto order
104
+ # Retrieve an auto order by code
92
105
  # Retrieves a single auto order using the specified reference (original) order id.
93
106
  # @param auto_order_code The auto order oid to retrieve.
94
107
  # @param [Hash] opts the optional parameters
@@ -135,7 +148,7 @@ module UltracartClient
135
148
  end
136
149
  return data, status_code, headers
137
150
  end
138
- # Retrieve an auto order
151
+ # Retrieve an auto order by order id
139
152
  # Retrieves a single auto order using the specified reference (original) order id.
140
153
  # @param reference_order_id The auto order oid to retrieve.
141
154
  # @param [Hash] opts the optional parameters
@@ -146,7 +159,7 @@ module UltracartClient
146
159
  data
147
160
  end
148
161
 
149
- # Retrieve an auto order
162
+ # Retrieve an auto order by order id
150
163
  # Retrieves a single auto order using the specified reference (original) order id.
151
164
  # @param reference_order_id The auto order oid to retrieve.
152
165
  # @param [Hash] opts the optional parameters
@@ -369,7 +382,7 @@ module UltracartClient
369
382
  end
370
383
  return data, status_code, headers
371
384
  end
372
- # Retrieve auto orders
385
+ # Retrieve auto orders by query
373
386
  # Retrieves a group of auto orders from the account based on a query object. You will need to make multiple API calls in order to retrieve the entire result set since this API performs result set pagination.
374
387
  # @param auto_order_query Auto order query
375
388
  # @param [Hash] opts the optional parameters
@@ -383,7 +396,7 @@ module UltracartClient
383
396
  data
384
397
  end
385
398
 
386
- # Retrieve auto orders
399
+ # Retrieve auto orders by query
387
400
  # Retrieves a group of auto orders from the account based on a query object. You will need to make multiple API calls in order to retrieve the entire result set since this API performs result set pagination.
388
401
  # @param auto_order_query Auto order query
389
402
  # @param [Hash] opts the optional parameters
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::ChargebackApi.new(api_client)
33
+ end
34
+
22
35
  # Delete a chargeback
23
36
  # Delete a chargeback on the UltraCart account.
24
37
  # @param chargeback_dispute_oid The chargeback_dispute_oid to delete.
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::CheckoutApi.new(api_client)
33
+ end
34
+
22
35
  # City/State for Zip
23
36
  # Look up the city and state for the shipping zip code. Useful for building an auto complete for parts of the shipping address
24
37
  # @param cart Cart
@@ -924,7 +937,7 @@ module UltracartClient
924
937
  return data, status_code, headers
925
938
  end
926
939
  # Setup Browser Application
927
- # Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth applicaiton, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use.
940
+ # Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth application, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use.
928
941
  # @param browser_key_request Setup browser key request
929
942
  # @param [Hash] opts the optional parameters
930
943
  # @return [CheckoutSetupBrowserKeyResponse]
@@ -934,7 +947,7 @@ module UltracartClient
934
947
  end
935
948
 
936
949
  # Setup Browser Application
937
- # Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth applicaiton, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use.
950
+ # Setup a browser key authenticated application with checkout permissions. This REST call must be made with an authentication scheme that is not browser key. The new application will be linked to the application that makes this call. If this application is disabled / deleted, then so will the application setup by this call. The purpose of this call is to allow an OAuth application, such as the Wordpress plugin, to setup the proper browser based authentication for the REST checkout API to use.
938
951
  # @param browser_key_request Setup browser key request
939
952
  # @param [Hash] opts the optional parameters
940
953
  # @return [Array<(CheckoutSetupBrowserKeyResponse, Fixnum, Hash)>] CheckoutSetupBrowserKeyResponse data, response status code and response headers
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::CouponApi.new(api_client)
33
+ end
34
+
22
35
  # Delete a coupon
23
36
  # Delete a coupon on the UltraCart account.
24
37
  # @param coupon_oid The coupon_oid to delete.
@@ -1021,7 +1034,7 @@ module UltracartClient
1021
1034
  end
1022
1035
  # Update multiple coupons
1023
1036
  # Update multiple coupon on the UltraCart account.
1024
- # @param coupons_request Coupons to update (synchronous maximum 20 / asynchronous maximum 100)
1037
+ # @param coupons_request Coupons to update (synchronous maximum 50 / asynchronous maximum 100)
1025
1038
  # @param [Hash] opts the optional parameters
1026
1039
  # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
1027
1040
  # @option opts [BOOLEAN] :_placeholders Whether or not placeholder values should be returned in the result. Useful for UIs that consume this REST API.
@@ -1034,7 +1047,7 @@ module UltracartClient
1034
1047
 
1035
1048
  # Update multiple coupons
1036
1049
  # Update multiple coupon on the UltraCart account.
1037
- # @param coupons_request Coupons to update (synchronous maximum 20 / asynchronous maximum 100)
1050
+ # @param coupons_request Coupons to update (synchronous maximum 50 / asynchronous maximum 100)
1038
1051
  # @param [Hash] opts the optional parameters
1039
1052
  # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
1040
1053
  # @option opts [BOOLEAN] :_placeholders Whether or not placeholder values should be returned in the result. Useful for UIs that consume this REST API.
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::CustomerApi.new(api_client)
33
+ end
34
+
22
35
  # Delete a customer
23
36
  # Delete a customer on the UltraCart account.
24
37
  # @param customer_profile_oid The customer_profile_oid to delete.
@@ -132,6 +145,64 @@ module UltracartClient
132
145
  end
133
146
  return data, status_code, headers
134
147
  end
148
+ # Retrieve a customer by Email
149
+ # Retrieves a single customer using the specified customer email address.
150
+ # @param email The email address of the customer to retrieve.
151
+ # @param [Hash] opts the optional parameters
152
+ # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
153
+ # @return [CustomerResponse]
154
+ def get_customer_by_email(email, opts = {})
155
+ data, _status_code, _headers = get_customer_by_email_with_http_info(email, opts)
156
+ data
157
+ end
158
+
159
+ # Retrieve a customer by Email
160
+ # Retrieves a single customer using the specified customer email address.
161
+ # @param email The email address of the customer to retrieve.
162
+ # @param [Hash] opts the optional parameters
163
+ # @option opts [String] :_expand The object expansion to perform on the result. See documentation for examples
164
+ # @return [Array<(CustomerResponse, Fixnum, Hash)>] CustomerResponse data, response status code and response headers
165
+ def get_customer_by_email_with_http_info(email, opts = {})
166
+ if @api_client.config.debugging
167
+ @api_client.config.logger.debug 'Calling API: CustomerApi.get_customer_by_email ...'
168
+ end
169
+ # verify the required parameter 'email' is set
170
+ if @api_client.config.client_side_validation && email.nil?
171
+ fail ArgumentError, "Missing the required parameter 'email' when calling CustomerApi.get_customer_by_email"
172
+ end
173
+ # resource path
174
+ local_var_path = '/customer/customers/by_email/{email}'.sub('{' + 'email' + '}', email.to_s)
175
+
176
+ # query parameters
177
+ query_params = {}
178
+ query_params[:'_expand'] = opts[:'_expand'] if !opts[:'_expand'].nil?
179
+
180
+ # header parameters
181
+ header_params = {}
182
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
183
+ # HTTP header 'Accept' (if needed)
184
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
185
+ # HTTP header 'Content-Type'
186
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
187
+
188
+ # form parameters
189
+ form_params = {}
190
+
191
+ # http body (model)
192
+ post_body = nil
193
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
194
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path,
195
+ :header_params => header_params,
196
+ :query_params => query_params,
197
+ :form_params => form_params,
198
+ :body => post_body,
199
+ :auth_names => auth_names,
200
+ :return_type => 'CustomerResponse')
201
+ if @api_client.config.debugging
202
+ @api_client.config.logger.debug "API called: CustomerApi#get_customer_by_email\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
203
+ end
204
+ return data, status_code, headers
205
+ end
135
206
  # Retrieve customers
136
207
  # Retrieves customers from the account. If no parameters are specified, all customers will be returned. You will need to make multiple API calls in order to retrieve the entire result set since this API performs result set pagination.
137
208
  # @param [Hash] opts the optional parameters
@@ -497,6 +568,61 @@ module UltracartClient
497
568
  end
498
569
  return data, status_code, headers
499
570
  end
571
+ # Create a token that can be used to verify a customer email address
572
+ # Create a token that can be used to verify a customer email address. The implementation of how a customer interacts with this token is left to the merchant.
573
+ # @param token_request Token request
574
+ # @param [Hash] opts the optional parameters
575
+ # @return [EmailVerifyTokenResponse]
576
+ def get_email_verification_token(token_request, opts = {})
577
+ data, _status_code, _headers = get_email_verification_token_with_http_info(token_request, opts)
578
+ data
579
+ end
580
+
581
+ # Create a token that can be used to verify a customer email address
582
+ # Create a token that can be used to verify a customer email address. The implementation of how a customer interacts with this token is left to the merchant.
583
+ # @param token_request Token request
584
+ # @param [Hash] opts the optional parameters
585
+ # @return [Array<(EmailVerifyTokenResponse, Fixnum, Hash)>] EmailVerifyTokenResponse data, response status code and response headers
586
+ def get_email_verification_token_with_http_info(token_request, opts = {})
587
+ if @api_client.config.debugging
588
+ @api_client.config.logger.debug 'Calling API: CustomerApi.get_email_verification_token ...'
589
+ end
590
+ # verify the required parameter 'token_request' is set
591
+ if @api_client.config.client_side_validation && token_request.nil?
592
+ fail ArgumentError, "Missing the required parameter 'token_request' when calling CustomerApi.get_email_verification_token"
593
+ end
594
+ # resource path
595
+ local_var_path = '/customer/customers/email_verify/get_token'
596
+
597
+ # query parameters
598
+ query_params = {}
599
+
600
+ # header parameters
601
+ header_params = {}
602
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
603
+ # HTTP header 'Accept' (if needed)
604
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
605
+ # HTTP header 'Content-Type'
606
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
607
+
608
+ # form parameters
609
+ form_params = {}
610
+
611
+ # http body (model)
612
+ post_body = @api_client.object_to_http_body(token_request)
613
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
614
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
615
+ :header_params => header_params,
616
+ :query_params => query_params,
617
+ :form_params => form_params,
618
+ :body => post_body,
619
+ :auth_names => auth_names,
620
+ :return_type => 'EmailVerifyTokenResponse')
621
+ if @api_client.config.debugging
622
+ @api_client.config.logger.debug "API called: CustomerApi#get_email_verification_token\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
623
+ end
624
+ return data, status_code, headers
625
+ end
500
626
  # Insert a customer
501
627
  # Insert a customer on the UltraCart account.
502
628
  # @param customer Customer to insert
@@ -680,5 +806,60 @@ module UltracartClient
680
806
  end
681
807
  return data, status_code, headers
682
808
  end
809
+ # Validate a token that can be used to verify a customer email address
810
+ # Validate a token that can be used to verify a customer email address. The implementation of how a customer interacts with this token is left to the merchant.
811
+ # @param validation_request Token validation request
812
+ # @param [Hash] opts the optional parameters
813
+ # @return [EmailVerifyTokenValidateResponse]
814
+ def validate_email_verification_token(validation_request, opts = {})
815
+ data, _status_code, _headers = validate_email_verification_token_with_http_info(validation_request, opts)
816
+ data
817
+ end
818
+
819
+ # Validate a token that can be used to verify a customer email address
820
+ # Validate a token that can be used to verify a customer email address. The implementation of how a customer interacts with this token is left to the merchant.
821
+ # @param validation_request Token validation request
822
+ # @param [Hash] opts the optional parameters
823
+ # @return [Array<(EmailVerifyTokenValidateResponse, Fixnum, Hash)>] EmailVerifyTokenValidateResponse data, response status code and response headers
824
+ def validate_email_verification_token_with_http_info(validation_request, opts = {})
825
+ if @api_client.config.debugging
826
+ @api_client.config.logger.debug 'Calling API: CustomerApi.validate_email_verification_token ...'
827
+ end
828
+ # verify the required parameter 'validation_request' is set
829
+ if @api_client.config.client_side_validation && validation_request.nil?
830
+ fail ArgumentError, "Missing the required parameter 'validation_request' when calling CustomerApi.validate_email_verification_token"
831
+ end
832
+ # resource path
833
+ local_var_path = '/customer/customers/email_verify/validate_token'
834
+
835
+ # query parameters
836
+ query_params = {}
837
+
838
+ # header parameters
839
+ header_params = {}
840
+ header_params['X-UltraCart-Api-Version'] = @api_client.select_header_api_version()
841
+ # HTTP header 'Accept' (if needed)
842
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
843
+ # HTTP header 'Content-Type'
844
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
845
+
846
+ # form parameters
847
+ form_params = {}
848
+
849
+ # http body (model)
850
+ post_body = @api_client.object_to_http_body(validation_request)
851
+ auth_names = ['ultraCartOauth', 'ultraCartSimpleApiKey']
852
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path,
853
+ :header_params => header_params,
854
+ :query_params => query_params,
855
+ :form_params => form_params,
856
+ :body => post_body,
857
+ :auth_names => auth_names,
858
+ :return_type => 'EmailVerifyTokenValidateResponse')
859
+ if @api_client.config.debugging
860
+ @api_client.config.logger.debug "API called: CustomerApi#validate_email_verification_token\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
861
+ end
862
+ return data, status_code, headers
863
+ end
683
864
  end
684
865
  end
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::FulfillmentApi.new(api_client)
33
+ end
34
+
22
35
  # Acknowledge receipt of orders.
23
36
  # Acknowledge receipt of orders so that they are removed from the fulfillment queue. This method must be called after receiving and order (via webhook) or retrieving (via retrieve orders method).
24
37
  # @param distribution_center_code Distribution center code
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::ItemApi.new(api_client)
33
+ end
34
+
22
35
  # Delete an item
23
36
  # Delete an item on the UltraCart account.
24
37
  # @param merchant_item_oid The item oid to delete.
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::OauthApi.new(api_client)
33
+ end
34
+
22
35
  # Exchange authorization code for access token.
23
36
  # The final leg in the OAuth process which exchanges the specified access token for the access code needed to make API calls.
24
37
  # @param client_id The OAuth application client_id.
@@ -19,6 +19,19 @@ module UltracartClient
19
19
  def initialize(api_client = ApiClient.default)
20
20
  @api_client = api_client
21
21
  end
22
+
23
+ def self.new_using_api_key(simple_key, verify_ssl = true, debugging = false)
24
+ api_config = Configuration.new
25
+ api_config.api_key_prefix['x-ultracart-simple-key'] = simple_key
26
+ api_config.api_version = '2017-03-01'
27
+ api_config.verify_ssl = verify_ssl
28
+
29
+ api_client = ApiClient.new(api_config)
30
+ api_client.config.debugging = debugging
31
+
32
+ UltracartClient::OrderApi.new(api_client)
33
+ end
34
+
22
35
  # Adjusts an order total
23
36
  # Adjusts an order total. Adjusts individual items appropriately and considers taxes. Desired total should be provided in the same currency as the order. Returns true if successful.
24
37
  # @param order_id The order id to cancel.
@@ -734,7 +747,7 @@ module UltracartClient
734
747
  end
735
748
  return data, status_code, headers
736
749
  end
737
- # Retrieve orders
750
+ # Retrieve orders by query
738
751
  # Retrieves a group of orders from the account based on a query object. If no parameters are specified, the API call will fail with a bad request error. Always specify some parameters to limit the scope of the orders returned to ones you are truly interested in. You will need to make multiple API calls in order to retrieve the entire result set since this API performs result set pagination.
739
752
  # @param order_query Order query
740
753
  # @param [Hash] opts the optional parameters
@@ -748,7 +761,7 @@ module UltracartClient
748
761
  data
749
762
  end
750
763
 
751
- # Retrieve orders
764
+ # Retrieve orders by query
752
765
  # Retrieves a group of orders from the account based on a query object. If no parameters are specified, the API call will fail with a bad request error. Always specify some parameters to limit the scope of the orders returned to ones you are truly interested in. You will need to make multiple API calls in order to retrieve the entire result set since this API performs result set pagination.
753
766
  # @param order_query Order query
754
767
  # @param [Hash] opts the optional parameters