Square: Orders schemas (part 3)
38 Square schemas with complete fields and constraints.
← Orders operations · All schemas
Pay Order — response body — order line items The line items included in the order item pricing blocklists blocked discounts, blocked service charges, blocked taxes blocked taxes array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A tax to block from applying to a line item. The tax must be identified by either `tax_uid` or `tax_catalog_object_id`, but not both. |
tax_catalog_object_id | JSON | Optional | |
tax_catalog_object_id (anyOf 1) | string | Alternative | The `catalog_object_id` of the tax that should be blocked. Use this field to block catalog taxes. For ad hoc taxes, use the `tax_uid` field. Maximum length: 192 |
tax_catalog_object_id (anyOf 2) | null | Alternative | |
tax_uid | JSON | Optional | |
tax_uid (anyOf 1) | string | Alternative | The `uid` of the tax that should be blocked. Use this field to block ad hoc taxes. For catalog, taxes use the `tax_catalog_object_id` field. Maximum length: 60 |
tax_uid (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID of the `BlockedTax` within the order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Pay Order — response body — order line items The line items included in the order item quantity unit catalog object id, catalog version, measurement unit, precision
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Contains the measurement unit for a quantity and a precision that specifies the number of digits after the decimal point for decimal quantities. |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing the [CatalogMeasurementUnit](entity:CatalogMeasurementUnit). This field is set when this is a catalog-backed measurement unit. |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this measurement unit references. This field is set when this is a catalog-backed measurement unit. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
measurement_unit | JSON | Optional | |
measurement_unit (anyOf 1) | Model | Alternative | Expand Batch Change Inventory — response body — changes item measurement unit measurement unit area unit, custom unit, generic unit, length unit, time unit, type, volume unit, weight unit A [MeasurementUnit](entity:MeasurementUnit) that represents the unit of measure for the quantity. |
measurement_unit (anyOf 2) | null | Alternative | |
precision | JSON | Optional | |
precision (anyOf 1) | JSON | Alternative | |
precision (anyOf 1) (anyOf 1) | integer | Alternative | For non-integer quantities, represents the number of digits after the decimal point that are recorded for this quantity. For example, a precision of 1 allows quantities such as `"1.0"` and `"1.1"`, but not `"1.01"`. Min: 0. Max: 5. |
precision (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
precision (anyOf 2) | null | Alternative |
Pay Order — response body — order net amounts
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A collection of various money amounts. |
discount_money | JSON | Optional | |
discount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The money associated with discounts. |
discount_money (anyOf 2) | null | Alternative | |
service_charge_money | JSON | Optional | |
service_charge_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The money associated with service charges. |
service_charge_money (anyOf 2) | null | Alternative | |
tax_money | JSON | Optional | |
tax_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The money associated with taxes. |
tax_money (anyOf 2) | null | Alternative | |
tip_money | JSON | Optional | |
tip_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The money associated with tips. |
tip_money (anyOf 2) | null | Alternative | |
total_money | JSON | Optional | |
total_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The total money. |
total_money (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order pricing options auto apply discounts, auto apply taxes
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Pricing options for an order. The options affect how the order's price is calculated. They can be used, for example, to apply automatic price adjustments that are based on preconfigured [pricing rules](entity:CatalogPricingRule). |
auto_apply_discounts | JSON | Optional | |
auto_apply_discounts (anyOf 1) | boolean | Alternative | The option to determine whether pricing rule-based discounts are automatically applied to an order. |
auto_apply_discounts (anyOf 2) | null | Alternative | |
auto_apply_taxes | JSON | Optional | |
auto_apply_taxes (anyOf 1) | boolean | Alternative | The option to determine whether rule-based taxes are automatically applied to an order when the criteria of the corresponding rules are met. |
auto_apply_taxes (anyOf 2) | null | Alternative |
Pay Order — response body — order refunds item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a refund processed for a Square transaction. |
additional_recipients | JSON | Optional | |
additional_recipients (anyOf 1) | array | Alternative | Additional recipients (other than the merchant) receiving a portion of this refund. For example, fees assessed on a refund of a purchase by a third party integration. |
additional_recipients (anyOf 1)[] | Model | Each item | Expand Create Checkout — response body — checkout additional recipients array item |
additional_recipients (anyOf 2) | null | Alternative | |
amount_money | Model | Required within parent | Expand Pay Order — response body — order total money The amount of money refunded to the buyer. |
created_at | string | Optional | The timestamp for when the refund was created, in RFC 3339 format. Maximum length: 32 Read only: true |
id | string | Required within parent | The refund's unique ID. Maximum length: 255 |
location_id | string | Required within parent | The ID of the refund's associated location. Maximum length: 50 |
processing_fee_money | JSON | Optional | |
processing_fee_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of Square processing fee money refunded to the *merchant*. |
processing_fee_money (anyOf 2) | null | Alternative | |
reason | string | Required within parent | The reason for the refund being issued. Maximum length: 192 |
status | string | Required within parent | Indicates a refund's current status. The current status of the refund (`PENDING`, `APPROVED`, `REJECTED`, or `FAILED`). See [RefundStatus](#type-refundstatus) for possible values Known values: PENDING, APPROVED, REJECTED, FAILED |
tender_id | JSON | Optional | |
tender_id (anyOf 1) | string | Alternative | The ID of the refunded tender. Maximum length: 192 |
tender_id (anyOf 2) | null | Alternative | |
transaction_id | JSON | Optional | |
transaction_id (anyOf 1) | string | Alternative | The ID of the transaction that the refunded tender is part of. Maximum length: 192 |
transaction_id (anyOf 2) | null | Alternative |
Referenced models: Create Checkout — response body — checkout additional recipients array item, Pay Order — response body — order total money
Pay Order — response body — order returns item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | The set of line items, service charges, taxes, discounts, tips, and other items being returned in an order. |
return_amounts | JSON | Optional | |
return_amounts (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order net amounts An aggregate monetary value being returned by this return entry. |
return_amounts (anyOf 2) | null | Alternative | |
return_discounts | JSON | Optional | |
return_discounts (anyOf 1) | array | Alternative | A collection of references to discounts being returned for an order, including the total applied discount amount to be returned. The discounts must reference a top-level discount ID from the source order. |
return_discounts (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return discounts array item |
return_discounts (anyOf 2) | null | Alternative | |
return_line_items | JSON | Optional | |
return_line_items (anyOf 1) | array | Alternative | A collection of line items that are being returned. |
return_line_items (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return line items A collection of line items that are being returned item |
return_line_items (anyOf 2) | null | Alternative | |
return_service_charges | JSON | Optional | |
return_service_charges (anyOf 1) | array | Alternative | A collection of service charges that are being returned. |
return_service_charges (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return service charges array item |
return_service_charges (anyOf 2) | null | Alternative | |
return_taxes | JSON | Optional | |
return_taxes (anyOf 1) | array | Alternative | A collection of references to taxes being returned for an order, including the total applied tax amount to be returned. The taxes must reference a top-level tax ID from the source order. |
return_taxes (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return taxes array item |
return_taxes (anyOf 2) | null | Alternative | |
return_tips | JSON | Optional | |
return_tips (anyOf 1) | array | Alternative | A collection of references to tips being returned for an order. |
return_tips (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return tips array item |
return_tips (anyOf 2) | null | Alternative | |
rounding_adjustment | JSON | Optional | |
rounding_adjustment (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order rounding adjustment A positive or negative rounding adjustment to the total value being returned. Adjustments are commonly used to apply cash rounding when the minimum unit of the account is smaller than the lowest physical denomination of the currency. |
rounding_adjustment (anyOf 2) | null | Alternative | |
source_order_id | JSON | Optional | |
source_order_id (anyOf 1) | string | Alternative | An order that contains the original sale of these return line items. This is unset for unlinked returns. |
source_order_id (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the return only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order net amounts, Pay Order — response body — order returns item return discounts array item, Pay Order — response body — order returns item return line items A collection of line items that are being returned item, Pay Order — response body — order returns item return service charges array item, Pay Order — response body — order returns item return taxes array item, Pay Order — response body — order returns item return tips array item, Pay Order — response body — order rounding adjustment
Pay Order — response body — order returns item return discounts array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a discount being returned that applies to one or more return line items in an order. Fixed-amount, order-scoped discounts are distributed across all non-zero return line item totals. The amount distributed to each return line item is relative to that item’s contribution to the order subtotal. |
amount_money | JSON | Optional | |
amount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The total declared monetary amount of the discount. `amount_money` is not set for percentage-based discounts. |
amount_money (anyOf 2) | null | Alternative | |
applied_money | Model | Optional | Expand Pay Order — response body — order total money The amount of discount actually applied to this line item. When an amount-based discount is at the order level, this value is different from `amount_money` because the discount is distributed across the line items. Read only: true |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing [CatalogDiscount](entity:CatalogDiscount). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this discount references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The discount's name. Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
percentage | JSON | Optional | |
percentage (anyOf 1) | string | Alternative | The percentage of the tax, as a string representation of a decimal number. A value of `"7.25"` corresponds to a percentage of 7.25%. `percentage` is not set for amount-based discounts. Maximum length: 10 |
percentage (anyOf 2) | null | Alternative | |
scope | JSON | Optional | |
scope (anyOf 1) | string | Alternative | Indicates whether this is a line-item or order-level discount. Indicates the level at which the `OrderReturnDiscount` applies. For `ORDER` scoped discounts, the server generates references in `applied_discounts` on all `OrderReturnLineItem`s. For `LINE_ITEM` scoped discounts, the discount is only applied to `OrderReturnLineItem`s with references in their `applied_discounts` field. See [OrderLineItemDiscountScope](#type-orderlineitemdiscountscope) for possible values Known values: OTHER_DISCOUNT_SCOPE, LINE_ITEM, ORDER |
scope (anyOf 2) | null | Alternative | |
source_discount_uid | JSON | Optional | |
source_discount_uid (anyOf 1) | string | Alternative | The discount `uid` from the order that contains the original application of this discount. Maximum length: 60 |
source_discount_uid (anyOf 2) | null | Alternative | |
type | JSON | Optional | |
type (anyOf 1) | string | Alternative | Indicates how the discount is applied to the associated line item or order. The type of the discount. If it is created by the API, it is `FIXED_PERCENTAGE` or `FIXED_AMOUNT`. Discounts that do not reference a catalog object ID must have a type of `FIXED_PERCENTAGE` or `FIXED_AMOUNT`. See [OrderLineItemDiscountType](#type-orderlineitemdiscounttype) for possible values Known values: UNKNOWN_DISCOUNT, FIXED_PERCENTAGE, FIXED_AMOUNT, VARIABLE_PERCENTAGE, VARIABLE_AMOUNT |
type (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the returned discount only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order returns item return line items A collection of line items that are being returned item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | The line item being returned in an order. |
applied_discounts | JSON | Optional | |
applied_discounts (anyOf 1) | array | Alternative | The list of references to `OrderReturnDiscount` entities applied to the return line item. Each `OrderLineItemAppliedDiscount` has a `discount_uid` that references the `uid` of a top-level `OrderReturnDiscount` applied to the return line item. On reads, the applied amount is populated. |
applied_discounts (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order line items The line items included in the order item applied discounts array item |
applied_discounts (anyOf 2) | null | Alternative | |
applied_service_charges | JSON | Optional | |
applied_service_charges (anyOf 1) | array | Alternative | The list of references to `OrderReturnServiceCharge` entities applied to the return line item. Each `OrderLineItemAppliedServiceCharge` has a `service_charge_uid` that references the `uid` of a top-level `OrderReturnServiceCharge` applied to the return line item. On reads, the applied amount is populated. |
applied_service_charges (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order line items The line items included in the order item applied service charges array item |
applied_service_charges (anyOf 2) | null | Alternative | |
applied_taxes | JSON | Optional | |
applied_taxes (anyOf 1) | array | Alternative | The list of references to `OrderReturnTax` entities applied to the return line item. Each `OrderLineItemAppliedTax` has a `tax_uid` that references the `uid` of a top-level `OrderReturnTax` applied to the return line item. On reads, the applied amount is populated. |
applied_taxes (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order line items The line items included in the order item applied taxes array item |
applied_taxes (anyOf 2) | null | Alternative | |
base_price_money | JSON | Optional | |
base_price_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The base price for a single unit of the line item. |
base_price_money (anyOf 2) | null | Alternative | |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The [CatalogItemVariation](entity:CatalogItemVariation) ID applied to this return line item. Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this line item references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
gross_return_money | Model | Optional | Expand Pay Order — response body — order total money The gross return amount of money calculated as (item base price + modifiers price) * quantity. Read only: true |
item_type | JSON | Optional | |
item_type (anyOf 1) | string | Alternative | Represents the line item type. The type of line item: an itemized return, a non-itemized return (custom amount), or the return of an unactivated gift card sale. See [OrderLineItemItemType](#type-orderlineitemitemtype) for possible values Known values: ITEM, CUSTOM_AMOUNT, GIFT_CARD |
item_type (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the line item. Maximum length: 512 |
name (anyOf 2) | null | Alternative | |
note | JSON | Optional | |
note (anyOf 1) | string | Alternative | The note of the return line item. Maximum length: 2000 |
note (anyOf 2) | null | Alternative | |
quantity | string | Required within parent | The quantity returned, formatted as a decimal number. For example, `"3"`. Line items with a `quantity_unit` can have non-integer quantities. For example, `"1.70000"`. Maximum length: 12 Minimum length: 1 |
quantity_unit | JSON | Optional | |
quantity_unit (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order line items The line items included in the order item quantity unit catalog object id, catalog version, measurement unit, precision The unit and precision that this return line item's quantity is measured in. |
quantity_unit (anyOf 2) | null | Alternative | |
return_modifiers | JSON | Optional | |
return_modifiers (anyOf 1) | array | Alternative | The [CatalogModifier](entity:CatalogModifier)s applied to this line item. |
return_modifiers (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order returns item return line items A collection of line items that are being returned item return modifiers array item |
return_modifiers (anyOf 2) | null | Alternative | |
source_line_item_uid | JSON | Optional | |
source_line_item_uid (anyOf 1) | string | Alternative | The `uid` of the line item in the original sale order. Maximum length: 60 |
source_line_item_uid (anyOf 2) | null | Alternative | |
total_discount_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of discount money to return for the line item. Read only: true |
total_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of money to return for this line item. Read only: true |
total_service_charge_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of apportioned service charge money to return for the line item. Read only: true |
total_tax_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of tax money to return for the line item. Read only: true |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID for this return line-item entry. Maximum length: 60 |
uid (anyOf 2) | null | Alternative | |
variation_name | JSON | Optional | |
variation_name (anyOf 1) | string | Alternative | The name of the variation applied to this return line item. Maximum length: 400 |
variation_name (anyOf 2) | null | Alternative | |
variation_total_price_money | Model | Optional | Expand Pay Order — response body — order total money The total price of all item variations returned in this line item. The price is calculated as `base_price_money` multiplied by `quantity` and does not include modifiers. Read only: true |
Referenced models: Pay Order — response body — order total money, Pay Order — response body — order line items The line items included in the order item applied discounts array item, Pay Order — response body — order line items The line items included in the order item applied service charges array item, Pay Order — response body — order line items The line items included in the order item applied taxes array item, Pay Order — response body — order line items The line items included in the order item quantity unit catalog object id, catalog version, measurement unit, precision, Pay Order — response body — order returns item return line items A collection of line items that are being returned item return modifiers array item
Pay Order — response body — order returns item return line items A collection of line items that are being returned item return modifiers array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A line item modifier being returned. |
base_price_money | JSON | Optional | |
base_price_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The base price for the modifier. `base_price_money` is required for ad hoc modifiers. If both `catalog_object_id` and `base_price_money` are set, `base_price_money` overrides the predefined [CatalogModifier](entity:CatalogModifier) price. |
base_price_money (anyOf 2) | null | Alternative | |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing [CatalogModifier](entity:CatalogModifier). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this line item modifier references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the item modifier. Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
quantity | JSON | Optional | |
quantity (anyOf 1) | string | Alternative | The quantity of the line item modifier. The modifier quantity can be 0 or more. For example, suppose a restaurant offers a cheeseburger on the menu. When a buyer orders this item, the restaurant records the purchase by creating an `Order` object with a line item for a burger. The line item includes a line item modifier: the name is cheese and the quantity is 1. The buyer has the option to order extra cheese (or no cheese). If the buyer chooses the extra cheese option, the modifier quantity increases to 2. If the buyer does not want any cheese, the modifier quantity is set to 0. |
quantity (anyOf 2) | null | Alternative | |
source_modifier_uid | JSON | Optional | |
source_modifier_uid (anyOf 1) | string | Alternative | The modifier `uid` from the order's line item that contains the original sale of this line item modifier. Maximum length: 60 |
source_modifier_uid (anyOf 2) | null | Alternative | |
total_price_money | Model | Optional | Expand Pay Order — response body — order total money The total price of the item modifier for its line item. This is the modifier's `base_price_money` multiplied by the line item's quantity. Read only: true |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the return modifier only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order returns item return service charges array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the service charge applied to the original order. |
amount_money | JSON | Optional | |
amount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of a non-percentage-based service charge. Either `percentage` or `amount_money` should be set, but not both. |
amount_money (anyOf 2) | null | Alternative | |
applied_money | Model | Optional | Expand Pay Order — response body — order total money The amount of money applied to the order by the service charge, including any inclusive tax amounts, as calculated by Square. - For fixed-amount service charges, `applied_money` is equal to `amount_money`. - For percentage-based service charges, `applied_money` is the money calculated using the percentage. Read only: true |
applied_taxes | JSON | Optional | |
applied_taxes (anyOf 1) | array | Alternative | The list of references to `OrderReturnTax` entities applied to the `OrderReturnServiceCharge`. Each `OrderLineItemAppliedTax` has a `tax_uid` that references the `uid` of a top-level `OrderReturnTax` that is being applied to the `OrderReturnServiceCharge`. On reads, the applied amount is populated. |
applied_taxes (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order line items The line items included in the order item applied taxes array item |
applied_taxes (anyOf 2) | null | Alternative | |
calculation_phase | string | Optional | Represents a phase in the process of calculating order totals. Service charges are applied after the indicated phase. [Read more about how order totals are calculated.](https://developer.squareup.com/docs/orders-api/how-it-works#how-totals-are-calculated) The calculation phase after which to apply the service charge. See [OrderServiceChargeCalculationPhase](#type-orderservicechargecalculationphase) for possible values Known values: SUBTOTAL_PHASE, TOTAL_PHASE, APPORTIONED_PERCENTAGE_PHASE, APPORTIONED_AMOUNT_PHASE Read only: true |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID of the associated [OrderServiceCharge](entity:OrderServiceCharge). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this service charge references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the service charge. Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
percentage | JSON | Optional | |
percentage (anyOf 1) | string | Alternative | The percentage of the service charge, as a string representation of a decimal number. For example, a value of `"7.25"` corresponds to a percentage of 7.25%. Either `percentage` or `amount_money` should be set, but not both. Maximum length: 10 |
percentage (anyOf 2) | null | Alternative | |
scope | JSON | Optional | |
scope (anyOf 1) | string | Alternative | Indicates whether this is a line-item or order-level apportioned service charge. Indicates the level at which the apportioned service charge applies. For `ORDER` scoped service charges, Square generates references in `applied_service_charges` on all order line items that do not have them. For `LINE_ITEM` scoped service charges, the service charge only applies to line items with a service charge reference in their `applied_service_charges` field. This field is immutable. To change the scope of an apportioned service charge, you must delete the apportioned service charge and re-add it as a new apportioned service charge. See [OrderServiceChargeScope](#type-orderservicechargescope) for possible values Known values: OTHER_SERVICE_CHARGE_SCOPE, LINE_ITEM, ORDER |
scope (anyOf 2) | null | Alternative | |
source_service_charge_uid | JSON | Optional | |
source_service_charge_uid (anyOf 1) | string | Alternative | The service charge `uid` from the order containing the original service charge. `source_service_charge_uid` is `null` for unlinked returns. Maximum length: 60 |
source_service_charge_uid (anyOf 2) | null | Alternative | |
taxable | JSON | Optional | |
taxable (anyOf 1) | boolean | Alternative | Indicates whether the surcharge can be taxed. Service charges calculated in the `TOTAL_PHASE` cannot be marked as taxable. |
taxable (anyOf 2) | null | Alternative | |
total_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of money to collect for the service charge. __NOTE__: If an inclusive tax is applied to the service charge, `total_money` does not equal `applied_money` plus `total_tax_money` because the inclusive tax amount is already included in both `applied_money` and `total_tax_money`. Read only: true |
total_tax_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of tax money to collect for the service charge. Read only: true |
treatment_type | JSON | Optional | |
treatment_type (anyOf 1) | string | Alternative | Indicates whether the service charge will be treated as a value-holding line item or apportioned toward a line item. Indicates whether the service charge will be treated as a value-holding line item or apportioned toward a line item. See [OrderServiceChargeTreatmentType](#type-orderservicechargetreatmenttype) for possible values Known values: LINE_ITEM_TREATMENT, APPORTIONED_TREATMENT |
treatment_type (anyOf 2) | null | Alternative | |
type | string | Optional | The type of the service charge. See [OrderServiceChargeType](#type-orderservicechargetype) for possible values Known values: AUTO_GRATUITY, CUSTOM Read only: true |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the return service charge only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money, Pay Order — response body — order line items The line items included in the order item applied taxes array item
Pay Order — response body — order returns item return taxes array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a tax being returned that applies to one or more return line items in an order. Fixed-amount, order-scoped taxes are distributed across all non-zero return line item totals. The amount distributed to each return line item is relative to that item’s contribution to the order subtotal. |
applied_money | Model | Optional | Expand Pay Order — response body — order total money The amount of money applied by the tax in an order. Read only: true |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing [CatalogTax](entity:CatalogTax). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this tax references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The tax's name. Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
percentage | JSON | Optional | |
percentage (anyOf 1) | string | Alternative | The percentage of the tax, as a string representation of a decimal number. For example, a value of `"7.25"` corresponds to a percentage of 7.25%. Maximum length: 10 |
percentage (anyOf 2) | null | Alternative | |
scope | JSON | Optional | |
scope (anyOf 1) | string | Alternative | Indicates whether this is a line-item or order-level tax. Indicates the level at which the `OrderReturnTax` applies. For `ORDER` scoped taxes, Square generates references in `applied_taxes` on all `OrderReturnLineItem`s. For `LINE_ITEM` scoped taxes, the tax is only applied to `OrderReturnLineItem`s with references in their `applied_discounts` field. See [OrderLineItemTaxScope](#type-orderlineitemtaxscope) for possible values Known values: OTHER_TAX_SCOPE, LINE_ITEM, ORDER |
scope (anyOf 2) | null | Alternative | |
source_tax_uid | JSON | Optional | |
source_tax_uid (anyOf 1) | string | Alternative | The tax `uid` from the order that contains the original tax charge. Maximum length: 60 |
source_tax_uid (anyOf 2) | null | Alternative | |
type | JSON | Optional | |
type (anyOf 1) | string | Alternative | Indicates how the tax is applied to the associated line item or order. Indicates the calculation method used to apply the tax. See [OrderLineItemTaxType](#type-orderlineitemtaxtype) for possible values Known values: UNKNOWN_TAX, ADDITIVE, INCLUSIVE |
type (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the returned tax only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order returns item return tips array item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A tip being returned. |
applied_money | Model | Optional | Expand Pay Order — response body — order total money The amount of tip being returned -- Read only: true |
source_tender_id | JSON | Optional | |
source_tender_id (anyOf 1) | string | Alternative | The tender `id` from the order that contains the original application of this tip. Maximum length: 192 |
source_tender_id (anyOf 2) | null | Alternative | |
source_tender_uid | JSON | Optional | |
source_tender_uid (anyOf 1) | string | Alternative | The tender `uid` from the order that contains the original application of this tip. Maximum length: 192 |
source_tender_uid (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the tip only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order rewards item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a reward that can be applied to an order if the necessary reward tier criteria are met. Rewards are created through the Loyalty API. |
id | string | Required within parent | The identifier of the reward. Minimum length: 1 |
reward_tier_id | string | Required within parent | The identifier of the reward tier corresponding to this reward. Minimum length: 1 |
Pay Order — response body — order rounding adjustment
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A rounding adjustment of the money being returned. Commonly used to apply cash rounding when the minimum unit of the account is smaller than the lowest physical denomination of the currency. |
amount_money | JSON | Optional | |
amount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The actual rounding adjustment amount. |
amount_money (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the rounding adjustment from the original sale order. |
name (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the rounding adjustment only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order service charges A list of service charges applied to the order item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a service charge applied to an order. |
amount_money | JSON | Optional | |
amount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of a non-percentage-based service charge. Exactly one of `percentage` or `amount_money` should be set. |
amount_money (anyOf 2) | null | Alternative | |
applied_money | Model | Optional | Expand Pay Order — response body — order total money The amount of money applied to the order by the service charge, including any inclusive tax amounts, as calculated by Square. - For fixed-amount service charges, `applied_money` is equal to `amount_money`. - For percentage-based service charges, `applied_money` is the money calculated using the percentage. Read only: true |
applied_taxes | JSON | Optional | |
applied_taxes (anyOf 1) | array | Alternative | The list of references to the taxes applied to this service charge. Each `OrderLineItemAppliedTax` has a `tax_uid` that references the `uid` of a top-level `OrderLineItemTax` that is being applied to this service charge. On reads, the amount applied is populated. An `OrderLineItemAppliedTax` is automatically created on every taxable service charge for all `ORDER` scoped taxes that are added to the order. `OrderLineItemAppliedTax` records for `LINE_ITEM` scoped taxes must be added in requests for the tax to apply to any taxable service charge. Taxable service charges have the `taxable` field set to `true` and calculated in the `SUBTOTAL_PHASE`. To change the amount of a tax, modify the referenced top-level tax. |
applied_taxes (anyOf 1)[] | Model | Each item | Expand Pay Order — response body — order line items The line items included in the order item applied taxes array item |
applied_taxes (anyOf 2) | null | Alternative | |
calculation_phase | JSON | Optional | |
calculation_phase (anyOf 1) | string | Alternative | Represents a phase in the process of calculating order totals. Service charges are applied after the indicated phase. [Read more about how order totals are calculated.](https://developer.squareup.com/docs/orders-api/how-it-works#how-totals-are-calculated) The calculation phase at which to apply the service charge. See [OrderServiceChargeCalculationPhase](#type-orderservicechargecalculationphase) for possible values Known values: SUBTOTAL_PHASE, TOTAL_PHASE, APPORTIONED_PERCENTAGE_PHASE, APPORTIONED_AMOUNT_PHASE |
calculation_phase (anyOf 2) | null | Alternative | |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing the service charge [CatalogObject](entity:CatalogObject). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this service charge references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
metadata | JSON | Optional | |
metadata (anyOf 1) | object | Alternative | Application-defined data attached to this service charge. 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 (such as personally identifiable information or card details). Keys written by applications must be 60 characters or less and must be in the character set `[a-zA-Z0-9_-]`. Entries can also include metadata generated by Square. These keys are prefixed with a namespace, separated from the key with a ':' character. Values have a maximum length of 255 characters. An application can 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. For more information, see [Metadata](https://developer.squareup.com/docs/build-basics/metadata). Additional keys: see wildcard field |
metadata (anyOf 1).* | string | Additional keys | |
metadata (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the service charge. This is unused and null for AUTO_GRATUITY to match the behavior on Bills. Maximum length: 512 |
name (anyOf 2) | null | Alternative | |
percentage | JSON | Optional | |
percentage (anyOf 1) | string | Alternative | The service charge percentage as a string representation of a decimal number. For example, `"7.25"` indicates a service charge of 7.25%. Exactly 1 of `percentage` or `amount_money` should be set. Maximum length: 10 |
percentage (anyOf 2) | null | Alternative | |
scope | JSON | Optional | |
scope (anyOf 1) | string | Alternative | Indicates whether this is a line-item or order-level apportioned service charge. Indicates the level at which the apportioned service charge applies. For `ORDER` scoped service charges, Square generates references in `applied_service_charges` on all order line items that do not have them. For `LINE_ITEM` scoped service charges, the service charge only applies to line items with a service charge reference in their `applied_service_charges` field. This field is immutable. To change the scope of an apportioned service charge, you must delete the apportioned service charge and re-add it as a new apportioned service charge. See [OrderServiceChargeScope](#type-orderservicechargescope) for possible values Known values: OTHER_SERVICE_CHARGE_SCOPE, LINE_ITEM, ORDER |
scope (anyOf 2) | null | Alternative | |
taxable | JSON | Optional | |
taxable (anyOf 1) | boolean | Alternative | Indicates whether the service charge can be taxed. If set to `true`, order-level taxes automatically apply to the service charge. Note that service charges calculated in the `TOTAL_PHASE` cannot be marked as taxable. |
taxable (anyOf 2) | null | Alternative | |
total_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of money to collect for the service charge. __Note__: If an inclusive tax is applied to the service charge, `total_money` does not equal `applied_money` plus `total_tax_money` because the inclusive tax amount is already included in both `applied_money` and `total_tax_money`. Read only: true |
total_tax_money | Model | Optional | Expand Pay Order — response body — order total money The total amount of tax money to collect for the service charge. Read only: true |
treatment_type | JSON | Optional | |
treatment_type (anyOf 1) | string | Alternative | Indicates whether the service charge will be treated as a value-holding line item or apportioned toward a line item. Indicates whether the service charge will be treated as a value-holding line item or apportioned toward a line item. See [OrderServiceChargeTreatmentType](#type-orderservicechargetreatmenttype) for possible values Known values: LINE_ITEM_TREATMENT, APPORTIONED_TREATMENT |
treatment_type (anyOf 2) | null | Alternative | |
type | string | Optional | The type of the service charge. See [OrderServiceChargeType](#type-orderservicechargetype) for possible values Known values: AUTO_GRATUITY, CUSTOM Read only: true |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the service charge only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money, Pay Order — response body — order line items The line items included in the order item applied taxes array item
Pay Order — response body — order source Represents the origination details of an order
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the origination details of an order. |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name used to identify the place (physical or digital) that an order originates. If unset, the name defaults to the name of the application that created the order. |
name (anyOf 2) | null | Alternative |
Pay Order — response body — order taxes The list of all taxes associated with the order item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a tax that applies to one or more line item in the order. Fixed-amount, order-scoped taxes are distributed across all non-zero line item totals. The amount distributed to each line item is relative to the amount the item contributes to the order subtotal. |
applied_money | JSON | Optional | |
applied_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of money applied to the order by the tax. - For percentage-based taxes, `applied_money` is the money calculated using the percentage. |
applied_money (anyOf 2) | null | Alternative | |
auto_applied | boolean | Optional | Determines whether the tax was automatically applied to the order based on the catalog configuration. For an example, see [Automatically Apply Taxes to an Order](https://developer.squareup.com/docs/orders-api/apply-taxes-and-discounts/auto-apply-taxes). Read only: true |
catalog_object_id | JSON | Optional | |
catalog_object_id (anyOf 1) | string | Alternative | The catalog object ID referencing [CatalogTax](entity:CatalogTax). Maximum length: 192 |
catalog_object_id (anyOf 2) | null | Alternative | |
catalog_version | JSON | Optional | |
catalog_version (anyOf 1) | JSON | Alternative | |
catalog_version (anyOf 1) (anyOf 1) | integer | Alternative | The version of the catalog object that this tax references. Format: int64 |
catalog_version (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
catalog_version (anyOf 2) | null | Alternative | |
metadata | JSON | Optional | |
metadata (anyOf 1) | object | Alternative | Application-defined data attached to this tax. 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 (such as personally identifiable information or card details). Keys written by applications must be 60 characters or less and must be in the character set `[a-zA-Z0-9_-]`. Entries can also include metadata generated by Square. These keys are prefixed with a namespace, separated from the key with a ':' character. Values have a maximum length of 255 characters. An application can 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. For more information, see [Metadata](https://developer.squareup.com/docs/build-basics/metadata). Additional keys: see wildcard field |
metadata (anyOf 1).* | string | Additional keys | |
metadata (anyOf 2) | null | Alternative | |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The tax's name. Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
percentage | JSON | Optional | |
percentage (anyOf 1) | string | Alternative | The percentage of the tax, as a string representation of a decimal number. For example, a value of `"7.25"` corresponds to a percentage of 7.25%. Maximum length: 10 |
percentage (anyOf 2) | null | Alternative | |
scope | JSON | Optional | |
scope (anyOf 1) | string | Alternative | Indicates whether this is a line-item or order-level tax. Indicates the level at which the tax applies. For `ORDER` scoped taxes, Square generates references in `applied_taxes` on all order line items that do not have them. For `LINE_ITEM` scoped taxes, the tax only applies to line items with references in their `applied_taxes` field. This field is immutable. To change the scope, you must delete the tax and re-add it as a new tax. See [OrderLineItemTaxScope](#type-orderlineitemtaxscope) for possible values Known values: OTHER_TAX_SCOPE, LINE_ITEM, ORDER |
scope (anyOf 2) | null | Alternative | |
type | JSON | Optional | |
type (anyOf 1) | string | Alternative | Indicates how the tax is applied to the associated line item or order. Indicates the calculation method used to apply the tax. See [OrderLineItemTaxType](#type-orderlineitemtaxtype) for possible values Known values: UNKNOWN_TAX, ADDITIVE, INCLUSIVE |
type (anyOf 2) | null | Alternative | |
uid | JSON | Optional | |
uid (anyOf 1) | string | Alternative | A unique ID that identifies the tax only within this order. Maximum length: 60 |
uid (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order tenders item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a tender (i.e., a method of payment) used in a Square transaction. |
additional_recipients | JSON | Optional | |
additional_recipients (anyOf 1) | array | Alternative | Additional recipients (other than the merchant) receiving a portion of this tender. For example, fees assessed on the purchase by a third party integration. |
additional_recipients (anyOf 1)[] | Model | Each item | Expand Create Checkout — response body — checkout additional recipients array item |
additional_recipients (anyOf 2) | null | Alternative | |
amount_money | JSON | Optional | |
amount_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The total amount of the tender, including `tip_money`. If the tender has a `payment_id`, the `total_money` of the corresponding [Payment](entity:Payment) will be equal to the `amount_money` of the tender. |
amount_money (anyOf 2) | null | Alternative | |
bank_account_details | JSON | Optional | |
bank_account_details (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order tenders item bank account details status The details of the bank account tender. This value is present only if the value of `type` is `BANK_ACCOUNT`. |
bank_account_details (anyOf 2) | null | Alternative | |
buy_now_pay_later_details | JSON | Optional | |
buy_now_pay_later_details (anyOf 1) | Model | Alternative | Expand PayOrder — response body — order / tenders / item / buy_now_pay_later_details / buy_now_pay_later_brand: OTHER BRAND, AFTERPAY The details of a Buy Now Pay Later tender. This value is present only if the value of `type` is `BUY_NOW_PAY_LATER`. |
buy_now_pay_later_details (anyOf 2) | null | Alternative | |
card_details | JSON | Optional | |
card_details (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order tenders item card details card, entry method, status The details of the card tender. This value is present only if the value of `type` is `CARD`. |
card_details (anyOf 2) | null | Alternative | |
cash_details | JSON | Optional | |
cash_details (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order tenders item cash details buyer tendered money, change back money The details of the cash tender. This value is present only if the value of `type` is `CASH`. |
cash_details (anyOf 2) | null | Alternative | |
created_at | string | Optional | The timestamp for when the tender was created, in RFC 3339 format. Maximum length: 32 Read only: true |
customer_id | JSON | Optional | |
customer_id (anyOf 1) | string | Alternative | If the tender is associated with a customer or represents a customer's card on file, this is the ID of the associated customer. Maximum length: 191 |
customer_id (anyOf 2) | null | Alternative | |
id | string | Optional | The tender's unique ID. It is the associated payment ID. Maximum length: 192 |
location_id | JSON | Optional | |
location_id (anyOf 1) | string | Alternative | The ID of the transaction's associated location. Maximum length: 50 |
location_id (anyOf 2) | null | Alternative | |
note | JSON | Optional | |
note (anyOf 1) | string | Alternative | An optional note associated with the tender at the time of payment. Maximum length: 500 |
note (anyOf 2) | null | Alternative | |
payment_id | JSON | Optional | |
payment_id (anyOf 1) | string | Alternative | The ID of the [Payment](entity:Payment) that corresponds to this tender. This value is only present for payments created with the v2 Payments API. Maximum length: 192 |
payment_id (anyOf 2) | null | Alternative | |
processing_fee_money | JSON | Optional | |
processing_fee_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of any Square processing fees applied to the tender. This field is not immediately populated when a new transaction is created. It is usually available after about ten seconds. |
processing_fee_money (anyOf 2) | null | Alternative | |
square_account_details | JSON | Optional | |
square_account_details (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order tenders item square account details status The details of a Square Account tender. This value is present only if the value of `type` is `SQUARE_ACCOUNT`. |
square_account_details (anyOf 2) | null | Alternative | |
tip_money | JSON | Optional | |
tip_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The tip's amount of the tender. |
tip_money (anyOf 2) | null | Alternative | |
transaction_id | JSON | Optional | |
transaction_id (anyOf 1) | string | Alternative | The ID of the tender's associated transaction. Maximum length: 192 |
transaction_id (anyOf 2) | null | Alternative | |
type | string | Required within parent | Indicates a tender's type. The type of tender, such as `CARD` or `CASH`. See [TenderType](#type-tendertype) for possible values Known values: CARD, CASH, THIRD_PARTY_CARD, SQUARE_GIFT_CARD, NO_SALE, BANK_ACCOUNT, WALLET, BUY_NOW_PAY_LATER, SQUARE_ACCOUNT, OTHER |
Referenced models: Create Checkout — response body — checkout additional recipients array item, Pay Order — response body — order total money, Pay Order — response body — order tenders item bank account details status, PayOrder — response body — order / tenders / item / buy_now_pay_later_details / buy_now_pay_later_brand: OTHER BRAND, AFTERPAY, Pay Order — response body — order tenders item card details card, entry method, status, Pay Order — response body — order tenders item cash details buyer tendered money, change back money, Pay Order — response body — order tenders item square account details status
Pay Order — response body — order tenders item bank account details status
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the details of a tender with `type` `BANK_ACCOUNT`. See [BankAccountPaymentDetails](entity:BankAccountPaymentDetails) for more exposed details of a bank account payment. |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | Indicates the bank account payment's current status. The bank account payment's current state. See [TenderBankAccountPaymentDetailsStatus](entity:TenderBankAccountDetailsStatus) for possible values. See [TenderBankAccountDetailsStatus](#type-tenderbankaccountdetailsstatus) for possible values Known values: PENDING, COMPLETED, FAILED |
status (anyOf 2) | null | Alternative |
Pay Order — response body — order tenders item card details card, entry method, status
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents additional details of a tender with `type` `CARD` or `SQUARE_GIFT_CARD` |
card | JSON | Optional | |
card (anyOf 1) | Model | Alternative | Expand Create Card — response body — card The credit card's non-confidential details. |
card (anyOf 2) | null | Alternative | |
entry_method | JSON | Optional | |
entry_method (anyOf 1) | string | Alternative | Indicates the method used to enter the card's details. The method used to enter the card's details for the transaction. See [TenderCardDetailsEntryMethod](#type-tendercarddetailsentrymethod) for possible values Known values: SWIPED, KEYED, EMV, ON_FILE, CONTACTLESS |
entry_method (anyOf 2) | null | Alternative | |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | Indicates the card transaction's current status. The credit card payment's current state (such as `AUTHORIZED` or `CAPTURED`). See [TenderCardDetailsStatus](entity:TenderCardDetailsStatus) for possible values. See [TenderCardDetailsStatus](#type-tendercarddetailsstatus) for possible values Known values: AUTHORIZED, CAPTURED, VOIDED, FAILED |
status (anyOf 2) | null | Alternative |
Referenced models: Create Card — response body — card
Pay Order — response body — order tenders item cash details buyer tendered money, change back money
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the details of a tender with `type` `CASH`. |
buyer_tendered_money | JSON | Optional | |
buyer_tendered_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The total amount of cash provided by the buyer, before change is given. |
buyer_tendered_money (anyOf 2) | null | Alternative | |
change_back_money | JSON | Optional | |
change_back_money (anyOf 1) | Model | Alternative | Expand Pay Order — response body — order total money The amount of change returned to the buyer. |
change_back_money (anyOf 2) | null | Alternative |
Referenced models: Pay Order — response body — order total money
Pay Order — response body — order tenders item square account details status
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the details of a tender with `type` `SQUARE_ACCOUNT`. |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | The Square Account payment's current state (such as `AUTHORIZED` or `CAPTURED`). See [TenderSquareAccountDetailsStatus](entity:TenderSquareAccountDetailsStatus) for possible values. See [Status](#type-status) for possible values Known values: AUTHORIZED, CAPTURED, VOIDED, FAILED |
status (anyOf 2) | null | Alternative |
Pay Order — response body — order total money
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an amount of money. `Money` fields can be signed or unsigned. Fields that do not explicitly define whether they are signed or unsigned are considered unsigned and can only hold positive amounts. For signed fields, the sign of the value indicates the purpose of the money transfer. See [Working with Monetary Amounts](https://developer.squareup.com/docs/build-basics/working-with-monetary-amounts) for more information. |
amount | JSON | Optional | |
amount (anyOf 1) | JSON | Alternative | |
amount (anyOf 1) (anyOf 1) | integer | Alternative | The amount of money, in the smallest denomination of the currency indicated by `currency`. For example, when `currency` is `USD`, `amount` is in cents. Monetary amounts can be positive or negative. See the specific field description to determine the meaning of the sign in a particular case. Format: int64 |
amount (anyOf 1) (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
amount (anyOf 2) | null | Alternative | |
currency | JSON | Optional | |
currency (anyOf 1) | Model | Alternative | Expand Create Location — response body — location currency The type of currency, in __ISO 4217 format__. For example, the currency code for US dollars is `USD`. See [Currency](entity:Currency) for possible values. See [Currency](#type-currency) for possible values |
currency (anyOf 2) | null | Alternative |
Referenced models: Create Location — response body — location currency
PayOrder — response body — order / tenders / item / buy_now_pay_later_details / buy_now_pay_later_brand: OTHER BRAND, AFTERPAY
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents the details of a tender with `type` `BUY_NOW_PAY_LATER`. |
buy_now_pay_later_brand | string | Optional | The Buy Now Pay Later brand. See [Brand](#type-brand) for possible values Known values: OTHER_BRAND, AFTERPAY Read only: true |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | The buy now pay later payment's current state (such as `AUTHORIZED` or `CAPTURED`). See [TenderBuyNowPayLaterDetailsStatus](entity:TenderBuyNowPayLaterDetailsStatus) for possible values. See [Status](#type-status) for possible values Known values: AUTHORIZED, CAPTURED, VOIDED, FAILED |
status (anyOf 2) | null | Alternative |
Retrieve Order — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
errors | array | Optional | Any errors that occurred during the request. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
order | Model | Optional | Expand Pay Order — response body — order The requested order. |
Referenced models: Get Shift — response body — errors item, Pay Order — response body — order
Search Orders — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
cursor | string | Optional | A pagination cursor returned by a previous call to this endpoint. Provide this cursor to retrieve the next set of results for your original query. For more information, see [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination). |
limit | integer | Optional | The maximum number of results to be returned in a single page. Default: `500` Max: `1000` |
location_ids | array | Optional | The location IDs for the orders to query. All locations must belong to the same merchant. Max: 10 location IDs. |
location_ids[] | string | Each item | |
query | Model | Optional | Expand Search Orders — request body — body query Query conditions used to filter or sort the results. Note that when retrieving additional pages using a cursor, you must use the original query. |
return_entries | boolean | Optional | A Boolean that controls the format of the search results. If `true`, `SearchOrders` returns [OrderEntry](entity:OrderEntry) objects. If `false`, `SearchOrders` returns complete order objects. Default: `false`. |
Referenced models: Search Orders — request body — body query
Search Orders — request body — body query
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Contains query criteria for the search. |
filter | JSON | Optional | |
filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter Criteria to filter results by. |
filter (anyOf 2) | null | Alternative | |
sort | JSON | Optional | |
sort (anyOf 1) | Model | Alternative | Expand SearchOrders — request body — body / query / sort / sort_field: CREATED AT, UPDATED AT, CLOSED AT Criteria to sort results by. |
sort (anyOf 2) | null | Alternative |
Referenced models: Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter, SearchOrders — request body — body / query / sort / sort_field: CREATED AT, UPDATED AT, CLOSED AT
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Filtering criteria to use for a `SearchOrders` request. Multiple filters are ANDed together. |
customer_filter | JSON | Optional | |
customer_filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter customer filter customer ids Filter by customers associated with the order. |
customer_filter (anyOf 2) | null | Alternative | |
date_time_filter | JSON | Optional | |
date_time_filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter date time filter closed at, created at, updated at Filter for results within a time range. __Important:__ If you filter for orders by time range, you must set `SearchOrdersSort` to sort by the same field. [Learn more about filtering orders by time range.](https://developer.squareup.com/docs/orders-api/manage-orders/search-orders#important-note-about-filtering-orders-by-time-range) |
date_time_filter (anyOf 2) | null | Alternative | |
fulfillment_filter | JSON | Optional | |
fulfillment_filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter fulfillment filter fulfillment states, fulfillment types Filter by the fulfillment type or state. |
fulfillment_filter (anyOf 2) | null | Alternative | |
source_filter | JSON | Optional | |
source_filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter source filter A filter based on order `source` information Filter by the source of the order. |
source_filter (anyOf 2) | null | Alternative | |
state_filter | JSON | Optional | |
state_filter (anyOf 1) | Model | Alternative | Expand Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter state filter Filter by the current order `state` Filter by [OrderState](entity:OrderState). |
state_filter (anyOf 2) | null | Alternative |
Referenced models: Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter customer filter customer ids, Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter date time filter closed at, created at, updated at, Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter fulfillment filter fulfillment states, fulfillment types, Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter source filter A filter based on order `source` information, Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter state filter Filter by the current order `state`
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter customer filter customer ids
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A filter based on the order `customer_id` and any tender `customer_id` associated with the order. It does not filter based on the [FulfillmentRecipient](entity:FulfillmentRecipient) `customer_id`. |
customer_ids | JSON | Optional | |
customer_ids (anyOf 1) | array | Alternative | A list of customer IDs to filter by. Max: 10 customer ids. |
customer_ids (anyOf 1)[] | string | Each item | |
customer_ids (anyOf 2) | null | Alternative |
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter date time filter closed at, created at, updated at
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Filter for `Order` objects based on whether their `CREATED_AT`, `CLOSED_AT`, or `UPDATED_AT` timestamps fall within a specified time range. You can specify the time range and which timestamp to filter for. You can filter for only one time range at a time. For each time range, the start time and end time are inclusive. If the end time is absent, it defaults to the time of the first request for the cursor. __Important:__ If you use the `DateTimeFilter` in a `SearchOrders` query, you must set the `sort_field` in [OrdersSort](entity:SearchOrdersSort) to the same field you filter for. For example, if you set the `CLOSED_AT` field in `DateTimeFilter`, you must set the `sort_field` in `SearchOrdersSort` to `CLOSED_AT`. Otherwise, `SearchOrders` throws an error. [Learn more about filtering orders by time range.](https://developer.squareup.com/docs/orders-api/manage-orders/search-orders#important-note-about-filtering-orders-by-time-range) |
closed_at | JSON | Optional | |
closed_at (anyOf 1) | Model | Alternative | Expand Search Availability — request body — body query filter start at range The time range for filtering on the `closed_at` timestamp. If you use this value, you must set the `sort_field` in the `OrdersSearchSort` object to `CLOSED_AT`. |
closed_at (anyOf 2) | null | Alternative | |
created_at | Model | Optional | Expand Search Availability — request body — body query filter start at range The time range for filtering on the `created_at` timestamp. If you use this value, you must set the `sort_field` in the `OrdersSearchSort` object to `CREATED_AT`. |
updated_at | Model | Optional | Expand Search Availability — request body — body query filter start at range The time range for filtering on the `updated_at` timestamp. If you use this value, you must set the `sort_field` in the `OrdersSearchSort` object to `UPDATED_AT`. |
Referenced models: Search Availability — request body — body query filter start at range
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter fulfillment filter fulfillment states, fulfillment types
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Filter based on [order fulfillment](entity:Fulfillment) information. |
fulfillment_states | JSON | Optional | |
fulfillment_states (anyOf 1) | array | Alternative | A list of [fulfillment states](entity:FulfillmentState) to filter for. The list returns orders if any of its fulfillments match any of the fulfillment states listed in this field. See [FulfillmentState](#type-fulfillmentstate) for possible values |
fulfillment_states (anyOf 1)[] | string | Each item | The current state of this fulfillment. One of: PROPOSED, RESERVED, PREPARED, COMPLETED, CANCELED, FAILED |
fulfillment_states (anyOf 2) | null | Alternative | |
fulfillment_types | JSON | Optional | |
fulfillment_types (anyOf 1) | array | Alternative | A list of [fulfillment types](entity:FulfillmentType) to filter for. The list returns orders if any of its fulfillments match any of the fulfillment types listed in this field. See [FulfillmentType](#type-fulfillmenttype) for possible values |
fulfillment_types (anyOf 1)[] | string | Each item | The type of fulfillment. One of: PICKUP, SHIPMENT, DELIVERY, IN_STORE |
fulfillment_types (anyOf 2) | null | Alternative |
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter source filter A filter based on order `source` information
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A filter based on order `source` information. |
source_names | JSON | Optional | |
source_names (anyOf 1) | array | Alternative | Filters by the [Source](entity:OrderSource) `name`. The filter returns any orders with a `source.name` that matches any of the listed source names. Max: 10 source names. |
source_names (anyOf 1)[] | string | Each item | |
source_names (anyOf 2) | null | Alternative |
Search Orders — request body — body query filter customer filter, date time filter, fulfillment filter, source filter, state filter state filter Filter by the current order `state`
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Filter by the current order `state`. |
states | array | Required within parent | States to filter for. See [OrderState](#type-orderstate) for possible values |
states[] | string | Each item | The state of the order. One of: OPEN, COMPLETED, CANCELED, DRAFT |
Search Orders — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Either the `order_entries` or `orders` field is set, depending on whether `return_entries` is set on the [SearchOrdersRequest](api-endpoint:Orders-SearchOrders). |
cursor | string | Optional | The pagination cursor to be used in a subsequent request. If unset, this is the final response. For more information, see [Pagination](https://developer.squareup.com/docs/build-basics/common-api-patterns/pagination). |
errors | array | Optional | [Errors](entity:Error) encountered during the search. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
order_entries | array | Optional | A list of [OrderEntries](entity:OrderEntry) that fit the query conditions. The list is populated only if `return_entries` is set to `true` in the request. |
order_entries[] | Model | Each item | Expand Search Orders — response body — order entries item |
orders | array | Optional | A list of [Order](entity:Order) objects that match the query conditions. The list is populated only if `return_entries` is set to `false` in the request. |
orders[] | Model | Each item | Expand Pay Order — response body — order |
Referenced models: Get Shift — response body — errors item, Pay Order — response body — order, Search Orders — response body — order entries item
Search Orders — response body — order entries item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A lightweight description of an [order](entity:Order) that is returned when `returned_entries` is `true` on a [SearchOrdersRequest](api-endpoint:Orders-SearchOrders). |
location_id | JSON | Optional | |
location_id (anyOf 1) | string | Alternative | The location ID the order belongs to. |
location_id (anyOf 2) | null | Alternative | |
order_id | JSON | Optional | |
order_id (anyOf 1) | string | Alternative | The ID of the order. |
order_id (anyOf 2) | null | Alternative | |
version | JSON | Optional | |
version (anyOf 1) | integer | Alternative | The version number, which is incremented each time an update is committed to the order. Orders that were not created through the API do not include a version number and therefore cannot be updated. [Read more about working with versions.](https://developer.squareup.com/docs/orders-api/manage-orders/update-orders) Read only: true |
version (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
SearchOrders — request body — body / query / sort / sort_field: CREATED AT, UPDATED AT, CLOSED AT
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Sorting criteria for a `SearchOrders` request. Results can only be sorted by a timestamp field. |
sort_field | string | Required within parent | Specifies which timestamp to use to sort `SearchOrder` results. The field to sort by. __Important:__ When using a [DateTimeFilter](entity:SearchOrdersFilter), `sort_field` must match the timestamp field that the `DateTimeFilter` uses to filter. For example, if you set your `sort_field` to `CLOSED_AT` and you use a `DateTimeFilter`, your `DateTimeFilter` must filter for orders by their `CLOSED_AT` date. If this field does not match the timestamp field in `DateTimeFilter`, `SearchOrders` returns an error. Default: `CREATED_AT`. See [SearchOrdersSortField](#type-searchorderssortfield) for possible values One of: CREATED_AT, UPDATED_AT, CLOSED_AT |
sort_order | JSON | Optional | |
sort_order (anyOf 1) | string | Alternative | The order (e.g., chronological or alphabetical) in which results from a request are returned. The chronological order in which results are returned. Defaults to `DESC`. See [SortOrder](#type-sortorder) for possible values One of: DESC, ASC |
sort_order (anyOf 2) | null | Alternative |
Update Order — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Defines the fields that are included in requests to the [UpdateOrder](api-endpoint:Orders-UpdateOrder) endpoint. |
fields_to_clear | JSON | Optional | |
fields_to_clear (anyOf 1) | array | Alternative | The [dot notation paths](https://developer.squareup.com/docs/orders-api/manage-orders/update-orders#identifying-fields-to-delete) fields to clear. For example, `line_items[uid].note`. For more information, see [Deleting fields](https://developer.squareup.com/docs/orders-api/manage-orders/update-orders#deleting-fields). |
fields_to_clear (anyOf 1)[] | string | Each item | |
fields_to_clear (anyOf 2) | null | Alternative | |
idempotency_key | JSON | Optional | |
idempotency_key (anyOf 1) | string | Alternative | A value you specify that uniquely identifies this update request. If you are unsure whether a particular update was applied to an order successfully, you can reattempt it with the same idempotency key without worrying about creating duplicate updates to the order. The latest order version is returned. For more information, see [Idempotency](https://developer.squareup.com/docs/build-basics/common-api-patterns/idempotency). Maximum length: 192 |
idempotency_key (anyOf 2) | null | Alternative | |
order | JSON | Optional | |
order (anyOf 1) | Model | Alternative | Expand Create Order — request body — body order The [sparse order](https://developer.squareup.com/docs/orders-api/manage-orders/update-orders#sparse-order-objects) containing only the fields to update and the version to which the update is being applied. |
order (anyOf 2) | null | Alternative |
Referenced models: Create Order — request body — body order
Update Order — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Defines the fields that are included in the response body of a request to the [UpdateOrder](api-endpoint:Orders-UpdateOrder) endpoint. |
errors | array | Optional | Any errors that occurred during the request. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
order | Model | Optional | Expand Pay Order — response body — order The updated order. |
Referenced models: Get Shift — response body — errors item, Pay Order — response body — order