@eventcatalog/create-eventcatalog 4.1.3 → 4.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (189) hide show
  1. package/dist/index.js +510 -539
  2. package/package.json +9 -6
  3. package/templates/amazon-api-gateway/README-template.md +4 -8
  4. package/templates/amazon-api-gateway/eventcatalog.auth.js +4 -5
  5. package/templates/amazon-api-gateway/eventcatalog.config.js +16 -11
  6. package/templates/amazon-api-gateway/eventcatalog.styles.css +1 -1
  7. package/templates/analytics.ts +8 -8
  8. package/templates/asyncapi/asyncapi-files/messages/user-signed-up.yml +1 -1
  9. package/templates/asyncapi/asyncapi-files/user-service.yml +1 -1
  10. package/templates/asyncapi/eventcatalog.auth.js +4 -5
  11. package/templates/asyncapi/eventcatalog.config.js +16 -9
  12. package/templates/asyncapi/eventcatalog.styles.css +1 -1
  13. package/templates/asyncapi/teams/order-management.mdx +6 -6
  14. package/templates/asyncapi/teams/user-management.mdx +4 -4
  15. package/templates/asyncapi/users/aSmith.mdx +0 -1
  16. package/templates/asyncapi/users/alee.mdx +1 -1
  17. package/templates/asyncapi/users/azhang.mdx +1 -1
  18. package/templates/asyncapi/users/dboyne.mdx +4 -3
  19. package/templates/asyncapi/users/dkim.mdx +1 -1
  20. package/templates/asyncapi/users/jbrown.mdx +1 -1
  21. package/templates/asyncapi/users/mSmith.mdx +2 -2
  22. package/templates/confluent/README-template.md +4 -8
  23. package/templates/confluent/eventcatalog.auth.js +4 -5
  24. package/templates/confluent/eventcatalog.config.js +7 -8
  25. package/templates/confluent/eventcatalog.styles.css +1 -1
  26. package/templates/default/channels/inventory.{env}.events/index.mdx +10 -8
  27. package/templates/default/channels/orders.{env}.events/index.mdx +5 -3
  28. package/templates/default/channels/payment.{env}.events/index.mdx +14 -13
  29. package/templates/default/domains/E-Commerce/index.mdx +32 -20
  30. package/templates/default/domains/E-Commerce/ubiquitous-language.mdx +9 -9
  31. package/templates/default/domains/Orders/changelog.mdx +1 -1
  32. package/templates/default/domains/Orders/entities/CartItem/index.mdx +15 -14
  33. package/templates/default/domains/Orders/entities/Customer/index.mdx +5 -5
  34. package/templates/default/domains/Orders/entities/Order/index.mdx +9 -9
  35. package/templates/default/domains/Orders/entities/OrderItem/index.mdx +6 -5
  36. package/templates/default/domains/Orders/entities/ShoppingCart/index.mdx +16 -15
  37. package/templates/default/domains/Orders/index.mdx +22 -7
  38. package/templates/default/domains/Orders/services/InventoryService/changelog.mdx +1 -1
  39. package/templates/default/domains/Orders/services/InventoryService/commands/AddInventory/index.mdx +2 -5
  40. package/templates/default/domains/Orders/services/InventoryService/commands/AddInventory/schema.json +26 -27
  41. package/templates/default/domains/Orders/services/InventoryService/commands/PlaceOrder/index.mdx +10 -12
  42. package/templates/default/domains/Orders/services/InventoryService/commands/UpdateInventory/index.mdx +1 -1
  43. package/templates/default/domains/Orders/services/InventoryService/commands/UpdateInventory/schema.json +26 -27
  44. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/changelog.mdx +3 -4
  45. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/index.mdx +14 -4
  46. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/0.0.1/changelog.mdx +3 -7
  47. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/0.0.1/index.mdx +8 -5
  48. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/1.0.0/changelog.mdx +11 -11
  49. package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/1.0.0/index.mdx +15 -12
  50. package/templates/default/domains/Orders/services/InventoryService/events/OutOfStock/index.mdx +1 -0
  51. package/templates/default/domains/Orders/services/InventoryService/events/OutOfStock/versioned/0.0.1/index.mdx +13 -12
  52. package/templates/default/domains/Orders/services/InventoryService/index.mdx +40 -21
  53. package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryList/index.mdx +5 -5
  54. package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryList/schema.json +48 -49
  55. package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryStatus/index.mdx +6 -7
  56. package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryStatus/schema.json +25 -26
  57. package/templates/default/domains/Orders/services/NotificationService/index.mdx +29 -10
  58. package/templates/default/domains/Orders/services/NotificationService/queries/GetNotificationDetails/index.mdx +4 -4
  59. package/templates/default/domains/Orders/services/NotificationService/queries/GetNotificationDetails/schema.json +0 -1
  60. package/templates/default/domains/Orders/services/NotificationService/queries/GetUserNotifications/index.mdx +4 -5
  61. package/templates/default/domains/Orders/services/NotificationService/queries/GetUserNotifications/schema.json +43 -44
  62. package/templates/default/domains/Orders/services/OrdersService/changelog.mdx +1 -1
  63. package/templates/default/domains/Orders/services/OrdersService/events/OrderAmended/schema.json +66 -67
  64. package/templates/default/domains/Orders/services/OrdersService/events/OrderCancelled/index.mdx +1 -2
  65. package/templates/default/domains/Orders/services/OrdersService/events/OrderCancelled/schema.json +67 -68
  66. package/templates/default/domains/Orders/services/OrdersService/events/OrderConfirmed/index.mdx +1 -1
  67. package/templates/default/domains/Orders/services/OrdersService/events/OrderConfirmed/schema.json +62 -63
  68. package/templates/default/domains/Orders/services/OrdersService/index.mdx +26 -6
  69. package/templates/default/domains/Orders/services/OrdersService/openapi.yml +3 -3
  70. package/templates/default/domains/Orders/services/OrdersService/order-service-asyncapi.yaml +11 -11
  71. package/templates/default/domains/Orders/services/OrdersService/queries/GetOrder/index.mdx +5 -5
  72. package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/changelog.mdx +1 -1
  73. package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/index.mdx +1 -1
  74. package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/openapi.yml +1 -1
  75. package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/order-service-asyncapi.yaml +11 -11
  76. package/templates/default/domains/Orders/services/ShippingService/commands/CancelShipment/index.mdx +1 -2
  77. package/templates/default/domains/Orders/services/ShippingService/commands/CancelShipment/schema.json +12 -12
  78. package/templates/default/domains/Orders/services/ShippingService/commands/CreateReturnLabel/index.mdx +2 -2
  79. package/templates/default/domains/Orders/services/ShippingService/commands/CreateReturnLabel/schema.json +17 -17
  80. package/templates/default/domains/Orders/services/ShippingService/commands/CreateShipment/index.mdx +2 -2
  81. package/templates/default/domains/Orders/services/ShippingService/commands/UpdateShipmentStatus/index.mdx +2 -2
  82. package/templates/default/domains/Orders/services/ShippingService/commands/UpdateShipmentStatus/schema.json +26 -26
  83. package/templates/default/domains/Orders/services/ShippingService/events/DeliveryFailed/index.mdx +2 -2
  84. package/templates/default/domains/Orders/services/ShippingService/events/DeliveryFailed/schema.json +15 -15
  85. package/templates/default/domains/Orders/services/ShippingService/events/ReturnInitiated/index.mdx +2 -2
  86. package/templates/default/domains/Orders/services/ShippingService/events/ReturnInitiated/schema.json +15 -15
  87. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentCreated/index.mdx +2 -2
  88. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentCreated/schema.json +0 -1
  89. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDelivered/index.mdx +2 -2
  90. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDelivered/schema.json +15 -15
  91. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDispatched/index.mdx +2 -2
  92. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDispatched/schema.json +15 -15
  93. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentInTransit/index.mdx +2 -2
  94. package/templates/default/domains/Orders/services/ShippingService/events/ShipmentInTransit/schema.json +15 -15
  95. package/templates/default/domains/Orders/services/ShippingService/index.mdx +14 -5
  96. package/templates/default/domains/Orders/ubiquitous-language.mdx +10 -10
  97. package/templates/default/domains/Orders/versioned/0.0.1/index.mdx +7 -7
  98. package/templates/default/domains/Orders/versioned/0.0.2/index.mdx +3 -3
  99. package/templates/default/domains/Payment/entities/Address/index.mdx +17 -16
  100. package/templates/default/domains/Payment/entities/Invoice/index.mdx +8 -7
  101. package/templates/default/domains/Payment/entities/Payment/index.mdx +15 -14
  102. package/templates/default/domains/Payment/entities/PaymentMethod/index.mdx +8 -7
  103. package/templates/default/domains/Payment/entities/Transaction/index.mdx +6 -5
  104. package/templates/default/domains/Payment/flows/PaymentProcessed/index.mdx +71 -70
  105. package/templates/default/domains/Payment/index.mdx +10 -10
  106. package/templates/default/domains/Payment/services/FraudDetectionService/events/FraudCheckCompleted/index.mdx +2 -2
  107. package/templates/default/domains/Payment/services/FraudDetectionService/events/FraudCheckCompleted/schema.json +1 -1
  108. package/templates/default/domains/Payment/services/FraudDetectionService/index.mdx +3 -2
  109. package/templates/default/domains/Payment/services/PaymentGatewayService/commands/ProcessPayment/index.mdx +4 -3
  110. package/templates/default/domains/Payment/services/PaymentGatewayService/commands/ProcessPayment/schema.json +1 -1
  111. package/templates/default/domains/Payment/services/PaymentGatewayService/events/PaymentFailed/index.mdx +4 -2
  112. package/templates/default/domains/Payment/services/PaymentGatewayService/events/PaymentFailed/schema.json +1 -1
  113. package/templates/default/domains/Payment/services/PaymentGatewayService/index.mdx +3 -2
  114. package/templates/default/domains/Payment/services/PaymentService/events/PaymentInitiated/index.mdx +1 -1
  115. package/templates/default/domains/Payment/services/PaymentService/events/PaymentProcessed/index.mdx +1 -1
  116. package/templates/default/domains/Payment/services/PaymentService/events/PaymentProcessed/versioned/0.0.1/index.mdx +3 -3
  117. package/templates/default/domains/Payment/services/PaymentService/index.mdx +1 -0
  118. package/templates/default/domains/Payment/services/PaymentService/queries/GetPaymentStatus/index.mdx +5 -5
  119. package/templates/default/domains/Payment/services/PaymentService/queries/GetPaymentStatus/schema.json +0 -1
  120. package/templates/default/domains/Payment/ubiquitous-language.mdx +8 -8
  121. package/templates/default/domains/ProductCatalog/entities/Category/index.mdx +10 -9
  122. package/templates/default/domains/ProductCatalog/entities/Inventory/index.mdx +15 -14
  123. package/templates/default/domains/ProductCatalog/entities/Product/index.mdx +11 -10
  124. package/templates/default/domains/ProductCatalog/entities/Review/index.mdx +15 -14
  125. package/templates/default/domains/ProductCatalog/index.mdx +8 -6
  126. package/templates/default/domains/ProductCatalog/ubiquitous-language.mdx +10 -10
  127. package/templates/default/domains/Subscriptions/entities/BillingProfile/index.mdx +8 -7
  128. package/templates/default/domains/Subscriptions/entities/SubscriptionPeriod/index.mdx +8 -7
  129. package/templates/default/domains/Subscriptions/flows/CancelSubscription/SubscriptionRenewed/index.mdx +207 -208
  130. package/templates/default/domains/Subscriptions/flows/CancelSubscription/index.mdx +48 -49
  131. package/templates/default/domains/Subscriptions/flows/CancelSubscription/versioned/0.0.1/index.mdx +36 -36
  132. package/templates/default/domains/Subscriptions/index.mdx +10 -10
  133. package/templates/default/domains/Subscriptions/services/BillingService/events/SubscriptionPaymentDue/index.mdx +3 -2
  134. package/templates/default/domains/Subscriptions/services/BillingService/events/SubscriptionPaymentDue/schema.json +1 -1
  135. package/templates/default/domains/Subscriptions/services/BillingService/index.mdx +2 -1
  136. package/templates/default/domains/Subscriptions/services/PlanManagementService/index.mdx +6 -2
  137. package/templates/default/domains/Subscriptions/services/SubscriptionService/commands/CancelSubscription/index.mdx +5 -5
  138. package/templates/default/domains/Subscriptions/services/SubscriptionService/commands/SubscribeUser/index.mdx +5 -5
  139. package/templates/default/domains/Subscriptions/services/SubscriptionService/events/UserSubscriptionCancelled/index.mdx +5 -5
  140. package/templates/default/domains/Subscriptions/services/SubscriptionService/events/UserSubscriptionStarted/index.mdx +5 -5
  141. package/templates/default/domains/Subscriptions/services/SubscriptionService/index.mdx +30 -10
  142. package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/index.mdx +5 -5
  143. package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/schema.json +10 -2
  144. package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/versioned/0.0.1/index.mdx +5 -5
  145. package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/versioned/0.0.1/schema.json +10 -2
  146. package/templates/default/domains/Subscriptions/ubiquitous-language.mdx +9 -9
  147. package/templates/default/eventcatalog.auth.js +4 -5
  148. package/templates/default/eventcatalog.config.js +6 -8
  149. package/templates/default/eventcatalog.styles.css +1 -1
  150. package/templates/default/teams/full-stack.mdx +4 -4
  151. package/templates/default/teams/mobile-devs.mdx +4 -2
  152. package/templates/default/users/aSmith.mdx +0 -1
  153. package/templates/default/users/dboyne.mdx +4 -3
  154. package/templates/default/users/mSmith.mdx +2 -2
  155. package/templates/empty/eventcatalog.auth.js +4 -5
  156. package/templates/empty/eventcatalog.config.js +6 -7
  157. package/templates/empty/eventcatalog.styles.css +1 -1
  158. package/templates/eventbridge/README-template.md +4 -8
  159. package/templates/eventbridge/eventcatalog.auth.js +4 -5
  160. package/templates/eventbridge/eventcatalog.config.js +7 -8
  161. package/templates/eventbridge/eventcatalog.styles.css +1 -1
  162. package/templates/graphql/eventcatalog.auth.js +4 -5
  163. package/templates/graphql/eventcatalog.config.js +29 -20
  164. package/templates/graphql/eventcatalog.styles.css +1 -1
  165. package/templates/graphql/teams/order-management.mdx +6 -6
  166. package/templates/graphql/teams/payment-management.mdx +4 -4
  167. package/templates/graphql/teams/product-management.mdx +4 -4
  168. package/templates/graphql/users/aSmith.mdx +0 -1
  169. package/templates/graphql/users/alee.mdx +1 -1
  170. package/templates/graphql/users/azhang.mdx +1 -1
  171. package/templates/graphql/users/dboyne.mdx +4 -3
  172. package/templates/graphql/users/dkim.mdx +1 -1
  173. package/templates/graphql/users/jbrown.mdx +1 -1
  174. package/templates/graphql/users/mSmith.mdx +2 -2
  175. package/templates/index.ts +49 -59
  176. package/templates/openapi/eventcatalog.auth.js +4 -5
  177. package/templates/openapi/eventcatalog.config.js +33 -26
  178. package/templates/openapi/eventcatalog.styles.css +1 -1
  179. package/templates/openapi/teams/order-management.mdx +6 -6
  180. package/templates/openapi/teams/payment-management.mdx +4 -4
  181. package/templates/openapi/teams/product-management.mdx +4 -4
  182. package/templates/openapi/users/aSmith.mdx +0 -1
  183. package/templates/openapi/users/alee.mdx +1 -1
  184. package/templates/openapi/users/azhang.mdx +1 -1
  185. package/templates/openapi/users/dboyne.mdx +4 -3
  186. package/templates/openapi/users/dkim.mdx +1 -1
  187. package/templates/openapi/users/jbrown.mdx +1 -1
  188. package/templates/openapi/users/mSmith.mdx +2 -2
  189. package/templates/types.ts +12 -3
@@ -35,14 +35,33 @@ import Footer from '@catalog/components/footer.astro';
35
35
 
36
36
  The Notification Service is responsible for managing and delivering notifications to users and other services. It supports various notification channels such as email, SMS, push notifications, and in-app notifications. The service ensures reliable and timely delivery of messages and integrates with other services to trigger notifications based on specific events.
37
37
 
38
- <Tiles >
39
- <Tile icon="DocumentIcon" href={`/docs/services/${frontmatter.id}/${frontmatter.version}/changelog`} title="View the changelog" description="Want to know the history of this service? View the change logs" />
40
- <Tile icon="UserGroupIcon" href="/docs/teams/full-stack" title="Contact the team" description="Any questions? Feel free to contact the owners" />
41
- <Tile icon="BoltIcon" href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`} title={`Sends ${frontmatter.sends.length} messages`} description="This service sends messages to downstream consumers" />
42
- <Tile icon="BoltIcon" href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`} title={`Receives ${frontmatter.receives.length} messages`} description="This service receives messages from other services" />
38
+ <Tiles>
39
+ <Tile
40
+ icon="DocumentIcon"
41
+ href={`/docs/services/${frontmatter.id}/${frontmatter.version}/changelog`}
42
+ title="View the changelog"
43
+ description="Want to know the history of this service? View the change logs"
44
+ />
45
+ <Tile
46
+ icon="UserGroupIcon"
47
+ href="/docs/teams/full-stack"
48
+ title="Contact the team"
49
+ description="Any questions? Feel free to contact the owners"
50
+ />
51
+ <Tile
52
+ icon="BoltIcon"
53
+ href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`}
54
+ title={`Sends ${frontmatter.sends.length} messages`}
55
+ description="This service sends messages to downstream consumers"
56
+ />
57
+ <Tile
58
+ icon="BoltIcon"
59
+ href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`}
60
+ title={`Receives ${frontmatter.receives.length} messages`}
61
+ description="This service receives messages from other services"
62
+ />
43
63
  </Tiles>
44
64
 
45
-
46
65
  ## Architecture diagram
47
66
 
48
67
  <NodeGraph />
@@ -51,12 +70,12 @@ The Notification Service is responsible for managing and delivering notification
51
70
 
52
71
  <AccordionGroup>
53
72
  <Accordion title="Notification">
54
- - Description: A message that is sent to a user or a service.
55
- - Attributes: notificationId, type, recipient, content, channel, status, timestamp
73
+ - Description: A message that is sent to a user or a service. - Attributes: notificationId, type, recipient, content, channel,
74
+ status, timestamp
56
75
  </Accordion>
57
76
  <Accordion title="Channel">
58
- - Description: The medium through which the notification is delivered (e.g., email, SMS, push notification).
59
- - Attributes: channelId, name, provider, configuration
77
+ - Description: The medium through which the notification is delivered (e.g., email, SMS, push notification). - Attributes:
78
+ channelId, name, provider, configuration
60
79
  </Accordion>
61
80
  </AccordionGroup>
62
81
 
@@ -5,11 +5,11 @@ version: 0.0.1
5
5
  summary: |
6
6
  GET request that will return detailed information about a specific notification, identified by its notificationId.
7
7
  owners:
8
- - dboyne
8
+ - dboyne
9
9
  badges:
10
- - content: Recently updated!
11
- backgroundColor: green
12
- textColor: green
10
+ - content: Recently updated!
11
+ backgroundColor: green
12
+ textColor: green
13
13
  schemaPath: schema.json
14
14
  ---
15
15
 
@@ -1,4 +1,3 @@
1
-
2
1
  {
3
2
  "$schema": "http://json-schema.org/draft-07/schema#",
4
3
  "title": "GetNotificationDetailsResponse",
@@ -5,11 +5,11 @@ version: 0.0.1
5
5
  summary: |
6
6
  GET request that will return a list of notifications for a specific user, with options to filter by status (unread or all).
7
7
  owners:
8
- - dboyne
8
+ - dboyne
9
9
  badges:
10
- - content: Recently updated!
11
- backgroundColor: green
12
- textColor: green
10
+ - content: Recently updated!
11
+ backgroundColor: green
12
+ textColor: green
13
13
  schemaPath: schema.json
14
14
  ---
15
15
 
@@ -24,4 +24,3 @@ Use cases include delivering notifications for order updates, promotional campai
24
24
  <NodeGraph />
25
25
 
26
26
  <SchemaViewer file="schema.json" title="JSON Schema" maxHeight="500" />
27
-
@@ -1,47 +1,46 @@
1
1
  {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "GetUserNotificationsResponse",
4
- "type": "object",
5
- "properties": {
6
- "userId": {
7
- "type": "string",
8
- "description": "The unique identifier for the user."
9
- },
10
- "notifications": {
11
- "type": "array",
12
- "description": "A list of notifications for the user.",
13
- "items": {
14
- "type": "object",
15
- "properties": {
16
- "notificationId": {
17
- "type": "string",
18
- "description": "The unique identifier for the notification."
19
- },
20
- "title": {
21
- "type": "string",
22
- "description": "The title or subject of the notification."
23
- },
24
- "message": {
25
- "type": "string",
26
- "description": "The message body of the notification."
27
- },
28
- "status": {
29
- "type": "string",
30
- "enum": ["unread", "read"],
31
- "description": "The read status of the notification."
32
- },
33
- "createdAt": {
34
- "type": "string",
35
- "format": "date-time",
36
- "description": "The date and time when the notification was created."
37
- }
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "GetUserNotificationsResponse",
4
+ "type": "object",
5
+ "properties": {
6
+ "userId": {
7
+ "type": "string",
8
+ "description": "The unique identifier for the user."
9
+ },
10
+ "notifications": {
11
+ "type": "array",
12
+ "description": "A list of notifications for the user.",
13
+ "items": {
14
+ "type": "object",
15
+ "properties": {
16
+ "notificationId": {
17
+ "type": "string",
18
+ "description": "The unique identifier for the notification."
19
+ },
20
+ "title": {
21
+ "type": "string",
22
+ "description": "The title or subject of the notification."
23
+ },
24
+ "message": {
25
+ "type": "string",
26
+ "description": "The message body of the notification."
38
27
  },
39
- "required": ["notificationId", "title", "message", "status", "createdAt"],
40
- "additionalProperties": false
41
- }
28
+ "status": {
29
+ "type": "string",
30
+ "enum": ["unread", "read"],
31
+ "description": "The read status of the notification."
32
+ },
33
+ "createdAt": {
34
+ "type": "string",
35
+ "format": "date-time",
36
+ "description": "The date and time when the notification was created."
37
+ }
38
+ },
39
+ "required": ["notificationId", "title", "message", "status", "createdAt"],
40
+ "additionalProperties": false
42
41
  }
43
- },
44
- "required": ["userId", "notifications"],
45
- "additionalProperties": false
46
- }
47
-
42
+ }
43
+ },
44
+ "required": ["userId", "notifications"],
45
+ "additionalProperties": false
46
+ }
@@ -1,3 +1,3 @@
1
1
  ---
2
2
  createdAt: 2024-08-01
3
- ---
3
+ ---
@@ -1,71 +1,70 @@
1
1
  {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "OrderAmendedEvent",
4
- "type": "object",
5
- "properties": {
6
- "orderId": {
7
- "type": "string",
8
- "format": "uuid",
9
- "description": "The unique identifier of the order that was amended."
10
- },
11
- "userId": {
12
- "type": "string",
13
- "format": "uuid",
14
- "description": "The unique identifier of the user who placed the order."
15
- },
16
- "amendedItems": {
17
- "type": "array",
18
- "description": "A list of items that were amended in the order, each containing product details and updated quantities.",
19
- "items": {
20
- "type": "object",
21
- "properties": {
22
- "productId": {
23
- "type": "string",
24
- "format": "uuid",
25
- "description": "The unique identifier of the product."
26
- },
27
- "productName": {
28
- "type": "string",
29
- "description": "The name of the product."
30
- },
31
- "oldQuantity": {
32
- "type": "integer",
33
- "description": "The original quantity of the product ordered."
34
- },
35
- "newQuantity": {
36
- "type": "integer",
37
- "description": "The new quantity of the product ordered."
38
- },
39
- "unitPrice": {
40
- "type": "number",
41
- "format": "float",
42
- "description": "The price per unit of the product."
43
- },
44
- "totalPrice": {
45
- "type": "number",
46
- "format": "float",
47
- "description": "The total price for this order item (newQuantity * unitPrice)."
48
- }
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "OrderAmendedEvent",
4
+ "type": "object",
5
+ "properties": {
6
+ "orderId": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "description": "The unique identifier of the order that was amended."
10
+ },
11
+ "userId": {
12
+ "type": "string",
13
+ "format": "uuid",
14
+ "description": "The unique identifier of the user who placed the order."
15
+ },
16
+ "amendedItems": {
17
+ "type": "array",
18
+ "description": "A list of items that were amended in the order, each containing product details and updated quantities.",
19
+ "items": {
20
+ "type": "object",
21
+ "properties": {
22
+ "productId": {
23
+ "type": "string",
24
+ "format": "uuid",
25
+ "description": "The unique identifier of the product."
26
+ },
27
+ "productName": {
28
+ "type": "string",
29
+ "description": "The name of the product."
30
+ },
31
+ "oldQuantity": {
32
+ "type": "integer",
33
+ "description": "The original quantity of the product ordered."
49
34
  },
50
- "required": ["productId", "productName", "oldQuantity", "newQuantity", "unitPrice", "totalPrice"]
51
- }
52
- },
53
- "orderStatus": {
54
- "type": "string",
55
- "description": "The current status of the order after the amendment."
56
- },
57
- "totalAmount": {
58
- "type": "number",
59
- "format": "float",
60
- "description": "The total amount of the order after the amendment."
61
- },
62
- "timestamp": {
63
- "type": "string",
64
- "format": "date-time",
65
- "description": "The date and time when the order was amended, in ISO 8601 format."
35
+ "newQuantity": {
36
+ "type": "integer",
37
+ "description": "The new quantity of the product ordered."
38
+ },
39
+ "unitPrice": {
40
+ "type": "number",
41
+ "format": "float",
42
+ "description": "The price per unit of the product."
43
+ },
44
+ "totalPrice": {
45
+ "type": "number",
46
+ "format": "float",
47
+ "description": "The total price for this order item (newQuantity * unitPrice)."
48
+ }
49
+ },
50
+ "required": ["productId", "productName", "oldQuantity", "newQuantity", "unitPrice", "totalPrice"]
66
51
  }
67
52
  },
68
- "required": ["orderId", "userId", "amendedItems", "orderStatus", "totalAmount", "timestamp"],
69
- "additionalProperties": false
70
- }
71
-
53
+ "orderStatus": {
54
+ "type": "string",
55
+ "description": "The current status of the order after the amendment."
56
+ },
57
+ "totalAmount": {
58
+ "type": "number",
59
+ "format": "float",
60
+ "description": "The total amount of the order after the amendment."
61
+ },
62
+ "timestamp": {
63
+ "type": "string",
64
+ "format": "date-time",
65
+ "description": "The date and time when the order was amended, in ISO 8601 format."
66
+ }
67
+ },
68
+ "required": ["orderId", "userId", "amendedItems", "orderStatus", "totalAmount", "timestamp"],
69
+ "additionalProperties": false
70
+ }
@@ -43,13 +43,12 @@ The OrderCancelled event is triggered whenever an existing order is cancelled. T
43
43
  "cancellationReason": "Customer requested cancellation",
44
44
  "timestamp": "2024-07-04T14:48:00Z"
45
45
  }
46
-
47
46
  ```
48
47
 
49
48
  ## Schema
50
49
 
51
50
  JSON schema for the event.
52
51
 
53
- <Schema title="JSON Schema" file="schema.json"/>
52
+ <Schema title="JSON Schema" file="schema.json" />
54
53
 
55
54
  <Footer />
@@ -1,72 +1,71 @@
1
1
  {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "OrderCancelledEvent",
4
- "type": "object",
5
- "properties": {
6
- "orderId": {
7
- "type": "string",
8
- "format": "uuid",
9
- "description": "The unique identifier of the order that was cancelled."
10
- },
11
- "userId": {
12
- "type": "string",
13
- "format": "uuid",
14
- "description": "The unique identifier of the user who placed the order."
15
- },
16
- "orderItems": {
17
- "type": "array",
18
- "description": "A list of items included in the cancelled order, each containing product details and quantities.",
19
- "items": {
20
- "type": "object",
21
- "properties": {
22
- "productId": {
23
- "type": "string",
24
- "format": "uuid",
25
- "description": "The unique identifier of the product."
26
- },
27
- "productName": {
28
- "type": "string",
29
- "description": "The name of the product."
30
- },
31
- "quantity": {
32
- "type": "integer",
33
- "description": "The quantity of the product ordered."
34
- },
35
- "unitPrice": {
36
- "type": "number",
37
- "format": "float",
38
- "description": "The price per unit of the product."
39
- },
40
- "totalPrice": {
41
- "type": "number",
42
- "format": "float",
43
- "description": "The total price for this order item (quantity * unit price)."
44
- }
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "OrderCancelledEvent",
4
+ "type": "object",
5
+ "properties": {
6
+ "orderId": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "description": "The unique identifier of the order that was cancelled."
10
+ },
11
+ "userId": {
12
+ "type": "string",
13
+ "format": "uuid",
14
+ "description": "The unique identifier of the user who placed the order."
15
+ },
16
+ "orderItems": {
17
+ "type": "array",
18
+ "description": "A list of items included in the cancelled order, each containing product details and quantities.",
19
+ "items": {
20
+ "type": "object",
21
+ "properties": {
22
+ "productId": {
23
+ "type": "string",
24
+ "format": "uuid",
25
+ "description": "The unique identifier of the product."
26
+ },
27
+ "productName": {
28
+ "type": "string",
29
+ "description": "The name of the product."
30
+ },
31
+ "quantity": {
32
+ "type": "integer",
33
+ "description": "The quantity of the product ordered."
45
34
  },
46
- "required": ["productId", "productName", "quantity", "unitPrice", "totalPrice"]
47
- }
48
- },
49
- "orderStatus": {
50
- "type": "string",
51
- "description": "The current status of the order after cancellation.",
52
- "enum": ["cancelled"]
53
- },
54
- "totalAmount": {
55
- "type": "number",
56
- "format": "float",
57
- "description": "The total amount of the order that was cancelled."
58
- },
59
- "cancellationReason": {
60
- "type": "string",
61
- "description": "The reason for the order cancellation, if provided."
62
- },
63
- "timestamp": {
64
- "type": "string",
65
- "format": "date-time",
66
- "description": "The date and time when the order was cancelled."
35
+ "unitPrice": {
36
+ "type": "number",
37
+ "format": "float",
38
+ "description": "The price per unit of the product."
39
+ },
40
+ "totalPrice": {
41
+ "type": "number",
42
+ "format": "float",
43
+ "description": "The total price for this order item (quantity * unit price)."
44
+ }
45
+ },
46
+ "required": ["productId", "productName", "quantity", "unitPrice", "totalPrice"]
67
47
  }
68
48
  },
69
- "required": ["orderId", "userId", "orderItems", "orderStatus", "totalAmount", "timestamp"],
70
- "additionalProperties": false
71
- }
72
-
49
+ "orderStatus": {
50
+ "type": "string",
51
+ "description": "The current status of the order after cancellation.",
52
+ "enum": ["cancelled"]
53
+ },
54
+ "totalAmount": {
55
+ "type": "number",
56
+ "format": "float",
57
+ "description": "The total amount of the order that was cancelled."
58
+ },
59
+ "cancellationReason": {
60
+ "type": "string",
61
+ "description": "The reason for the order cancellation, if provided."
62
+ },
63
+ "timestamp": {
64
+ "type": "string",
65
+ "format": "date-time",
66
+ "description": "The date and time when the order was cancelled."
67
+ }
68
+ },
69
+ "required": ["orderId", "userId", "orderItems", "orderStatus", "totalAmount", "timestamp"],
70
+ "additionalProperties": false
71
+ }
@@ -50,6 +50,6 @@ The OrderConfirmed event is triggered when an order has been successfully confir
50
50
 
51
51
  ## Schema
52
52
 
53
- <Schema file="schema.json"/>
53
+ <Schema file="schema.json" />
54
54
 
55
55
  <Footer />
@@ -1,67 +1,66 @@
1
1
  {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "OrderConfirmedEvent",
4
- "type": "object",
5
- "properties": {
6
- "orderId": {
7
- "type": "string",
8
- "format": "uuid",
9
- "description": "The unique identifier of the confirmed order."
10
- },
11
- "userId": {
12
- "type": "string",
13
- "format": "uuid",
14
- "description": "The unique identifier of the user who placed the order."
15
- },
16
- "orderItems": {
17
- "type": "array",
18
- "description": "A list of items included in the confirmed order, each containing product details and quantities.",
19
- "items": {
20
- "type": "object",
21
- "properties": {
22
- "productId": {
23
- "type": "string",
24
- "format": "uuid",
25
- "description": "The unique identifier of the product."
26
- },
27
- "productName": {
28
- "type": "string",
29
- "description": "The name of the product."
30
- },
31
- "quantity": {
32
- "type": "integer",
33
- "description": "The quantity of the product ordered."
34
- },
35
- "unitPrice": {
36
- "type": "number",
37
- "format": "float",
38
- "description": "The price per unit of the product."
39
- },
40
- "totalPrice": {
41
- "type": "number",
42
- "format": "float",
43
- "description": "The total price for this order item (quantity * unitPrice)."
44
- }
2
+ "$schema": "http://json-schema.org/draft-07/schema#",
3
+ "title": "OrderConfirmedEvent",
4
+ "type": "object",
5
+ "properties": {
6
+ "orderId": {
7
+ "type": "string",
8
+ "format": "uuid",
9
+ "description": "The unique identifier of the confirmed order."
10
+ },
11
+ "userId": {
12
+ "type": "string",
13
+ "format": "uuid",
14
+ "description": "The unique identifier of the user who placed the order."
15
+ },
16
+ "orderItems": {
17
+ "type": "array",
18
+ "description": "A list of items included in the confirmed order, each containing product details and quantities.",
19
+ "items": {
20
+ "type": "object",
21
+ "properties": {
22
+ "productId": {
23
+ "type": "string",
24
+ "format": "uuid",
25
+ "description": "The unique identifier of the product."
26
+ },
27
+ "productName": {
28
+ "type": "string",
29
+ "description": "The name of the product."
30
+ },
31
+ "quantity": {
32
+ "type": "integer",
33
+ "description": "The quantity of the product ordered."
45
34
  },
46
- "required": ["productId", "productName", "quantity", "unitPrice", "totalPrice"]
47
- }
48
- },
49
- "orderStatus": {
50
- "type": "string",
51
- "description": "The current status of the order after confirmation."
52
- },
53
- "totalAmount": {
54
- "type": "number",
55
- "format": "float",
56
- "description": "The total amount of the confirmed order."
57
- },
58
- "confirmationTimestamp": {
59
- "type": "string",
60
- "format": "date-time",
61
- "description": "The date and time when the order was confirmed."
35
+ "unitPrice": {
36
+ "type": "number",
37
+ "format": "float",
38
+ "description": "The price per unit of the product."
39
+ },
40
+ "totalPrice": {
41
+ "type": "number",
42
+ "format": "float",
43
+ "description": "The total price for this order item (quantity * unitPrice)."
44
+ }
45
+ },
46
+ "required": ["productId", "productName", "quantity", "unitPrice", "totalPrice"]
62
47
  }
63
48
  },
64
- "required": ["orderId", "userId", "orderItems", "orderStatus", "totalAmount", "confirmationTimestamp"],
65
- "additionalProperties": false
66
- }
67
-
49
+ "orderStatus": {
50
+ "type": "string",
51
+ "description": "The current status of the order after confirmation."
52
+ },
53
+ "totalAmount": {
54
+ "type": "number",
55
+ "format": "float",
56
+ "description": "The total amount of the confirmed order."
57
+ },
58
+ "confirmationTimestamp": {
59
+ "type": "string",
60
+ "format": "date-time",
61
+ "description": "The date and time when the order was confirmed."
62
+ }
63
+ },
64
+ "required": ["orderId", "userId", "orderItems", "orderStatus", "totalAmount", "confirmationTimestamp"],
65
+ "additionalProperties": false
66
+ }