@nebulit/embuilder 0.1.39

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 (212) hide show
  1. package/README.md +254 -0
  2. package/dist/cli.d.ts +2 -0
  3. package/dist/cli.js +138 -0
  4. package/package.json +49 -0
  5. package/templates/.claude/hooks/QUICKSTART.md +256 -0
  6. package/templates/.claude/hooks/README.md +533 -0
  7. package/templates/.claude/hooks/analyze-commit.sh +22 -0
  8. package/templates/.claude/hooks/analyze-commit.ts +518 -0
  9. package/templates/.claude/hooks/analyzers/README.md +198 -0
  10. package/templates/.claude/hooks/analyzers/code-quality-checker.ts +154 -0
  11. package/templates/.claude/hooks/analyzers/code-quality.md +54 -0
  12. package/templates/.claude/hooks/analyzers/commit-blocker-example.ts.disabled +110 -0
  13. package/templates/.claude/hooks/analyzers/commit-policy.md +49 -0
  14. package/templates/.claude/hooks/analyzers/event-model-validator.md +49 -0
  15. package/templates/.claude/hooks/analyzers/event-model-validator.ts +169 -0
  16. package/templates/.claude/hooks/analyzers/example-logger.ts +70 -0
  17. package/templates/.claude/hooks/analyzers/slice-scope-validator.md +81 -0
  18. package/templates/.claude/hooks/check-review-result.sh +47 -0
  19. package/templates/.claude/hooks/prepare-review.sh +34 -0
  20. package/templates/.claude/hooks/review-agent-prompt.md +42 -0
  21. package/templates/.claude/hooks/run-review-agent.sh +124 -0
  22. package/templates/.claude/settings.local.json +37 -0
  23. package/templates/.claude/skills/help/README.md +84 -0
  24. package/templates/.claude/skills/help/SKILL.md +393 -0
  25. package/templates/.claude/skills/help/templates/demo-config.json +6753 -0
  26. package/templates/.claude/skills/sample-slices/SKILL.md +8 -0
  27. package/templates/.claude/skills/sample-slices/templates/.slices/Library/addbook/code-slice.json +124 -0
  28. package/templates/.claude/skills/sample-slices/templates/.slices/Library/addbook/slice.json +255 -0
  29. package/templates/.claude/skills/sample-slices/templates/.slices/Library/availablebooks/slice.json +107 -0
  30. package/templates/.claude/skills/sample-slices/templates/.slices/index.json +20 -0
  31. package/templates/.claude/skills/sample-slices/templates/Cart/additem/slice.json +979 -0
  32. package/templates/.claude/skills/sample-slices/templates/Cart/archiveitem/slice.json +529 -0
  33. package/templates/.claude/skills/sample-slices/templates/Cart/cartitems/slice.json +1072 -0
  34. package/templates/.claude/skills/sample-slices/templates/Cart/cartwithproducts/slice.json +394 -0
  35. package/templates/.claude/skills/sample-slices/templates/Cart/changedprices/slice.json +88 -0
  36. package/templates/.claude/skills/sample-slices/templates/Cart/changeinventory/slice.json +264 -0
  37. package/templates/.claude/skills/sample-slices/templates/Cart/changeprice/slice.json +308 -0
  38. package/templates/.claude/skills/sample-slices/templates/Cart/clearcart/slice.json +358 -0
  39. package/templates/.claude/skills/sample-slices/templates/Cart/inventories/slice.json +203 -0
  40. package/templates/.claude/skills/sample-slices/templates/Cart/publishcart/slice.json +876 -0
  41. package/templates/.claude/skills/sample-slices/templates/Cart/removeitem/slice.json +560 -0
  42. package/templates/.claude/skills/sample-slices/templates/Cart/submitcart/slice.json +708 -0
  43. package/templates/.claude/skills/sample-slices/templates/Cart/submittedcartdata/slice.json +399 -0
  44. package/templates/.claude/skills/sample-slices/templates/index.json +108 -0
  45. package/templates/.claude/skills/slice-automation/SKILL.md +49 -0
  46. package/templates/.claude/skills/slice-state-change/SKILL.md +369 -0
  47. package/templates/.claude/skills/slice-state-change/templates/AddLocation/AddLocation.test.ts.sample +76 -0
  48. package/templates/.claude/skills/slice-state-change/templates/AddLocation/AddLocationCommand.ts.sample +84 -0
  49. package/templates/.claude/skills/slice-state-change/templates/AddLocation/routes.ts.sample +73 -0
  50. package/templates/.claude/skills/slice-state-change/templates/README.md +46 -0
  51. package/templates/.claude/skills/slice-state-view/SKILL.md +336 -0
  52. package/templates/.claude/skills/slice-state-view/templates/Locations/Locations.test.ts.sample +84 -0
  53. package/templates/.claude/skills/slice-state-view/templates/Locations/LocationsProjection.ts.sample +50 -0
  54. package/templates/.claude/skills/slice-state-view/templates/Locations/routes.ts.sample +46 -0
  55. package/templates/.claude/skills/slice-state-view/templates/README.md +109 -0
  56. package/templates/.claude/skills/slice-state-view/templates/Tables/Tables.test.ts.sample +104 -0
  57. package/templates/.claude/skills/slice-state-view/templates/Tables/TablesProjection.ts.sample +59 -0
  58. package/templates/.claude/skills/slice-state-view/templates/Tables/routes.ts.sample +46 -0
  59. package/templates/.claude/skills/slice-state-view/templates/V2__tables.sql +7 -0
  60. package/templates/.claude/skills/slice-state-view/templates/V8__locations.sql +7 -0
  61. package/templates/.claude/skills/test-analyzer/SKILL.md +373 -0
  62. package/templates/.claude/skills/test-analyzer/examples/specification-format.md +143 -0
  63. package/templates/.claude/skills/test-analyzer/examples/state-change-example.md +111 -0
  64. package/templates/.claude/skills/test-analyzer/examples/state-view-example.md +122 -0
  65. package/templates/AGENTS.md +110 -0
  66. package/templates/Claude.md +58 -0
  67. package/templates/README.md +178 -0
  68. package/templates/backend/.env +9 -0
  69. package/templates/backend/BACKEND_AUTH_SETUP.md +183 -0
  70. package/templates/backend/SWAGGER.md +213 -0
  71. package/templates/backend/eslint.config.mjs +31 -0
  72. package/templates/backend/flyway.conf +17 -0
  73. package/templates/backend/package.json +44 -0
  74. package/templates/backend/prd.json.example +64 -0
  75. package/templates/backend/public/assets/images/banner.png +0 -0
  76. package/templates/backend/public/assets/logo.png +0 -0
  77. package/templates/backend/public/file.svg +4 -0
  78. package/templates/backend/public/globe.svg +12 -0
  79. package/templates/backend/public/next.svg +6 -0
  80. package/templates/backend/public/vercel.svg +3 -0
  81. package/templates/backend/public/window.svg +5 -0
  82. package/templates/backend/server.ts +129 -0
  83. package/templates/backend/setup-env.sh +50 -0
  84. package/templates/backend/src/common/assertions.ts +6 -0
  85. package/templates/backend/src/common/db.ts +1 -0
  86. package/templates/backend/src/common/loadPostgresEventstore.ts +16 -0
  87. package/templates/backend/src/common/parseEndpoint.ts +51 -0
  88. package/templates/backend/src/common/replay.ts +9 -0
  89. package/templates/backend/src/common/routes.ts +19 -0
  90. package/templates/backend/src/common/testHelpers.ts +53 -0
  91. package/templates/backend/src/core/readmodel.ts +28 -0
  92. package/templates/backend/src/core/types.ts +26 -0
  93. package/templates/backend/src/process/process.ts +53 -0
  94. package/templates/backend/src/supabase/LoginHandler.ts +36 -0
  95. package/templates/backend/src/supabase/ProtectedPageProps.ts +21 -0
  96. package/templates/backend/src/supabase/README.md +171 -0
  97. package/templates/backend/src/supabase/api.ts +63 -0
  98. package/templates/backend/src/supabase/authMiddleware.ts +53 -0
  99. package/templates/backend/src/supabase/component.ts +12 -0
  100. package/templates/backend/src/supabase/requireUser.ts +72 -0
  101. package/templates/backend/src/supabase/serverProps.ts +25 -0
  102. package/templates/backend/src/supabase/staticProps.ts +10 -0
  103. package/templates/backend/src/swagger.ts +34 -0
  104. package/templates/backend/src/util/assertions.ts +6 -0
  105. package/templates/backend/supabase/config.toml +295 -0
  106. package/templates/backend/supabase/migrations/20260121155918593_catalogentries.sql.sample +23 -0
  107. package/templates/backend/supabase/seed.sql +1 -0
  108. package/templates/backend/tsconfig.json +31 -0
  109. package/templates/frontend/.env.development +3 -0
  110. package/templates/frontend/AGENTS.md +7 -0
  111. package/templates/frontend/README.md +73 -0
  112. package/templates/frontend/components.json +20 -0
  113. package/templates/frontend/eslint.config.js +26 -0
  114. package/templates/frontend/index.html +18 -0
  115. package/templates/frontend/package-lock.json +8347 -0
  116. package/templates/frontend/package.json +94 -0
  117. package/templates/frontend/postcss.config.js +6 -0
  118. package/templates/frontend/public/favicon.ico +0 -0
  119. package/templates/frontend/public/logo.png +0 -0
  120. package/templates/frontend/public/placeholder.svg +1 -0
  121. package/templates/frontend/public/robots.txt +14 -0
  122. package/templates/frontend/src/App.css +42 -0
  123. package/templates/frontend/src/App.tsx +47 -0
  124. package/templates/frontend/src/components/NavLink.tsx +28 -0
  125. package/templates/frontend/src/components/ProtectedRoute.tsx +24 -0
  126. package/templates/frontend/src/components/calendar/Calendar.tsx +302 -0
  127. package/templates/frontend/src/components/layout/DashboardLayout.tsx +21 -0
  128. package/templates/frontend/src/components/layout/Header.tsx +45 -0
  129. package/templates/frontend/src/components/layout/Sidebar.tsx +82 -0
  130. package/templates/frontend/src/components/tables/ReservationTemplates.tsx +189 -0
  131. package/templates/frontend/src/components/ui/accordion.tsx +52 -0
  132. package/templates/frontend/src/components/ui/alert-dialog.tsx +104 -0
  133. package/templates/frontend/src/components/ui/alert.tsx +43 -0
  134. package/templates/frontend/src/components/ui/aspect-ratio.tsx +5 -0
  135. package/templates/frontend/src/components/ui/avatar.tsx +38 -0
  136. package/templates/frontend/src/components/ui/badge.tsx +29 -0
  137. package/templates/frontend/src/components/ui/breadcrumb.tsx +90 -0
  138. package/templates/frontend/src/components/ui/button.tsx +47 -0
  139. package/templates/frontend/src/components/ui/calendar.tsx +54 -0
  140. package/templates/frontend/src/components/ui/card.tsx +43 -0
  141. package/templates/frontend/src/components/ui/carousel.tsx +224 -0
  142. package/templates/frontend/src/components/ui/chart.tsx +303 -0
  143. package/templates/frontend/src/components/ui/checkbox.tsx +26 -0
  144. package/templates/frontend/src/components/ui/collapsible.tsx +9 -0
  145. package/templates/frontend/src/components/ui/command.tsx +132 -0
  146. package/templates/frontend/src/components/ui/context-menu.tsx +178 -0
  147. package/templates/frontend/src/components/ui/dialog.tsx +95 -0
  148. package/templates/frontend/src/components/ui/drawer.tsx +87 -0
  149. package/templates/frontend/src/components/ui/dropdown-menu.tsx +179 -0
  150. package/templates/frontend/src/components/ui/form.tsx +129 -0
  151. package/templates/frontend/src/components/ui/hover-card.tsx +27 -0
  152. package/templates/frontend/src/components/ui/input-otp.tsx +61 -0
  153. package/templates/frontend/src/components/ui/input.tsx +22 -0
  154. package/templates/frontend/src/components/ui/label.tsx +17 -0
  155. package/templates/frontend/src/components/ui/menubar.tsx +207 -0
  156. package/templates/frontend/src/components/ui/navigation-menu.tsx +120 -0
  157. package/templates/frontend/src/components/ui/pagination.tsx +81 -0
  158. package/templates/frontend/src/components/ui/popover.tsx +29 -0
  159. package/templates/frontend/src/components/ui/progress.tsx +23 -0
  160. package/templates/frontend/src/components/ui/radio-group.tsx +36 -0
  161. package/templates/frontend/src/components/ui/resizable.tsx +37 -0
  162. package/templates/frontend/src/components/ui/scroll-area.tsx +38 -0
  163. package/templates/frontend/src/components/ui/select.tsx +143 -0
  164. package/templates/frontend/src/components/ui/separator.tsx +20 -0
  165. package/templates/frontend/src/components/ui/sheet.tsx +107 -0
  166. package/templates/frontend/src/components/ui/sidebar.tsx +637 -0
  167. package/templates/frontend/src/components/ui/skeleton.tsx +7 -0
  168. package/templates/frontend/src/components/ui/slider.tsx +23 -0
  169. package/templates/frontend/src/components/ui/sonner.tsx +27 -0
  170. package/templates/frontend/src/components/ui/stat-card.tsx +44 -0
  171. package/templates/frontend/src/components/ui/switch.tsx +27 -0
  172. package/templates/frontend/src/components/ui/table.tsx +72 -0
  173. package/templates/frontend/src/components/ui/tabs.tsx +53 -0
  174. package/templates/frontend/src/components/ui/textarea.tsx +21 -0
  175. package/templates/frontend/src/components/ui/toast.tsx +111 -0
  176. package/templates/frontend/src/components/ui/toaster.tsx +24 -0
  177. package/templates/frontend/src/components/ui/toggle-group.tsx +49 -0
  178. package/templates/frontend/src/components/ui/toggle.tsx +37 -0
  179. package/templates/frontend/src/components/ui/tooltip.tsx +28 -0
  180. package/templates/frontend/src/components/ui/use-toast.ts +3 -0
  181. package/templates/frontend/src/contexts/AuthContext.tsx +94 -0
  182. package/templates/frontend/src/contexts/RefreshContext.tsx +236 -0
  183. package/templates/frontend/src/hooks/api/index.ts +2 -0
  184. package/templates/frontend/src/hooks/api/useLocations.ts +15 -0
  185. package/templates/frontend/src/hooks/use-mobile.tsx +19 -0
  186. package/templates/frontend/src/hooks/use-toast.ts +186 -0
  187. package/templates/frontend/src/hooks/useApiContext.ts +11 -0
  188. package/templates/frontend/src/index.css +118 -0
  189. package/templates/frontend/src/integrations/supabase/client.ts +9 -0
  190. package/templates/frontend/src/lib/api-client.ts +136 -0
  191. package/templates/frontend/src/lib/api.ts +1028 -0
  192. package/templates/frontend/src/lib/utils.ts +6 -0
  193. package/templates/frontend/src/main.tsx +5 -0
  194. package/templates/frontend/src/pages/Auth.tsx +408 -0
  195. package/templates/frontend/src/pages/Dashboard.tsx +168 -0
  196. package/templates/frontend/src/pages/Menus.tsx +224 -0
  197. package/templates/frontend/src/pages/NotFound.tsx +24 -0
  198. package/templates/frontend/src/pages/Register.tsx +285 -0
  199. package/templates/frontend/src/test/example.test.ts +0 -0
  200. package/templates/frontend/src/test/setup.ts +15 -0
  201. package/templates/frontend/src/types/index.ts +8 -0
  202. package/templates/frontend/src/vite-env.d.ts +1 -0
  203. package/templates/frontend/tailwind.config.ts +101 -0
  204. package/templates/frontend/tsconfig.app.json +31 -0
  205. package/templates/frontend/tsconfig.json +16 -0
  206. package/templates/frontend/tsconfig.node.json +22 -0
  207. package/templates/frontend/vite.config.ts +21 -0
  208. package/templates/frontend/vitest.config.ts +16 -0
  209. package/templates/init.sh +1 -0
  210. package/templates/prompt.md +139 -0
  211. package/templates/ralph.sh +120 -0
  212. package/templates/server.mjs +505 -0
@@ -0,0 +1,876 @@
1
+ {
2
+ "id": "3458764596112734544",
3
+ "status": "Done",
4
+ "title": "slice: publish cart",
5
+ "context": "Cart",
6
+ "sliceType": "STATE_CHANGE",
7
+ "commands": [
8
+ {
9
+ "id": "3458764596112734332",
10
+ "tags": [],
11
+ "domain": "Cart",
12
+ "elementContext": "INTERNAL",
13
+ "modelContext": "Cart",
14
+ "context": "INTERNAL",
15
+ "slice": "slice: publish cart",
16
+ "title": "Publish Cart",
17
+ "fields": [
18
+ {
19
+ "name": "aggregateId",
20
+ "type": "UUID",
21
+ "example": "",
22
+ "mapping": "",
23
+ "optional": false,
24
+ "cardinality": "Single",
25
+ "idAttribute": false
26
+ },
27
+ {
28
+ "name": "orderedProducts",
29
+ "type": "Custom",
30
+ "example": "productId, price",
31
+ "mapping": "",
32
+ "optional": false,
33
+ "cardinality": "List",
34
+ "idAttribute": false
35
+ },
36
+ {
37
+ "name": "totalPrice",
38
+ "type": "Double",
39
+ "example": "",
40
+ "mapping": "orderedProducts",
41
+ "optional": false,
42
+ "cardinality": "Single",
43
+ "idAttribute": false
44
+ }
45
+ ],
46
+ "type": "COMMAND",
47
+ "description": "",
48
+ "aggregate": "Cart",
49
+ "aggregateDependencies": [
50
+ "Cart"
51
+ ],
52
+ "dependencies": [
53
+ {
54
+ "id": "3458764599253812385",
55
+ "type": "OUTBOUND",
56
+ "title": "Cart Publication Failed",
57
+ "elementType": "EVENT"
58
+ },
59
+ {
60
+ "id": "3458764599014166815",
61
+ "type": "OUTBOUND",
62
+ "title": "Cart Published",
63
+ "elementType": "EVENT"
64
+ },
65
+ {
66
+ "id": "3458764596112850382",
67
+ "type": "OUTBOUND",
68
+ "title": "External Cart Published",
69
+ "elementType": "EVENT"
70
+ },
71
+ {
72
+ "id": "3458764596112734108",
73
+ "type": "INBOUND",
74
+ "title": "automation",
75
+ "elementType": "AUTOMATION"
76
+ }
77
+ ],
78
+ "apiEndpoint": "",
79
+ "createsAggregate": false,
80
+ "triggers": [],
81
+ "sketched": false,
82
+ "prototype": {
83
+ "activeByDefault": false
84
+ }
85
+ }
86
+ ],
87
+ "events": [
88
+ {
89
+ "id": "3458764596112850382",
90
+ "tags": [],
91
+ "domain": "Cart",
92
+ "elementContext": "EXTERNAL",
93
+ "modelContext": "Cart",
94
+ "context": "EXTERNAL",
95
+ "slice": "slice: publish cart",
96
+ "title": "External Cart Published",
97
+ "fields": [
98
+ {
99
+ "name": "aggregateId",
100
+ "type": "UUID",
101
+ "example": "",
102
+ "mapping": "",
103
+ "optional": false,
104
+ "cardinality": "Single",
105
+ "idAttribute": false
106
+ },
107
+ {
108
+ "name": "orderedProducts",
109
+ "type": "Custom",
110
+ "example": "productId, price",
111
+ "mapping": "",
112
+ "optional": false,
113
+ "cardinality": "List",
114
+ "idAttribute": false
115
+ },
116
+ {
117
+ "name": "totalPrice",
118
+ "type": "Double",
119
+ "example": "",
120
+ "mapping": "orderedProducts",
121
+ "optional": false,
122
+ "cardinality": "Single",
123
+ "idAttribute": false
124
+ }
125
+ ],
126
+ "type": "EVENT",
127
+ "description": "",
128
+ "aggregate": "Cart",
129
+ "aggregateDependencies": [
130
+ "Cart"
131
+ ],
132
+ "dependencies": [
133
+ {
134
+ "id": "3458764596112734332",
135
+ "type": "INBOUND",
136
+ "title": "Publish Cart",
137
+ "elementType": "COMMAND"
138
+ }
139
+ ],
140
+ "apiEndpoint": "",
141
+ "createsAggregate": false,
142
+ "triggers": [],
143
+ "sketched": false,
144
+ "prototype": {
145
+ "activeByDefault": false
146
+ }
147
+ },
148
+ {
149
+ "id": "3458764599253812385",
150
+ "tags": [],
151
+ "domain": "Cart",
152
+ "elementContext": "INTERNAL",
153
+ "modelContext": "Cart",
154
+ "context": "INTERNAL",
155
+ "slice": "slice: publish cart",
156
+ "title": "Cart Publication Failed",
157
+ "fields": [
158
+ {
159
+ "name": "aggregateId",
160
+ "type": "UUID",
161
+ "example": "",
162
+ "mapping": "",
163
+ "optional": false,
164
+ "cardinality": "Single",
165
+ "idAttribute": false
166
+ }
167
+ ],
168
+ "type": "EVENT",
169
+ "description": "",
170
+ "aggregate": "Cart",
171
+ "aggregateDependencies": [
172
+ "Cart"
173
+ ],
174
+ "dependencies": [
175
+ {
176
+ "id": "3458764596112734332",
177
+ "type": "INBOUND",
178
+ "title": "Publish Cart",
179
+ "elementType": "COMMAND"
180
+ }
181
+ ],
182
+ "apiEndpoint": "",
183
+ "createsAggregate": false,
184
+ "triggers": [],
185
+ "sketched": false,
186
+ "prototype": {
187
+ "activeByDefault": false
188
+ }
189
+ },
190
+ {
191
+ "id": "3458764599014166815",
192
+ "tags": [],
193
+ "domain": "Cart",
194
+ "elementContext": "INTERNAL",
195
+ "modelContext": "Cart",
196
+ "context": "INTERNAL",
197
+ "slice": "slice: publish cart",
198
+ "title": "Cart Published",
199
+ "fields": [
200
+ {
201
+ "name": "aggregateId",
202
+ "type": "UUID",
203
+ "example": "",
204
+ "mapping": "",
205
+ "optional": false,
206
+ "cardinality": "Single",
207
+ "idAttribute": false
208
+ }
209
+ ],
210
+ "type": "EVENT",
211
+ "description": "",
212
+ "aggregate": "Cart",
213
+ "aggregateDependencies": [
214
+ "Cart"
215
+ ],
216
+ "dependencies": [
217
+ {
218
+ "id": "3458764596112734332",
219
+ "type": "INBOUND",
220
+ "title": "Publish Cart",
221
+ "elementType": "COMMAND"
222
+ }
223
+ ],
224
+ "apiEndpoint": "",
225
+ "createsAggregate": false,
226
+ "triggers": [],
227
+ "sketched": false,
228
+ "prototype": {
229
+ "activeByDefault": false
230
+ }
231
+ }
232
+ ],
233
+ "readmodels": [],
234
+ "screens": [],
235
+ "screenImages": [],
236
+ "screenLayouts": [],
237
+ "processors": [
238
+ {
239
+ "id": "3458764596112734108",
240
+ "tags": [],
241
+ "domain": "Cart",
242
+ "elementContext": "INTERNAL",
243
+ "modelContext": "Cart",
244
+ "context": "INTERNAL",
245
+ "slice": "slice: publish cart",
246
+ "title": "automation",
247
+ "fields": [
248
+ {
249
+ "name": "aggregateId",
250
+ "type": "UUID",
251
+ "example": "",
252
+ "mapping": "",
253
+ "optional": false,
254
+ "cardinality": "Single",
255
+ "idAttribute": false
256
+ },
257
+ {
258
+ "name": "orderedProducts",
259
+ "type": "Custom",
260
+ "example": "productId, price",
261
+ "mapping": "",
262
+ "optional": false,
263
+ "cardinality": "List",
264
+ "idAttribute": false
265
+ },
266
+ {
267
+ "name": "totalPrice",
268
+ "type": "Double",
269
+ "example": "",
270
+ "mapping": "orderedProducts",
271
+ "optional": false,
272
+ "cardinality": "Single",
273
+ "idAttribute": false
274
+ }
275
+ ],
276
+ "type": "AUTOMATION",
277
+ "description": "",
278
+ "aggregate": "Cart",
279
+ "aggregateDependencies": [
280
+ "Cart"
281
+ ],
282
+ "dependencies": [
283
+ {
284
+ "id": "3458764596112734332",
285
+ "type": "OUTBOUND",
286
+ "title": "Publish Cart",
287
+ "elementType": "COMMAND"
288
+ },
289
+ {
290
+ "id": "3458764596111217572",
291
+ "type": "INBOUND",
292
+ "title": "Submitted Cart Data",
293
+ "elementType": "READMODEL"
294
+ }
295
+ ],
296
+ "apiEndpoint": "",
297
+ "createsAggregate": false,
298
+ "triggers": [],
299
+ "sketched": false,
300
+ "prototype": {
301
+ "activeByDefault": false
302
+ }
303
+ }
304
+ ],
305
+ "tables": [],
306
+ "specifications": [
307
+ {
308
+ "vertical": false,
309
+ "id": "3458764599254252536",
310
+ "sliceName": "slice: publish cart",
311
+ "title": "spec: publish cart after publication",
312
+ "given": [
313
+ {
314
+ "title": "Cart Published",
315
+ "tags": [],
316
+ "id": "3458764599254252542",
317
+ "index": 3,
318
+ "type": "SPEC_EVENT",
319
+ "fields": [
320
+ {
321
+ "name": "aggregateId",
322
+ "type": "UUID",
323
+ "example": "",
324
+ "mapping": "",
325
+ "optional": false,
326
+ "cardinality": "Single",
327
+ "subfields": []
328
+ }
329
+ ],
330
+ "linkedId": "3458764599014166815"
331
+ },
332
+ {
333
+ "title": "Cart Submitted",
334
+ "tags": [],
335
+ "id": "3458764599254252541",
336
+ "index": 2,
337
+ "type": "SPEC_EVENT",
338
+ "fields": [
339
+ {
340
+ "name": "aggregateId",
341
+ "type": "UUID",
342
+ "example": "",
343
+ "mapping": "",
344
+ "optional": false,
345
+ "cardinality": "Single",
346
+ "subfields": []
347
+ },
348
+ {
349
+ "name": "orderedProducts",
350
+ "type": "Custom",
351
+ "example": "productId, price",
352
+ "mapping": "",
353
+ "optional": false,
354
+ "cardinality": "List",
355
+ "subfields": []
356
+ },
357
+ {
358
+ "name": "totalPrice",
359
+ "type": "Double",
360
+ "example": "",
361
+ "mapping": "orderedProducts",
362
+ "optional": false,
363
+ "cardinality": "Single",
364
+ "subfields": []
365
+ }
366
+ ],
367
+ "linkedId": "3458764595641022547"
368
+ },
369
+ {
370
+ "title": "Item Added",
371
+ "tags": [],
372
+ "id": "3458764599254252540",
373
+ "index": 1,
374
+ "type": "SPEC_EVENT",
375
+ "fields": [
376
+ {
377
+ "name": "aggregateId",
378
+ "type": "UUID",
379
+ "example": "",
380
+ "mapping": "",
381
+ "optional": false,
382
+ "cardinality": "Single",
383
+ "subfields": []
384
+ },
385
+ {
386
+ "name": "description",
387
+ "type": "String",
388
+ "example": "",
389
+ "mapping": "",
390
+ "optional": false,
391
+ "cardinality": "Single",
392
+ "subfields": []
393
+ },
394
+ {
395
+ "name": "image",
396
+ "type": "String",
397
+ "example": "",
398
+ "mapping": "",
399
+ "optional": false,
400
+ "cardinality": "Single",
401
+ "subfields": []
402
+ },
403
+ {
404
+ "name": "price",
405
+ "type": "Double",
406
+ "example": "",
407
+ "mapping": "",
408
+ "optional": false,
409
+ "cardinality": "Single",
410
+ "subfields": []
411
+ },
412
+ {
413
+ "name": "itemId",
414
+ "type": "UUID",
415
+ "example": "",
416
+ "mapping": "",
417
+ "optional": false,
418
+ "cardinality": "Single",
419
+ "subfields": []
420
+ },
421
+ {
422
+ "name": "productId",
423
+ "type": "UUID",
424
+ "example": "",
425
+ "mapping": "",
426
+ "optional": false,
427
+ "cardinality": "Single",
428
+ "subfields": []
429
+ }
430
+ ],
431
+ "linkedId": "3458764595631345476"
432
+ },
433
+ {
434
+ "title": "Cart Created",
435
+ "tags": [],
436
+ "id": "3458764599254252539",
437
+ "index": 0,
438
+ "type": "SPEC_EVENT",
439
+ "fields": [
440
+ {
441
+ "name": "aggregateId",
442
+ "type": "UUID",
443
+ "example": "",
444
+ "mapping": "",
445
+ "optional": false,
446
+ "cardinality": "Single",
447
+ "subfields": []
448
+ }
449
+ ],
450
+ "linkedId": "3458764596402400430"
451
+ }
452
+ ],
453
+ "when": [
454
+ {
455
+ "title": "Publish Cart",
456
+ "tags": [],
457
+ "id": "3458764599254252543",
458
+ "index": 0,
459
+ "type": "SPEC_COMMAND",
460
+ "fields": [
461
+ {
462
+ "name": "aggregateId",
463
+ "type": "UUID",
464
+ "example": "",
465
+ "mapping": "",
466
+ "optional": false,
467
+ "cardinality": "Single",
468
+ "subfields": []
469
+ },
470
+ {
471
+ "name": "orderedProducts",
472
+ "type": "Custom",
473
+ "example": "productId, price",
474
+ "mapping": "",
475
+ "optional": false,
476
+ "cardinality": "List",
477
+ "subfields": []
478
+ },
479
+ {
480
+ "name": "totalPrice",
481
+ "type": "Double",
482
+ "example": "",
483
+ "mapping": "orderedProducts",
484
+ "optional": false,
485
+ "cardinality": "Single",
486
+ "subfields": []
487
+ }
488
+ ],
489
+ "linkedId": "3458764596112734332"
490
+ }
491
+ ],
492
+ "then": [
493
+ {
494
+ "title": "Cart Publication Failed",
495
+ "tags": [],
496
+ "id": "3458764599254252544",
497
+ "index": 0,
498
+ "type": "SPEC_EVENT",
499
+ "fields": [
500
+ {
501
+ "name": "aggregateId",
502
+ "type": "UUID",
503
+ "example": "",
504
+ "mapping": "",
505
+ "optional": false,
506
+ "cardinality": "Single",
507
+ "subfields": []
508
+ }
509
+ ],
510
+ "linkedId": "3458764599253812385"
511
+ }
512
+ ],
513
+ "comments": [
514
+ {
515
+ "description": "cannot republish a cart"
516
+ }
517
+ ],
518
+ "linkedId": "3458764596112734544"
519
+ },
520
+ {
521
+ "vertical": false,
522
+ "id": "3458764599254119458",
523
+ "sliceName": "slice: publish cart",
524
+ "title": "spec: publish cart unsubmitted",
525
+ "given": [
526
+ {
527
+ "title": "Item Added",
528
+ "tags": [],
529
+ "id": "3458764599254119460",
530
+ "index": 1,
531
+ "type": "SPEC_EVENT",
532
+ "fields": [
533
+ {
534
+ "name": "aggregateId",
535
+ "type": "UUID",
536
+ "example": "",
537
+ "mapping": "",
538
+ "optional": false,
539
+ "cardinality": "Single",
540
+ "subfields": []
541
+ },
542
+ {
543
+ "name": "description",
544
+ "type": "String",
545
+ "example": "",
546
+ "mapping": "",
547
+ "optional": false,
548
+ "cardinality": "Single",
549
+ "subfields": []
550
+ },
551
+ {
552
+ "name": "image",
553
+ "type": "String",
554
+ "example": "",
555
+ "mapping": "",
556
+ "optional": false,
557
+ "cardinality": "Single",
558
+ "subfields": []
559
+ },
560
+ {
561
+ "name": "price",
562
+ "type": "Double",
563
+ "example": "",
564
+ "mapping": "",
565
+ "optional": false,
566
+ "cardinality": "Single",
567
+ "subfields": []
568
+ },
569
+ {
570
+ "name": "itemId",
571
+ "type": "UUID",
572
+ "example": "",
573
+ "mapping": "",
574
+ "optional": false,
575
+ "cardinality": "Single",
576
+ "subfields": []
577
+ },
578
+ {
579
+ "name": "productId",
580
+ "type": "UUID",
581
+ "example": "",
582
+ "mapping": "",
583
+ "optional": false,
584
+ "cardinality": "Single",
585
+ "subfields": []
586
+ }
587
+ ],
588
+ "linkedId": "3458764595631345476"
589
+ },
590
+ {
591
+ "title": "Cart Created",
592
+ "tags": [],
593
+ "id": "3458764599254119459",
594
+ "index": 0,
595
+ "type": "SPEC_EVENT",
596
+ "fields": [
597
+ {
598
+ "name": "aggregateId",
599
+ "type": "UUID",
600
+ "example": "",
601
+ "mapping": "",
602
+ "optional": false,
603
+ "cardinality": "Single",
604
+ "subfields": []
605
+ }
606
+ ],
607
+ "linkedId": "3458764596402400430"
608
+ }
609
+ ],
610
+ "when": [
611
+ {
612
+ "title": "Publish Cart",
613
+ "tags": [],
614
+ "id": "3458764599254119461",
615
+ "index": 0,
616
+ "type": "SPEC_COMMAND",
617
+ "fields": [
618
+ {
619
+ "name": "aggregateId",
620
+ "type": "UUID",
621
+ "example": "",
622
+ "mapping": "",
623
+ "optional": false,
624
+ "cardinality": "Single",
625
+ "subfields": []
626
+ },
627
+ {
628
+ "name": "orderedProducts",
629
+ "type": "Custom",
630
+ "example": "productId, price",
631
+ "mapping": "",
632
+ "optional": false,
633
+ "cardinality": "List",
634
+ "subfields": []
635
+ },
636
+ {
637
+ "name": "totalPrice",
638
+ "type": "Double",
639
+ "example": "",
640
+ "mapping": "orderedProducts",
641
+ "optional": false,
642
+ "cardinality": "Single",
643
+ "subfields": []
644
+ }
645
+ ],
646
+ "linkedId": "3458764596112734332"
647
+ }
648
+ ],
649
+ "then": [
650
+ {
651
+ "title": "Cart Publication Failed",
652
+ "tags": [],
653
+ "id": "3458764599254119462",
654
+ "index": 0,
655
+ "type": "SPEC_EVENT",
656
+ "fields": [
657
+ {
658
+ "name": "aggregateId",
659
+ "type": "UUID",
660
+ "example": "",
661
+ "mapping": "",
662
+ "optional": false,
663
+ "cardinality": "Single",
664
+ "subfields": []
665
+ }
666
+ ],
667
+ "linkedId": "3458764599253812385"
668
+ }
669
+ ],
670
+ "comments": [
671
+ {
672
+ "description": "cannot publish an unsubmitted cart"
673
+ }
674
+ ],
675
+ "linkedId": "3458764596112734544"
676
+ },
677
+ {
678
+ "vertical": false,
679
+ "id": "3458764599057291070",
680
+ "sliceName": "slice: publish cart",
681
+ "title": "spec: publish cart",
682
+ "given": [
683
+ {
684
+ "title": "Cart Submitted",
685
+ "tags": [],
686
+ "id": "3458764599057291075",
687
+ "index": 2,
688
+ "type": "SPEC_EVENT",
689
+ "fields": [
690
+ {
691
+ "name": "aggregateId",
692
+ "type": "UUID",
693
+ "example": "",
694
+ "mapping": "",
695
+ "optional": false,
696
+ "cardinality": "Single",
697
+ "subfields": []
698
+ },
699
+ {
700
+ "name": "orderedProducts",
701
+ "type": "Custom",
702
+ "example": "productId, price",
703
+ "mapping": "",
704
+ "optional": false,
705
+ "cardinality": "List",
706
+ "subfields": []
707
+ },
708
+ {
709
+ "name": "totalPrice",
710
+ "type": "Double",
711
+ "example": "",
712
+ "mapping": "orderedProducts",
713
+ "optional": false,
714
+ "cardinality": "Single",
715
+ "subfields": []
716
+ }
717
+ ],
718
+ "linkedId": "3458764595641022547"
719
+ },
720
+ {
721
+ "title": "Item Added",
722
+ "tags": [],
723
+ "id": "3458764599057291074",
724
+ "index": 1,
725
+ "type": "SPEC_EVENT",
726
+ "fields": [
727
+ {
728
+ "name": "aggregateId",
729
+ "type": "UUID",
730
+ "example": "",
731
+ "mapping": "",
732
+ "optional": false,
733
+ "cardinality": "Single",
734
+ "subfields": []
735
+ },
736
+ {
737
+ "name": "description",
738
+ "type": "String",
739
+ "example": "",
740
+ "mapping": "",
741
+ "optional": false,
742
+ "cardinality": "Single",
743
+ "subfields": []
744
+ },
745
+ {
746
+ "name": "image",
747
+ "type": "String",
748
+ "example": "",
749
+ "mapping": "",
750
+ "optional": false,
751
+ "cardinality": "Single",
752
+ "subfields": []
753
+ },
754
+ {
755
+ "name": "price",
756
+ "type": "Double",
757
+ "example": "",
758
+ "mapping": "",
759
+ "optional": false,
760
+ "cardinality": "Single",
761
+ "subfields": []
762
+ },
763
+ {
764
+ "name": "itemId",
765
+ "type": "UUID",
766
+ "example": "",
767
+ "mapping": "",
768
+ "optional": false,
769
+ "cardinality": "Single",
770
+ "subfields": []
771
+ },
772
+ {
773
+ "name": "productId",
774
+ "type": "UUID",
775
+ "example": "",
776
+ "mapping": "",
777
+ "optional": false,
778
+ "cardinality": "Single",
779
+ "subfields": []
780
+ }
781
+ ],
782
+ "linkedId": "3458764595631345476"
783
+ },
784
+ {
785
+ "title": "Cart Created",
786
+ "tags": [],
787
+ "id": "3458764599057291073",
788
+ "index": 0,
789
+ "type": "SPEC_EVENT",
790
+ "fields": [
791
+ {
792
+ "name": "aggregateId",
793
+ "type": "UUID",
794
+ "example": "",
795
+ "mapping": "",
796
+ "optional": false,
797
+ "cardinality": "Single",
798
+ "subfields": []
799
+ }
800
+ ],
801
+ "linkedId": "3458764596402400430"
802
+ }
803
+ ],
804
+ "when": [
805
+ {
806
+ "title": "Publish Cart",
807
+ "tags": [],
808
+ "id": "3458764599057291076",
809
+ "index": 0,
810
+ "type": "SPEC_COMMAND",
811
+ "fields": [
812
+ {
813
+ "name": "aggregateId",
814
+ "type": "UUID",
815
+ "example": "",
816
+ "mapping": "",
817
+ "optional": false,
818
+ "cardinality": "Single",
819
+ "subfields": []
820
+ },
821
+ {
822
+ "name": "orderedProducts",
823
+ "type": "Custom",
824
+ "example": "productId, price",
825
+ "mapping": "",
826
+ "optional": false,
827
+ "cardinality": "List",
828
+ "subfields": []
829
+ },
830
+ {
831
+ "name": "totalPrice",
832
+ "type": "Double",
833
+ "example": "",
834
+ "mapping": "orderedProducts",
835
+ "optional": false,
836
+ "cardinality": "Single",
837
+ "subfields": []
838
+ }
839
+ ],
840
+ "linkedId": "3458764596112734332"
841
+ }
842
+ ],
843
+ "then": [
844
+ {
845
+ "title": "Cart Published",
846
+ "tags": [],
847
+ "id": "3458764599057291077",
848
+ "index": 0,
849
+ "type": "SPEC_EVENT",
850
+ "fields": [
851
+ {
852
+ "name": "aggregateId",
853
+ "type": "UUID",
854
+ "example": "",
855
+ "mapping": "",
856
+ "optional": false,
857
+ "cardinality": "Single",
858
+ "subfields": []
859
+ }
860
+ ],
861
+ "linkedId": "3458764599014166815"
862
+ }
863
+ ],
864
+ "comments": [],
865
+ "linkedId": "3458764596112734544"
866
+ }
867
+ ],
868
+ "actors": [
869
+ {
870
+ "name": "bots"
871
+ }
872
+ ],
873
+ "aggregates": [
874
+ "Cart"
875
+ ]
876
+ }