Create a service charge on an order

Creates a service charge to an order.

Log in to see full request history
Path Params
string
required

Merchant identifier.

string
required

Order identifier.

Body Params
string

Unique identifier.

item
object

A reference to the inventory item that was used to create this line item. Note that since this a reference the item can be changed and deleted any time such that it no longer matches this line item.

string

Hex code representation of the color assigned to item in the form of #fff, #ffffff, or #ffffffff. Note that item color can be changed and deleted any time such that it no longer matches this line item

string

Line item name.

string

Alternate name of the line item.

int64

Price of the item, typically in cents of merchant currency. When unit quantity is not null then this is the price for a single unit and is not the complete price.

int64

Price of item after adding all modifications. This is used only for reporting.

int64

Price of item after adding all modifications and subtracting all line item and order level discounts. This is used only for reporting.

integer

This is applicable only if the item is priced by quantity of a unit. The item must have a priceType of PER_UNIT. The value is a fixed-point integer with scaling factor of 1000 (e.g. if charging per ounce, the value should be set to 2500 for 2.5 ounces). To compute the complete price perform the following calculation: PRICE * (UNIT QTY / 1000). If the item doesn’t have a priceType of PER_UNIT, then unitQty is ignored.

string

Unit name (e.g. oz, lb, etc) if priced by unit, otherwise null.

string
string
boolean
Defaults to false

True if this line item has been printed out on an order printer at least once already.

exchangedLineItem
object
string
string
int64
int64
discounts
array of objects

List of discounts applied to the line item. Each line item on an order may have zero or more percentage or amount discounts. Line item discounts are separate from order-level discounts (which are applied to the order subtotal).

discounts
orderLevelDiscounts
array of objects

List of order level discounts attributed to this line item. Amounts are rounded to the nearest penny. This is for reporting purposes only. These rounding approximates are not used when calculating the transaction.

orderLevelDiscounts
integer

Unnamed fixed discount amount in cents. Or, in reporting, this may be the calculated sum of all the line item discounts.

int64

The calculated sum of order level discounts attributed, approximately to the nearest cent, to this the line item. This is only used in reporting.

boolean
Defaults to false
modifications
array of objects

List of references to modifications applied to this line item.

modifications
tags
array of objects

List of tags associated with this line item.

tags
boolean
Defaults to false

True if this line item has been refunded

refund
object

direct item refund

boolean
Defaults to false

True if this item should be counted as revenue, for example gift cards and donations would not.

taxRates
array of objects

Tax rates that apply to this line item

taxRates
payments
array of objects

Payments that apply to this line item

payments
int64

Revenue collected for this. This field is only used in reporting.

number

Quantity sold for this line item. This field is only used in reporting

printGroup
object

Optional reference to the print group that this line item belongs to.

boolean
Defaults to false

True if this line item has been marked as hidden on User Interface like Orders page and receipts

integer

For percentage based order fee line item, percent to charge times 10000, e.g. 12.5% will be 125000

orderFee
object

A reference to the inventory order fee that was used to create this line item. Note that since this a reference the order fee can be changed and deleted any time such that it no longer matches this line item.

boolean

True if this line item is an order fee line item

boolean

True if this line item is an platform order fee line item

string

Used to define type of order fee line item, e.g. gratuity.

Response

Language
Credentials
Click Try It! to start a request and see the response here! Or choose an example:
application/json