Lotus
Type to search documentation.
Orders

List all orders

Retrieve a collection of orders with optional filtering and pagination.

get/orders

Security

This operation accepts the following authorization requirements.

Required credentials

One credential is required.
OAuth2oauth2

OAuth2 authorization for API access.

orders:read

Request

Query parameters

filterstring

Filters the collection items using space-separated field:value pairs.

Format: field1:value1 field2:value2

Supported operators:

  • field:value - Exact match
  • field:value1,value2 - Match any of the comma-separated values (OR)
  • Time ranges: Use 30d (30 days), 7d (7 days), 1h (1 hour), etc.

Examples:

  • status:placed - Filter by single status.
  • status:placed,completed - Filter by multiple statuses.
  • createdAt:30d - Filter orders created in the last 30 days.
  • orderId:ord_01h1s5z6vf2mm1mz3hevnn9va7 - Filter by specific order ID.
  • status:placed createdAt:7d - Combine multiple filters.
sortstring

To sort by id in descending order use -id. To sort by id in ascending order use id.

limitinteger

Use to return a number of results per page. If there is more data, use in combination with after to page through the data.

afterstring

Use the endCursor as a value for the after parameter to get the next page.

beforestring

Use the startCursor as a value for the before parameter to get the next page.

searchstring

Performs a case-insensitive text search across relevant fields in the collection.

Fields searched depend on the endpoint:

  • Menu items: name, photoTextDescription
  • Orders: customerName, id

Returns items where any of the searchable fields contain the search term as a substring.

Response

Successful operation.

objectstringrequired

Allowed values:"list"

Entity name.

pageobjectrequired
Properties (6)
endCursorstringrequired

Use with the after query parameter to load the next page of data. When null, there is no data. The cursor is opaque and internal structure is subject to change.

startCursorstringrequired

Use with the before query parameter to load the previous page of data. When null, there is no data. The cursor is opaque and internal structure is subject to change.

hasNextPagebooleanrequired

Indicates if there is a next page with items.

hasPrevPagebooleanrequired

Indicates if there is a previous page with items.

limitintegerrequired

Value showing how many items are in the page limit.

totalintegerrequired

Count of items across all pages.

itemsobject[]required
Item properties (8)
idstring:ulid

Order ID. Unique identifier prefixed with ord_.

objectstring

Allowed values:"order"

Entity name.

customerNamestringrequired

Name of the customer who placed the order. Must start and end with a letter, and can contain letters, spaces, hyphens, and apostrophes (e.g., “John Doe”, “Mary-Jane”, “O’Brien”).

statusstring
totalPriceinteger

Total order price in cents.

createdAtstring:date-time

Created date.

updatedAtstring:date-time

Updated date.

orderItemsobject[]required

List of items to include in the order.

Item properties (4)
menuItemIdstringrequired

ID of the menu item to add to the order.

quantityintegerrequired

Quantity of the menu item.

discountinteger

Discount amount in cents (absolute value).

commentstring

Optional comment for the order item (e.g., “No sugar”).