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