Order

The schema of an order, especially as it exists sent to the event system.

Order Attributes

attribute

Type

Example values

Description

id *required

String or Integer

"1234", 1234

Your platform's ID for the order.

total

*required

Float

10.0, 1042.32

The grand total of the order; the amount that was paid by the customer.

line_items

*required

Array of LineItem‚Äč

[LineItem, LineItem]

An array of the line item objects that were purchased.

See Line Item model schema.

number

optional

String

"1"

A user-friendly order number that can be displayed to a shopper without revealing the number of orders your store has gotten

Default: id

test

optional

Boolean

true, false

Is this order a test order? If so it will be omitted from certain calculations.

Default: false

canceled

optional

Boolean

true, false

If true, then the order will not be counted in certain calculations and displays.

total_usd

optional

Float

7.32

If specified and different than total then the order will be assumed to have been in another currency.

Default: If not specified then the store's base currency is assumed.

created_at

optional

ISO 8601 DateTime (String)

"2019-03-18T21:01:10+00:00"

The date the order was created.

Default: Current date/time right now (when order was recorded by Fera system)

modified_at

optional

ISO 8601 DateTime (String)

"2019-03-18T21:01:10+00:00"

The date the order was last modified.

Default: Current date/time right now (when order was recorded by Fera system)

source_name

optional

String

"web", "amazon", "ebay", "pos"

The medium which the order took place upon.

Default: "web"

Example Payload

{
id: "12345", // Required - Integer, String: A unique identifier that your platform can identify the order by.
number: "order-5", // Optional - Integer, String: A user-friendly order identifier that appears on the order frontend.
test: false, // Optional - Boolean: If true, the order will be skipped in certain calculations.
canceled: false, // Optional - Boolean If true, the order will be ignored from certain calculations.
total: 10.0, // Optional - Float: If not provided, then line item totals must be provided.
total_usd: 10.0, // Optional - Float: If not USD main currency
created_at: "2019-03-18T21:01:10+00:00", // (Optional) String (ISO 8601 format DateTime)
modified_at: "2019-03-18T21:01:10+00:00", // (Optional) String (ISO 8601 format DateTime)
source_name: "web", // (Optional) String
line_items: [LineItem] // See Line Item schema
}