Object Index / Definition

You are viewing an old version of the API
Order​Line​Item

Represents a line item in an order

Each line item describes a different product to purchase, with its own quantity and price details.

Properties

Name Description
quantity
string

Required

The quantity purchased, formatted as a decimal number. For example: "3".

Line items with a quantity_unit can have non-integer quantities. For example: "1.70000".

Max Length 12 Min Length 1
applied_discounts
Order​Line​Item​Applied​Discount [ ]

Beta

The list of references to discounts applied to this line item. Each OrderLineItemAppliedDiscount has a discount_uid that references the uid of a top-level OrderLineItemDiscounts applied to the line item. On reads, the amount applied is populated.

An OrderLineItemAppliedDiscount will be automatically created on every line item for all ORDER scoped discounts that are added to the order. OrderLineItemAppliedDiscount records for LINE_ITEM scoped discounts must be added in requests for the discount to apply to any line items.

To change the amount of a discount, modify the referenced top-level discount.

applied_taxes
Order​Line​Item​Applied​Tax [ ]

Beta

The list of references to taxes applied to this line item. Each OrderLineItemAppliedTax has a tax_uid that references the uid of a top-level OrderLineItemTax applied to the line item. On reads, the amount applied is populated.

An OrderLineItemAppliedTax will be automatically created on every line item for all ORDER scoped taxes added to the order. OrderLineItemAppliedTax records for LINE_ITEM scoped taxes must be added in requests for the tax to apply to any line items.

To change the amount of a tax, modify the referenced top-level tax.

base_price_money
Money

The base price for a single unit of the line item.

catalog_object_id
string

The CatalogItemVariation id applied to this line item.

Max Length 192
gross_sales_money
Money

Read only The amount of money made in gross sales for this line item. Calculated as the sum of the variation's total price and each modifier's total price.

metadata
object

Beta

Application-defined data attached to this line item. Metadata fields are intended to store descriptive references or associations with an entity in another system or store brief information about the object. Square does not process this field; it only stores and returns it in relevant API calls. Do not use metadata to store any sensitive information (personally identifiable information, card details, etc.).

Keys written by applications must be 60 characters or less and must be in the character set [a-zA-Z0-9_-]. Entries may also include metadata generated by Square. These keys are prefixed with a namespace, separated from the key with a ':' character.

Values have a max length of 255 characters.

An application may have up to 10 entries per metadata field.

Entries written by applications are private and can only be read or modified by the same application.

See Metadata for more information.

modifiers
Order​Line​Item​Modifier [ ]

The CatalogModifiers applied to this line item.

name
string

The name of the line item.

Max Length 500
note
string

The note of the line item.

Max Length 500
quantity_unit
Order​Quantity​Unit

The unit and precision that this line item's quantity is measured in.

total_discount_money
Money

Read only The total discount amount of money to collect for the line item.

total_money
Money

Read only The total amount of money to collect for this line item.

total_tax_money
Money

Read only The total tax amount of money to collect for the line item.

uid
string

Beta

Unique ID that identifies the line item only within this order.

Max Length 60
variation_name
string

The name of the variation applied to this line item.

Max Length 255
variation_total_price_money
Money

Read only The total price of all item variations sold in this line item. Calculated as base_price_money multiplied by quantity. Does not include modifiers.

discounts
Order​Line​Item​Discount [ ]

Deprecated

A list of discounts applied to this line item. On read or retrieve, this list includes both item-level discounts and any order-level discounts apportioned to this item. When creating an Order, set your item-level discounts in this list.

This field has been deprecated in favour of applied_discounts. Usage of both this field and applied_discounts when creating an order will result in an error. Usage of this field when sending requests to the UpdateOrder endpoint will result in an error.

taxes
Order​Line​Item​Tax [ ]

Deprecated

A list of taxes applied to this line item. On read or retrieve, this list includes both item-level taxes and any order-level taxes apportioned to this item. When creating an Order, set your item-level taxes in this list.

This field has been deprecated in favour of applied_taxes. Usage of both this field and applied_taxes when creating an order will result in an error. Usage of this field when sending requests to the UpdateOrder endpoint will result in an error.

Share Feedback

Thanks for visiting the Square API documentation. What's on your mind?