ultracart_api 3.6.37 → 3.8.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +25 -4
- data/docs/AutoOrder.md +1 -0
- data/docs/AutoOrderLog.md +9 -0
- data/docs/CustomerApi.md +3 -4
- data/docs/ExperimentVariation.md +1 -0
- data/docs/GiftCertificate.md +19 -0
- data/docs/GiftCertificateApi.md +433 -0
- data/docs/GiftCertificateCreateRequest.md +11 -0
- data/docs/GiftCertificateLedgerEntry.md +13 -0
- data/docs/GiftCertificateQuery.md +16 -0
- data/docs/GiftCertificateResponse.md +12 -0
- data/docs/GiftCertificatesResponse.md +12 -0
- data/lib/ultracart_api/api/customer_api.rb +5 -6
- data/lib/ultracart_api/api/gift_certificate_api.rb +502 -0
- data/lib/ultracart_api/models/auto_order.rb +13 -1
- data/lib/ultracart_api/models/auto_order_log.rb +195 -0
- data/lib/ultracart_api/models/experiment_variation.rb +11 -1
- data/lib/ultracart_api/models/gift_certificate.rb +297 -0
- data/lib/ultracart_api/models/gift_certificate_create_request.rb +215 -0
- data/lib/ultracart_api/models/gift_certificate_ledger_entry.rb +235 -0
- data/lib/ultracart_api/models/gift_certificate_query.rb +265 -0
- data/lib/ultracart_api/models/gift_certificate_response.rb +221 -0
- data/lib/ultracart_api/models/gift_certificates_response.rb +223 -0
- data/lib/ultracart_api/version.rb +1 -1
- data/lib/ultracart_api.rb +8 -0
- metadata +18 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6412a8238f4fe528a28a303ce630e77e99b6b2228b4f4d5203573f261e568109
|
4
|
+
data.tar.gz: 1a96aae95a1230fa762bf4ea920a512d06d434ff1a483025273fa541a684ac5a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 8ecb7304421102db1396eb30c198919c3f7d1b991130b8f00c13b1e73a553e2d590cd0b17432e41c287721d9f7ec32c72ea451f4a8c62f014a49e5b7a574bedf
|
7
|
+
data.tar.gz: cfcca9ecfe33cc77fa1ddf47210dc921693aa40dd6f4f9775935458c2d95e4a777a93aad7dbc36f148630d5bb8718598a30451a67e5c2d9486544ee3b71ce62a
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@ UltraCart REST API Version 2
|
|
7
7
|
This SDK is automatically generated by the [Swagger Codegen](https://github.com/swagger-api/swagger-codegen) project:
|
8
8
|
|
9
9
|
- API version: 2.0.0
|
10
|
-
- Package version: 3.
|
10
|
+
- Package version: 3.8.1
|
11
11
|
- Build package: io.swagger.codegen.languages.RubyClientCodegen
|
12
12
|
For more information, please visit [http://www.ultracart.com](http://www.ultracart.com)
|
13
13
|
|
@@ -24,15 +24,15 @@ gem build ultracart_api.gemspec
|
|
24
24
|
Then either install the gem locally:
|
25
25
|
|
26
26
|
```shell
|
27
|
-
gem install ./ultracart_api-3.
|
27
|
+
gem install ./ultracart_api-3.8.1.gem
|
28
28
|
```
|
29
|
-
(for development, run `gem install --dev ./ultracart_api-3.
|
29
|
+
(for development, run `gem install --dev ./ultracart_api-3.8.1.gem` to install the development dependencies)
|
30
30
|
|
31
31
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
32
32
|
|
33
33
|
Finally add this to the Gemfile:
|
34
34
|
|
35
|
-
gem 'ultracart_api', '~> 3.
|
35
|
+
gem 'ultracart_api', '~> 3.8.1'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -173,6 +173,14 @@ Class | Method | HTTP request | Description
|
|
173
173
|
*UltracartClient::FulfillmentApi* | [**get_distribution_centers**](docs/FulfillmentApi.md#get_distribution_centers) | **GET** /fulfillment/distribution_centers | Retrieve distribution centers
|
174
174
|
*UltracartClient::FulfillmentApi* | [**ship_orders**](docs/FulfillmentApi.md#ship_orders) | **POST** /fulfillment/distribution_centers/{distribution_center_code}/shipments | Mark orders as shipped
|
175
175
|
*UltracartClient::FulfillmentApi* | [**update_inventory**](docs/FulfillmentApi.md#update_inventory) | **POST** /fulfillment/distribution_centers/{distribution_center_code}/inventory | Update inventory
|
176
|
+
*UltracartClient::GiftCertificateApi* | [**add_gift_certificate_ledger_entry**](docs/GiftCertificateApi.md#add_gift_certificate_ledger_entry) | **POST** /gift_certificate/gift_certificates/{gift_certificate_oid}/ledger_entry | Add a gift certificate ledger entry
|
177
|
+
*UltracartClient::GiftCertificateApi* | [**create_gift_certificate**](docs/GiftCertificateApi.md#create_gift_certificate) | **POST** /gift_certificate/gift_certificates | Create a gift certificate
|
178
|
+
*UltracartClient::GiftCertificateApi* | [**delete_gift_certificate**](docs/GiftCertificateApi.md#delete_gift_certificate) | **DELETE** /gift_certificate/gift_certificates/{gift_certificate_oid} | Delete a gift certificate
|
179
|
+
*UltracartClient::GiftCertificateApi* | [**get_gift_certificate_by_code**](docs/GiftCertificateApi.md#get_gift_certificate_by_code) | **POST** /gift_certificate/gift_certificates/by_code/{code} | Retrieve gift certificate by code
|
180
|
+
*UltracartClient::GiftCertificateApi* | [**get_gift_certificate_by_oid**](docs/GiftCertificateApi.md#get_gift_certificate_by_oid) | **POST** /gift_certificate/gift_certificates/{gift_certificate_oid} | Retrieve gift certificate by oid
|
181
|
+
*UltracartClient::GiftCertificateApi* | [**get_gift_certificates_by_email**](docs/GiftCertificateApi.md#get_gift_certificates_by_email) | **POST** /gift_certificate/gift_certificates/by_email/{email} | Retrieve gift certificate by email
|
182
|
+
*UltracartClient::GiftCertificateApi* | [**get_gift_certificates_by_query**](docs/GiftCertificateApi.md#get_gift_certificates_by_query) | **POST** /gift_certificate/gift_certificates/query | Retrieve gift certificates by query
|
183
|
+
*UltracartClient::GiftCertificateApi* | [**update_gift_certificate**](docs/GiftCertificateApi.md#update_gift_certificate) | **PUT** /gift_certificate/gift_certificates/{gift_certificate_oid} | Update a gift certificate
|
176
184
|
*UltracartClient::IntegrationLogApi* | [**get_integration_log**](docs/IntegrationLogApi.md#get_integration_log) | **GET** /integration_log/query/{pk}/{sk} | Retrieve an integration log
|
177
185
|
*UltracartClient::IntegrationLogApi* | [**get_integration_log_file**](docs/IntegrationLogApi.md#get_integration_log_file) | **GET** /integration_log/query/{pk}/{sk}/{uuid} | Retrieve an integration log file
|
178
186
|
*UltracartClient::IntegrationLogApi* | [**get_integration_log_summaries_query**](docs/IntegrationLogApi.md#get_integration_log_summaries_query) | **POST** /integration_log/summary/query | Retrieve integration log summaries
|
@@ -449,6 +457,7 @@ Class | Method | HTTP request | Description
|
|
449
457
|
- [UltracartClient::AutoOrderItemFutureSchedule](docs/AutoOrderItemFutureSchedule.md)
|
450
458
|
- [UltracartClient::AutoOrderItemOption](docs/AutoOrderItemOption.md)
|
451
459
|
- [UltracartClient::AutoOrderItemSimpleSchedule](docs/AutoOrderItemSimpleSchedule.md)
|
460
|
+
- [UltracartClient::AutoOrderLog](docs/AutoOrderLog.md)
|
452
461
|
- [UltracartClient::AutoOrderQuery](docs/AutoOrderQuery.md)
|
453
462
|
- [UltracartClient::AutoOrderQueryBatch](docs/AutoOrderQueryBatch.md)
|
454
463
|
- [UltracartClient::AutoOrderResponse](docs/AutoOrderResponse.md)
|
@@ -737,6 +746,12 @@ Class | Method | HTTP request | Description
|
|
737
746
|
- [UltracartClient::GeoPoint](docs/GeoPoint.md)
|
738
747
|
- [UltracartClient::GeocodeRequest](docs/GeocodeRequest.md)
|
739
748
|
- [UltracartClient::GeocodeResponse](docs/GeocodeResponse.md)
|
749
|
+
- [UltracartClient::GiftCertificate](docs/GiftCertificate.md)
|
750
|
+
- [UltracartClient::GiftCertificateCreateRequest](docs/GiftCertificateCreateRequest.md)
|
751
|
+
- [UltracartClient::GiftCertificateLedgerEntry](docs/GiftCertificateLedgerEntry.md)
|
752
|
+
- [UltracartClient::GiftCertificateQuery](docs/GiftCertificateQuery.md)
|
753
|
+
- [UltracartClient::GiftCertificateResponse](docs/GiftCertificateResponse.md)
|
754
|
+
- [UltracartClient::GiftCertificatesResponse](docs/GiftCertificatesResponse.md)
|
740
755
|
- [UltracartClient::Group](docs/Group.md)
|
741
756
|
- [UltracartClient::GroupResponse](docs/GroupResponse.md)
|
742
757
|
- [UltracartClient::GroupUserMembership](docs/GroupUserMembership.md)
|
@@ -1097,6 +1112,8 @@ Class | Method | HTTP request | Description
|
|
1097
1112
|
- customer_write: Allows you to write customer information.
|
1098
1113
|
- fulfillment_read: Allows you to read fulfillment information.
|
1099
1114
|
- fulfillment_write: Allows you to write fulfillment information.
|
1115
|
+
- gift_certificate_read: Allows you to read gift certificate information.
|
1116
|
+
- gift_certificate_write: Allows you to write gift certificate information.
|
1100
1117
|
- integration_log_read: Allows you to read integration log information.
|
1101
1118
|
- integration_log_write: Allows you to write integration log information.
|
1102
1119
|
- order_read: Allows you to read order information.
|
@@ -1128,6 +1145,10 @@ Not every change is committed to every SDK.
|
|
1128
1145
|
|
1129
1146
|
| Version | Date | Comments |
|
1130
1147
|
| --: | :-: | --- |
|
1148
|
+
| 3.8.1 | 02/16/2022 | auto order item level pause flag |
|
1149
|
+
| 3.8.0 | 02/16/2022 | gift certificate api (testing) |
|
1150
|
+
| 3.7.38 | 02/15/2022 | gift certificate api (currently in testing) |
|
1151
|
+
| 3.6.38 | 02/07/2022 | Exposed auto order logs |
|
1131
1152
|
| 3.6.37 | 02/04/2022 | insurance type for insurance payments |
|
1132
1153
|
| 3.6.36 | 12/29/2021 | Mail actual post card flag added to test method |
|
1133
1154
|
| 3.6.35 | 12/14/2021 | Add cancel_auto_order option to the accounts receivable retry configuration |
|
data/docs/AutoOrder.md
CHANGED
@@ -16,6 +16,7 @@ Name | Type | Description | Notes
|
|
16
16
|
**enabled** | **BOOLEAN** | True if this auto order is enabled | [optional]
|
17
17
|
**failure_reason** | **String** | The reason this auto order failed during the last rebill attempt | [optional]
|
18
18
|
**items** | [**Array<AutoOrderItem>**](AutoOrderItem.md) | The items that are setup to rebill | [optional]
|
19
|
+
**logs** | [**Array<AutoOrderLog>**](AutoOrderLog.md) | Logs associated with this auto order | [optional]
|
19
20
|
**next_attempt** | **String** | The next time that the auto order will be attempted for processing | [optional]
|
20
21
|
**original_order** | [**Order**](Order.md) | | [optional]
|
21
22
|
**original_order_id** | **String** | The original order id that this auto order is associated with. | [optional]
|
@@ -0,0 +1,9 @@
|
|
1
|
+
# UltracartClient::AutoOrderLog
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**log_dts** | **String** | Date/time that the log message was added | [optional]
|
7
|
+
**log_message** | **String** | Log message | [optional]
|
8
|
+
|
9
|
+
|
data/docs/CustomerApi.md
CHANGED
@@ -20,7 +20,7 @@ Method | HTTP request | Description
|
|
20
20
|
|
21
21
|
|
22
22
|
# **delete_customer**
|
23
|
-
>
|
23
|
+
> delete_customer(customer_profile_oid)
|
24
24
|
|
25
25
|
Delete a customer
|
26
26
|
|
@@ -41,8 +41,7 @@ customer_profile_oid = 56 # Integer | The customer_profile_oid to delete.
|
|
41
41
|
|
42
42
|
begin
|
43
43
|
#Delete a customer
|
44
|
-
|
45
|
-
p result
|
44
|
+
api_instance.delete_customer(customer_profile_oid)
|
46
45
|
rescue UltracartClient::ApiError => e
|
47
46
|
puts "Exception when calling CustomerApi->delete_customer: #{e}"
|
48
47
|
end
|
@@ -56,7 +55,7 @@ Name | Type | Description | Notes
|
|
56
55
|
|
57
56
|
### Return type
|
58
57
|
|
59
|
-
|
58
|
+
nil (empty response body)
|
60
59
|
|
61
60
|
### Authorization
|
62
61
|
|
data/docs/ExperimentVariation.md
CHANGED
@@ -17,6 +17,7 @@ Name | Type | Description | Notes
|
|
17
17
|
**order_item_count** | **Integer** | Total order item count for this variation | [optional]
|
18
18
|
**original_traffic_percentage** | **Float** | Percentage of the traffic the variation originally started out with | [optional]
|
19
19
|
**page_view_count** | **Integer** | Total page view count for this variation | [optional]
|
20
|
+
**paused** | **BOOLEAN** | True if traffic should be paused to this variation | [optional]
|
20
21
|
**revenue** | **Float** | Total revenue for this variation | [optional]
|
21
22
|
**session_count** | **Integer** | Total sessions for this variation | [optional]
|
22
23
|
**traffic_percentage** | **Float** | Percentage of the traffic this variation is currently receiving | [optional]
|
@@ -0,0 +1,19 @@
|
|
1
|
+
# UltracartClient::GiftCertificate
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**activated** | **BOOLEAN** | True if this gift certificate is activated and ready to apply to purchases. | [optional]
|
7
|
+
**code** | **String** | The code used by the customer to purchase against this gift certificate. | [optional]
|
8
|
+
**deleted** | **BOOLEAN** | True if this gift certificate was deleted. | [optional]
|
9
|
+
**email** | **String** | Email of the customer associated with this gift certificate. | [optional]
|
10
|
+
**expiration_dts** | **String** | Expiration date time. | [optional]
|
11
|
+
**gift_certificate_oid** | **Integer** | Gift certificate oid. | [optional]
|
12
|
+
**ledger_entries** | [**Array<GiftCertificateLedgerEntry>**](GiftCertificateLedgerEntry.md) | A list of all ledger activity for this gift certificate. | [optional]
|
13
|
+
**merchant_id** | **String** | Merchant Id | [optional]
|
14
|
+
**merchant_note** | **String** | A list of all ledger activity for this gift certificate. | [optional]
|
15
|
+
**original_balance** | **Float** | Original balance of the gift certificate. | [optional]
|
16
|
+
**reference_order_id** | **String** | The order used to purchase this gift certificate. This value is ONLY set during checkout when a certificate is purchased, not when it is used. Any usage is recorded in the ledger | [optional]
|
17
|
+
**remaining_balance** | **Float** | The remaining balance on the gift certificate. This is never set directly, but calculated from the ledger. To change the remaining balance, add a ledger entry. | [optional]
|
18
|
+
|
19
|
+
|
@@ -0,0 +1,433 @@
|
|
1
|
+
# UltracartClient::GiftCertificateApi
|
2
|
+
|
3
|
+
All URIs are relative to *https://secure.ultracart.com/rest/v2*
|
4
|
+
|
5
|
+
Method | HTTP request | Description
|
6
|
+
------------- | ------------- | -------------
|
7
|
+
[**add_gift_certificate_ledger_entry**](GiftCertificateApi.md#add_gift_certificate_ledger_entry) | **POST** /gift_certificate/gift_certificates/{gift_certificate_oid}/ledger_entry | Add a gift certificate ledger entry
|
8
|
+
[**create_gift_certificate**](GiftCertificateApi.md#create_gift_certificate) | **POST** /gift_certificate/gift_certificates | Create a gift certificate
|
9
|
+
[**delete_gift_certificate**](GiftCertificateApi.md#delete_gift_certificate) | **DELETE** /gift_certificate/gift_certificates/{gift_certificate_oid} | Delete a gift certificate
|
10
|
+
[**get_gift_certificate_by_code**](GiftCertificateApi.md#get_gift_certificate_by_code) | **POST** /gift_certificate/gift_certificates/by_code/{code} | Retrieve gift certificate by code
|
11
|
+
[**get_gift_certificate_by_oid**](GiftCertificateApi.md#get_gift_certificate_by_oid) | **POST** /gift_certificate/gift_certificates/{gift_certificate_oid} | Retrieve gift certificate by oid
|
12
|
+
[**get_gift_certificates_by_email**](GiftCertificateApi.md#get_gift_certificates_by_email) | **POST** /gift_certificate/gift_certificates/by_email/{email} | Retrieve gift certificate by email
|
13
|
+
[**get_gift_certificates_by_query**](GiftCertificateApi.md#get_gift_certificates_by_query) | **POST** /gift_certificate/gift_certificates/query | Retrieve gift certificates by query
|
14
|
+
[**update_gift_certificate**](GiftCertificateApi.md#update_gift_certificate) | **PUT** /gift_certificate/gift_certificates/{gift_certificate_oid} | Update a gift certificate
|
15
|
+
|
16
|
+
|
17
|
+
# **add_gift_certificate_ledger_entry**
|
18
|
+
> GiftCertificateResponse add_gift_certificate_ledger_entry(gift_certificate_oid, gift_certificate_ledger_entry)
|
19
|
+
|
20
|
+
Add a gift certificate ledger entry
|
21
|
+
|
22
|
+
Adds a ledger entry for this gift certificate.
|
23
|
+
|
24
|
+
### Example
|
25
|
+
```ruby
|
26
|
+
# load the gem
|
27
|
+
require 'ultracart_api'
|
28
|
+
|
29
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
30
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
31
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
32
|
+
|
33
|
+
|
34
|
+
gift_certificate_oid = 56 # Integer |
|
35
|
+
|
36
|
+
gift_certificate_ledger_entry = UltracartClient::GiftCertificateLedgerEntry.new # GiftCertificateLedgerEntry | Gift certificate ledger entry
|
37
|
+
|
38
|
+
|
39
|
+
begin
|
40
|
+
#Add a gift certificate ledger entry
|
41
|
+
result = api_instance.add_gift_certificate_ledger_entry(gift_certificate_oid, gift_certificate_ledger_entry)
|
42
|
+
p result
|
43
|
+
rescue UltracartClient::ApiError => e
|
44
|
+
puts "Exception when calling GiftCertificateApi->add_gift_certificate_ledger_entry: #{e}"
|
45
|
+
end
|
46
|
+
```
|
47
|
+
|
48
|
+
### Parameters
|
49
|
+
|
50
|
+
Name | Type | Description | Notes
|
51
|
+
------------- | ------------- | ------------- | -------------
|
52
|
+
**gift_certificate_oid** | **Integer**| |
|
53
|
+
**gift_certificate_ledger_entry** | [**GiftCertificateLedgerEntry**](GiftCertificateLedgerEntry.md)| Gift certificate ledger entry |
|
54
|
+
|
55
|
+
### Return type
|
56
|
+
|
57
|
+
[**GiftCertificateResponse**](GiftCertificateResponse.md)
|
58
|
+
|
59
|
+
### Authorization
|
60
|
+
|
61
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
62
|
+
|
63
|
+
### HTTP request headers
|
64
|
+
|
65
|
+
- **Content-Type**: application/json
|
66
|
+
- **Accept**: application/json
|
67
|
+
|
68
|
+
|
69
|
+
|
70
|
+
# **create_gift_certificate**
|
71
|
+
> GiftCertificateResponse create_gift_certificate(gift_certificate_create_request)
|
72
|
+
|
73
|
+
Create a gift certificate
|
74
|
+
|
75
|
+
Creates a gift certificate for this merchant account.
|
76
|
+
|
77
|
+
### Example
|
78
|
+
```ruby
|
79
|
+
# load the gem
|
80
|
+
require 'ultracart_api'
|
81
|
+
|
82
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
83
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
84
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
85
|
+
|
86
|
+
|
87
|
+
gift_certificate_create_request = UltracartClient::GiftCertificateCreateRequest.new # GiftCertificateCreateRequest | Gift certificate create request
|
88
|
+
|
89
|
+
|
90
|
+
begin
|
91
|
+
#Create a gift certificate
|
92
|
+
result = api_instance.create_gift_certificate(gift_certificate_create_request)
|
93
|
+
p result
|
94
|
+
rescue UltracartClient::ApiError => e
|
95
|
+
puts "Exception when calling GiftCertificateApi->create_gift_certificate: #{e}"
|
96
|
+
end
|
97
|
+
```
|
98
|
+
|
99
|
+
### Parameters
|
100
|
+
|
101
|
+
Name | Type | Description | Notes
|
102
|
+
------------- | ------------- | ------------- | -------------
|
103
|
+
**gift_certificate_create_request** | [**GiftCertificateCreateRequest**](GiftCertificateCreateRequest.md)| Gift certificate create request |
|
104
|
+
|
105
|
+
### Return type
|
106
|
+
|
107
|
+
[**GiftCertificateResponse**](GiftCertificateResponse.md)
|
108
|
+
|
109
|
+
### Authorization
|
110
|
+
|
111
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
112
|
+
|
113
|
+
### HTTP request headers
|
114
|
+
|
115
|
+
- **Content-Type**: application/json
|
116
|
+
- **Accept**: application/json
|
117
|
+
|
118
|
+
|
119
|
+
|
120
|
+
# **delete_gift_certificate**
|
121
|
+
> delete_gift_certificate(gift_certificate_oid)
|
122
|
+
|
123
|
+
Delete a gift certificate
|
124
|
+
|
125
|
+
Deletes a gift certificate for this merchant account.
|
126
|
+
|
127
|
+
### Example
|
128
|
+
```ruby
|
129
|
+
# load the gem
|
130
|
+
require 'ultracart_api'
|
131
|
+
|
132
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
133
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
134
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
135
|
+
|
136
|
+
|
137
|
+
gift_certificate_oid = 56 # Integer |
|
138
|
+
|
139
|
+
|
140
|
+
begin
|
141
|
+
#Delete a gift certificate
|
142
|
+
api_instance.delete_gift_certificate(gift_certificate_oid)
|
143
|
+
rescue UltracartClient::ApiError => e
|
144
|
+
puts "Exception when calling GiftCertificateApi->delete_gift_certificate: #{e}"
|
145
|
+
end
|
146
|
+
```
|
147
|
+
|
148
|
+
### Parameters
|
149
|
+
|
150
|
+
Name | Type | Description | Notes
|
151
|
+
------------- | ------------- | ------------- | -------------
|
152
|
+
**gift_certificate_oid** | **Integer**| |
|
153
|
+
|
154
|
+
### Return type
|
155
|
+
|
156
|
+
nil (empty response body)
|
157
|
+
|
158
|
+
### Authorization
|
159
|
+
|
160
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
161
|
+
|
162
|
+
### HTTP request headers
|
163
|
+
|
164
|
+
- **Content-Type**: application/json
|
165
|
+
- **Accept**: application/json
|
166
|
+
|
167
|
+
|
168
|
+
|
169
|
+
# **get_gift_certificate_by_code**
|
170
|
+
> GiftCertificateResponse get_gift_certificate_by_code(code)
|
171
|
+
|
172
|
+
Retrieve gift certificate by code
|
173
|
+
|
174
|
+
Retrieves a gift certificate from the account based on the code (the value the customer enters at checkout time).
|
175
|
+
|
176
|
+
### Example
|
177
|
+
```ruby
|
178
|
+
# load the gem
|
179
|
+
require 'ultracart_api'
|
180
|
+
|
181
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
182
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
183
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
184
|
+
|
185
|
+
|
186
|
+
code = 'code_example' # String |
|
187
|
+
|
188
|
+
|
189
|
+
begin
|
190
|
+
#Retrieve gift certificate by code
|
191
|
+
result = api_instance.get_gift_certificate_by_code(code)
|
192
|
+
p result
|
193
|
+
rescue UltracartClient::ApiError => e
|
194
|
+
puts "Exception when calling GiftCertificateApi->get_gift_certificate_by_code: #{e}"
|
195
|
+
end
|
196
|
+
```
|
197
|
+
|
198
|
+
### Parameters
|
199
|
+
|
200
|
+
Name | Type | Description | Notes
|
201
|
+
------------- | ------------- | ------------- | -------------
|
202
|
+
**code** | **String**| |
|
203
|
+
|
204
|
+
### Return type
|
205
|
+
|
206
|
+
[**GiftCertificateResponse**](GiftCertificateResponse.md)
|
207
|
+
|
208
|
+
### Authorization
|
209
|
+
|
210
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
211
|
+
|
212
|
+
### HTTP request headers
|
213
|
+
|
214
|
+
- **Content-Type**: application/json
|
215
|
+
- **Accept**: application/json
|
216
|
+
|
217
|
+
|
218
|
+
|
219
|
+
# **get_gift_certificate_by_oid**
|
220
|
+
> GiftCertificateResponse get_gift_certificate_by_oid(gift_certificate_oid)
|
221
|
+
|
222
|
+
Retrieve gift certificate by oid
|
223
|
+
|
224
|
+
Retrieves a gift certificate from the account based on the internal primary key.
|
225
|
+
|
226
|
+
### Example
|
227
|
+
```ruby
|
228
|
+
# load the gem
|
229
|
+
require 'ultracart_api'
|
230
|
+
|
231
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
232
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
233
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
234
|
+
|
235
|
+
|
236
|
+
gift_certificate_oid = 56 # Integer |
|
237
|
+
|
238
|
+
|
239
|
+
begin
|
240
|
+
#Retrieve gift certificate by oid
|
241
|
+
result = api_instance.get_gift_certificate_by_oid(gift_certificate_oid)
|
242
|
+
p result
|
243
|
+
rescue UltracartClient::ApiError => e
|
244
|
+
puts "Exception when calling GiftCertificateApi->get_gift_certificate_by_oid: #{e}"
|
245
|
+
end
|
246
|
+
```
|
247
|
+
|
248
|
+
### Parameters
|
249
|
+
|
250
|
+
Name | Type | Description | Notes
|
251
|
+
------------- | ------------- | ------------- | -------------
|
252
|
+
**gift_certificate_oid** | **Integer**| |
|
253
|
+
|
254
|
+
### Return type
|
255
|
+
|
256
|
+
[**GiftCertificateResponse**](GiftCertificateResponse.md)
|
257
|
+
|
258
|
+
### Authorization
|
259
|
+
|
260
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
261
|
+
|
262
|
+
### HTTP request headers
|
263
|
+
|
264
|
+
- **Content-Type**: application/json
|
265
|
+
- **Accept**: application/json
|
266
|
+
|
267
|
+
|
268
|
+
|
269
|
+
# **get_gift_certificates_by_email**
|
270
|
+
> GiftCertificatesResponse get_gift_certificates_by_email(email)
|
271
|
+
|
272
|
+
Retrieve gift certificate by email
|
273
|
+
|
274
|
+
Retrieves all gift certificates from the account based on customer email.
|
275
|
+
|
276
|
+
### Example
|
277
|
+
```ruby
|
278
|
+
# load the gem
|
279
|
+
require 'ultracart_api'
|
280
|
+
|
281
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
282
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
283
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
284
|
+
|
285
|
+
|
286
|
+
email = 'email_example' # String |
|
287
|
+
|
288
|
+
|
289
|
+
begin
|
290
|
+
#Retrieve gift certificate by email
|
291
|
+
result = api_instance.get_gift_certificates_by_email(email)
|
292
|
+
p result
|
293
|
+
rescue UltracartClient::ApiError => e
|
294
|
+
puts "Exception when calling GiftCertificateApi->get_gift_certificates_by_email: #{e}"
|
295
|
+
end
|
296
|
+
```
|
297
|
+
|
298
|
+
### Parameters
|
299
|
+
|
300
|
+
Name | Type | Description | Notes
|
301
|
+
------------- | ------------- | ------------- | -------------
|
302
|
+
**email** | **String**| |
|
303
|
+
|
304
|
+
### Return type
|
305
|
+
|
306
|
+
[**GiftCertificatesResponse**](GiftCertificatesResponse.md)
|
307
|
+
|
308
|
+
### Authorization
|
309
|
+
|
310
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
311
|
+
|
312
|
+
### HTTP request headers
|
313
|
+
|
314
|
+
- **Content-Type**: application/json
|
315
|
+
- **Accept**: application/json
|
316
|
+
|
317
|
+
|
318
|
+
|
319
|
+
# **get_gift_certificates_by_query**
|
320
|
+
> GiftCertificatesResponse get_gift_certificates_by_query(gift_certificate_query, opts)
|
321
|
+
|
322
|
+
Retrieve gift certificates by query
|
323
|
+
|
324
|
+
Retrieves gift certificates from the account. If no parameters are specified, all gift certificates 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.
|
325
|
+
|
326
|
+
### Example
|
327
|
+
```ruby
|
328
|
+
# load the gem
|
329
|
+
require 'ultracart_api'
|
330
|
+
|
331
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
332
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
333
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
334
|
+
|
335
|
+
|
336
|
+
gift_certificate_query = UltracartClient::GiftCertificateQuery.new # GiftCertificateQuery | Gift certificates query
|
337
|
+
|
338
|
+
opts = {
|
339
|
+
_limit: 100, # Integer | The maximum number of records to return on this one API call. (Max 200)
|
340
|
+
_offset: 0, # Integer | Pagination of the record set. Offset is a zero based index.
|
341
|
+
_since: '_since_example', # String | Fetch customers that have been created/modified since this date/time.
|
342
|
+
_sort: '_sort_example', # String | The sort order of the customers. See Sorting documentation for examples of using multiple values and sorting by ascending and descending.
|
343
|
+
_expand: '_expand_example' # String | The object expansion to perform on the result. See documentation for examples
|
344
|
+
}
|
345
|
+
|
346
|
+
begin
|
347
|
+
#Retrieve gift certificates by query
|
348
|
+
result = api_instance.get_gift_certificates_by_query(gift_certificate_query, opts)
|
349
|
+
p result
|
350
|
+
rescue UltracartClient::ApiError => e
|
351
|
+
puts "Exception when calling GiftCertificateApi->get_gift_certificates_by_query: #{e}"
|
352
|
+
end
|
353
|
+
```
|
354
|
+
|
355
|
+
### Parameters
|
356
|
+
|
357
|
+
Name | Type | Description | Notes
|
358
|
+
------------- | ------------- | ------------- | -------------
|
359
|
+
**gift_certificate_query** | [**GiftCertificateQuery**](GiftCertificateQuery.md)| Gift certificates query |
|
360
|
+
**_limit** | **Integer**| The maximum number of records to return on this one API call. (Max 200) | [optional] [default to 100]
|
361
|
+
**_offset** | **Integer**| Pagination of the record set. Offset is a zero based index. | [optional] [default to 0]
|
362
|
+
**_since** | **String**| Fetch customers that have been created/modified since this date/time. | [optional]
|
363
|
+
**_sort** | **String**| The sort order of the customers. See Sorting documentation for examples of using multiple values and sorting by ascending and descending. | [optional]
|
364
|
+
**_expand** | **String**| The object expansion to perform on the result. See documentation for examples | [optional]
|
365
|
+
|
366
|
+
### Return type
|
367
|
+
|
368
|
+
[**GiftCertificatesResponse**](GiftCertificatesResponse.md)
|
369
|
+
|
370
|
+
### Authorization
|
371
|
+
|
372
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
373
|
+
|
374
|
+
### HTTP request headers
|
375
|
+
|
376
|
+
- **Content-Type**: application/json
|
377
|
+
- **Accept**: application/json
|
378
|
+
|
379
|
+
|
380
|
+
|
381
|
+
# **update_gift_certificate**
|
382
|
+
> GiftCertificateResponse update_gift_certificate(gift_certificate_oid, gift_certificate)
|
383
|
+
|
384
|
+
Update a gift certificate
|
385
|
+
|
386
|
+
Update a gift certificate for this merchant account.
|
387
|
+
|
388
|
+
### Example
|
389
|
+
```ruby
|
390
|
+
# load the gem
|
391
|
+
require 'ultracart_api'
|
392
|
+
|
393
|
+
# Create a Simple Key: https://ultracart.atlassian.net/wiki/spaces/ucdoc/pages/38688545/API+Simple+Key
|
394
|
+
simple_key = '109ee846ee69f50177018ab12f008a00748a25aa28dbdc0177018ab12f008a00'
|
395
|
+
api_instance = UltracartClient::GiftCertificateApi.new_using_api_key(simple_key, false, false)
|
396
|
+
|
397
|
+
|
398
|
+
gift_certificate_oid = 56 # Integer |
|
399
|
+
|
400
|
+
gift_certificate = UltracartClient::GiftCertificate.new # GiftCertificate | Gift certificate
|
401
|
+
|
402
|
+
|
403
|
+
begin
|
404
|
+
#Update a gift certificate
|
405
|
+
result = api_instance.update_gift_certificate(gift_certificate_oid, gift_certificate)
|
406
|
+
p result
|
407
|
+
rescue UltracartClient::ApiError => e
|
408
|
+
puts "Exception when calling GiftCertificateApi->update_gift_certificate: #{e}"
|
409
|
+
end
|
410
|
+
```
|
411
|
+
|
412
|
+
### Parameters
|
413
|
+
|
414
|
+
Name | Type | Description | Notes
|
415
|
+
------------- | ------------- | ------------- | -------------
|
416
|
+
**gift_certificate_oid** | **Integer**| |
|
417
|
+
**gift_certificate** | [**GiftCertificate**](GiftCertificate.md)| Gift certificate |
|
418
|
+
|
419
|
+
### Return type
|
420
|
+
|
421
|
+
[**GiftCertificateResponse**](GiftCertificateResponse.md)
|
422
|
+
|
423
|
+
### Authorization
|
424
|
+
|
425
|
+
[ultraCartOauth](../README.md#ultraCartOauth), [ultraCartSimpleApiKey](../README.md#ultraCartSimpleApiKey)
|
426
|
+
|
427
|
+
### HTTP request headers
|
428
|
+
|
429
|
+
- **Content-Type**: application/json
|
430
|
+
- **Accept**: application/json
|
431
|
+
|
432
|
+
|
433
|
+
|
@@ -0,0 +1,11 @@
|
|
1
|
+
# UltracartClient::GiftCertificateCreateRequest
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**amount** | **Float** | Initial amount of this gift certificate. | [optional]
|
7
|
+
**expiration_dts** | **String** | Expiration date time. | [optional]
|
8
|
+
**initial_ledger_description** | **String** | A brief description of how and/or why this gift certificate was created. | [optional]
|
9
|
+
**merchant_note** | **String** | Any internal details you wish to record about this gift certificate. | [optional]
|
10
|
+
|
11
|
+
|
@@ -0,0 +1,13 @@
|
|
1
|
+
# UltracartClient::GiftCertificateLedgerEntry
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**amount** | **Float** | The amount of the activity. | [optional]
|
7
|
+
**description** | **String** | Description of what this ledger entry is used. | [optional]
|
8
|
+
**entry_dts** | **String** | Date time of this ledger activity. | [optional]
|
9
|
+
**gift_certificate_ledger_oid** | **Integer** | Gift certificate ledger oid is a primary key for this object, used internally. | [optional]
|
10
|
+
**gift_certificate_oid** | **Integer** | Gift certificate oid. | [optional]
|
11
|
+
**reference_order_id** | **String** | The order id if this gift certificate was used as part of the payment. | [optional]
|
12
|
+
|
13
|
+
|
@@ -0,0 +1,16 @@
|
|
1
|
+
# UltracartClient::GiftCertificateQuery
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**code** | **String** | Gift certificate code | [optional]
|
7
|
+
**email** | **String** | Email address of this gift certificate | [optional]
|
8
|
+
**expiration_dts_end** | **String** | Expiration date end | [optional]
|
9
|
+
**expiration_dts_start** | **String** | Expiration date start | [optional]
|
10
|
+
**original_balance_end** | **Float** | Original balance end | [optional]
|
11
|
+
**original_balance_start** | **Float** | Original balance start | [optional]
|
12
|
+
**reference_order_id** | **String** | Gift certificate reference order id | [optional]
|
13
|
+
**remaining_balance_end** | **Float** | Remaining balance end | [optional]
|
14
|
+
**remaining_balance_start** | **Float** | Remaining balance start | [optional]
|
15
|
+
|
16
|
+
|
@@ -0,0 +1,12 @@
|
|
1
|
+
# UltracartClient::GiftCertificateResponse
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
Name | Type | Description | Notes
|
5
|
+
------------ | ------------- | ------------- | -------------
|
6
|
+
**error** | [**Error**](Error.md) | | [optional]
|
7
|
+
**gift_certificate** | [**GiftCertificate**](GiftCertificate.md) | | [optional]
|
8
|
+
**metadata** | [**ResponseMetadata**](ResponseMetadata.md) | | [optional]
|
9
|
+
**success** | **BOOLEAN** | Indicates if API call was successful | [optional]
|
10
|
+
**warning** | [**Warning**](Warning.md) | | [optional]
|
11
|
+
|
12
|
+
|