Order records

An order record represents the finalized state of an order that has already been completed or originated outside the operational OMS flow. Unlike an order, an order record doesn't express customer intent that needs to be fulfilled. It captures what happened, not what needs to happen next. It doesn't participate in the fulfillment lifecycle and doesn't trigger routing, picking, packing, shipping, or any downstream operational processes.

Order records exist to make non-operational order data available for audit, analytics, and reporting, without adding load or complexity to the operational OMS.

Distinction between order and order record

Dimension
Order record
Order

Purpose

Persist completed or external orders

Create demand and trigger fulfillment

Lifecycle

No lifecycle

Full lifecycle with events

Downstream entities

None

Yes (pick jobs, pack jobs, parcels, …)

Validation

Minimal

Strict

Input type

Offline, batch, legacy, historical

Real-time operational orders

Cost profile

Low (storage-oriented)

Higher (event-driven, stateful)

Create order records

Order records are created using a bulk endpoint that accepts up to 25 records per request. To create order records, call the following PUT endpoint:

PUT https://{projectId}.api.fulfillmenttools.com/api/orderrecords

Order record structure

Required fields

  • orderRecordDate: Date and time of the transaction (ISO 8601)

  • facilityRef: Reference to the facility where the transaction occurred

  • lineItems: Array of purchased items (1–500 items)

Optional fields

  • tenantOrderRecordId: Your external order record ID for reference

  • consumer: Customer information including consumerId, email, and addresses (up to 10)

  • payments: Payment details (up to 100) including method, amounts, and status (COMPLETED, FAILED, CANCELLED, REFUNDED, PARTIALLY_REFUNDED)

  • origin: POS origin information with terminalId and cashierId

  • pricing: Order-level pricing breakdown with discounts (up to 100), fees (up to 100), and taxes (up to 100)

  • customAttributes: Free-form key-value attributes for tenant-specific data

Line items

Each line item requires an article with a tenantArticleId and a quantity (minimum 1). Optional fields include:

  • article.title: Product name

  • article.attributes: Product attributes with key, value, and optional category, priority, type, and localized values

  • measurementUnitKey: Unit of measure

  • warranty: Warranty details with warrantyStartDate and warrantyPeriod (ISO 8601 duration, for example, P2Y for 2 years)

  • returnPolicy: Return details with isReturnable flag and returnWindowEndDate

  • customAttributes: Free-form attributes

Monetary values

All monetary values use the MonetaryValue format:

value: Amount in the smallest currency unit (for example, cents)

currency: ISO 4217 currency code

decimalPlaces: Number of decimal places (defaults to currency standard)

System-generated fields

These fields are automatically set and returned in the response:

  • id: Unique identifier for the order record

  • version: Version number for optimistic locking

  • created: Timestamp when the record was created

  • lastModified: Timestamp of the last modification

  • anonymized: Whether PII has been anonymized (GDPR)

  • gdprCleanupDate: When anonymization will occur

  • deletionDate: When the record will be permanently deleted

  • pricing.priceBreakdown: Calculated totals including subTotal, totalDiscounts, totalTaxes, totalFees, totalDeposit, and total

List order records

To retrieve a paginated list of order records, call the following GET endpoint:

Query parameters

  • size (optional): Number of items per page, maximum 500, default 20

  • startAfterId (optional): Cursor for keyset pagination — pass the id of the last record from the previous page

  • facilityRef (optional): Filter by facility reference

  • tenantOrderRecordId (optional): Filter by your external order record ID

Example: List with filtering

Get a single order record

To retrieve a specific order record by its ID:

Returns the full order record object or a 404 Not Found if the record doesn't exist.

Authorization

Order record operations require the following permissions:

  • ORDER_RECORD_READ: Required for listing and retrieving order records

  • ORDER_RECORD_WRITE: Required for creating order records

See the Authorization article for more information.

GDPR and data retention

Order records support automatic GDPR compliance:

  • Anonymization: PII is automatically anonymized based on the configured GDPR cleanup schedule

  • Deletion: Records are permanently deleted after the configured retention period

  • The anonymized, gdprCleanupDate, and deletionDate fields track the GDPR lifecycle

See the GDPR configuration for more details.

Last updated