@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,282 +1,281 @@
|
|
|
1
1
|
---
|
|
2
|
-
id:
|
|
3
|
-
name:
|
|
4
|
-
version:
|
|
5
|
-
summary:
|
|
2
|
+
id: 'SubscriptionRenewed'
|
|
3
|
+
name: 'Subscription Renewal Flow'
|
|
4
|
+
version: '1.0.0'
|
|
5
|
+
summary: 'Business flow for automatic subscription renewals and related processes'
|
|
6
6
|
steps:
|
|
7
|
-
- id:
|
|
8
|
-
title:
|
|
7
|
+
- id: 'renewal_timer_triggered'
|
|
8
|
+
title: 'Renewal Period Reached'
|
|
9
9
|
custom:
|
|
10
|
-
title:
|
|
11
|
-
color:
|
|
12
|
-
icon:
|
|
13
|
-
type:
|
|
14
|
-
summary:
|
|
10
|
+
title: 'Renewal Timer'
|
|
11
|
+
color: 'orange'
|
|
12
|
+
icon: 'ClockIcon'
|
|
13
|
+
type: 'Scheduler'
|
|
14
|
+
summary: 'Automated timer triggers the subscription renewal process'
|
|
15
15
|
height: 8
|
|
16
16
|
properties:
|
|
17
|
-
subscription_id:
|
|
18
|
-
renewal_type:
|
|
19
|
-
billing_cycle:
|
|
20
|
-
next_billing_date:
|
|
17
|
+
subscription_id: 'sub_12345678'
|
|
18
|
+
renewal_type: 'Automatic'
|
|
19
|
+
billing_cycle: 'Monthly'
|
|
20
|
+
next_billing_date: '2024-08-01'
|
|
21
21
|
menu:
|
|
22
|
-
- label:
|
|
23
|
-
url:
|
|
24
|
-
- label:
|
|
25
|
-
url:
|
|
22
|
+
- label: 'View scheduler configuration'
|
|
23
|
+
url: 'https://docs.example.com/scheduler'
|
|
24
|
+
- label: 'Subscription timing documentation'
|
|
25
|
+
url: 'https://docs.example.com/subscription-timing'
|
|
26
26
|
next_step:
|
|
27
|
-
id:
|
|
28
|
-
label:
|
|
27
|
+
id: 'check_subscription_status'
|
|
28
|
+
label: 'Verify subscription status'
|
|
29
29
|
|
|
30
|
-
- id:
|
|
31
|
-
title:
|
|
30
|
+
- id: 'check_subscription_status'
|
|
31
|
+
title: 'Check Subscription Status'
|
|
32
32
|
service:
|
|
33
|
-
id:
|
|
34
|
-
version:
|
|
33
|
+
id: 'SubscriptionService'
|
|
34
|
+
version: '0.0.1'
|
|
35
35
|
next_steps:
|
|
36
|
-
- id:
|
|
37
|
-
label:
|
|
38
|
-
- id:
|
|
39
|
-
label:
|
|
40
|
-
- id:
|
|
41
|
-
label:
|
|
42
|
-
|
|
43
|
-
- id:
|
|
44
|
-
title:
|
|
45
|
-
type:
|
|
36
|
+
- id: 'payment_approval_check'
|
|
37
|
+
label: 'Subscription active, proceed to payment'
|
|
38
|
+
- id: 'subscription_expired'
|
|
39
|
+
label: 'Subscription has expired'
|
|
40
|
+
- id: 'subscription_canceled'
|
|
41
|
+
label: 'Subscription was canceled'
|
|
42
|
+
|
|
43
|
+
- id: 'subscription_expired'
|
|
44
|
+
title: 'Subscription Expired'
|
|
45
|
+
type: 'node'
|
|
46
46
|
next_step:
|
|
47
|
-
id:
|
|
48
|
-
label:
|
|
47
|
+
id: 'send_renewal_notification'
|
|
48
|
+
label: 'Notify customer to renew'
|
|
49
49
|
|
|
50
|
-
- id:
|
|
51
|
-
title:
|
|
52
|
-
type:
|
|
50
|
+
- id: 'subscription_canceled'
|
|
51
|
+
title: 'Subscription Canceled'
|
|
52
|
+
type: 'node'
|
|
53
53
|
next_step:
|
|
54
|
-
id:
|
|
55
|
-
label:
|
|
54
|
+
id: 'send_reactivation_offer'
|
|
55
|
+
label: 'Send special reactivation offer'
|
|
56
56
|
|
|
57
|
-
- id:
|
|
58
|
-
title:
|
|
57
|
+
- id: 'send_renewal_notification'
|
|
58
|
+
title: 'Send Renewal Notification'
|
|
59
59
|
service:
|
|
60
|
-
id:
|
|
61
|
-
version:
|
|
60
|
+
id: 'NotificationService'
|
|
61
|
+
version: '0.0.2'
|
|
62
62
|
next_step:
|
|
63
|
-
id:
|
|
64
|
-
label:
|
|
63
|
+
id: 'await_customer_action'
|
|
64
|
+
label: 'Wait for customer response'
|
|
65
65
|
|
|
66
|
-
- id:
|
|
67
|
-
title:
|
|
66
|
+
- id: 'send_reactivation_offer'
|
|
67
|
+
title: 'Send Reactivation Offer'
|
|
68
68
|
service:
|
|
69
|
-
id:
|
|
70
|
-
version:
|
|
69
|
+
id: 'NotificationService'
|
|
70
|
+
version: '0.0.2'
|
|
71
71
|
next_step:
|
|
72
|
-
id:
|
|
73
|
-
label:
|
|
72
|
+
id: 'await_customer_action'
|
|
73
|
+
label: 'Wait for customer response'
|
|
74
74
|
|
|
75
|
-
- id:
|
|
76
|
-
title:
|
|
75
|
+
- id: 'await_customer_action'
|
|
76
|
+
title: 'Await Customer Action'
|
|
77
77
|
custom:
|
|
78
|
-
title:
|
|
79
|
-
color:
|
|
80
|
-
icon:
|
|
81
|
-
type:
|
|
78
|
+
title: 'Customer Decision Point'
|
|
79
|
+
color: 'purple'
|
|
80
|
+
icon: 'UserIcon'
|
|
81
|
+
type: 'Decision'
|
|
82
82
|
height: 8
|
|
83
|
-
summary:
|
|
83
|
+
summary: 'Waiting period for customer to take action on notification'
|
|
84
84
|
properties:
|
|
85
|
-
timeout_period:
|
|
86
|
-
options:
|
|
85
|
+
timeout_period: '7 days'
|
|
86
|
+
options: 'Renew, Upgrade, Cancel, Ignore'
|
|
87
87
|
next_steps:
|
|
88
|
-
- id:
|
|
89
|
-
label:
|
|
90
|
-
- id:
|
|
91
|
-
label:
|
|
92
|
-
|
|
93
|
-
- id:
|
|
94
|
-
title:
|
|
95
|
-
type:
|
|
88
|
+
- id: 'manual_renewal_flow'
|
|
89
|
+
label: 'Customer manually renews'
|
|
90
|
+
- id: 'flow_ends'
|
|
91
|
+
label: 'No action taken'
|
|
92
|
+
|
|
93
|
+
- id: 'manual_renewal_flow'
|
|
94
|
+
title: 'Manual Renewal Flow'
|
|
95
|
+
type: 'node'
|
|
96
96
|
next_step:
|
|
97
|
-
id:
|
|
98
|
-
label:
|
|
97
|
+
id: 'payment_initiated'
|
|
98
|
+
label: 'Process payment'
|
|
99
99
|
|
|
100
|
-
- id:
|
|
101
|
-
title:
|
|
100
|
+
- id: 'payment_approval_check'
|
|
101
|
+
title: 'Check Payment Approval'
|
|
102
102
|
message:
|
|
103
|
-
id:
|
|
104
|
-
version:
|
|
103
|
+
id: 'GetPaymentStatus'
|
|
104
|
+
version: '0.0.1'
|
|
105
105
|
next_steps:
|
|
106
|
-
- id:
|
|
107
|
-
label:
|
|
108
|
-
- id:
|
|
109
|
-
label:
|
|
110
|
-
|
|
111
|
-
- id:
|
|
112
|
-
title:
|
|
113
|
-
type:
|
|
106
|
+
- id: 'payment_initiated'
|
|
107
|
+
label: 'Payment approved, proceed with billing'
|
|
108
|
+
- id: 'payment_method_invalid'
|
|
109
|
+
label: 'Invalid payment method'
|
|
110
|
+
|
|
111
|
+
- id: 'payment_method_invalid'
|
|
112
|
+
title: 'Invalid Payment Method'
|
|
113
|
+
type: 'node'
|
|
114
114
|
next_step:
|
|
115
|
-
id:
|
|
116
|
-
label:
|
|
115
|
+
id: 'request_payment_update'
|
|
116
|
+
label: 'Request updated payment method'
|
|
117
117
|
|
|
118
|
-
- id:
|
|
119
|
-
title:
|
|
118
|
+
- id: 'request_payment_update'
|
|
119
|
+
title: 'Request Payment Update'
|
|
120
120
|
service:
|
|
121
|
-
id:
|
|
122
|
-
version:
|
|
121
|
+
id: 'NotificationService'
|
|
122
|
+
version: '0.0.2'
|
|
123
123
|
next_step:
|
|
124
|
-
id:
|
|
125
|
-
label:
|
|
124
|
+
id: 'await_updated_payment'
|
|
125
|
+
label: 'Wait for payment update'
|
|
126
126
|
|
|
127
|
-
- id:
|
|
128
|
-
title:
|
|
127
|
+
- id: 'await_updated_payment'
|
|
128
|
+
title: 'Await Updated Payment Method'
|
|
129
129
|
actor:
|
|
130
|
-
name:
|
|
130
|
+
name: 'Customer'
|
|
131
131
|
next_steps:
|
|
132
|
-
- id:
|
|
133
|
-
label:
|
|
134
|
-
- id:
|
|
135
|
-
label:
|
|
132
|
+
- id: 'payment_initiated'
|
|
133
|
+
label: 'Payment method updated'
|
|
134
|
+
- id: 'subscription_grace_period'
|
|
135
|
+
label: 'No update received'
|
|
136
136
|
|
|
137
|
-
- id:
|
|
138
|
-
title:
|
|
137
|
+
- id: 'subscription_grace_period'
|
|
138
|
+
title: 'Grace Period'
|
|
139
139
|
custom:
|
|
140
|
-
title:
|
|
141
|
-
color:
|
|
142
|
-
icon:
|
|
143
|
-
type:
|
|
144
|
-
summary:
|
|
140
|
+
title: 'Subscription Grace Period'
|
|
141
|
+
color: 'yellow'
|
|
142
|
+
icon: 'ShieldExclamationIcon'
|
|
143
|
+
type: 'Timer'
|
|
144
|
+
summary: 'Limited period where subscription remains active despite payment failure'
|
|
145
145
|
properties:
|
|
146
|
-
duration:
|
|
147
|
-
status:
|
|
146
|
+
duration: '7 days'
|
|
147
|
+
status: 'At risk'
|
|
148
148
|
next_steps:
|
|
149
|
-
- id:
|
|
150
|
-
label:
|
|
151
|
-
- id:
|
|
152
|
-
label:
|
|
149
|
+
- id: 'payment_initiated'
|
|
150
|
+
label: 'Payment updated during grace period'
|
|
151
|
+
- id: 'subscription_suspended'
|
|
152
|
+
label: 'Grace period expired'
|
|
153
153
|
|
|
154
|
-
- id:
|
|
155
|
-
title:
|
|
154
|
+
- id: 'subscription_suspended'
|
|
155
|
+
title: 'Subscription Suspended'
|
|
156
156
|
message:
|
|
157
|
-
id:
|
|
158
|
-
version:
|
|
157
|
+
id: 'UserSubscriptionCancelled'
|
|
158
|
+
version: '0.0.1'
|
|
159
159
|
next_step:
|
|
160
|
-
id:
|
|
161
|
-
label:
|
|
160
|
+
id: 'send_suspension_notification'
|
|
161
|
+
label: 'Notify customer of suspension'
|
|
162
162
|
|
|
163
|
-
- id:
|
|
164
|
-
title:
|
|
163
|
+
- id: 'send_suspension_notification'
|
|
164
|
+
title: 'Send Suspension Notification'
|
|
165
165
|
service:
|
|
166
|
-
id:
|
|
167
|
-
version:
|
|
166
|
+
id: 'NotificationService'
|
|
167
|
+
version: '0.0.2'
|
|
168
168
|
next_step:
|
|
169
|
-
id:
|
|
170
|
-
label:
|
|
169
|
+
id: 'flow_ends'
|
|
170
|
+
label: 'Flow ends'
|
|
171
171
|
|
|
172
|
-
- id:
|
|
173
|
-
title:
|
|
172
|
+
- id: 'payment_initiated'
|
|
173
|
+
title: 'Process Payment'
|
|
174
174
|
message:
|
|
175
|
-
id:
|
|
176
|
-
version:
|
|
175
|
+
id: 'PaymentInitiated'
|
|
176
|
+
version: '0.0.1'
|
|
177
177
|
next_step:
|
|
178
|
-
id:
|
|
179
|
-
label:
|
|
178
|
+
id: 'payment_gateway'
|
|
179
|
+
label: 'Send to payment gateway'
|
|
180
180
|
|
|
181
|
-
- id:
|
|
182
|
-
title:
|
|
181
|
+
- id: 'payment_gateway'
|
|
182
|
+
title: 'Payment Gateway'
|
|
183
183
|
externalSystem:
|
|
184
|
-
name:
|
|
185
|
-
summary:
|
|
186
|
-
url:
|
|
184
|
+
name: 'Stripe'
|
|
185
|
+
summary: '3rd party payment processor'
|
|
186
|
+
url: 'https://stripe.com/'
|
|
187
187
|
next_steps:
|
|
188
|
-
- id:
|
|
189
|
-
label:
|
|
190
|
-
- id:
|
|
191
|
-
label:
|
|
192
|
-
|
|
193
|
-
- id:
|
|
194
|
-
title:
|
|
195
|
-
type:
|
|
188
|
+
- id: 'payment_processed'
|
|
189
|
+
label: 'Payment successful'
|
|
190
|
+
- id: 'payment_failed'
|
|
191
|
+
label: 'Payment failed'
|
|
192
|
+
|
|
193
|
+
- id: 'payment_failed'
|
|
194
|
+
title: 'Payment Failed'
|
|
195
|
+
type: 'node'
|
|
196
196
|
next_step:
|
|
197
|
-
id:
|
|
198
|
-
label:
|
|
197
|
+
id: 'retry_payment'
|
|
198
|
+
label: 'Retry payment'
|
|
199
199
|
|
|
200
|
-
- id:
|
|
201
|
-
title:
|
|
200
|
+
- id: 'retry_payment'
|
|
201
|
+
title: 'Retry Payment'
|
|
202
202
|
custom:
|
|
203
|
-
title:
|
|
204
|
-
color:
|
|
205
|
-
icon:
|
|
206
|
-
type:
|
|
207
|
-
summary:
|
|
203
|
+
title: 'Payment Retry Logic'
|
|
204
|
+
color: 'red'
|
|
205
|
+
icon: 'ArrowPathIcon'
|
|
206
|
+
type: 'Processor'
|
|
207
|
+
summary: 'Automated retry logic for failed payments'
|
|
208
208
|
properties:
|
|
209
209
|
max_attempts: 3
|
|
210
|
-
backoff_interval:
|
|
210
|
+
backoff_interval: '24 hours'
|
|
211
211
|
current_attempt: 1
|
|
212
212
|
next_steps:
|
|
213
|
-
- id:
|
|
214
|
-
label:
|
|
215
|
-
- id:
|
|
216
|
-
label:
|
|
213
|
+
- id: 'payment_initiated'
|
|
214
|
+
label: 'Retry payment'
|
|
215
|
+
- id: 'subscription_grace_period'
|
|
216
|
+
label: 'Max retries exceeded'
|
|
217
217
|
|
|
218
|
-
- id:
|
|
219
|
-
title:
|
|
218
|
+
- id: 'payment_processed'
|
|
219
|
+
title: 'Payment Processed'
|
|
220
220
|
message:
|
|
221
|
-
id:
|
|
222
|
-
version:
|
|
221
|
+
id: 'PaymentProcessed'
|
|
222
|
+
version: '1.0.0'
|
|
223
223
|
next_step:
|
|
224
|
-
id:
|
|
225
|
-
label:
|
|
224
|
+
id: 'update_subscription_status'
|
|
225
|
+
label: 'Update subscription'
|
|
226
226
|
|
|
227
|
-
- id:
|
|
228
|
-
title:
|
|
227
|
+
- id: 'update_subscription_status'
|
|
228
|
+
title: 'Update Subscription'
|
|
229
229
|
service:
|
|
230
|
-
id:
|
|
231
|
-
version:
|
|
230
|
+
id: 'SubscriptionService'
|
|
231
|
+
version: '0.0.1'
|
|
232
232
|
next_step:
|
|
233
|
-
id:
|
|
234
|
-
label:
|
|
233
|
+
id: 'send_renewal_confirmation'
|
|
234
|
+
label: 'Confirm renewal to customer'
|
|
235
235
|
|
|
236
|
-
- id:
|
|
237
|
-
title:
|
|
236
|
+
- id: 'send_renewal_confirmation'
|
|
237
|
+
title: 'Send Renewal Confirmation'
|
|
238
238
|
service:
|
|
239
|
-
id:
|
|
240
|
-
version:
|
|
239
|
+
id: 'NotificationService'
|
|
240
|
+
version: '0.0.2'
|
|
241
241
|
next_step:
|
|
242
|
-
id:
|
|
243
|
-
label:
|
|
242
|
+
id: 'analyze_customer_usage'
|
|
243
|
+
label: 'Analyze customer usage patterns'
|
|
244
244
|
|
|
245
|
-
- id:
|
|
246
|
-
title:
|
|
245
|
+
- id: 'analyze_customer_usage'
|
|
246
|
+
title: 'Analyze Usage Patterns'
|
|
247
247
|
custom:
|
|
248
|
-
title:
|
|
249
|
-
color:
|
|
250
|
-
icon:
|
|
251
|
-
type:
|
|
252
|
-
summary:
|
|
248
|
+
title: 'Usage Analytics'
|
|
249
|
+
color: 'blue'
|
|
250
|
+
icon: 'ChartBarIcon'
|
|
251
|
+
type: 'Analytics'
|
|
252
|
+
summary: 'Analyze customer usage patterns to identify upsell opportunities'
|
|
253
253
|
properties:
|
|
254
|
-
metrics_analyzed:
|
|
255
|
-
lookback_period:
|
|
254
|
+
metrics_analyzed: 'Feature usage, Resource consumption, Access patterns'
|
|
255
|
+
lookback_period: '90 days'
|
|
256
256
|
menu:
|
|
257
|
-
- label:
|
|
258
|
-
url:
|
|
259
|
-
- label:
|
|
260
|
-
url:
|
|
257
|
+
- label: 'View analytics dashboard'
|
|
258
|
+
url: 'https://analytics.example.com/subscriptions'
|
|
259
|
+
- label: 'Documentation'
|
|
260
|
+
url: 'https://docs.example.com/analytics'
|
|
261
261
|
next_steps:
|
|
262
|
-
- id:
|
|
263
|
-
label:
|
|
264
|
-
- id:
|
|
265
|
-
label:
|
|
262
|
+
- id: 'send_upgrade_recommendation'
|
|
263
|
+
label: 'Usage suggests upgrade opportunity'
|
|
264
|
+
- id: 'flow_ends'
|
|
265
|
+
label: 'No upgrade opportunity identified'
|
|
266
266
|
|
|
267
|
-
- id:
|
|
268
|
-
title:
|
|
267
|
+
- id: 'send_upgrade_recommendation'
|
|
268
|
+
title: 'Send Upgrade Recommendation'
|
|
269
269
|
service:
|
|
270
|
-
id:
|
|
271
|
-
version:
|
|
270
|
+
id: 'NotificationService'
|
|
271
|
+
version: '0.0.2'
|
|
272
272
|
next_step:
|
|
273
|
-
id:
|
|
274
|
-
label:
|
|
275
|
-
|
|
276
|
-
- id: "flow_ends"
|
|
277
|
-
title: "Flow Completed"
|
|
278
|
-
type: "node"
|
|
273
|
+
id: 'flow_ends'
|
|
274
|
+
label: 'Flow completed'
|
|
279
275
|
|
|
276
|
+
- id: 'flow_ends'
|
|
277
|
+
title: 'Flow Completed'
|
|
278
|
+
type: 'node'
|
|
280
279
|
---
|
|
281
280
|
|
|
282
281
|
## Subscription Renewal Flow
|
|
@@ -287,11 +286,11 @@ This flow documents the process of automatic subscription renewals, including ha
|
|
|
287
286
|
|
|
288
287
|
### Key Components
|
|
289
288
|
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
289
|
+
- **Automatic Renewal Process**: Triggered by a scheduled timer when the subscription renewal period is reached
|
|
290
|
+
- **Payment Processing**: Integration with payment gateway and handling of payment failures
|
|
291
|
+
- **Customer Notifications**: Various notifications sent throughout the process
|
|
292
|
+
- **Grace Period Handling**: Special handling when payments fail with a grace period before subscription suspension
|
|
293
|
+
- **Usage Analytics**: Analysis of customer usage patterns to identify upgrade opportunities
|
|
295
294
|
|
|
296
295
|
### Business Rules
|
|
297
296
|
|
|
@@ -1,70 +1,69 @@
|
|
|
1
1
|
---
|
|
2
|
-
id:
|
|
3
|
-
name:
|
|
4
|
-
version:
|
|
5
|
-
summary:
|
|
2
|
+
id: 'CancelSubscription'
|
|
3
|
+
name: 'User Cancels Subscription'
|
|
4
|
+
version: '1.0.0'
|
|
5
|
+
summary: 'Flow for when a user has cancelled a subscription'
|
|
6
6
|
owners:
|
|
7
7
|
- dboyne
|
|
8
8
|
steps:
|
|
9
|
-
- id:
|
|
10
|
-
title:
|
|
11
|
-
summary:
|
|
9
|
+
- id: 'cancel_subscription_initiated'
|
|
10
|
+
title: 'Cancels Subscription'
|
|
11
|
+
summary: 'User cancels their subscription'
|
|
12
12
|
actor:
|
|
13
|
-
name:
|
|
14
|
-
next_step:
|
|
15
|
-
id:
|
|
16
|
-
label:
|
|
13
|
+
name: 'User'
|
|
14
|
+
next_step:
|
|
15
|
+
id: 'cancel_subscription_request'
|
|
16
|
+
label: 'Initiate subscription cancellation'
|
|
17
17
|
|
|
18
|
-
- id:
|
|
19
|
-
title:
|
|
18
|
+
- id: 'cancel_subscription_request'
|
|
19
|
+
title: 'Cancel Subscription'
|
|
20
20
|
message:
|
|
21
|
-
id:
|
|
22
|
-
version:
|
|
23
|
-
next_step:
|
|
24
|
-
id:
|
|
25
|
-
label:
|
|
21
|
+
id: 'CancelSubscription'
|
|
22
|
+
version: '0.0.1'
|
|
23
|
+
next_step:
|
|
24
|
+
id: 'subscription_service'
|
|
25
|
+
label: 'Proceed to subscription service'
|
|
26
26
|
|
|
27
|
-
- id:
|
|
28
|
-
title:
|
|
27
|
+
- id: 'stripe_integration'
|
|
28
|
+
title: 'Stripe'
|
|
29
29
|
externalSystem:
|
|
30
|
-
name:
|
|
31
|
-
summary:
|
|
32
|
-
url:
|
|
33
|
-
next_step:
|
|
34
|
-
id:
|
|
35
|
-
label:
|
|
30
|
+
name: 'Stripe'
|
|
31
|
+
summary: '3rd party payment system'
|
|
32
|
+
url: 'https://stripe.com/'
|
|
33
|
+
next_step:
|
|
34
|
+
id: 'subscription_service'
|
|
35
|
+
label: 'Return to subscription service'
|
|
36
36
|
|
|
37
|
-
- id:
|
|
38
|
-
title:
|
|
37
|
+
- id: 'subscription_service'
|
|
38
|
+
title: 'Subscription Service'
|
|
39
39
|
service:
|
|
40
|
-
id:
|
|
41
|
-
version:
|
|
40
|
+
id: 'SubscriptionService'
|
|
41
|
+
version: '0.0.1'
|
|
42
42
|
next_steps:
|
|
43
|
-
- id:
|
|
44
|
-
label:
|
|
45
|
-
- id:
|
|
46
|
-
label:
|
|
47
|
-
- id:
|
|
48
|
-
label:
|
|
43
|
+
- id: 'stripe_integration'
|
|
44
|
+
label: 'Cancel subscription via Stripe'
|
|
45
|
+
- id: 'subscription_cancelled'
|
|
46
|
+
label: 'Successful cancellation'
|
|
47
|
+
- id: 'subscription_rejected'
|
|
48
|
+
label: 'Failed cancellation'
|
|
49
49
|
|
|
50
|
-
- id:
|
|
51
|
-
title:
|
|
50
|
+
- id: 'subscription_cancelled'
|
|
51
|
+
title: 'Subscription has been Cancelled'
|
|
52
52
|
message:
|
|
53
|
-
id:
|
|
54
|
-
version:
|
|
53
|
+
id: 'UserSubscriptionCancelled'
|
|
54
|
+
version: '0.0.1'
|
|
55
55
|
next_step:
|
|
56
|
-
id:
|
|
57
|
-
label:
|
|
56
|
+
id: 'notification_service'
|
|
57
|
+
label: 'Email customer'
|
|
58
58
|
|
|
59
|
-
- id:
|
|
60
|
-
title:
|
|
59
|
+
- id: 'subscription_rejected'
|
|
60
|
+
title: 'Subscription cancellation has been rejected'
|
|
61
61
|
|
|
62
|
-
- id:
|
|
63
|
-
title:
|
|
62
|
+
- id: 'notification_service'
|
|
63
|
+
title: 'Notifications Service'
|
|
64
64
|
service:
|
|
65
|
-
id:
|
|
66
|
-
version:
|
|
67
|
-
|
|
65
|
+
id: 'NotificationService'
|
|
66
|
+
version: '0.0.2'
|
|
68
67
|
---
|
|
69
68
|
|
|
70
69
|
<NodeGraph />
|