Order Event
An order event interaction is an ecommerce event that captures actions performed by a
customer to manage new, in progress, or completed orders.
Purchase Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1PurchaseOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.purchase(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Preorder Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1PreOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.preorder(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Cancel Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1CancelOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.cancel(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Ship Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1ShipOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.ship(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Deliver Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1DeliverOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.deliver(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Return Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1ReturnOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.returnOrder(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)Exchange Order Example
| Field Name | Field Type | Description |
|---|---|---|
| order | Order Attribute | Required. A single order attribute value. |
1ExchangeOrderEvent(
2 order: Order(
3 id: "order-1",
4 lineItems: [
5 LineItem(
6 catalogObjectType: "Product",
7 catalogObjectId: "product-11",
8 quantity: 1
9 )
10 ]
11 )
12)1OrderEvent.exchange(
2 order = Order(
3 id = "order-1",
4 totalValue = 9.99,
5 currency = "USD",
6 attributes = mapOf(
7 "PROMO_CODE" to "HELLO"
8 ),
9 lineItems = listOf(
10 LineItem(
11 catalogObjectId = "product-1",
12 catalogObjectType = "Product",
13 quantity = 1,
14 price = 20.0,
15 currency = "USD",
16 attributes = mapOf(
17 "gift_wrap" to true
18 )
19 )
20 )
21 )
22)