Application Load
ICartSummary
The physical TypeScript declaration from the Nuxt starter, with linked types and field comments.
ICartSummaryCurrent cart state, totals, address and payment choices.
interfaces/orionplace/cart/ICartData.tsexport interface ICartSummary {
// Cart ID.
id: number;
// `ECartState.STATE_CART` — product selection and quantity changes.
// `ECartState.STATE_CHECKOUT` — checkout with delivery groups, payment and
// shipping. This value determines the shape of `page_data.cart_data`.
state: ECartState;
// Amounts by currency and the delivery estimate flag.
prices: ICartPrices;
// Total physical and digital quantity counter.
c_cart_positions: number;
// Cart-item counter recalculated for the current state.
c_cart_items: number;
// Digital quantity counter.
c_digital_pos: number;
// Physical quantity counter.
c_physical_pos: number;
// Delivery-group count.
c_dlf: number;
// Saved addresses of the signed-in customer. Each address has an ID for
// `cart_customer_address_set`. An empty list means no addresses are saved;
// null is returned for guests.
address_list: IUserAddress[] | null;
// Payment methods currently eligible for this cart, keyed by method ID. Use
// their `id`, `locale` names and `logo` for the choices. A method limited by
// country is offered by the customer’s phone country, not by the cart
// address. An empty dictionary contains no available method.
payment_methods: Record<string, IPaymentMethod>;
// Selected payment-method ID; match it to `payment_methods`. Null means no
// method is selected. Checkout cart validation clears a choice that is no
// longer eligible; the customer must choose again. A return from checkout to
// `ECartState.STATE_CART` also clears it.
selected_payment: number | null;
// Current cart delivery address: copied address fields without the saved
// address ID, or null when unset. Compare with `address_list` to display a
// saved selection. The copy remains when its saved entry is edited or
// deleted; choosing an address replaces it.
cart_address: ICartAddress | null;
// Attached promotion definition, or null.
attached_promo: IPromoDefinition | null;
// Attached issued code, or null.
promocode: string | null;
/** Absent on backends without the whole-cart promo rules. */
promo_notice?: ICartPromoNotice | null;
// Saved order comment, up to 1024 characters. Empty text means no comment.
// Save it as `cart_commentary` through `cart_customer_commentary_set`.
comment: string;
// `client` contains the account holder’s full_name and phone; `receiver`
// contains the order recipient’s full_name and phone. Each missing recipient
// value falls back to the corresponding account value.
// `cart_customer_reciever_clean` restores those defaults for the cart. Empty
// for guests.
contact: {
// Optional value of client; it may be omitted.
client?: ICartContact;
// Optional value of receiver; it may be omitted.
receiver?: ICartContact;
};
// `true` signals a change in available quantities or items that cannot be
// shipped. Use the returned cart data. The notification clears after reading;
// a later `false` does not restore previous quantities.
cart_stock_was_modifed: boolean;
}