forked from adobe/xdm
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcommerce.schema.json
More file actions
105 lines (105 loc) · 5 KB
/
commerce.schema.json
File metadata and controls
105 lines (105 loc) · 5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
{
"meta:license": [
"Copyright 2017 Adobe Systems Incorporated. All rights reserved.",
"This work is licensed under a Creative Commons Attribution 4.0 International (CC BY 4.0) license",
"you may not use this file except in compliance with the License. You may obtain a copy",
"of the License at https://creativecommons.org/licenses/by/4.0/"
],
"$id": "https://ns.adobe.com/xdm/context/commerce",
"$schema": "http://json-schema.org/draft-06/schema#",
"title": "Commerce",
"type": "object",
"meta:extensible": true,
"description": "The records related to buying and selling activity.",
"definitions": {
"commerce": {
"properties": {
"xdm:order": {
"title": "Order",
"$ref": "https://ns.adobe.com/xdm/data/order",
"description": "The placed order for one or more products."
},
"xdm:cartAbandons": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "A product list has been identified as no longer accessible or purchasable by the user."
},
"xdm:checkouts": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "An action during a checkout process of a product list, there can be more than one checkout event if there are multiple steps in a checkout process. If there are multiple steps the event time information and referenced page or experience is used to identify the step individual events represent in order."
},
"xdm:productListAdds": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "Addition of a product to the product list, for example a product is added to a shopping cart."
},
"xdm:productListOpens": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "Initializations of a new product list, for example a shopping cart is created."
},
"xdm:productListRemovals": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "Removal or removals of a product entry from a product list, for example a product is removed from a shopping cart."
},
"xdm:productListReopens": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "A product list that was no longer accessible (abandoned) has been re-activated by the user. Example via a re-marketing activity."
},
"xdm:productListViews": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "View or views of a product-list has occurred."
},
"xdm:productViews": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "View or views of a product have occurred."
},
"xdm:purchases": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "An order has been accepted. Purchase is the only required action in a commerce conversion. Purchase must have a product list referenced."
},
"xdm:saveForLaters": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "Product list is saved for future use, for example a product wish list."
},
"xdm:inStorePurchase": {
"$ref": "https://ns.adobe.com/xdm/data/measure",
"description": "'inStore' purchase is saved for analytics use."
}
}
}
},
"allOf": [
{
"$ref": "https://ns.adobe.com/xdm/common/extensible#/definitions/@context"
},
{
"$ref": "#/definitions/commerce"
}
],
"meta:status": "stable",
"examples": [
{
"xdm:order": {
"xdm:purchaseID": "a8g784hjq1mnp3",
"xdm:purchaseOrderNumber": "123456",
"xdm:payments": [
{
"xdm:transactionID": "transactid-a111",
"xdm:paymentAmount": 899.99,
"xdm:paymentType": "credit_card",
"xdm:currencyCode": "USD"
},
{
"xdm:transactionID": "transactid-a222",
"xdm:paymentAmount": 99.99,
"xdm:paymentType": "gift_card",
"xdm:currencyCode": "USD"
}
],
"xdm:currencyCode": "USD",
"xdm:priceTotal": 999.98
},
"xdm:purchases": {
"xdm:value": 1
}
}
]
}