Purchase History data definition
A number of Distil’s features require knowledge of your Customers’ Purchase History. For example the Product Recommendations Enrichment suggests follow-on Purchases and finds Products that are commonly purchased together, the Spend Brackets Enrichment calculates which of your Customers are the Big Spenders and the Demographic Profiling Enrichment creates socio-economic profiles based on spending behaviour.
Providing Customer purchase history unlocks these Distil.ai features. Distil.ai provides multiple methods to bring this dataset in. These are detailed in Database Sync, Tracking and Integrations.
The table below shows the Purchase History data definition.
Please note that each record in this data set is equivalent to an Order Line item, i.e. all the instances of a Product being purchased in one order. Therefore one Order may be comprised of multiple rows in this data set.
Attribute Friendly Name | Attribute Database Name | Data Type | Required | Description |
Id | id | Text | Yes | A unique id for this row. Each row in this dataset should be unique. It is expected that an Order Id has multiple line items, each with their own Id. A suggestion here is to use the Order Id and Product Id combined to form a unique Id attribute value. |
Customer Id | customer_id | Text | Yes | The ID of the Customer. This should match to a Customer Id provided in the Customers dataset. |
Order Id | order_id | Text | Yes | The Id of the Order. As each record in this data set is an Order Line Item, this Order Id Attribute will be duplicated for all Items in the same order. |
Product Id | product_id | Text | Yes | The ID of the Product purchased in this Line Item. This should match to a Product Id provided in the Products dataset. |
Order Timestamp UTC | order_timestamp | Timestamp | Yes | The Timestamp of the Order in UTC. |
Quantity | qty | Integer | Yes | The quantity of the Product purchased in this order. |
Line Value Excluding Tax | line_value_ex_tax | Decimal | Yes | The value of the line, excluding any Tax. |
Line Value Including Tax | line_value_inc_tax | Decimal | Yes | The value of the line, including Tax. |
Payment method | payment_method | Text | String for storing the payment method. | |
Currency | currency | Text in ISO Currency Code | Yes | ISO Currency Code. https://www.iso.org/iso-4217-currency-codes.html |
Postal Address Line 1 | postal_address_line_1 | Text | The postal address for the Order | |
Postal Address Line 2 | postal_address_line_2 | Text | ||
Postal Address Town | postal_address_line_town | Text | ||
Postal Address Region | postal_address_line_region | Text | ||
Postal Address Country | postal_address_line_country | Text | ||
Postal Address Postcode | postal_address_line_postcode | Text | ||
Billing Address Line 1 | billing_address_line_1 | Text | The billing address for the order | |
Billing Address Line 2 | billing_address_line_2 | Text | ||
Billing Address Town | billing_address_line_town | Text | ||
Billing Address Region | billing_address_line_region | Text | ||
Billing Address Country | billing_address_line_country | Text | ||
Billing Address Postcode | billing_address_line_postcode | Text |
Enrichment
- Product Recommendations: This enrichment creates unique product recommendations on a Customer by Customer basis. Customer Purchase History is used to understand which of your Products are commonly purchased together, which Products are purchased after each other, as well as excluding Products from the recommendation that a Customer has already purchased.
- Spend Brackets: This enrichment uses the Purchase History to identify which categories individual Customers are interested in.
- Demographics Profile: This enrichment uses the Purchase History data overlaid with Distil.ai’s internal Demographics datasets to build profiles based on socio-economic markers and spending behaviour.