SbPublicApiCartLinePricing
snowbee.ecom.cart.SbPublicApiCartLinePricing
How a cart line is priced right now, resolved by SnowBee with the same rules as the cash register
basicGrossUnitPricerequiredThe sku's ordinary gross unit price before any campaign
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,2})?$
Example"299"basicNetUnitPricerequiredThe sku's ordinary net unit price before any campaign, up to 4 decimals
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,4})?$
Example"239.2"campaignoptionalShow child fields
appliesrequiredTrue when this campaign changed the line charge
ExampletruecampaignTyperequiredNORMAL sets the unit price; THREE_FOR_TWO discounts the basket
Allowed values"NORMAL""THREE_FOR_TWO"Example"THREE_FOR_TWO"coderequiredCampaign code, the value to send as campaignCode when the order is created
Example"SUMMER24"idrequirednamerequirednetUnitPriceoptionalThe campaign's own net unit price, up to 4 decimals. For a 3 for 2 the blended net unit price after the offer, or null when the offer did not bite.
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,4})?$
Example"191.2"
grossLineAmountrequiredGross amount for the whole line quantity
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,2})?$
Example"598"grossUnitPricerequiredGross unit price charged
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,2})?$
Example"299"netLineAmountrequiredNet amount for the whole line quantity
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,2})?$
Example"478.4"netUnitPricerequiredNet unit price charged, up to 4 decimals. Send this as netUnitPrice when the order is created.
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,4})?$
Example"239.2"vatRaterequiredVAT rate in percent
- Format: BigDecimal
- Pattern: ^-?\d+(\.\d{1,2})?$
Example"25"
View raw schema
{
"type": "object",
"description": "How a cart line is priced right now, resolved by SnowBee with the same rules as the cash register",
"properties": {
"basicGrossUnitPrice": {
"type": "string",
"format": "BigDecimal",
"description": "The sku's ordinary gross unit price before any campaign",
"example": "299",
"pattern": "^-?\\d+(\\.\\d{1,2})?$",
"title": "BigDecimalAsString"
},
"basicNetUnitPrice": {
"type": "string",
"format": "BigDecimal",
"description": "The sku's ordinary net unit price before any campaign, up to 4 decimals",
"example": "239.2",
"pattern": "^-?\\d+(\\.\\d{1,4})?$",
"title": "BigDecimalAsString"
},
"campaign": {
"oneOf": [
{
"type": "null"
},
{
"$ref": "#/components/schemas/snowbee.ecom.cart.SbPublicApiCartLineCampaign"
}
]
},
"grossLineAmount": {
"type": "string",
"format": "BigDecimal",
"description": "Gross amount for the whole line quantity",
"example": "598",
"pattern": "^-?\\d+(\\.\\d{1,2})?$",
"title": "BigDecimalAsString"
},
"grossUnitPrice": {
"type": "string",
"format": "BigDecimal",
"description": "Gross unit price charged",
"example": "299",
"pattern": "^-?\\d+(\\.\\d{1,2})?$",
"title": "BigDecimalAsString"
},
"netLineAmount": {
"type": "string",
"format": "BigDecimal",
"description": "Net amount for the whole line quantity",
"example": "478.4",
"pattern": "^-?\\d+(\\.\\d{1,2})?$",
"title": "BigDecimalAsString"
},
"netUnitPrice": {
"type": "string",
"format": "BigDecimal",
"description": "Net unit price charged, up to 4 decimals. Send this as netUnitPrice when the order is created.",
"example": "239.2",
"pattern": "^-?\\d+(\\.\\d{1,4})?$",
"title": "BigDecimalAsString"
},
"vatRate": {
"type": "string",
"format": "BigDecimal",
"description": "VAT rate in percent",
"example": "25",
"pattern": "^-?\\d+(\\.\\d{1,2})?$",
"title": "BigDecimalAsString"
}
},
"required": [
"basicGrossUnitPrice",
"basicNetUnitPrice",
"grossLineAmount",
"grossUnitPrice",
"netLineAmount",
"netUnitPrice",
"vatRate"
],
"title": "SbPublicApiCartLinePricing"
}