@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.
- package/dist/index.js +510 -539
- package/package.json +9 -6
- package/templates/amazon-api-gateway/README-template.md +4 -8
- package/templates/amazon-api-gateway/eventcatalog.auth.js +4 -5
- package/templates/amazon-api-gateway/eventcatalog.config.js +16 -11
- package/templates/amazon-api-gateway/eventcatalog.styles.css +1 -1
- package/templates/analytics.ts +8 -8
- package/templates/asyncapi/asyncapi-files/messages/user-signed-up.yml +1 -1
- package/templates/asyncapi/asyncapi-files/user-service.yml +1 -1
- package/templates/asyncapi/eventcatalog.auth.js +4 -5
- package/templates/asyncapi/eventcatalog.config.js +16 -9
- package/templates/asyncapi/eventcatalog.styles.css +1 -1
- package/templates/asyncapi/teams/order-management.mdx +6 -6
- package/templates/asyncapi/teams/user-management.mdx +4 -4
- package/templates/asyncapi/users/aSmith.mdx +0 -1
- package/templates/asyncapi/users/alee.mdx +1 -1
- package/templates/asyncapi/users/azhang.mdx +1 -1
- package/templates/asyncapi/users/dboyne.mdx +4 -3
- package/templates/asyncapi/users/dkim.mdx +1 -1
- package/templates/asyncapi/users/jbrown.mdx +1 -1
- package/templates/asyncapi/users/mSmith.mdx +2 -2
- package/templates/confluent/README-template.md +4 -8
- package/templates/confluent/eventcatalog.auth.js +4 -5
- package/templates/confluent/eventcatalog.config.js +7 -8
- package/templates/confluent/eventcatalog.styles.css +1 -1
- package/templates/default/channels/inventory.{env}.events/index.mdx +10 -8
- package/templates/default/channels/orders.{env}.events/index.mdx +5 -3
- package/templates/default/channels/payment.{env}.events/index.mdx +14 -13
- package/templates/default/domains/E-Commerce/index.mdx +32 -20
- package/templates/default/domains/E-Commerce/ubiquitous-language.mdx +9 -9
- package/templates/default/domains/Orders/changelog.mdx +1 -1
- package/templates/default/domains/Orders/entities/CartItem/index.mdx +15 -14
- package/templates/default/domains/Orders/entities/Customer/index.mdx +5 -5
- package/templates/default/domains/Orders/entities/Order/index.mdx +9 -9
- package/templates/default/domains/Orders/entities/OrderItem/index.mdx +6 -5
- package/templates/default/domains/Orders/entities/ShoppingCart/index.mdx +16 -15
- package/templates/default/domains/Orders/index.mdx +22 -7
- package/templates/default/domains/Orders/services/InventoryService/changelog.mdx +1 -1
- package/templates/default/domains/Orders/services/InventoryService/commands/AddInventory/index.mdx +2 -5
- package/templates/default/domains/Orders/services/InventoryService/commands/AddInventory/schema.json +26 -27
- package/templates/default/domains/Orders/services/InventoryService/commands/PlaceOrder/index.mdx +10 -12
- package/templates/default/domains/Orders/services/InventoryService/commands/UpdateInventory/index.mdx +1 -1
- package/templates/default/domains/Orders/services/InventoryService/commands/UpdateInventory/schema.json +26 -27
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/changelog.mdx +3 -4
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/index.mdx +14 -4
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/0.0.1/changelog.mdx +3 -7
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/0.0.1/index.mdx +8 -5
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/1.0.0/changelog.mdx +11 -11
- package/templates/default/domains/Orders/services/InventoryService/events/InventoryAdjusted/versioned/1.0.0/index.mdx +15 -12
- package/templates/default/domains/Orders/services/InventoryService/events/OutOfStock/index.mdx +1 -0
- package/templates/default/domains/Orders/services/InventoryService/events/OutOfStock/versioned/0.0.1/index.mdx +13 -12
- package/templates/default/domains/Orders/services/InventoryService/index.mdx +40 -21
- package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryList/index.mdx +5 -5
- package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryList/schema.json +48 -49
- package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryStatus/index.mdx +6 -7
- package/templates/default/domains/Orders/services/InventoryService/queries/GetInventoryStatus/schema.json +25 -26
- package/templates/default/domains/Orders/services/NotificationService/index.mdx +29 -10
- package/templates/default/domains/Orders/services/NotificationService/queries/GetNotificationDetails/index.mdx +4 -4
- package/templates/default/domains/Orders/services/NotificationService/queries/GetNotificationDetails/schema.json +0 -1
- package/templates/default/domains/Orders/services/NotificationService/queries/GetUserNotifications/index.mdx +4 -5
- package/templates/default/domains/Orders/services/NotificationService/queries/GetUserNotifications/schema.json +43 -44
- package/templates/default/domains/Orders/services/OrdersService/changelog.mdx +1 -1
- package/templates/default/domains/Orders/services/OrdersService/events/OrderAmended/schema.json +66 -67
- package/templates/default/domains/Orders/services/OrdersService/events/OrderCancelled/index.mdx +1 -2
- package/templates/default/domains/Orders/services/OrdersService/events/OrderCancelled/schema.json +67 -68
- package/templates/default/domains/Orders/services/OrdersService/events/OrderConfirmed/index.mdx +1 -1
- package/templates/default/domains/Orders/services/OrdersService/events/OrderConfirmed/schema.json +62 -63
- package/templates/default/domains/Orders/services/OrdersService/index.mdx +26 -6
- package/templates/default/domains/Orders/services/OrdersService/openapi.yml +3 -3
- package/templates/default/domains/Orders/services/OrdersService/order-service-asyncapi.yaml +11 -11
- package/templates/default/domains/Orders/services/OrdersService/queries/GetOrder/index.mdx +5 -5
- package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/changelog.mdx +1 -1
- package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/index.mdx +1 -1
- package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/openapi.yml +1 -1
- package/templates/default/domains/Orders/services/OrdersService/versioned/0.0.2/order-service-asyncapi.yaml +11 -11
- package/templates/default/domains/Orders/services/ShippingService/commands/CancelShipment/index.mdx +1 -2
- package/templates/default/domains/Orders/services/ShippingService/commands/CancelShipment/schema.json +12 -12
- package/templates/default/domains/Orders/services/ShippingService/commands/CreateReturnLabel/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/commands/CreateReturnLabel/schema.json +17 -17
- package/templates/default/domains/Orders/services/ShippingService/commands/CreateShipment/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/commands/UpdateShipmentStatus/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/commands/UpdateShipmentStatus/schema.json +26 -26
- package/templates/default/domains/Orders/services/ShippingService/events/DeliveryFailed/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/DeliveryFailed/schema.json +15 -15
- package/templates/default/domains/Orders/services/ShippingService/events/ReturnInitiated/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/ReturnInitiated/schema.json +15 -15
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentCreated/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentCreated/schema.json +0 -1
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDelivered/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDelivered/schema.json +15 -15
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDispatched/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentDispatched/schema.json +15 -15
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentInTransit/index.mdx +2 -2
- package/templates/default/domains/Orders/services/ShippingService/events/ShipmentInTransit/schema.json +15 -15
- package/templates/default/domains/Orders/services/ShippingService/index.mdx +14 -5
- package/templates/default/domains/Orders/ubiquitous-language.mdx +10 -10
- package/templates/default/domains/Orders/versioned/0.0.1/index.mdx +7 -7
- package/templates/default/domains/Orders/versioned/0.0.2/index.mdx +3 -3
- package/templates/default/domains/Payment/entities/Address/index.mdx +17 -16
- package/templates/default/domains/Payment/entities/Invoice/index.mdx +8 -7
- package/templates/default/domains/Payment/entities/Payment/index.mdx +15 -14
- package/templates/default/domains/Payment/entities/PaymentMethod/index.mdx +8 -7
- package/templates/default/domains/Payment/entities/Transaction/index.mdx +6 -5
- package/templates/default/domains/Payment/flows/PaymentProcessed/index.mdx +71 -70
- package/templates/default/domains/Payment/index.mdx +10 -10
- package/templates/default/domains/Payment/services/FraudDetectionService/events/FraudCheckCompleted/index.mdx +2 -2
- package/templates/default/domains/Payment/services/FraudDetectionService/events/FraudCheckCompleted/schema.json +1 -1
- package/templates/default/domains/Payment/services/FraudDetectionService/index.mdx +3 -2
- package/templates/default/domains/Payment/services/PaymentGatewayService/commands/ProcessPayment/index.mdx +4 -3
- package/templates/default/domains/Payment/services/PaymentGatewayService/commands/ProcessPayment/schema.json +1 -1
- package/templates/default/domains/Payment/services/PaymentGatewayService/events/PaymentFailed/index.mdx +4 -2
- package/templates/default/domains/Payment/services/PaymentGatewayService/events/PaymentFailed/schema.json +1 -1
- package/templates/default/domains/Payment/services/PaymentGatewayService/index.mdx +3 -2
- package/templates/default/domains/Payment/services/PaymentService/events/PaymentInitiated/index.mdx +1 -1
- package/templates/default/domains/Payment/services/PaymentService/events/PaymentProcessed/index.mdx +1 -1
- package/templates/default/domains/Payment/services/PaymentService/events/PaymentProcessed/versioned/0.0.1/index.mdx +3 -3
- package/templates/default/domains/Payment/services/PaymentService/index.mdx +1 -0
- package/templates/default/domains/Payment/services/PaymentService/queries/GetPaymentStatus/index.mdx +5 -5
- package/templates/default/domains/Payment/services/PaymentService/queries/GetPaymentStatus/schema.json +0 -1
- package/templates/default/domains/Payment/ubiquitous-language.mdx +8 -8
- package/templates/default/domains/ProductCatalog/entities/Category/index.mdx +10 -9
- package/templates/default/domains/ProductCatalog/entities/Inventory/index.mdx +15 -14
- package/templates/default/domains/ProductCatalog/entities/Product/index.mdx +11 -10
- package/templates/default/domains/ProductCatalog/entities/Review/index.mdx +15 -14
- package/templates/default/domains/ProductCatalog/index.mdx +8 -6
- package/templates/default/domains/ProductCatalog/ubiquitous-language.mdx +10 -10
- package/templates/default/domains/Subscriptions/entities/BillingProfile/index.mdx +8 -7
- package/templates/default/domains/Subscriptions/entities/SubscriptionPeriod/index.mdx +8 -7
- package/templates/default/domains/Subscriptions/flows/CancelSubscription/SubscriptionRenewed/index.mdx +207 -208
- package/templates/default/domains/Subscriptions/flows/CancelSubscription/index.mdx +48 -49
- package/templates/default/domains/Subscriptions/flows/CancelSubscription/versioned/0.0.1/index.mdx +36 -36
- package/templates/default/domains/Subscriptions/index.mdx +10 -10
- package/templates/default/domains/Subscriptions/services/BillingService/events/SubscriptionPaymentDue/index.mdx +3 -2
- package/templates/default/domains/Subscriptions/services/BillingService/events/SubscriptionPaymentDue/schema.json +1 -1
- package/templates/default/domains/Subscriptions/services/BillingService/index.mdx +2 -1
- package/templates/default/domains/Subscriptions/services/PlanManagementService/index.mdx +6 -2
- package/templates/default/domains/Subscriptions/services/SubscriptionService/commands/CancelSubscription/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/commands/SubscribeUser/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/events/UserSubscriptionCancelled/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/events/UserSubscriptionStarted/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/index.mdx +30 -10
- package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/schema.json +10 -2
- package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/versioned/0.0.1/index.mdx +5 -5
- package/templates/default/domains/Subscriptions/services/SubscriptionService/queries/GetSubscriptionStatus/versioned/0.0.1/schema.json +10 -2
- package/templates/default/domains/Subscriptions/ubiquitous-language.mdx +9 -9
- package/templates/default/eventcatalog.auth.js +4 -5
- package/templates/default/eventcatalog.config.js +6 -8
- package/templates/default/eventcatalog.styles.css +1 -1
- package/templates/default/teams/full-stack.mdx +4 -4
- package/templates/default/teams/mobile-devs.mdx +4 -2
- package/templates/default/users/aSmith.mdx +0 -1
- package/templates/default/users/dboyne.mdx +4 -3
- package/templates/default/users/mSmith.mdx +2 -2
- package/templates/empty/eventcatalog.auth.js +4 -5
- package/templates/empty/eventcatalog.config.js +6 -7
- package/templates/empty/eventcatalog.styles.css +1 -1
- package/templates/eventbridge/README-template.md +4 -8
- package/templates/eventbridge/eventcatalog.auth.js +4 -5
- package/templates/eventbridge/eventcatalog.config.js +7 -8
- package/templates/eventbridge/eventcatalog.styles.css +1 -1
- package/templates/graphql/eventcatalog.auth.js +4 -5
- package/templates/graphql/eventcatalog.config.js +29 -20
- package/templates/graphql/eventcatalog.styles.css +1 -1
- package/templates/graphql/teams/order-management.mdx +6 -6
- package/templates/graphql/teams/payment-management.mdx +4 -4
- package/templates/graphql/teams/product-management.mdx +4 -4
- package/templates/graphql/users/aSmith.mdx +0 -1
- package/templates/graphql/users/alee.mdx +1 -1
- package/templates/graphql/users/azhang.mdx +1 -1
- package/templates/graphql/users/dboyne.mdx +4 -3
- package/templates/graphql/users/dkim.mdx +1 -1
- package/templates/graphql/users/jbrown.mdx +1 -1
- package/templates/graphql/users/mSmith.mdx +2 -2
- package/templates/index.ts +49 -59
- package/templates/openapi/eventcatalog.auth.js +4 -5
- package/templates/openapi/eventcatalog.config.js +33 -26
- package/templates/openapi/eventcatalog.styles.css +1 -1
- package/templates/openapi/teams/order-management.mdx +6 -6
- package/templates/openapi/teams/payment-management.mdx +4 -4
- package/templates/openapi/teams/product-management.mdx +4 -4
- package/templates/openapi/users/aSmith.mdx +0 -1
- package/templates/openapi/users/alee.mdx +1 -1
- package/templates/openapi/users/azhang.mdx +1 -1
- package/templates/openapi/users/dboyne.mdx +4 -3
- package/templates/openapi/users/dkim.mdx +1 -1
- package/templates/openapi/users/jbrown.mdx +1 -1
- package/templates/openapi/users/mSmith.mdx +2 -2
- package/templates/types.ts +12 -3
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
},
|
|
11
|
-
"orderId": {
|
|
12
|
-
"type": "string",
|
|
13
|
-
"description": "Identifier for the associated order"
|
|
14
|
-
}
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"title": "ShipmentDispatched",
|
|
5
|
+
"description": "Schema for shipment dispatched event",
|
|
6
|
+
"properties": {
|
|
7
|
+
"shipmentId": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"description": "Unique identifier for the shipment"
|
|
15
10
|
},
|
|
16
|
-
"
|
|
17
|
-
|
|
11
|
+
"orderId": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"description": "Identifier for the associated order"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"required": ["shipmentId", "orderId"]
|
|
17
|
+
}
|
package/templates/default/domains/Orders/services/ShippingService/events/ShipmentInTransit/index.mdx
CHANGED
|
@@ -5,7 +5,7 @@ version: 0.0.1
|
|
|
5
5
|
summary: |
|
|
6
6
|
Event that is emitted when a shipment is in transit.
|
|
7
7
|
owners:
|
|
8
|
-
|
|
8
|
+
- dboyne
|
|
9
9
|
schemaPath: schema.json
|
|
10
10
|
---
|
|
11
11
|
|
|
@@ -19,4 +19,4 @@ This event can be applied in e-commerce systems, marketplaces, or any platform w
|
|
|
19
19
|
|
|
20
20
|
<NodeGraph />
|
|
21
21
|
|
|
22
|
-
<SchemaViewer file="schema.json" title="JSON Schema" maxHeight="500" />
|
|
22
|
+
<SchemaViewer file="schema.json" title="JSON Schema" maxHeight="500" />
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
},
|
|
11
|
-
"orderId": {
|
|
12
|
-
"type": "string",
|
|
13
|
-
"description": "Identifier for the associated order"
|
|
14
|
-
}
|
|
2
|
+
"$schema": "http://json-schema.org/draft-07/schema#",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"title": "ShipmentInTransit",
|
|
5
|
+
"description": "Schema for shipment in transit event",
|
|
6
|
+
"properties": {
|
|
7
|
+
"shipmentId": {
|
|
8
|
+
"type": "string",
|
|
9
|
+
"description": "Unique identifier for the shipment"
|
|
15
10
|
},
|
|
16
|
-
"
|
|
17
|
-
|
|
11
|
+
"orderId": {
|
|
12
|
+
"type": "string",
|
|
13
|
+
"description": "Identifier for the associated order"
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
"required": ["shipmentId", "orderId"]
|
|
17
|
+
}
|
|
@@ -33,17 +33,26 @@ import Footer from '@catalog/components/footer.astro';
|
|
|
33
33
|
|
|
34
34
|
The Shipping Service is responsible for managing shipping within the system. It handles order creation, updating, status tracking, and interactions with other services such as Inventory, Payment, and Notification services to ensure smooth order processing and fulfillment.
|
|
35
35
|
|
|
36
|
-
<Tiles
|
|
37
|
-
|
|
38
|
-
|
|
36
|
+
<Tiles>
|
|
37
|
+
<Tile
|
|
38
|
+
icon="BoltIcon"
|
|
39
|
+
href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`}
|
|
40
|
+
title={`Sends ${frontmatter.sends.length} messages`}
|
|
41
|
+
description="This service sends messages to downstream consumers"
|
|
42
|
+
/>
|
|
43
|
+
<Tile
|
|
44
|
+
icon="BoltIcon"
|
|
45
|
+
href={`/visualiser/services/${frontmatter.id}/${frontmatter.version}`}
|
|
46
|
+
title={`Receives ${frontmatter.receives.length} messages`}
|
|
47
|
+
description="This service receives messages from other services"
|
|
48
|
+
/>
|
|
39
49
|
</Tiles>
|
|
40
50
|
|
|
41
51
|
### Core features
|
|
42
52
|
|
|
43
53
|
The Shipping Service is responsible for managing shipping within the system. It handles order creation, updating, status tracking, and interactions with other services such as Inventory, Payment, and Notification services to ensure smooth order processing and fulfillment.
|
|
44
54
|
|
|
45
|
-
|
|
46
|
-
## Architecture diagram
|
|
55
|
+
## Architecture diagram
|
|
47
56
|
|
|
48
57
|
<NodeGraph />
|
|
49
58
|
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
dictionary:
|
|
3
3
|
- id: Payment
|
|
4
4
|
name: Payment
|
|
5
|
-
summary:
|
|
5
|
+
summary: 'The act of paying for magical goods or services.'
|
|
6
6
|
icon: Wand2
|
|
7
7
|
- id: Purchase Order
|
|
8
8
|
name: Purchase Order
|
|
9
|
-
summary:
|
|
9
|
+
summary: 'A mystical document issued by a buyer to a seller indicating the types, quantities, and agreed prices for enchanted products or services.'
|
|
10
10
|
description: |
|
|
11
11
|
A purchase order (PO) is a magical document that initiates the buying process between mystical entities. It protects both buyer and seller by clearly documenting the transaction details. Key components include:
|
|
12
12
|
|
|
@@ -20,7 +20,7 @@ dictionary:
|
|
|
20
20
|
icon: FileText
|
|
21
21
|
- id: Order Line
|
|
22
22
|
name: Order Line
|
|
23
|
-
summary:
|
|
23
|
+
summary: 'An individual enchanted item within a purchase order, representing a specific magical product or service being ordered.'
|
|
24
24
|
description: |
|
|
25
25
|
Order lines are the fundamental building blocks of any purchase order. Each line represents a distinct item or service and contains critical information for order fulfillment:
|
|
26
26
|
|
|
@@ -34,7 +34,7 @@ dictionary:
|
|
|
34
34
|
icon: ListOrdered
|
|
35
35
|
- id: SKU
|
|
36
36
|
name: SKU
|
|
37
|
-
summary:
|
|
37
|
+
summary: 'Sorcery Keeping Unit - A unique identifier for distinct magical products and their variants in inventory.'
|
|
38
38
|
description: |
|
|
39
39
|
SKUs are the cornerstone of effective inventory management systems. Each SKU represents a unique combination of product attributes:
|
|
40
40
|
|
|
@@ -47,7 +47,7 @@ dictionary:
|
|
|
47
47
|
icon: Tag
|
|
48
48
|
- id: Consignment
|
|
49
49
|
name: Consignment
|
|
50
|
-
summary:
|
|
50
|
+
summary: 'A batch of enchanted goods destined for or delivered to someone.'
|
|
51
51
|
description: |
|
|
52
52
|
A consignment represents the physical movement of goods through the supply chain. It encompasses all aspects of the shipping process:
|
|
53
53
|
|
|
@@ -60,7 +60,7 @@ dictionary:
|
|
|
60
60
|
icon: Package
|
|
61
61
|
- id: Invoice
|
|
62
62
|
name: Invoice
|
|
63
|
-
summary:
|
|
63
|
+
summary: 'A document issued by a seller to a buyer, listing enchanted goods or services provided and the amount due.'
|
|
64
64
|
description: |
|
|
65
65
|
Invoices are critical for financial transactions, serving as a request for payment from the buyer. They include:
|
|
66
66
|
|
|
@@ -74,7 +74,7 @@ dictionary:
|
|
|
74
74
|
icon: Receipt
|
|
75
75
|
- id: Supplier
|
|
76
76
|
name: Supplier
|
|
77
|
-
summary:
|
|
77
|
+
summary: 'An entity that provides enchanted goods or services to another organization.'
|
|
78
78
|
description: |
|
|
79
79
|
Suppliers are key partners in the supply chain, responsible for delivering the necessary products or services. Key aspects include:
|
|
80
80
|
|
|
@@ -87,7 +87,7 @@ dictionary:
|
|
|
87
87
|
icon: Truck
|
|
88
88
|
- id: Inventory
|
|
89
89
|
name: Inventory
|
|
90
|
-
summary:
|
|
90
|
+
summary: 'The complete list of enchanted items held in stock by a business.'
|
|
91
91
|
description: |
|
|
92
92
|
Inventory management is crucial for balancing supply and demand. It involves:
|
|
93
93
|
|
|
@@ -100,7 +100,7 @@ dictionary:
|
|
|
100
100
|
icon: Warehouse
|
|
101
101
|
- id: Fulfillment
|
|
102
102
|
name: Fulfillment
|
|
103
|
-
summary:
|
|
103
|
+
summary: 'The process of completing an order and delivering it to the customer.'
|
|
104
104
|
description: |
|
|
105
105
|
Fulfillment encompasses all steps from order receipt to delivery, including:
|
|
106
106
|
|
|
@@ -113,7 +113,7 @@ dictionary:
|
|
|
113
113
|
icon: PackageCheck
|
|
114
114
|
- id: Return
|
|
115
115
|
name: Return
|
|
116
|
-
summary:
|
|
116
|
+
summary: 'The process of sending back enchanted goods to the seller for a refund or exchange.'
|
|
117
117
|
description: |
|
|
118
118
|
Returns management is an important aspect of customer service and inventory control. It involves:
|
|
119
119
|
|
|
@@ -5,15 +5,15 @@ version: 0.0.1
|
|
|
5
5
|
summary: |
|
|
6
6
|
Domain for everything shopping
|
|
7
7
|
owners:
|
|
8
|
-
|
|
9
|
-
|
|
8
|
+
- dboyne
|
|
9
|
+
- full-stack
|
|
10
10
|
services:
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
- id: InventoryService
|
|
12
|
+
version: 0.0.2
|
|
13
13
|
badges:
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
- content: New domain
|
|
15
|
+
backgroundColor: blue
|
|
16
|
+
textColor: blue
|
|
17
17
|
---
|
|
18
18
|
|
|
19
19
|
## Overview
|
|
@@ -22,7 +22,9 @@ badges:
|
|
|
22
22
|
|
|
23
23
|
The Orders domain handles all operations related to customer orders, from creation to fulfillment. This documentation provides an overview of the events and services involved in the Orders domain, helping developers and stakeholders understand the event-driven architecture.
|
|
24
24
|
|
|
25
|
-
<Admonition type="warning">
|
|
25
|
+
<Admonition type="warning">
|
|
26
|
+
Please ensure all services are updated to the latest version for compatibility and performance improvements.
|
|
27
|
+
</Admonition>
|
|
26
28
|
|
|
27
29
|
## Bounded context
|
|
28
30
|
|
|
@@ -46,5 +48,3 @@ sequenceDiagram
|
|
|
46
48
|
OrdersService->>Customer: Order Placed Successfully
|
|
47
49
|
OrdersService->>InventoryService: Update Inventory
|
|
48
50
|
```
|
|
49
|
-
|
|
50
|
-
|
|
@@ -133,32 +133,33 @@ properties:
|
|
|
133
133
|
The Address entity stores shipping and billing addresses for customers, orders, and payments. It supports address validation, geocoding, and delivery instructions to ensure accurate order fulfillment.
|
|
134
134
|
|
|
135
135
|
### Entity Properties
|
|
136
|
+
|
|
136
137
|
<EntityPropertiesTable />
|
|
137
138
|
|
|
138
139
|
## Relationships
|
|
139
140
|
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
141
|
+
- **Customer:** An address can belong to one `Customer` (identified by `customerId`).
|
|
142
|
+
- **Order:** An address can be used by multiple `Order` entities for shipping.
|
|
143
|
+
- **Payment:** An address can be used by multiple `Payment` entities for billing.
|
|
143
144
|
|
|
144
145
|
## Address Types
|
|
145
146
|
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
147
|
+
- **Billing:** Used for payment processing and invoicing
|
|
148
|
+
- **Shipping:** Used for order delivery
|
|
149
|
+
- **Both:** Can be used for both billing and shipping
|
|
149
150
|
|
|
150
151
|
## Examples
|
|
151
152
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
153
|
+
- **Address #1:** John Doe's home address - default shipping and billing address.
|
|
154
|
+
- **Address #2:** Corporate office address - billing only, validated with high confidence.
|
|
155
|
+
- **Address #3:** Gift recipient address - shipping only, with special delivery instructions.
|
|
155
156
|
|
|
156
157
|
## Business Rules
|
|
157
158
|
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
159
|
+
- Each customer can have only one default address per type
|
|
160
|
+
- Addresses must be validated before being marked as default
|
|
161
|
+
- International addresses require country-specific validation
|
|
162
|
+
- Geocoordinates are automatically populated when available
|
|
163
|
+
- Address changes should create new versions for audit trail
|
|
164
|
+
- PO Box addresses may have shipping restrictions
|
|
165
|
+
- Address validation improves delivery success rates
|
|
@@ -75,17 +75,18 @@ properties:
|
|
|
75
75
|
The Invoice entity represents a formal request for payment issued by the business to a customer. It details the products, services, quantities, prices, taxes, and total amount due, along with payment terms.
|
|
76
76
|
|
|
77
77
|
### Entity Properties
|
|
78
|
+
|
|
78
79
|
<EntityPropertiesTable />
|
|
79
80
|
|
|
80
81
|
## Relationships
|
|
81
82
|
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
83
|
+
- **Customer:** An invoice is issued to one `Customer`.
|
|
84
|
+
- **Order/Subscription:** An invoice may be related to one or more `Order`s or a specific `Subscription` period.
|
|
85
|
+
- **Payment:** An invoice is settled by one or more `Payment` transactions.
|
|
86
|
+
- **InvoiceLineItem:** An invoice contains multiple `InvoiceLineItem`s detailing the charges.
|
|
87
|
+
- **BillingProfile:** Invoice generation often uses details from the customer's `BillingProfile`.
|
|
87
88
|
|
|
88
89
|
## Examples
|
|
89
90
|
|
|
90
|
-
|
|
91
|
-
|
|
91
|
+
- Invoice #INV-00123 issued to Jane Doe for her monthly subscription renewal, due in 15 days.
|
|
92
|
+
- Invoice #INV-00124 issued to Acme Corp for consulting services rendered in the previous month, status Paid.
|
|
@@ -105,14 +105,15 @@ properties:
|
|
|
105
105
|
The Payment entity manages all payment transactions in the e-commerce system. It tracks payment details, status, and relationships with orders and customers, supporting various payment methods and refund scenarios.
|
|
106
106
|
|
|
107
107
|
### Entity Properties
|
|
108
|
+
|
|
108
109
|
<EntityPropertiesTable />
|
|
109
110
|
|
|
110
111
|
## Relationships
|
|
111
112
|
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
113
|
+
- **Order:** Each payment belongs to one `Order` (identified by `orderId`).
|
|
114
|
+
- **Customer:** Each payment is made by one `Customer` (identified by `customerId`).
|
|
115
|
+
- **Address:** Each payment has a billing `Address` (identified by `billingAddress`).
|
|
116
|
+
- **PaymentRefund:** A payment can have multiple `PaymentRefund` entities for partial or full refunds.
|
|
116
117
|
|
|
117
118
|
## Payment States
|
|
118
119
|
|
|
@@ -124,16 +125,16 @@ cancelled failed refunded/partially_refunded
|
|
|
124
125
|
|
|
125
126
|
## Examples
|
|
126
127
|
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
128
|
+
- **Payment #1:** $299.99 credit card payment for Order #12345, completed successfully.
|
|
129
|
+
- **Payment #2:** $150.00 PayPal payment for Order #67890, failed due to insufficient funds.
|
|
130
|
+
- **Payment #3:** $500.00 bank transfer, completed with $50.00 partial refund.
|
|
130
131
|
|
|
131
132
|
## Business Rules
|
|
132
133
|
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
134
|
+
- Payment amount must match the order total
|
|
135
|
+
- Payment status transitions must follow valid state machine
|
|
136
|
+
- Failed payments should include failure reason
|
|
137
|
+
- Completed payments cannot be cancelled
|
|
138
|
+
- Refunds cannot exceed the original payment amount
|
|
139
|
+
- Payment method details are encrypted and PCI compliant
|
|
140
|
+
- Transaction IDs from payment gateways must be stored for reconciliation
|
|
@@ -63,17 +63,18 @@ The PaymentMethod entity represents a specific payment instrument registered by
|
|
|
63
63
|
**Security Note:** Sensitive details like full card numbers or bank account numbers should **never** be stored directly. Rely on tokenization provided by payment gateways.
|
|
64
64
|
|
|
65
65
|
### Entity Properties
|
|
66
|
+
|
|
66
67
|
<EntityPropertiesTable />
|
|
67
68
|
|
|
68
69
|
## Relationships
|
|
69
70
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
71
|
+
- **Customer:** A payment method belongs to one `Customer`.
|
|
72
|
+
- **Address:** Linked to a specific billing `Address`.
|
|
73
|
+
- **Payment:** Used to make `Payment` transactions.
|
|
74
|
+
- **Subscription:** May be designated as the payment method for a `Subscription`.
|
|
74
75
|
|
|
75
76
|
## Examples
|
|
76
77
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
78
|
+
- Jane Doe's default Visa card ending in 1234, expiring 12/2025, status Active.
|
|
79
|
+
- John Smith's linked bank account (Chase, Checking), status Active.
|
|
80
|
+
- An old MasterCard ending in 5678 belonging to Jane Doe, status Expired.
|
|
@@ -65,15 +65,16 @@ properties:
|
|
|
65
65
|
The Transaction entity logs the individual interactions with an external payment processor (like Stripe, PayPal, Adyen) that occur as part of processing a `Payment`. This provides a detailed audit trail of gateway operations, including authorizations, captures, refunds, and any associated success or failure responses.
|
|
66
66
|
|
|
67
67
|
### Entity Properties
|
|
68
|
+
|
|
68
69
|
<EntityPropertiesTable />
|
|
69
70
|
|
|
70
71
|
## Relationships
|
|
71
72
|
|
|
72
|
-
|
|
73
|
+
- **Payment:** A transaction is part of one `Payment`.
|
|
73
74
|
|
|
74
75
|
## Examples
|
|
75
76
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
77
|
+
- **Authorization Success:** Type: Authorize, PaymentID: PAY-98765, GatewayRef: auth_abc, Amount: $19.99, Status: Success.
|
|
78
|
+
- **Capture Success:** Type: Capture, PaymentID: PAY-98765, GatewayRef: ch_def, Amount: $19.99, Status: Success (following the authorization).
|
|
79
|
+
- **Authorization Failure:** Type: Authorize, PaymentID: PAY-98766, GatewayRef: auth_ghi, Amount: $50.00, Status: Failure, ResponseCode: 'declined', ResponseMessage: 'Insufficient Funds'.
|
|
80
|
+
- **Refund Success:** Type: Refund, PaymentID: PAY-98760, GatewayRef: re_jkl, Amount: $25.00, Status: Success.
|
|
@@ -6,76 +6,77 @@ summary: Business flow for processing payments in an e-commerce platform
|
|
|
6
6
|
owners:
|
|
7
7
|
- dboyne
|
|
8
8
|
steps:
|
|
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
|
-
|
|
9
|
+
- id: 'customer_place_order'
|
|
10
|
+
title: Customer places order
|
|
11
|
+
next_step: 'place_order_request'
|
|
12
|
+
- id: 'place_order_request'
|
|
13
|
+
title: Place order
|
|
14
|
+
message:
|
|
15
|
+
id: PlaceOrder
|
|
16
|
+
version: 0.0.1
|
|
17
|
+
next_step:
|
|
18
|
+
id: 'payment_initiated'
|
|
19
|
+
label: Initiate payment
|
|
20
|
+
- id: 'payment_initiated'
|
|
21
|
+
title: Payment Initiated
|
|
22
|
+
message:
|
|
23
|
+
id: PaymentInitiated
|
|
24
|
+
version: 0.0.1
|
|
25
|
+
next_steps:
|
|
26
|
+
- 'payment_processed'
|
|
27
|
+
- 'payment_failed'
|
|
28
|
+
- id: 'payment_processed'
|
|
29
|
+
title: Payment Processed
|
|
30
|
+
message:
|
|
31
|
+
id: PaymentProcessed
|
|
32
|
+
version: 0.0.1
|
|
33
|
+
next_steps:
|
|
34
|
+
- id: 'adjust_inventory'
|
|
35
|
+
label: Adjust inventory
|
|
36
|
+
- id: 'send_custom_notification'
|
|
37
|
+
label: Notify customer
|
|
38
|
+
- id: 'payment_failed'
|
|
39
|
+
title: Payment Failed
|
|
40
|
+
type: node
|
|
41
|
+
next_steps:
|
|
42
|
+
- id: 'failure_notification'
|
|
43
|
+
label: Notify customer of failure
|
|
44
|
+
- id: 'retry_payment'
|
|
45
|
+
label: Retry payment
|
|
46
|
+
- id: 'adjust_inventory'
|
|
47
|
+
title: Inventory Adjusted
|
|
48
|
+
message:
|
|
49
|
+
id: InventoryAdjusted
|
|
50
|
+
version: 1.0.1
|
|
51
|
+
next_step:
|
|
52
|
+
id: 'payment_complete'
|
|
53
|
+
label: Complete order
|
|
54
|
+
- id: 'send_custom_notification'
|
|
55
|
+
title: Customer Notified of Payment
|
|
56
|
+
type: node
|
|
57
|
+
next_step:
|
|
58
|
+
id: 'payment_complete'
|
|
59
|
+
label: Complete order
|
|
60
|
+
- id: 'failure_notification'
|
|
61
|
+
title: Customer Notified of Failure
|
|
62
|
+
type: node
|
|
63
|
+
- id: 'retry_payment'
|
|
64
|
+
title: Retry Payment
|
|
65
|
+
type: node
|
|
66
|
+
next_step:
|
|
67
|
+
id: 'payment_initiated'
|
|
68
|
+
label: Retry payment process
|
|
69
|
+
- id: 'payment_complete'
|
|
70
|
+
title: Payment Complete
|
|
71
|
+
type: node
|
|
72
|
+
next_step:
|
|
73
|
+
id: 'order-complete'
|
|
74
|
+
label: Order completed
|
|
75
|
+
- id: 'order-complete'
|
|
76
|
+
title: Order Completed
|
|
77
|
+
type: node
|
|
78
78
|
---
|
|
79
79
|
|
|
80
80
|
### Flow of feature
|
|
81
|
-
|
|
81
|
+
|
|
82
|
+
<NodeGraph />
|
|
@@ -5,14 +5,14 @@ version: 0.0.1
|
|
|
5
5
|
summary: |
|
|
6
6
|
Domain that contains payment related services and messages.
|
|
7
7
|
owners:
|
|
8
|
-
|
|
8
|
+
- dboyne
|
|
9
9
|
services:
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
10
|
+
- id: PaymentService
|
|
11
|
+
version: 0.0.1
|
|
12
|
+
- id: FraudDetectionService
|
|
13
|
+
version: 0.0.1
|
|
14
|
+
- id: PaymentGatewayService
|
|
15
|
+
version: 0.0.1
|
|
16
16
|
entities:
|
|
17
17
|
- id: Invoice
|
|
18
18
|
- id: Payment
|
|
@@ -20,9 +20,9 @@ entities:
|
|
|
20
20
|
- id: Transaction
|
|
21
21
|
- id: Address
|
|
22
22
|
badges:
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
- content: Payment Domain
|
|
24
|
+
backgroundColor: blue
|
|
25
|
+
textColor: blue
|
|
26
26
|
---
|
|
27
27
|
|
|
28
28
|
## Overview
|
|
@@ -16,7 +16,7 @@ badges:
|
|
|
16
16
|
schemaPath: schema.json
|
|
17
17
|
---
|
|
18
18
|
|
|
19
|
-
import Footer from '@catalog/components/footer.astro'
|
|
19
|
+
import Footer from '@catalog/components/footer.astro';
|
|
20
20
|
|
|
21
21
|
## Overview
|
|
22
22
|
|
|
@@ -47,4 +47,4 @@ The `FraudCheckCompleted` event is emitted when the fraud detection service has
|
|
|
47
47
|
}
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
<Footer />
|
|
50
|
+
<Footer />
|