Skip to main content

Interface: MarketCostPriceItem

Represents market-specific pricing information for a product code.

The MarketCostPriceItem interface provides context about how a product is priced in specific markets or pricing scenarios, including cost prices, recommended retail prices, and reference information. This contextual pricing helps both internal users and customers understand value propositions and margin structures.

Market cost price information is typically used for comparison with actual selling prices, margin calculations, and to show value messaging like "Compared to RRP". These prices can refer to whole products or to individual components, materials, or aspects of a product's construction.

Example

// Adding market pricing context to a product price
const productPrice = {
currency: "USD",
price: 89.99,
marketCostPrices: [
{
priceListName: "US Retail",
value: 129.99, // Suggested retail price
code: "CHAIR-BASE",
quantity: 1
}
]
};

// Displaying a value comparison
if (productPrice.marketCostPrices?.[0]?.value) {
const savings = productPrice.marketCostPrices[0].value - productPrice.price;
console.log(`Save ${savings} compared to recommended price!`);
}

Properties

code?

optional code: string

Product or component code this reference price applies to.

Identifies exactly which product, component, or material this reference price relates to. A complete product may reference multiple different price codes representing different aspects of its construction (base, fabric, hardware, etc.).


ignoreProductQuantity?

optional ignoreProductQuantity: boolean

When true, ignores the product quantity when applying this price.

This allows the price to be applied as a fixed reference regardless of how many units are being ordered, which is useful for establishing a consistent price comparison.


priceListName?

optional priceListName: string

Name of the price list this reference comes from.

Identifies the source of the reference price, which might be a standard retail list, manufacturer's suggested prices, or another named pricing scenario.


quantity?

optional quantity: number

Minimum quantity threshold for this price point.

This value establishes the lower bound of the quantity range where this price applies. When multiple entries for the same code exist with different quantities, they form a series of quantity breaks with progressive pricing.


value?

optional value: string | number

Reference price value for comparison.

This is the actual price amount (often an RRP or MSRP) used for comparison with the actual selling price. This creates context around the value proposition of the current price.