avro icon

Order confirmed

v0.0.1events

Indicates an order has been confirmed

1{
2  "type": "record",
3  "name": "OrderConfirmedEvent",
4  "namespace": "com.example.events",
5  "doc": "Event emitted when an order has been confirmed.",
6  "fields": [
7    {
8      "name": "orderId",
9      "type": "string",
10      "doc": "The unique identifier of the confirmed order."
11    },
12    {
13      "name": "userId",
14      "type": "string",
15      "doc": "The unique identifier of the user who placed the order."
16    },
17    {
18      "name": "orderItems",
19      "type": {
20        "type": "array",
21        "items": {
22          "type": "record",
23          "name": "OrderItem",
24          "fields": [
25            {
26              "name": "productId",
27              "type": "string",
28              "doc": "The unique identifier of the product."
29            },
30            {
31              "name": "productName",
32              "type": "string",
33              "doc": "The name of the product."
34            },
35            {
36              "name": "quantity",
37              "type": "int",
38              "doc": "The quantity of the product ordered."
39            },
40            {
41              "name": "unitPrice",
42              "type": "double",
43              "doc": "The price per unit of the product."
44            },
45            {
46              "name": "totalPrice",
47              "type": "double",
48              "doc": "The total price for this order item (quantity * unitPrice)."
49            }
50          ]
51        }
52      },
53      "doc": "A list of items included in the confirmed order."
54    },
55    {
56      "name": "orderStatus",
57      "type": "string",
58      "doc": "The current status of the order after confirmation."
59    },
60    {
61      "name": "totalAmount",
62      "type": "double",
63      "doc": "The total amount of the confirmed order."
64    },
65    {
66      "name": "confirmationTimestamp",
67      "type": {
68        "type": "long",
69        "logicalType": "timestamp-millis"
70      },
71      "doc": "The date and time when the order was confirmed."
72    }
73  ]
74}
75

Details

Format
Avro
Resource
events
Filename
schema.avro

Versions