Represents customer information during checkout. Provides access to customer details that are relevant during the checkout process including personal information, roles, and organizational details.

Hierarchy

  • CheckoutCustomer

Properties

DepartmentName: string

Department name of the customer. Represents the organizational department the customer belongs to.

Example

if (CheckoutItem.Customer.DepartmentName == "Procurement") {
console("Procurement department checkout - apply bulk pricing");
}
Email: string

Customer's email address.

Example

console("Customer email: " + CheckoutItem.Customer.Email);
if (/\.edu$/i.test(CheckoutItem.Customer.Email)) {
console("Educational customer - apply academic pricing");
}
FirstName: string

Customer's first name.

Example

console("Customer first name: " + CheckoutItem.Customer.FirstName);
LastName: string

Customer's last name.

Example

console("Customer last name: " + CheckoutItem.Customer.LastName);
Roles: string[]

Array of customer role system names. Contains all roles assigned to the customer for role-based pricing logic.

Example

console("Customer roles: " + CheckoutItem.Customer.Roles.join(", "));
if (HelperMethods.Contains(CheckoutItem.Customer.Roles, "VIP")) {
console("VIP customer checkout");
}

Generated using TypeDoc