ultracart_api 4.0.32.rc → 4.0.33.rc

Sign up to get free protection for your applications and to get access to all the features.
data/docs/CustomerApi.md CHANGED
@@ -36,18 +36,15 @@ Adds store credit to a customer
36
36
  ```ruby
37
37
  require 'time'
38
38
  require 'ultracart_api'
39
- # setup authorization
40
- UltracartClient.configure do |config|
41
- # Configure OAuth2 access token for authorization: ultraCartOauth
42
- config.access_token = 'YOUR ACCESS TOKEN'
43
-
44
- # Configure API key authorization: ultraCartSimpleApiKey
45
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
46
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
47
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
48
- end
39
+ require 'json'
40
+ require 'yaml'
41
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
42
+
43
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
44
+ # As such, this might not be the best way to use this object.
45
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
49
46
 
50
- api_instance = UltracartClient::CustomerApi.new
47
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
51
48
  customer_profile_oid = 56 # Integer | The customer oid to credit.
52
49
  store_credit_request = UltracartClient::CustomerStoreCreditAddRequest.new # CustomerStoreCreditAddRequest | Store credit to add
53
50
 
@@ -112,18 +109,15 @@ Updates the cashback balance for a customer by updating the internal gift certif
112
109
  ```ruby
113
110
  require 'time'
114
111
  require 'ultracart_api'
115
- # setup authorization
116
- UltracartClient.configure do |config|
117
- # Configure OAuth2 access token for authorization: ultraCartOauth
118
- config.access_token = 'YOUR ACCESS TOKEN'
119
-
120
- # Configure API key authorization: ultraCartSimpleApiKey
121
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
122
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
123
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
124
- end
112
+ require 'json'
113
+ require 'yaml'
114
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
125
115
 
126
- api_instance = UltracartClient::CustomerApi.new
116
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
117
+ # As such, this might not be the best way to use this object.
118
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
119
+
120
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
127
121
  customer_profile_oid = 56 # Integer | The customer profile oid
128
122
  adjust_internal_certificate_request = UltracartClient::AdjustInternalCertificateRequest.new # AdjustInternalCertificateRequest | adjustInternalCertificateRequest
129
123
 
@@ -188,18 +182,15 @@ Delete a customer on the UltraCart account.
188
182
  ```ruby
189
183
  require 'time'
190
184
  require 'ultracart_api'
191
- # setup authorization
192
- UltracartClient.configure do |config|
193
- # Configure OAuth2 access token for authorization: ultraCartOauth
194
- config.access_token = 'YOUR ACCESS TOKEN'
195
-
196
- # Configure API key authorization: ultraCartSimpleApiKey
197
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
198
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
199
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
200
- end
185
+ require 'json'
186
+ require 'yaml'
187
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
201
188
 
202
- api_instance = UltracartClient::CustomerApi.new
189
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
190
+ # As such, this might not be the best way to use this object.
191
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
192
+
193
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
203
194
  customer_profile_oid = 56 # Integer | The customer_profile_oid to delete.
204
195
 
205
196
  begin
@@ -261,18 +252,15 @@ Retrieves a single customer using the specified customer profile oid.
261
252
  ```ruby
262
253
  require 'time'
263
254
  require 'ultracart_api'
264
- # setup authorization
265
- UltracartClient.configure do |config|
266
- # Configure OAuth2 access token for authorization: ultraCartOauth
267
- config.access_token = 'YOUR ACCESS TOKEN'
268
-
269
- # Configure API key authorization: ultraCartSimpleApiKey
270
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
271
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
272
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
273
- end
255
+ require 'json'
256
+ require 'yaml'
257
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
274
258
 
275
- api_instance = UltracartClient::CustomerApi.new
259
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
260
+ # As such, this might not be the best way to use this object.
261
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
262
+
263
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
276
264
  customer_profile_oid = 56 # Integer | The customer oid to retrieve.
277
265
  opts = {
278
266
  _expand: '_expand_example' # String | The object expansion to perform on the result. See documentation for examples
@@ -339,18 +327,15 @@ Retrieves a single customer using the specified customer email address.
339
327
  ```ruby
340
328
  require 'time'
341
329
  require 'ultracart_api'
342
- # setup authorization
343
- UltracartClient.configure do |config|
344
- # Configure OAuth2 access token for authorization: ultraCartOauth
345
- config.access_token = 'YOUR ACCESS TOKEN'
346
-
347
- # Configure API key authorization: ultraCartSimpleApiKey
348
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
349
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
350
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
351
- end
330
+ require 'json'
331
+ require 'yaml'
332
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
352
333
 
353
- api_instance = UltracartClient::CustomerApi.new
334
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
335
+ # As such, this might not be the best way to use this object.
336
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
337
+
338
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
354
339
  email = 'email_example' # String | The email address of the customer to retrieve.
355
340
  opts = {
356
341
  _expand: '_expand_example' # String | The object expansion to perform on the result. See documentation for examples
@@ -417,18 +402,15 @@ Retrieve values needed for a customer profile editor.
417
402
  ```ruby
418
403
  require 'time'
419
404
  require 'ultracart_api'
420
- # setup authorization
421
- UltracartClient.configure do |config|
422
- # Configure OAuth2 access token for authorization: ultraCartOauth
423
- config.access_token = 'YOUR ACCESS TOKEN'
424
-
425
- # Configure API key authorization: ultraCartSimpleApiKey
426
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
427
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
428
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
429
- end
405
+ require 'json'
406
+ require 'yaml'
407
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
430
408
 
431
- api_instance = UltracartClient::CustomerApi.new
409
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
410
+ # As such, this might not be the best way to use this object.
411
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
412
+
413
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
432
414
 
433
415
  begin
434
416
  # Retrieve values needed for a customer profile editor
@@ -488,18 +470,15 @@ Retrieve all email lists across all storefronts
488
470
  ```ruby
489
471
  require 'time'
490
472
  require 'ultracart_api'
491
- # setup authorization
492
- UltracartClient.configure do |config|
493
- # Configure OAuth2 access token for authorization: ultraCartOauth
494
- config.access_token = 'YOUR ACCESS TOKEN'
495
-
496
- # Configure API key authorization: ultraCartSimpleApiKey
497
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
498
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
499
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
500
- end
473
+ require 'json'
474
+ require 'yaml'
475
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
501
476
 
502
- api_instance = UltracartClient::CustomerApi.new
477
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
478
+ # As such, this might not be the best way to use this object.
479
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
480
+
481
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
503
482
 
504
483
  begin
505
484
  # Retrieve all email lists across all storefronts
@@ -559,18 +538,15 @@ Retrieve the customer store credit accumulated through loyalty programs
559
538
  ```ruby
560
539
  require 'time'
561
540
  require 'ultracart_api'
562
- # setup authorization
563
- UltracartClient.configure do |config|
564
- # Configure OAuth2 access token for authorization: ultraCartOauth
565
- config.access_token = 'YOUR ACCESS TOKEN'
566
-
567
- # Configure API key authorization: ultraCartSimpleApiKey
568
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
569
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
570
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
571
- end
541
+ require 'json'
542
+ require 'yaml'
543
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
572
544
 
573
- api_instance = UltracartClient::CustomerApi.new
545
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
546
+ # As such, this might not be the best way to use this object.
547
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
548
+
549
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
574
550
  customer_profile_oid = 56 # Integer | The customer oid to retrieve.
575
551
 
576
552
  begin
@@ -633,18 +609,15 @@ Retrieves customers from the account. If no parameters are specified, all custo
633
609
  ```ruby
634
610
  require 'time'
635
611
  require 'ultracart_api'
636
- # setup authorization
637
- UltracartClient.configure do |config|
638
- # Configure OAuth2 access token for authorization: ultraCartOauth
639
- config.access_token = 'YOUR ACCESS TOKEN'
640
-
641
- # Configure API key authorization: ultraCartSimpleApiKey
642
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
643
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
644
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
645
- end
612
+ require 'json'
613
+ require 'yaml'
614
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
646
615
 
647
- api_instance = UltracartClient::CustomerApi.new
616
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
617
+ # As such, this might not be the best way to use this object.
618
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
619
+
620
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
648
621
  opts = {
649
622
  email: 'email_example', # String | Email
650
623
  qb_class: 'qb_class_example', # String | Quickbooks class
@@ -771,18 +744,15 @@ Retrieves customers from the account. If no parameters are specified, all custo
771
744
  ```ruby
772
745
  require 'time'
773
746
  require 'ultracart_api'
774
- # setup authorization
775
- UltracartClient.configure do |config|
776
- # Configure OAuth2 access token for authorization: ultraCartOauth
777
- config.access_token = 'YOUR ACCESS TOKEN'
778
-
779
- # Configure API key authorization: ultraCartSimpleApiKey
780
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
781
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
782
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
783
- end
747
+ require 'json'
748
+ require 'yaml'
749
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
750
+
751
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
752
+ # As such, this might not be the best way to use this object.
753
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
784
754
 
785
- api_instance = UltracartClient::CustomerApi.new
755
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
786
756
  customer_query = UltracartClient::CustomerQuery.new # CustomerQuery | Customer query
787
757
  opts = {
788
758
  _limit: 56, # Integer | The maximum number of records to return on this one API call. (Max 200)
@@ -857,18 +827,15 @@ Retrieves customers from the account. If no searches are specified, all custome
857
827
  ```ruby
858
828
  require 'time'
859
829
  require 'ultracart_api'
860
- # setup authorization
861
- UltracartClient.configure do |config|
862
- # Configure OAuth2 access token for authorization: ultraCartOauth
863
- config.access_token = 'YOUR ACCESS TOKEN'
864
-
865
- # Configure API key authorization: ultraCartSimpleApiKey
866
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
867
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
868
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
869
- end
830
+ require 'json'
831
+ require 'yaml'
832
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
833
+
834
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
835
+ # As such, this might not be the best way to use this object.
836
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
870
837
 
871
- api_instance = UltracartClient::CustomerApi.new
838
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
872
839
  opts = {
873
840
  _expand: '_expand_example' # String | The object expansion to perform on the result. See documentation for examples
874
841
  }
@@ -933,18 +900,15 @@ Create a token that can be used to verify a customer email address. The impleme
933
900
  ```ruby
934
901
  require 'time'
935
902
  require 'ultracart_api'
936
- # setup authorization
937
- UltracartClient.configure do |config|
938
- # Configure OAuth2 access token for authorization: ultraCartOauth
939
- config.access_token = 'YOUR ACCESS TOKEN'
940
-
941
- # Configure API key authorization: ultraCartSimpleApiKey
942
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
943
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
944
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
945
- end
903
+ require 'json'
904
+ require 'yaml'
905
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
906
+
907
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
908
+ # As such, this might not be the best way to use this object.
909
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
946
910
 
947
- api_instance = UltracartClient::CustomerApi.new
911
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
948
912
  token_request = UltracartClient::EmailVerifyTokenRequest.new # EmailVerifyTokenRequest | Token request
949
913
 
950
914
  begin
@@ -1007,18 +971,15 @@ Insert a customer on the UltraCart account.
1007
971
  ```ruby
1008
972
  require 'time'
1009
973
  require 'ultracart_api'
1010
- # setup authorization
1011
- UltracartClient.configure do |config|
1012
- # Configure OAuth2 access token for authorization: ultraCartOauth
1013
- config.access_token = 'YOUR ACCESS TOKEN'
1014
-
1015
- # Configure API key authorization: ultraCartSimpleApiKey
1016
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
1017
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1018
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
1019
- end
974
+ require 'json'
975
+ require 'yaml'
976
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
977
+
978
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
979
+ # As such, this might not be the best way to use this object.
980
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
1020
981
 
1021
- api_instance = UltracartClient::CustomerApi.new
982
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
1022
983
  customer = UltracartClient::Customer.new # Customer | Customer to insert
1023
984
  opts = {
1024
985
  _expand: '_expand_example' # String | The object expansion to perform on the result. See documentation for examples
@@ -1083,23 +1044,15 @@ Searches for all matching values (using POST)
1083
1044
  ```ruby
1084
1045
  require 'time'
1085
1046
  require 'ultracart_api'
1086
- # setup authorization
1087
- UltracartClient.configure do |config|
1088
- # Configure API key authorization: ultraCartBrowserApiKey
1089
- config.api_key['ultraCartBrowserApiKey'] = 'YOUR API KEY'
1090
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1091
- # config.api_key_prefix['ultraCartBrowserApiKey'] = 'Bearer'
1092
-
1093
- # Configure OAuth2 access token for authorization: ultraCartOauth
1094
- config.access_token = 'YOUR ACCESS TOKEN'
1095
-
1096
- # Configure API key authorization: ultraCartSimpleApiKey
1097
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
1098
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1099
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
1100
- end
1047
+ require 'json'
1048
+ require 'yaml'
1049
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
1050
+
1051
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
1052
+ # As such, this might not be the best way to use this object.
1053
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
1101
1054
 
1102
- api_instance = UltracartClient::CustomerApi.new
1055
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
1103
1056
  lookup_request = UltracartClient::LookupRequest.new # LookupRequest | LookupRequest
1104
1057
 
1105
1058
  begin
@@ -1162,18 +1115,15 @@ Update a customer on the UltraCart account.
1162
1115
  ```ruby
1163
1116
  require 'time'
1164
1117
  require 'ultracart_api'
1165
- # setup authorization
1166
- UltracartClient.configure do |config|
1167
- # Configure OAuth2 access token for authorization: ultraCartOauth
1168
- config.access_token = 'YOUR ACCESS TOKEN'
1169
-
1170
- # Configure API key authorization: ultraCartSimpleApiKey
1171
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
1172
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1173
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
1174
- end
1118
+ require 'json'
1119
+ require 'yaml'
1120
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
1121
+
1122
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
1123
+ # As such, this might not be the best way to use this object.
1124
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
1175
1125
 
1176
- api_instance = UltracartClient::CustomerApi.new
1126
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
1177
1127
  customer_profile_oid = 56 # Integer | The customer_profile_oid to update.
1178
1128
  customer = UltracartClient::Customer.new # Customer | Customer to update
1179
1129
  opts = {
@@ -1242,18 +1192,15 @@ Update email list subscriptions for a customer
1242
1192
  ```ruby
1243
1193
  require 'time'
1244
1194
  require 'ultracart_api'
1245
- # setup authorization
1246
- UltracartClient.configure do |config|
1247
- # Configure OAuth2 access token for authorization: ultraCartOauth
1248
- config.access_token = 'YOUR ACCESS TOKEN'
1249
-
1250
- # Configure API key authorization: ultraCartSimpleApiKey
1251
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
1252
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1253
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
1254
- end
1195
+ require 'json'
1196
+ require 'yaml'
1197
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
1198
+
1199
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
1200
+ # As such, this might not be the best way to use this object.
1201
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
1255
1202
 
1256
- api_instance = UltracartClient::CustomerApi.new
1203
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
1257
1204
  customer_profile_oid = 56 # Integer | The customer profile oid
1258
1205
  list_changes = UltracartClient::CustomerEmailListChanges.new # CustomerEmailListChanges | List changes
1259
1206
 
@@ -1318,18 +1265,15 @@ Validate a token that can be used to verify a customer email address. The imple
1318
1265
  ```ruby
1319
1266
  require 'time'
1320
1267
  require 'ultracart_api'
1321
- # setup authorization
1322
- UltracartClient.configure do |config|
1323
- # Configure OAuth2 access token for authorization: ultraCartOauth
1324
- config.access_token = 'YOUR ACCESS TOKEN'
1325
-
1326
- # Configure API key authorization: ultraCartSimpleApiKey
1327
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
1328
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
1329
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
1330
- end
1268
+ require 'json'
1269
+ require 'yaml'
1270
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
1271
+
1272
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
1273
+ # As such, this might not be the best way to use this object.
1274
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
1331
1275
 
1332
- api_instance = UltracartClient::CustomerApi.new
1276
+ api = UltracartClient::CustomerApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
1333
1277
  validation_request = UltracartClient::EmailVerifyTokenValidateRequest.new # EmailVerifyTokenValidateRequest | Token validation request
1334
1278
 
1335
1279
  begin
@@ -25,18 +25,15 @@ Acknowledge receipt of orders so that they are removed from the fulfillment queu
25
25
  ```ruby
26
26
  require 'time'
27
27
  require 'ultracart_api'
28
- # setup authorization
29
- UltracartClient.configure do |config|
30
- # Configure OAuth2 access token for authorization: ultraCartOauth
31
- config.access_token = 'YOUR ACCESS TOKEN'
32
-
33
- # Configure API key authorization: ultraCartSimpleApiKey
34
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
35
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
36
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
37
- end
28
+ require 'json'
29
+ require 'yaml'
30
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
31
+
32
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
33
+ # As such, this might not be the best way to use this object.
34
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
38
35
 
39
- api_instance = UltracartClient::FulfillmentApi.new
36
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
40
37
  distribution_center_code = 'distribution_center_code_example' # String | Distribution center code
41
38
  order_ids = ['property_example'] # Array<String> | Orders to acknowledge receipt of (limit 100)
42
39
 
@@ -100,18 +97,15 @@ The packing slip PDF that is returned is base 64 encoded
100
97
  ```ruby
101
98
  require 'time'
102
99
  require 'ultracart_api'
103
- # setup authorization
104
- UltracartClient.configure do |config|
105
- # Configure OAuth2 access token for authorization: ultraCartOauth
106
- config.access_token = 'YOUR ACCESS TOKEN'
107
-
108
- # Configure API key authorization: ultraCartSimpleApiKey
109
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
110
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
111
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
112
- end
100
+ require 'json'
101
+ require 'yaml'
102
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
113
103
 
114
- api_instance = UltracartClient::FulfillmentApi.new
104
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
105
+ # As such, this might not be the best way to use this object.
106
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
107
+
108
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
115
109
  distribution_center_code = 'distribution_center_code_example' # String | Distribution center code
116
110
  order_id = 'order_id_example' # String | Order ID
117
111
 
@@ -176,18 +170,15 @@ Retrieves up to 100 orders that are queued up in this distribution center. You
176
170
  ```ruby
177
171
  require 'time'
178
172
  require 'ultracart_api'
179
- # setup authorization
180
- UltracartClient.configure do |config|
181
- # Configure OAuth2 access token for authorization: ultraCartOauth
182
- config.access_token = 'YOUR ACCESS TOKEN'
183
-
184
- # Configure API key authorization: ultraCartSimpleApiKey
185
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
186
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
187
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
188
- end
173
+ require 'json'
174
+ require 'yaml'
175
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
176
+
177
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
178
+ # As such, this might not be the best way to use this object.
179
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
189
180
 
190
- api_instance = UltracartClient::FulfillmentApi.new
181
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
191
182
  distribution_center_code = 'distribution_center_code_example' # String | Distribution center code
192
183
 
193
184
  begin
@@ -250,18 +241,15 @@ Retrieves the distribution centers that this user has access to.
250
241
  ```ruby
251
242
  require 'time'
252
243
  require 'ultracart_api'
253
- # setup authorization
254
- UltracartClient.configure do |config|
255
- # Configure OAuth2 access token for authorization: ultraCartOauth
256
- config.access_token = 'YOUR ACCESS TOKEN'
257
-
258
- # Configure API key authorization: ultraCartSimpleApiKey
259
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
260
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
261
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
262
- end
244
+ require 'json'
245
+ require 'yaml'
246
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
247
+
248
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
249
+ # As such, this might not be the best way to use this object.
250
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
263
251
 
264
- api_instance = UltracartClient::FulfillmentApi.new
252
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
265
253
 
266
254
  begin
267
255
  # Retrieve distribution centers
@@ -321,18 +309,15 @@ Store the tracking information and mark the order shipped for this distribution
321
309
  ```ruby
322
310
  require 'time'
323
311
  require 'ultracart_api'
324
- # setup authorization
325
- UltracartClient.configure do |config|
326
- # Configure OAuth2 access token for authorization: ultraCartOauth
327
- config.access_token = 'YOUR ACCESS TOKEN'
328
-
329
- # Configure API key authorization: ultraCartSimpleApiKey
330
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
331
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
332
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
333
- end
312
+ require 'json'
313
+ require 'yaml'
314
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
334
315
 
335
- api_instance = UltracartClient::FulfillmentApi.new
316
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
317
+ # As such, this might not be the best way to use this object.
318
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
319
+
320
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
336
321
  distribution_center_code = 'distribution_center_code_example' # String | Distribution center code
337
322
  shipments = [UltracartClient::FulfillmentShipment.new] # Array<FulfillmentShipment> | Orders to mark shipped
338
323
 
@@ -396,18 +381,15 @@ Update the inventory for items associated with this distribution center
396
381
  ```ruby
397
382
  require 'time'
398
383
  require 'ultracart_api'
399
- # setup authorization
400
- UltracartClient.configure do |config|
401
- # Configure OAuth2 access token for authorization: ultraCartOauth
402
- config.access_token = 'YOUR ACCESS TOKEN'
403
-
404
- # Configure API key authorization: ultraCartSimpleApiKey
405
- config.api_key['ultraCartSimpleApiKey'] = 'YOUR API KEY'
406
- # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
407
- # config.api_key_prefix['ultraCartSimpleApiKey'] = 'Bearer'
408
- end
384
+ require 'json'
385
+ require 'yaml'
386
+ require_relative '../constants' # https://github.com/UltraCart/sdk_samples/blob/master/ruby/constants.rb
387
+
388
+ # This example is based on our samples_sdk project, but still contains auto-generated content from our sdk generators.
389
+ # As such, this might not be the best way to use this object.
390
+ # Please see https://github.com/UltraCart/sdk_samples for working examples.
409
391
 
410
- api_instance = UltracartClient::FulfillmentApi.new
392
+ api = UltracartClient::FulfillmentApi.new_using_api_key(Constants::API_KEY, Constants::VERIFY_SSL, Constants::DEBUG_MODE)
411
393
  distribution_center_code = 'distribution_center_code_example' # String | Distribution center code
412
394
  inventories = [UltracartClient::FulfillmentInventory.new] # Array<FulfillmentInventory> | Inventory updates (limit 500)
413
395