Summary
- The Annex Cloud’s (AC) cartridge contains the Loyalty Program and Refer a Friend (RAF) program module.
- The Loyalty Program module allows customers to:
- Earn loyalty points based on specific actions they perform on the client’s website.
- Use those loyalty points on featured purchases to get discounts or gift cards.
- The sales tracking script tracks orders being placed by customers who have interacted with the Annex Cloud modules.
- Integration for this cartridge includes the deployment of a generic cartridge combined with minor modifications of templates inside the storefront code.
Component
Functional Overview
From a user’s standpoint, the Annex Cloud cartridge is a combination of several different features enabled by using the different templates available inside this one cartridge.
For example, the Annex Cloud cartridge allows customers to access the merchant’s e-commerce site using their social networking credentials. Then, they can browse and purchase specific products or product categories and get rewarded for their activity. From a merchant’s standpoint, the cartridge is a tool that rewards loyal customers who share and promote their site or products and hence directs traffic towards the site.
While the sale tracking script doesn’t provide any additional functionality for customers, it goes along with other modules that use the data captured by the script.
Use Cases for Loyalty Program
- Customers can see the Enroll or Sign-Up link for the Loyalty Program on the client’s website.
- Upon clicking on the Enroll or Sign-Up link, the client’s registration or Create an Account page displays.
- After completion of the registration process, the customer views the Dashboard of the Loyalty Program.
- The Loyalty Dashboard has three main sections:
- Earn Points
- Manage Rewards
- Activity
- In the Earn Points tab, view the actions that yield points to the member.
- Any of these performed actions earn loyalty points.
- In the Manage Rewards tab, view the active rewards and the Claim Rewards link to redeem the active rewards.
- In the Activity tab, view a list of performed actions.
- You can view the Lifetime points earned from the enrollment date and the Available points earned after the reward redemption.
- View product points on the product page.
- View eligible product points on the category page.
- Redeem points (as dollars) on the checkout page.
- Redeem points (as a coupon code) on the checkout page.
- Earn loyalty points for performing a custom action.
- Earn loyalty points for performing a purchase action.
- Update member information, including first name, last name, address, and other data points.
Use Case for Sale Tracking
Sale tracking is used to track sales and provide reporting and analytics on Annex Cloud.
Limitations
There are no known limitations or constraints associated with third party offerings.
Compatibility
Built on Version 23.9 (Compatibility Mode: 22.7).
Payment Privacy
Once the customer chooses to interact with Annex Cloud’s widgets on the client site, the widgets ask for the customer’s permission to access their relevant profile data. The profile data is stored on the Annex Cloud database servers.
Once an Annex Cloud sale tracking script is in place, and a customer makes a purchase on the site, the script passes the customer’s order details to Annex Cloud for reporting purposes.
For more privacy policy details, please visit: Privacy Policy - Annex Cloud - Loyalty Experience Platform
Implementation Guide
Setup
Note: Before you start these instructions, contact Annex Cloud to initiate setup in the Loyalty system. Once the setup is done on Annex Cloud’s side, you can begin implementation on the client site. Check the support section for contact details.
- Add the cartridge to the site cartridge path as: int_annexcloud_v3:int_annexcloud_sfra_v3.
- Upload the annexcloud.zip file from the Metadata folder by navigating to Administration > Site Development > Site Import & Export > Choose File > Upload.
- Import the metadata by navigating to Administration > Site Development > Site Import & Export > Select uploaded file > Import.
- Add the isml tag on specific pages where you want to add the Annex Cloud modules. See the image below for the tag.
- Activate the Loyalty Program flag from the site preferences.
- Navigate to Merchant Tools > Site Preferences > Custom Site Preferences > Annex Cloud Main Configuration Option
- Select Activate Loyalty Program.
- To display the Loyalty Dashboard, insert the code below at the end of profileCard.isml.
<a
href="${URLUtils.url('LoyaltyProgramShowDashboard')}">${Resource.msg('annexcloud.profile.loyaltyDas
hboard','annexcloud',null)}</a>When the customer logs in or registers, the system redirects to the My Account page. The customer can view the Loyalty Dashboard link.
- Add the code below to the end of the profatileCard.isml file. This enables the ability to create users.
<iscomment>annexCloud : Create User API</iscomment> <isif
condition="${session.getCustomer().getProfile().getEmail()}"> <isscript> var
createUserJSONObj = {}; createUserJSONObj.id=session.getCustomer().getProfile().getEmail();
createUserJSONObj.email=session.getCustomer().getProfile().getEmail();
createUserJSONObj.firstName=session.getCustomer().getProfile().getFirstName();
createUserJSONObj.lastName=session.getCustomer().getProfile().getLastName();
createUserJSONObj.phoneNumber=pdict.account.profile.phone;
createUserJSONObj.optInStatus='YES'; createUserJSONObj.status='ACTIVE';
var giveUserScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/createCustomerAPI'); var
giveUserResponse = giveUserScriptObj.createCustomer(createUserJSONObj);
var giveUserJsonObj = JSON.stringify(giveUserResponse); //This contains parsed json response.
</isscript>
</isif>- Add the following code to enable the Get User Profile API. This API returns member profile details. The response of Get User Profile API will be returned in the userProfileObj object, which the client can use wherever required.
<isscript> var loyaltyID=session.getCustomer().getProfile().getEmail(); var
giveUserScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/getUserAPI'); var
giveUserResponse = giveUserScriptObj.userInfo(loyaltyID); var UserInfoJsonObj =
JSON.parse(giveUserResponse); //This contains parsed json response. </isscript>Sample Positive Response
| Status Code | Response |
| 200 | |
Sample Error Response
| Status Code | Response |
| 100001 | |
- Add the following code to enable the Display Current User Tier API. This API returns the current member tier. The response of the API will be returned in the userPointTierObj object, which the client can use wherever required.
Response
The Display Current User Tier API returns an array of the specified member’s current and next tier details with the following output fields.
- currentTier: Returns the name of the tier.
- previousTier: Returns the previous (last) tier that was assigned to the member.
- tierAchieveDate: Returns the current tier achievement date in in yyyy-MM-dd'T'HH:mm:ssZ format.
- tierExpirationDate: Returns the tier expiration date in yyyy-MM-dd'T'HH:mm:ssZ format.
- nextTier: Displays the name of the next tier.
- pointsToNextTier: Displays the number of points required to achieve the next tier.
- purchaseRatio: Displays the purchase ratio which will be applied to the member (from this tier) while earning purchase points.
- currentTierPurchaseRatio: Displays the purchase ratio which will be applied to the members of this tier while earning purchase points.
- spendAmountToNextTier: Displays the amount the member needs to spend to achieve the next tier.
- errorCode: Displays only when the API request fails and denotes the type of error.
- errorMessage: Displays the reason why the API request failed.
Sample Positive Response
| Status Code | Response |
| 200 | |
Sample Error Response
| Status Code | Response |
| 100001 | |
- Add the following code to enable the Display Product Points API. where you want to display product points. The response API returns the earnPointJsonObj object, which the client can use wherever required.
<iscomment>annexCloud : PDP Earn Point</iscomment> <isscript> var productDetailArr={ "0":{
"id":product.id, "quantity":"1", "unitPrice":price.decimalPrice, "autoDelivery":'No' } }; var
userUniqueId=''
//session.getCustomer().getProfile().getEmail(); var
productDetails=JSON.stringify(productDetailArr);varearnPointPdpObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/earnPointPdpAPI'); var
earnPointPdpObjResponse = earnPointPdpObj.earnPointPdp(userUniqueId,productDetails); var
earnPointJsonObj = JSON.parse(earnPointPdpObjResponse); //This contains parsed json response.
</isscript> You will earn ${earnPointJsonObj.data[0].unitPrice} PointsResponse
he response returns the product points. If the userID is passed then the API checks the tier purchase ratio and segment and campaign rules.
Output Fields:
- userId: Displays the unique customer ID.
- appliedPoints: Displays the number of points the member applies (for redeem) on the cart page.
- shippingAmount: Displays the amount applied for shipping the order.
- discountAmount: Displays the discount amount.
- lifetimePoints: Displays the lifetime points of the member.
- usedPoints: Displays the used points of the member.
- availablePoints: Displays the available points the member has.
- holdPoints: Displays the number of points on hold from the member.
- cartPoints: Displays the number of points the member earns after purchasing the products which are in the cart.
- availablePointsAfterOrder: Displays the number of available points the member has after placing the order.
- holdPointsAfterOrder: Displays the number of points on hold after placing the order.
- creditsToCurrencyRatio: Displays the credits to currency ratio set at the site admin level.
- creditsToCurrencyValue: Displays the converted value of credits to currency according to the ratio.
- creditsToCurrencyValueAfterOrder: Displays the credits to currency value of total available points after the order is placed.
- creditsToCurrencyValueCartPoints: Displays the credits to currency value of the current cart if the order is placed.
- productDetails: Returns an array of the product details which contains the following parameters.
- id: Displays the unique product ID.
- productName: Returns the name of the product.
- categoryId: Returns the category ID of the product.
- categoryName: Returns the category name of the product.
- quantity: Displays the quantity of the product.
- unitPrice: Displays the unit price of the product.
- points: Displays the number of points the member earns after purchasing a specific product.
- errorCode: Displays only when the API request fails and denotes the type of error.
- errorMessage: Displays the reason why the API request failed.
Sample Positive Response
| Status Code | Response |
| 200 | |
Sample Error Response
| Status Code | Response |
| 10006 | |
- Add the following code to enable the Display Earn Points on Cart Page API The response of this API will be returned in the cartJsonObj object, which the client can use wherever required.
annexCloud : Cart Point API var productDetailArr={ "0":{ "id":product.id, "quantity":"1",
"unitPrice":price.decimalPrice, "autoDelivery":'No' } }; var
userUniqueId=''//session.getCustomer().getProfile().getEmail(); var
productDetails=JSON.stringify(productDetailArr);
varcartObj=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/cartCalculationAPI') ;
var cartObjObjResponse =cartObj.getCartCalculation(userUniqueId,productDetails); var cartJsonObj =
JSON.parse(cartObjObjResponse); //This contains parsed json response. You will earn
${cartJsonObj.data[0].unitPrice} Points annexCloud : EndResponse
The response returns an array of the specific member’s details like User ID, Site ID, User Email address, first name, last name, DB add date, available points, lifetime points & used points.
Output Fields:
- userId: Displays the unique customer ID.
- appliedPoints: Displays the number of points the member has applied (for redeem) on the cart page.
- shippingAmount: Displays the amount applied for shipping the order.
- discountAmount: Displays the discount amount.
- lifetimePoints: Displays the lifetime points of the member.
- usedPoints: Displays the used points of the member.
- availablePoints: Displays the available points of the member.
- holdPoints: Displays the number of points on hold from the member.
- cartPoints: Displays the number of points the member earns after purchasing the products which are in the cart.
- availablePointsAfterOrder: Displays the number of available points of the member after placing the order.
- holdPointsAfterOrder: Displays the number of hold points of the member after placing the order.
- creditsToCurrencyRatio: Displays the credits to currency ration set at the site admin.
- creditsToCurrencyValue: Displays the converted value of credits to currency according to the ratio.
- creditsToCurrencyValueAfterOrder: Displays the credits to currency value of total available points after the order is placed.
- creditsToCurrencyValueCartPoints: Displays the credits to currency value of the current cart if the order is placed.
- productDetails: Returns an array of the product details which contains the following parameters.
- id: Displays the unique product ID.
- productName: Returns the name of the product.
- categoryId: Returns the category ID of the product.
- categoryName: Returns the category name of the product.
- quantity: Displays the quantity of the product.
- unitPrice: Displays the unit price of the product.
- points: Displays the number of points the member earns after purchasing that product.
- errorCode: Displays only when the API request fails and denotes the type of error.
- errorMessage: Displays the reason why the API request failed.
Sample Positive Response
| Status Code | Response |
| 200 | |
Sample Error Response
| Status Code | Response |
| 100001 | |
- Add the following code to enable the Display Point User API. This API displays the specified member’s point information. The response of this API will be returned in the userPointTierObj object, which the client can use wherever required.
Response:
Output Fields:
- id: Displays the unique ID of the member.
- availablePoints: Displays the available points of the member.
- expiredPoints: Displays the expired points of the member.
- lifetimePoints: Displays the number of points the member has earned since the account was created.
- earnedPointsPeriod: Displays the earned points period (anniversaryYear, calenderYear,quarter,semester)
- spendPointsPeriod: Displays the spend points period (anniversaryYear, calenderYear,quarter,semester)
- earnedPoints: Displays the total earned points in the select “earnedPointsPeriod”
- spendPoints: Displays the total spend points in the selected “spendPointsPeriod”
- holdPoints: Displays the total number of points on hold.
- usedPointsOnReward: Displays the number of points used on the reward.
- pointsToExpire: Displays the number of points that are about to expire.
- pointsToNextTier: Displays the number of points needed to achieve the next tier.
- pointsToExpireDate: Displays the date (in yyyy-mm-dd format) on which the points will expire.
- spendToNextTier: Displays the number of dollars that the member needs to spend to achieve the next tier. (This field displays only if the tier functionality is based on spend.)
- creditsToCurrencyRatio: Displays the credits to currency ratio set at the site admin level.
- creditsToCurrencyValue: Displays the converted value of credits to currency according to the ratio.
- errorCode: Displays only when the API request fails and denotes the type of error.
- errorMessage: Displays the reason why the API request failed.
Sample Positive Response
| Status Code | Response |
| 200 | |
Sample Error Response
| Status Code | Response |
| 100001 | |
- Add the following code to enable the Credit or Debit Custom User Point API. This API allows you to credit or debit custom user points.
annexCloud : Custom user Point API var userEmail=session.getCustomer().getProfile().getEmail(); var
actionId="xxx" var activity="xxx"; var points="xxx"; var reason="Manual Points"; var
customUserScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/customPointAPI'); var
customUserResponse = customUserScriptObj.customUserPoint(userEmail, actionId,
activity,points,reason); var customUserObj = JSON.stringify(customUserResponse); //This contains
parsed json response. ${customUserObj}The meaning of the attributes included above is as follows:
- actionId: Insert the action ID provided by the Annex Cloud.
- activity: Pass the name of the action performed by the member. It can be credit or debit.
- points: Pass custom points.
Note: Action IDs are provided by Annex Cloud.
- Insert the following code at the end of Confirmation.isml file to enable setup for the Order API Script.
File path: app_storefront_base/cartridge/templates/default/checkout/confirmation/confirmation.isml.
- OR, you can override the confirmation page by adding the file in int_annexcloud_sfra_v3_cartridge.
File Path int_annexcloud_sfra_v3/cartridge/templates/default/checkout/confirmation/confirmation.isml
<iscomment> === Annex Cloud Addition START === </iscomment>
<isinclude template="util/modules_annexcloud"/>
<isOrderApisadebug="0"/>
<iscomment> === Annex Cloud END=== </iscomment>
- Add the following code to enable Full Order Ship.
<iscomment>annexCloud : Fullship Order</iscomment>
<isscript>
var OrderJSONObj = {};
OrderJSONObj.orderId='pass orderId';
OrderJSONObj.status='ship';
var orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI'); var
orderStatusResponse = orderScriptObj. acOrderUpdate(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);//This contains parsed json
response.
</isscript>- Add the following code to enable Full Return Orders.
<iscomment>annexCloud : Fullreturn Order</iscomment>
<isscript>
var OrderJSONObj = {}; OrderJSONObj.orderId='pass order
Id'; OrderJSONObj.status='return';
var orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI'); var
orderStatusResponse = orderScriptObj.acOrderUpdate(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);//This contains parsed json
response.
</isscript>- Add the following code to enable Full Cancel Orders.
<iscomment>annexCloud : Full cancel Order</iscomment>
<isscript>
var OrderJSONObj = {}; OrderJSONObj.orderId='pass order
Id'; OrderJSONObj.status='cancel';
var orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI'); var
orderStatusResponse = orderScriptObj.acOrderUpdate(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);//This contains parsed json
response.
</isscript>- Add the following code to enable Partial Cancel Orders.
<iscomment>annexCloud : partial cancel Orderstart</iscomment>
<isscript>
var excludeProductDataObj =[];
excludeProductDataObj[0]=
{
id: pass product Id, quantity: pass
quantity, unitPrice: pass unit Price
}
excludeProductDataObj[1]=
{
id: pass product Id, quantity: pass
quantity, unitPrice: pass unit Price
}
var OrderJSONObj = {}; OrderJSONObj.orderId='Pass
Order Id'; OrderJSONObj.status='cancel';
OrderJSONObj.orderDetail=excludeProductDataObj; var
orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI'); var
orderStatusResponse =
orderScriptObj.acOrderUpdate(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);
//This contains parsed json response.
</isscript>
<iscomment>annexCloud : partial cancel Order End</iscomment>- Add the following code to enable Partial Return Orders.
<iscomment>annexCloud : partial return Order start</iscomment>
<isscript>
var excludeProductDataObj =[];
excludeProductDataObj[0]=
{
id: pass product Id, quantity: pass quantity, unitPrice: pass unit Price
}
excludeProductDataObj[1]=
{
id: pass product Id, quantity: pass quantity, unitPrice: pass unit Price
}
var OrderJSONObj = {}; OrderJSONObj.orderId='Pass Order Id';
OrderJSONObj.status='return';
OrderJSONObj.orderDetail=excludeProductDataObj; var orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI');
var orderStatusResponse = orderScriptObj.
acOrderUpdate(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);
//This contains parsed json response.
</isscript>
<iscomment>annexCloud : partialreturn Order End</iscomment>- Add the following code to enable Partial Ship Orders.
<iscomment>annexCloud : partial ship Order start</iscomment>
<isscript>
var excludeProductDataObj =[];
excludeProductDataObj[0]=
{
id: pass product Id,
quantity: pass quantity,
unitPrice: pass unit Price
}
excludeProductDataObj[1]=
{
id:pass product Id,
quantity: pass quantity,
unitPrice: pass unit Price
}
var OrderJSONObj = {}; OrderJSONObj.orderId='Pass Order Id'; OrderJSONObj.status='ship';
OrderJSONObj.orderDetail=excludeProductDataObj; var orderScriptObj
=require('int_annexcloud_sfra_v3/cartridge/scripts/loyaltyprogram/orderAPI'); var
orderStatusResponse = orderScriptObj.acOrderUpdate
(OrderJSONObj);
var orderStatusJsonObj = JSON.parse(orderStatusResponse);
//This contains parsed json response.
</isscript>
<iscomment>annexCloud : partial ship Order End</iscomment>Using Annex Cloud as a Payment Method
- Insert the following code into the COBilling.js file.
File path: storefront_controllers/cartridge/controllers/COBilling.js
var paymentMethods = 2;
if (app.getForm('billing').object.paymentMethods.selectedPaymentMethodID.value.equals('AN
NEXCLOUD')) {
paymentMethods = 1;
}
if (customer.profile) {
var acPointsToUse = app.getForm('annexcloud').object.acPointsToUse.value;
if (!typeof acPointsToUse == "number" || acPointsToUse < 0) {
acPointsToUse = 0;
}
var acPoints = require('int_annexcloud_v3/cartridge/scripts/helper/payment').calculatePaymentPoints(c
ustomer.profile.email, acPointsToUse, paymentMethods);
Transaction.wrap(function () { cart.object.custom.acActualPoints=
JSON.stringify(acPoints);
});
if (acPoints.error.isError){
return false;
}
- Insert the following code into the same COBilling.js file.
cart.removePaymentInstruments(cart.getPaymentInstruments('ANNEXCLOUD'));
...
cart.removePaymentInstruments(cart.getPaymentInstruments('ANNEXCLOUD'));
...
cart.removePaymentInstruments(cart.getPaymentInstruments('ANNEXCLOUD'));
} else if
(app.getForm('billing').object.paymentMethods.selectedPaymentMethodID.value.equals('AN
NEXCLOUD')) {
if (!customer.profile) {// if customer is not logged in
return false;
}
if (acPoints && (Number(acPoints.neededPoints) > Number(acPoints.availablePoints))) { //
customer does not have enought points to pay only with annex cloud points
return false;
}
app.getForm('billing').object.paymentMethods.creditCard.clearFormElement();
app.getForm('billing').object.paymentMethods.bml.clearFormElement();
cart.removePaymentInstruments(cart.getPaymentInstruments(PaymentInstrument.METHOD_
CRED IT_CARD));
cart.removePaymentInstruments(cart.getPaymentInstruments(PaymentInstrument.METHOD_
BML)
);
cart.removePaymentInstruments(cart.getPaymentInstruments('PayPal'));
- Update code in COPlaceOrder.js file.
File path: storefront_controllers/cartridge/controllers/COSummary.js.
var calculatePaymentTransactionTotal;
if (cart.object.custom.acActualPoints) { calculatePaymentTransactionTotal =
require('int_annexcloud_v3/cartridge/scripts/helper/cartModel').calculatePaymentTransa ctionTotal(cart);
} else {
calculatePaymentTransactionTotal = cart.calculatePaymentTransactionTotal()
}
Transaction.wrap(function () {
if (!calculatePaymentTransactionTotal) {
- Insert the following code into BASIC_CREDIT.js file.
File path: storefront_controllers/cartridge/scripts/payment/processor/BASIC_CREDIT.js.
var Money = require('dw/value/Money');
...
if(cart.object.custom &&cart.object.custom.acActualPoints) {
var amountPaidWithAnnexCloud = JSON.parse(cart.object.custom.acActualPoints).paidFor;
if (amountPaidWithAnnexCloud > 0) {
var moneyPaidWithAnnexCloud = new Money(amountPaidWithAnnexCloud,
cart.getCurrencyCode());
cart.removeExistingPaymentInstruments('ANNEXCLOUD');
cart.createPaymentInstrument('ANNEXCLOUD', moneyPaidWithAnnexCloud);
}
var amountPaidWithCC = JSON.parse(cart.object.custom.acActualPoints).unpaid;
var moneyPaidWithCC = new Money(amountPaidWithCC, cart.getCurrencyCode());
} else {
var moneyPaidWithCC = cart.getNonGiftCertificateAmount();
}
cart.removeExistingPaymentInstruments(dw.order.PaymentInstrument.METHOD_CREDIT_CARD); var
paymentInstrument =
cart.createPaymentInstrument(dw.order.PaymentInstrument.METHOD_CREDIT_CARD,
moneyPaidWithCC);
- Insert the following code into paymentmethods.isml file.
File path: torefront_core/cartridge/templates/default/checkout/billing/paymentmethods.isml.
<isif condition="${pdict.CurrentCustomer.authenticated}">
<isset name="acPoints"
value="${require('int_annexcloud_v3/cartridge/scripts/helper/payment').calculatePaymen
tPoints(pdict.CurrentCustomer.profile.email)}" scope="page" />
<iselse>
<isset name="acPoints" value="{}" scope="page" />
< /isif>
- Insert the following code into the same paymentmethods.isml file.
File path: torefront_core/cartridge/templates/default/checkout/billing/paymentmethods.isml
<isinclude template="checkout/pointstouse"/>

- Insert the following code into the same paymentmethods.isml file.
File path: torefront_core/cartridge/templates/default/checkout/billing/paymentmethods.isml
<div class="payment-method <isif condition="${!empty(pdict.selectedPaymentID)
&& pdict.selectedPaymentID=='ANNEXCLOUD'}">payment-method-expanded</isif>"
data-method="ANNEXCLOUD">
<isif condition="${pdict.CurrentCustomer.authenticated}">
<isif condition="${Number(acPoints.neededPoints) >
Number(acPoints.availablePoints)}">
You don't have enough points to pay only with Annex
Cloud points
<iselse>
<p>Use all your points for payment.</p>
<p>Your available points:
${acPoints.availablePoints}</p>
<p>Your Currency Balance: ${currencySymbol +
(acPoints.availablePoints / acPoints.ratio).toFixed(2)}</p>
</isif>
<iselse>
You have to be logged in
</isif>
</div>
Configuration
- To show the modules on the website, follow the below steps: Merchant Tools > Site Preferences > Custom Preferences > Annex Cloud Configuration. After clicking on Annex Cloud Main Configuration, complete the following fields.
- Site ID: Enter the site ID provided by Annex Cloud.
-
Activate Loyalty Program: To activate the Loyalty Program, check the Activate Loyalty Program
checkbox. -
Points ratio: Setup how many points are needed for specific currency in JSON format (For
example "USD":5 means 5 annex points represents one dollar).
- After activating the Loyalty Program, the following extra fields need to be set up: Merchant Tools > Site Preferences > Custom Preferences > Loyalty Program Config.
- Access Token: Enter the token number provided by Annex Cloud.
- Dashboard Page ID: Enter the Page ID which is provided by Annex Cloud.
-
Action ID: Enter the Action ID which is created when the member creates an account.
With the SFRA version, you do not need to make any changes, but to prevent conflict there is a
list of main parts updated with cartridge.
- Payment processor basic_credit.js was modified to support Annex Cloud Loyalty points
for partly pay
(int_annexcloud_sfra_v3\cartridge\scripts\hooks\payment\processor\basic_credit.js). - Frontend javascript file annexcloudcheckout.js is used to handle checkout flow
connected to Annex Cloud Payment Method
(int_annexcloud_sfra_v3\cartridge\static\default\js\annexcloudcheckout.js) - Template profileCard.isml was updated to display additional links in profile dashboard
menu and call Annex Cloud service to register customer on Annex Cloud side
(int_annexcloud_sfra_v3\cartridge\templates\default\account\profileCard.isml) - Template homepage.isml was updated to display Annex Cloud modules
(int_annexcloud_sfra_v3\cartridge\templates\default\home\homePage.isml) - Template creditCardContent.isml was updated to display additional form field for Annex
Cloud Loyalty points
(int_annexcloud_sfra_v3\cartridge\templates\default\checkout\billing\paymentOption
s\creditCar dContent.isml) - Template paymentOptionsContent.isml was updated to display Annex Cloud payment
method content on billing page
(int_annexcloud_sfra_v3\cartridge\templates\default\checkout\billing\paymentOption
s\payment OptionsContent.isml) - Template paymentOptionsSummary.isml was updated to display Annex Cloud payment
method content on summary page
(int_annexcloud_sfra_v3\cartridge\templates\default\checkout\billing\paymentOption
s\payment OptionsSummary.isml) - Template paymentOptionsTabs.isml was updated to display Annex Cloud payment
method option in the list of payment methods on billing page (int_annexcloud_sfra_v3\cartridge\templates\default\checkout\billing\paymentOption
s\payment OptionsTabs.isml) - Template confirmation.isml was updated to track created orders by Annex Cloud
(int_annexcloud_sfra_v3\cartridge\templates\default\checkout\confirmation\confirma
tion.isml) - Template productDetails.isml was updated to use Visual Commerce section on product
details page
(int_annexcloud_sfra_v3\cartridge\templates\default\product\productDetails.isml)
Custom Code
// same as the setup
External Interfaces
No exposed external interfaces for this cartridge.
Firewall Requirements
Outbound requests are made through port 80 and 443.
Operations & Maintenance
Data Storage
No data storage is applicable.
Availability
The Annex Cloud widgets, being asynchronous, gracefully degrade and don’t block loading of any page element.
Support
Please contact Annex Cloud at info@ http://Annexcloud.com or 866-802-8806.
User Guide
Roles & Responsibilites
There are no recurring tasks that need to be fulfilled to get the full potential of Annex Cloud. As long as the confirmation details are correct in your Site Preferences, that's all you need to do.
Business Manager
Within the Business Manager under Custom Site Preferences, there will be modules of Social Annex. The merchant must enter information for the following attributes:
- Site ID: Provided by Annex Cloud.
- Share & Save checkbox: Select this checkbox to enable Share and Save on site.
- Social Q & A checkbox: Select this checkbox to enable Social Q & A on site.
- Ratings & Reviews checkbox: Select this checkbox to enable the Ratings & Reviews module.
-
Activate Loyalty Program checkbox: Select this Activate Loyalty Program checkbox to
enable the Loyalty Program on site.
After selecting the checkbox set the following fields in the Loyalty Program Configure
section. - Access Token: Enter the Loyalty Access Token provided by Annex Cloud.
- Dashboard Page ID: Enter the loyalty dashboard Page ID provided by Annex Cloud.
-
Activate Visual Commerce: Select this checkbox to enable the Visual
Commerce module.
After selecting the checkbox, set the following extra fields in Visual Commerce Configure.- Home
- Product
- Category
- Gallery Page ID, which Annex Cloud provides you.
- Category page type as Category.
-
Refer a Friend Checkbox: Check the Refer a Friend checkbox to enable the module on an
e-commerce website.