Gift Card
AddGiftCard
Add a gift card code to the customer's current order.
Arguments
Name | Type | Description |
storeId | long | Id of the store. |
code | string | Code to add. |
Example
Arguments
Name | Type | Default | Description |
code | string | | Code to add. |
storeId | long | _storeId | Id of the store. |
async | boolean | true | Specifies if a request should be asynchronously. |
successfn | function(json[, jQForm]) | | A function to be called if the request succeeds. |
errorfn | function(json) | | A function to be called if the request fails. |
Return values
Type | Description |
methodsCalled | An object containing information about the methods called, related data to the methods and the order object if present.
Will only be returned if you use async = false |
Example
Arguments
Name | Type | Description |
storeId | long | Id of the store. |
code | string | Code to add. |
Return values
Type | Description |
AppliedGiftCard | The added gift card object. |
Example
RemoveGiftCard
Remove a gift card code from the customer's current order.
Arguments
Name | Type | Description |
storeId | long | Id of the store. |
code | string | Code to remove. |
Example
Arguments
Name | Type | Default | Description |
code | string | | Code to remove. |
storeId | long | _storeId | Id of the store. |
async | boolean | true | Specifies if a request should be asynchronously. |
successfn | function(json[, jQForm]) | | A function to be called if the request succeeds. |
errorfn | function(json) | | A function to be called if the request fails. |
Return values
Type | Description |
methodsCalled | An object containing information about the methods called, related data to the methods and the order object if present.
Will only be returned if you use async = false |
Example
Arguments
Name | Type | Description |
storeId | long | Id of the store. |
code | string | Code to remove. |
Return values
Type | Description |
AppliedDiscountCode | The removed gift card object. |
Example
Last Updated: 12/27/2018, 4:46:55 PM