@fougere/core 0.5.0-alpha.1 → 0.7.0-alpha.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 (519) hide show
  1. package/README.md +1 -1
  2. package/dist/boot/Emissions.d.ts +14 -91
  3. package/dist/boot/Emissions.d.ts.map +1 -1
  4. package/dist/boot/Emissions.js +21 -118
  5. package/dist/boot/Emissions.js.map +1 -1
  6. package/dist/boot/ambient-port.d.ts +3 -24
  7. package/dist/boot/ambient-port.d.ts.map +1 -1
  8. package/dist/boot/ambient.als.d.ts.map +1 -1
  9. package/dist/boot/ambient.als.js +7 -12
  10. package/dist/boot/ambient.als.js.map +1 -1
  11. package/dist/boot/ambient.queue.d.ts +2 -5
  12. package/dist/boot/ambient.queue.d.ts.map +1 -1
  13. package/dist/boot/ambient.queue.js.map +1 -1
  14. package/dist/boot/apply.d.ts +1 -13
  15. package/dist/boot/apply.d.ts.map +1 -1
  16. package/dist/boot/apply.js +3 -15
  17. package/dist/boot/apply.js.map +1 -1
  18. package/dist/boot/auth.d.ts +6 -16
  19. package/dist/boot/auth.d.ts.map +1 -1
  20. package/dist/boot/boot.d.ts +5 -18
  21. package/dist/boot/boot.d.ts.map +1 -1
  22. package/dist/boot/boot.js +4 -11
  23. package/dist/boot/boot.js.map +1 -1
  24. package/dist/boot/bootstrap.d.ts.map +1 -1
  25. package/dist/boot/bootstrap.js +106 -163
  26. package/dist/boot/bootstrap.js.map +1 -1
  27. package/dist/boot/card.d.ts +5 -0
  28. package/dist/boot/card.d.ts.map +1 -0
  29. package/dist/boot/card.js +71 -0
  30. package/dist/boot/card.js.map +1 -0
  31. package/dist/boot/frame.d.ts +8 -32
  32. package/dist/boot/frame.d.ts.map +1 -1
  33. package/dist/boot/frame.js +23 -57
  34. package/dist/boot/frame.js.map +1 -1
  35. package/dist/boot/hosted.d.ts +3 -19
  36. package/dist/boot/hosted.d.ts.map +1 -1
  37. package/dist/boot/hosted.js +12 -17
  38. package/dist/boot/hosted.js.map +1 -1
  39. package/dist/boot/ownership.d.ts +5 -36
  40. package/dist/boot/ownership.d.ts.map +1 -1
  41. package/dist/boot/ownership.js +9 -49
  42. package/dist/boot/ownership.js.map +1 -1
  43. package/dist/boot/ports.d.ts +2 -15
  44. package/dist/boot/ports.d.ts.map +1 -1
  45. package/dist/boot/ports.js +1 -14
  46. package/dist/boot/ports.js.map +1 -1
  47. package/dist/boot/remote.d.ts +5 -38
  48. package/dist/boot/remote.d.ts.map +1 -1
  49. package/dist/boot/remote.js +8 -41
  50. package/dist/boot/remote.js.map +1 -1
  51. package/dist/boot/runner.d.ts +11 -0
  52. package/dist/boot/runner.d.ts.map +1 -0
  53. package/dist/boot/runner.js +13 -0
  54. package/dist/boot/runner.js.map +1 -0
  55. package/dist/boot/seed.d.ts +5 -32
  56. package/dist/boot/seed.d.ts.map +1 -1
  57. package/dist/boot/seed.js +10 -41
  58. package/dist/boot/seed.js.map +1 -1
  59. package/dist/boot/statement-drift.d.ts +4 -22
  60. package/dist/boot/statement-drift.d.ts.map +1 -1
  61. package/dist/boot/statement-drift.js +4 -9
  62. package/dist/boot/statement-drift.js.map +1 -1
  63. package/dist/boot/together.d.ts +8 -12
  64. package/dist/boot/together.d.ts.map +1 -1
  65. package/dist/boot/together.js +28 -65
  66. package/dist/boot/together.js.map +1 -1
  67. package/dist/boot/types.d.ts +36 -180
  68. package/dist/boot/types.d.ts.map +1 -1
  69. package/dist/builtin/config.d.ts +7 -0
  70. package/dist/builtin/config.d.ts.map +1 -0
  71. package/dist/builtin/config.js +15 -0
  72. package/dist/builtin/config.js.map +1 -0
  73. package/dist/{builtins → builtin}/logger.d.ts +4 -25
  74. package/dist/builtin/logger.d.ts.map +1 -0
  75. package/dist/{builtins → builtin}/logger.js +5 -32
  76. package/dist/builtin/logger.js.map +1 -0
  77. package/dist/config-loader.d.ts +9 -67
  78. package/dist/config-loader.d.ts.map +1 -1
  79. package/dist/config-loader.js +5 -18
  80. package/dist/config-loader.js.map +1 -1
  81. package/dist/contract.d.ts +13 -31
  82. package/dist/contract.d.ts.map +1 -1
  83. package/dist/contract.js +10 -26
  84. package/dist/contract.js.map +1 -1
  85. package/dist/crypto/encoding.d.ts +2 -15
  86. package/dist/crypto/encoding.d.ts.map +1 -1
  87. package/dist/crypto/encoding.js +2 -15
  88. package/dist/crypto/encoding.js.map +1 -1
  89. package/dist/crypto/node.d.ts.map +1 -1
  90. package/dist/crypto/node.js +1 -7
  91. package/dist/crypto/node.js.map +1 -1
  92. package/dist/crypto/port.d.ts +2 -18
  93. package/dist/crypto/port.d.ts.map +1 -1
  94. package/dist/crypto/port.js +1 -17
  95. package/dist/crypto/port.js.map +1 -1
  96. package/dist/crypto/webcrypto.d.ts.map +1 -1
  97. package/dist/crypto/webcrypto.js +1 -12
  98. package/dist/crypto/webcrypto.js.map +1 -1
  99. package/dist/declare.d.ts +41 -0
  100. package/dist/declare.d.ts.map +1 -0
  101. package/dist/{scan/declare.js → declare.js} +6 -31
  102. package/dist/declare.js.map +1 -0
  103. package/dist/define.d.ts +2 -3
  104. package/dist/define.d.ts.map +1 -1
  105. package/dist/define.js +2 -3
  106. package/dist/define.js.map +1 -1
  107. package/dist/descriptor/Fronds.d.ts +19 -0
  108. package/dist/descriptor/Fronds.d.ts.map +1 -0
  109. package/dist/descriptor/Fronds.js +40 -0
  110. package/dist/descriptor/Fronds.js.map +1 -0
  111. package/dist/descriptor/frond.d.ts +135 -0
  112. package/dist/descriptor/frond.d.ts.map +1 -0
  113. package/dist/{scan → descriptor}/frond.js.map +1 -1
  114. package/dist/dispatch/ArgumentResolver.d.ts +6 -3
  115. package/dist/dispatch/ArgumentResolver.d.ts.map +1 -1
  116. package/dist/dispatch/ArgumentResolver.js +48 -3
  117. package/dist/dispatch/ArgumentResolver.js.map +1 -1
  118. package/dist/dispatch/DispatchEvent.d.ts +2 -2
  119. package/dist/dispatch/DispatchEvent.d.ts.map +1 -1
  120. package/dist/dispatch/DispatchLifecycle.d.ts +1 -7
  121. package/dist/dispatch/DispatchLifecycle.d.ts.map +1 -1
  122. package/dist/dispatch/DispatchLifecycle.js +1 -7
  123. package/dist/dispatch/DispatchLifecycle.js.map +1 -1
  124. package/dist/dispatch/DispatchPort.d.ts +1 -1
  125. package/dist/dispatch/DispatchPort.d.ts.map +1 -1
  126. package/dist/dispatch/Dispatcher.d.ts +1 -1
  127. package/dist/dispatch/Dispatcher.d.ts.map +1 -1
  128. package/dist/dispatch/Dispatcher.js +2 -2
  129. package/dist/dispatch/Dispatcher.js.map +1 -1
  130. package/dist/{boot → dispatch}/HandlerFacade.d.ts +25 -38
  131. package/dist/dispatch/HandlerFacade.d.ts.map +1 -0
  132. package/dist/{boot → dispatch}/HandlerFacade.js +65 -74
  133. package/dist/dispatch/HandlerFacade.js.map +1 -0
  134. package/dist/dispatch/LocalRoutePolicy.d.ts +1 -1
  135. package/dist/dispatch/LocalRoutePolicy.d.ts.map +1 -1
  136. package/dist/dispatch/LocalRoutePolicy.js +4 -4
  137. package/dist/dispatch/LocalRoutePolicy.js.map +1 -1
  138. package/dist/dispatch/OperationRoute.d.ts +2 -2
  139. package/dist/dispatch/OperationRoute.d.ts.map +1 -1
  140. package/dist/dispatch/OutputView.d.ts +3 -2
  141. package/dist/dispatch/OutputView.d.ts.map +1 -1
  142. package/dist/dispatch/OutputView.js +19 -1
  143. package/dist/dispatch/OutputView.js.map +1 -1
  144. package/dist/dispatch/Route.d.ts +2 -3
  145. package/dist/dispatch/Route.d.ts.map +1 -1
  146. package/dist/dispatch/RoutePolicy.d.ts +1 -1
  147. package/dist/dispatch/RoutePolicy.d.ts.map +1 -1
  148. package/dist/dispatch/RouteRegistry.d.ts +1 -1
  149. package/dist/dispatch/RouteRegistry.d.ts.map +1 -1
  150. package/dist/dispatch/RouteRegistry.js +2 -2
  151. package/dist/dispatch/RouteRegistry.js.map +1 -1
  152. package/dist/dispatch/RouteResolver.d.ts +2 -4
  153. package/dist/dispatch/RouteResolver.d.ts.map +1 -1
  154. package/dist/dispatch/StorageGuard.d.ts +9 -8
  155. package/dist/dispatch/StorageGuard.d.ts.map +1 -1
  156. package/dist/dispatch/StorageGuard.js +66 -23
  157. package/dist/dispatch/StorageGuard.js.map +1 -1
  158. package/dist/dispatch/presenterArguments.d.ts +7 -0
  159. package/dist/dispatch/presenterArguments.d.ts.map +1 -0
  160. package/dist/dispatch/presenterArguments.js +12 -0
  161. package/dist/dispatch/presenterArguments.js.map +1 -0
  162. package/dist/dispatch/remoteRoutes.d.ts +7 -0
  163. package/dist/dispatch/remoteRoutes.d.ts.map +1 -0
  164. package/dist/dispatch/{RemoteRouteResolver.js → remoteRoutes.js} +6 -10
  165. package/dist/dispatch/remoteRoutes.js.map +1 -0
  166. package/dist/dispatch/routeNotFound.d.ts +9 -0
  167. package/dist/dispatch/routeNotFound.d.ts.map +1 -0
  168. package/dist/dispatch/routeNotFound.js +21 -0
  169. package/dist/dispatch/routeNotFound.js.map +1 -0
  170. package/dist/dispatch/validateInput.d.ts +5 -0
  171. package/dist/dispatch/validateInput.d.ts.map +1 -0
  172. package/dist/dispatch/validateInput.js +20 -0
  173. package/dist/dispatch/validateInput.js.map +1 -0
  174. package/dist/effective-operation.d.ts +6 -3
  175. package/dist/effective-operation.d.ts.map +1 -1
  176. package/dist/effective-operation.js +49 -27
  177. package/dist/effective-operation.js.map +1 -1
  178. package/dist/emit.d.ts +4 -42
  179. package/dist/emit.d.ts.map +1 -1
  180. package/dist/emit.js +3 -39
  181. package/dist/emit.js.map +1 -1
  182. package/dist/entry/facade.d.ts +8 -0
  183. package/dist/entry/facade.d.ts.map +1 -0
  184. package/dist/entry/facade.js +28 -0
  185. package/dist/entry/facade.js.map +1 -0
  186. package/dist/entry/transport.d.ts +5 -0
  187. package/dist/entry/transport.d.ts.map +1 -0
  188. package/dist/entry/transport.js +11 -0
  189. package/dist/entry/transport.js.map +1 -0
  190. package/dist/frond-config.d.ts +8 -71
  191. package/dist/frond-config.d.ts.map +1 -1
  192. package/dist/frond-config.js +1 -9
  193. package/dist/frond-config.js.map +1 -1
  194. package/dist/graph.d.ts +1 -1
  195. package/dist/graph.d.ts.map +1 -1
  196. package/dist/identity-keys.d.ts +2 -5
  197. package/dist/identity-keys.d.ts.map +1 -1
  198. package/dist/identity-keys.js +3 -16
  199. package/dist/identity-keys.js.map +1 -1
  200. package/dist/identity.d.ts +4 -30
  201. package/dist/identity.d.ts.map +1 -1
  202. package/dist/identity.js +11 -73
  203. package/dist/identity.js.map +1 -1
  204. package/dist/imports.d.ts +2 -8
  205. package/dist/imports.d.ts.map +1 -1
  206. package/dist/imports.js +1 -7
  207. package/dist/imports.js.map +1 -1
  208. package/dist/index.d.ts +28 -30
  209. package/dist/index.d.ts.map +1 -1
  210. package/dist/index.js +17 -22
  211. package/dist/index.js.map +1 -1
  212. package/dist/loader.d.ts +1 -8
  213. package/dist/loader.d.ts.map +1 -1
  214. package/dist/loader.js +1 -8
  215. package/dist/loader.js.map +1 -1
  216. package/dist/node.d.ts +2 -11
  217. package/dist/node.d.ts.map +1 -1
  218. package/dist/node.js +2 -11
  219. package/dist/node.js.map +1 -1
  220. package/dist/prefab/collector.d.ts +1 -22
  221. package/dist/prefab/collector.d.ts.map +1 -1
  222. package/dist/prefab/collector.js +1 -22
  223. package/dist/prefab/collector.js.map +1 -1
  224. package/dist/prefab/crud.d.ts +19 -35
  225. package/dist/prefab/crud.d.ts.map +1 -1
  226. package/dist/prefab/crud.js +39 -66
  227. package/dist/prefab/crud.js.map +1 -1
  228. package/dist/prefab/mirror.d.ts +5 -27
  229. package/dist/prefab/mirror.d.ts.map +1 -1
  230. package/dist/prefab/mirror.js +6 -24
  231. package/dist/prefab/mirror.js.map +1 -1
  232. package/dist/prefab/prefab.d.ts +1 -7
  233. package/dist/prefab/prefab.d.ts.map +1 -1
  234. package/dist/prefab/prefab.js +1 -7
  235. package/dist/prefab/prefab.js.map +1 -1
  236. package/dist/prefab/presenter.d.ts +2 -36
  237. package/dist/prefab/presenter.d.ts.map +1 -1
  238. package/dist/prefab/presenter.js +2 -36
  239. package/dist/prefab/presenter.js.map +1 -1
  240. package/dist/prefab/repository.d.ts +12 -80
  241. package/dist/prefab/repository.d.ts.map +1 -1
  242. package/dist/prefab/repository.js +22 -35
  243. package/dist/prefab/repository.js.map +1 -1
  244. package/dist/scan/adapters.d.ts +3 -0
  245. package/dist/scan/adapters.d.ts.map +1 -0
  246. package/dist/scan/adapters.js +25 -0
  247. package/dist/scan/adapters.js.map +1 -0
  248. package/dist/scan/bundling.d.ts +1 -12
  249. package/dist/scan/bundling.d.ts.map +1 -1
  250. package/dist/scan/bundling.js +1 -12
  251. package/dist/scan/bundling.js.map +1 -1
  252. package/dist/scan/conventions.d.ts +6 -40
  253. package/dist/scan/conventions.d.ts.map +1 -1
  254. package/dist/scan/conventions.js +5 -34
  255. package/dist/scan/conventions.js.map +1 -1
  256. package/dist/scan/emit.d.ts +2 -6
  257. package/dist/scan/emit.d.ts.map +1 -1
  258. package/dist/scan/emit.js +5 -39
  259. package/dist/scan/emit.js.map +1 -1
  260. package/dist/scan/handler-parser.d.ts +9 -76
  261. package/dist/scan/handler-parser.d.ts.map +1 -1
  262. package/dist/scan/handler-parser.js +28 -85
  263. package/dist/scan/handler-parser.js.map +1 -1
  264. package/dist/scan/result.d.ts +28 -0
  265. package/dist/scan/result.d.ts.map +1 -0
  266. package/dist/scan/result.js +2 -0
  267. package/dist/scan/result.js.map +1 -0
  268. package/dist/scan/scanner.d.ts +3 -28
  269. package/dist/scan/scanner.d.ts.map +1 -1
  270. package/dist/scan/scanner.js +36 -135
  271. package/dist/scan/scanner.js.map +1 -1
  272. package/dist/scan/statement.d.ts +1 -1
  273. package/dist/scan/statement.d.ts.map +1 -1
  274. package/dist/scan/statement.js +4 -30
  275. package/dist/scan/statement.js.map +1 -1
  276. package/dist/source.d.ts +41 -0
  277. package/dist/source.d.ts.map +1 -0
  278. package/dist/source.js +10 -0
  279. package/dist/source.js.map +1 -0
  280. package/dist/storage.d.ts +92 -0
  281. package/dist/storage.d.ts.map +1 -0
  282. package/dist/storage.js +50 -0
  283. package/dist/storage.js.map +1 -0
  284. package/dist/store.d.ts +18 -0
  285. package/dist/store.d.ts.map +1 -0
  286. package/dist/store.js +146 -0
  287. package/dist/store.js.map +1 -0
  288. package/dist/verify.d.ts +6 -39
  289. package/dist/verify.d.ts.map +1 -1
  290. package/dist/verify.js +19 -39
  291. package/dist/verify.js.map +1 -1
  292. package/dist/wire/CallLog.d.ts +32 -0
  293. package/dist/wire/CallLog.d.ts.map +1 -0
  294. package/dist/{contract → wire}/CallLog.js.map +1 -1
  295. package/dist/wire/Invocation.d.ts +32 -0
  296. package/dist/wire/Invocation.d.ts.map +1 -0
  297. package/dist/wire/Invocation.js +66 -0
  298. package/dist/wire/Invocation.js.map +1 -0
  299. package/dist/wire/RouteAddress.d.ts +24 -0
  300. package/dist/wire/RouteAddress.d.ts.map +1 -0
  301. package/dist/{contract → wire}/RouteAddress.js +7 -0
  302. package/dist/wire/RouteAddress.js.map +1 -0
  303. package/dist/wire/binding.d.ts +36 -0
  304. package/dist/wire/binding.d.ts.map +1 -0
  305. package/dist/{boot → wire}/binding.js +5 -62
  306. package/dist/wire/binding.js.map +1 -0
  307. package/dist/wire/call.d.ts +25 -172
  308. package/dist/wire/call.d.ts.map +1 -1
  309. package/dist/wire/call.js +15 -166
  310. package/dist/wire/call.js.map +1 -1
  311. package/dist/wire/drift.d.ts +3 -28
  312. package/dist/wire/drift.d.ts.map +1 -1
  313. package/dist/wire/drift.js +4 -23
  314. package/dist/wire/drift.js.map +1 -1
  315. package/dist/wire/errors.d.ts +4 -24
  316. package/dist/wire/errors.d.ts.map +1 -1
  317. package/dist/wire/errors.js +4 -24
  318. package/dist/wire/errors.js.map +1 -1
  319. package/dist/wire/http-error.d.ts +2 -13
  320. package/dist/wire/http-error.d.ts.map +1 -1
  321. package/dist/wire/http-error.js +5 -19
  322. package/dist/wire/http-error.js.map +1 -1
  323. package/dist/wire/loggerMiddleware.d.ts +2 -8
  324. package/dist/wire/loggerMiddleware.d.ts.map +1 -1
  325. package/dist/wire/loggerMiddleware.js +1 -7
  326. package/dist/wire/loggerMiddleware.js.map +1 -1
  327. package/dist/wire/middleware.d.ts +3 -7
  328. package/dist/wire/middleware.d.ts.map +1 -1
  329. package/dist/wire/middleware.js +1 -5
  330. package/dist/wire/middleware.js.map +1 -1
  331. package/dist/wire/operation.d.ts +12 -74
  332. package/dist/wire/operation.d.ts.map +1 -1
  333. package/dist/wire/operation.js +4 -66
  334. package/dist/wire/operation.js.map +1 -1
  335. package/dist/wire/signature.d.ts +37 -0
  336. package/dist/wire/signature.d.ts.map +1 -0
  337. package/dist/wire/signature.js +2 -0
  338. package/dist/wire/signature.js.map +1 -0
  339. package/package.json +3 -3
  340. package/src/boot/Emissions.ts +22 -119
  341. package/src/boot/ambient-port.ts +3 -24
  342. package/src/boot/ambient.als.ts +7 -12
  343. package/src/boot/ambient.queue.ts +2 -5
  344. package/src/boot/apply.ts +3 -15
  345. package/src/boot/auth.ts +6 -16
  346. package/src/boot/boot.ts +8 -23
  347. package/src/boot/bootstrap.ts +117 -173
  348. package/src/boot/card.ts +84 -0
  349. package/src/boot/frame.ts +31 -65
  350. package/src/boot/hosted.ts +15 -40
  351. package/src/boot/ownership.ts +14 -49
  352. package/src/boot/ports.ts +2 -15
  353. package/src/boot/remote.ts +11 -58
  354. package/src/boot/runner.ts +17 -0
  355. package/src/boot/seed.ts +11 -42
  356. package/src/boot/statement-drift.ts +10 -28
  357. package/src/boot/together.ts +38 -72
  358. package/src/boot/types.ts +36 -180
  359. package/src/{builtins → builtin}/config.ts +1 -7
  360. package/src/{builtins → builtin}/logger.ts +6 -39
  361. package/src/config-loader.ts +12 -71
  362. package/src/contract.ts +15 -39
  363. package/src/crypto/encoding.ts +2 -15
  364. package/src/crypto/node.ts +1 -7
  365. package/src/crypto/port.ts +2 -18
  366. package/src/crypto/webcrypto.ts +1 -12
  367. package/src/{scan/declare.ts → declare.ts} +11 -42
  368. package/src/define.ts +2 -3
  369. package/src/descriptor/Fronds.ts +47 -0
  370. package/src/descriptor/frond.ts +145 -0
  371. package/src/dispatch/ArgumentResolver.ts +54 -8
  372. package/src/dispatch/DispatchEvent.ts +2 -2
  373. package/src/dispatch/DispatchLifecycle.ts +1 -7
  374. package/src/dispatch/DispatchPort.ts +1 -1
  375. package/src/dispatch/Dispatcher.ts +3 -3
  376. package/src/dispatch/HandlerFacade.ts +231 -0
  377. package/src/dispatch/LocalRoutePolicy.ts +4 -4
  378. package/src/dispatch/OperationRoute.ts +2 -2
  379. package/src/dispatch/OutputView.ts +24 -2
  380. package/src/dispatch/Route.ts +2 -4
  381. package/src/dispatch/RoutePolicy.ts +1 -1
  382. package/src/dispatch/RouteRegistry.ts +2 -2
  383. package/src/dispatch/RouteResolver.ts +2 -4
  384. package/src/dispatch/StorageGuard.ts +75 -23
  385. package/src/dispatch/presenterArguments.ts +25 -0
  386. package/src/dispatch/{RemoteRouteResolver.ts → remoteRoutes.ts} +7 -9
  387. package/src/dispatch/routeNotFound.ts +33 -0
  388. package/src/dispatch/validateInput.ts +28 -0
  389. package/src/effective-operation.ts +60 -37
  390. package/src/emit.ts +5 -63
  391. package/src/entry/facade.ts +44 -0
  392. package/src/entry/transport.ts +16 -0
  393. package/src/frond-config.ts +8 -71
  394. package/src/graph.ts +1 -1
  395. package/src/identity-keys.ts +3 -16
  396. package/src/identity.ts +12 -80
  397. package/src/imports.ts +3 -32
  398. package/src/index.ts +28 -33
  399. package/src/loader.ts +2 -16
  400. package/src/node.ts +2 -11
  401. package/src/prefab/collector.ts +1 -22
  402. package/src/prefab/crud.ts +51 -90
  403. package/src/prefab/mirror.ts +9 -49
  404. package/src/prefab/prefab.ts +2 -21
  405. package/src/prefab/presenter.ts +2 -36
  406. package/src/prefab/repository.ts +32 -108
  407. package/src/scan/adapters.ts +32 -0
  408. package/src/scan/bundling.ts +1 -12
  409. package/src/scan/conventions.ts +6 -40
  410. package/src/scan/emit.ts +7 -43
  411. package/src/scan/handler-parser.ts +41 -163
  412. package/src/scan/result.ts +29 -0
  413. package/src/scan/scanner.ts +40 -138
  414. package/src/scan/statement.ts +6 -31
  415. package/src/source.ts +44 -0
  416. package/src/storage.ts +141 -0
  417. package/src/store.ts +152 -0
  418. package/src/verify.ts +19 -60
  419. package/src/wire/CallLog.ts +30 -0
  420. package/src/{contract → wire}/Invocation.ts +24 -17
  421. package/src/{contract → wire}/RouteAddress.ts +10 -0
  422. package/src/wire/binding.ts +102 -0
  423. package/src/wire/call.ts +30 -261
  424. package/src/wire/drift.ts +5 -30
  425. package/src/wire/errors.ts +4 -24
  426. package/src/wire/http-error.ts +5 -19
  427. package/src/wire/loggerMiddleware.ts +2 -8
  428. package/src/wire/middleware.ts +3 -7
  429. package/src/wire/operation.ts +13 -110
  430. package/src/wire/signature.ts +38 -0
  431. package/dist/boot/HandlerFacade.d.ts.map +0 -1
  432. package/dist/boot/HandlerFacade.js.map +0 -1
  433. package/dist/boot/binding.d.ts +0 -60
  434. package/dist/boot/binding.d.ts.map +0 -1
  435. package/dist/boot/binding.js.map +0 -1
  436. package/dist/builtins/config.d.ts +0 -13
  437. package/dist/builtins/config.d.ts.map +0 -1
  438. package/dist/builtins/config.js +0 -21
  439. package/dist/builtins/config.js.map +0 -1
  440. package/dist/builtins/logger.d.ts.map +0 -1
  441. package/dist/builtins/logger.js.map +0 -1
  442. package/dist/contract/Call.d.ts +0 -10
  443. package/dist/contract/Call.d.ts.map +0 -1
  444. package/dist/contract/Call.js +0 -15
  445. package/dist/contract/Call.js.map +0 -1
  446. package/dist/contract/CallLog.d.ts +0 -57
  447. package/dist/contract/CallLog.d.ts.map +0 -1
  448. package/dist/contract/Invocation.d.ts +0 -27
  449. package/dist/contract/Invocation.d.ts.map +0 -1
  450. package/dist/contract/Invocation.js +0 -59
  451. package/dist/contract/Invocation.js.map +0 -1
  452. package/dist/contract/RouteAddress.d.ts +0 -17
  453. package/dist/contract/RouteAddress.d.ts.map +0 -1
  454. package/dist/contract/RouteAddress.js.map +0 -1
  455. package/dist/dispatch/InputValidator.d.ts +0 -7
  456. package/dist/dispatch/InputValidator.d.ts.map +0 -1
  457. package/dist/dispatch/InputValidator.js +0 -22
  458. package/dist/dispatch/InputValidator.js.map +0 -1
  459. package/dist/dispatch/OperationExecutor.d.ts +0 -25
  460. package/dist/dispatch/OperationExecutor.d.ts.map +0 -1
  461. package/dist/dispatch/OperationExecutor.js +0 -32
  462. package/dist/dispatch/OperationExecutor.js.map +0 -1
  463. package/dist/dispatch/OutputProjector.d.ts +0 -12
  464. package/dist/dispatch/OutputProjector.d.ts.map +0 -1
  465. package/dist/dispatch/OutputProjector.js +0 -30
  466. package/dist/dispatch/OutputProjector.js.map +0 -1
  467. package/dist/dispatch/PresenterArgumentResolver.d.ts +0 -12
  468. package/dist/dispatch/PresenterArgumentResolver.d.ts.map +0 -1
  469. package/dist/dispatch/PresenterArgumentResolver.js +0 -20
  470. package/dist/dispatch/PresenterArgumentResolver.js.map +0 -1
  471. package/dist/dispatch/RemoteRouteResolver.d.ts +0 -13
  472. package/dist/dispatch/RemoteRouteResolver.d.ts.map +0 -1
  473. package/dist/dispatch/RemoteRouteResolver.js.map +0 -1
  474. package/dist/dispatch/RouteNotFoundError.d.ts +0 -10
  475. package/dist/dispatch/RouteNotFoundError.d.ts.map +0 -1
  476. package/dist/dispatch/RouteNotFoundError.js +0 -24
  477. package/dist/dispatch/RouteNotFoundError.js.map +0 -1
  478. package/dist/entry/DynamicFacade.d.ts +0 -10
  479. package/dist/entry/DynamicFacade.d.ts.map +0 -1
  480. package/dist/entry/DynamicFacade.js +0 -27
  481. package/dist/entry/DynamicFacade.js.map +0 -1
  482. package/dist/entry/FacadeEntry.d.ts +0 -11
  483. package/dist/entry/FacadeEntry.d.ts.map +0 -1
  484. package/dist/entry/FacadeEntry.js +0 -26
  485. package/dist/entry/FacadeEntry.js.map +0 -1
  486. package/dist/entry/TransportEntry.d.ts +0 -13
  487. package/dist/entry/TransportEntry.d.ts.map +0 -1
  488. package/dist/entry/TransportEntry.js +0 -24
  489. package/dist/entry/TransportEntry.js.map +0 -1
  490. package/dist/orm.d.ts +0 -207
  491. package/dist/orm.d.ts.map +0 -1
  492. package/dist/orm.js +0 -66
  493. package/dist/orm.js.map +0 -1
  494. package/dist/scan/Fronds.d.ts +0 -45
  495. package/dist/scan/Fronds.d.ts.map +0 -1
  496. package/dist/scan/Fronds.js +0 -66
  497. package/dist/scan/Fronds.js.map +0 -1
  498. package/dist/scan/declare.d.ts +0 -71
  499. package/dist/scan/declare.d.ts.map +0 -1
  500. package/dist/scan/declare.js.map +0 -1
  501. package/dist/scan/frond.d.ts +0 -224
  502. package/dist/scan/frond.d.ts.map +0 -1
  503. package/src/boot/HandlerFacade.ts +0 -242
  504. package/src/boot/binding.ts +0 -182
  505. package/src/contract/Call.ts +0 -18
  506. package/src/contract/CallLog.ts +0 -55
  507. package/src/dispatch/InputValidator.ts +0 -28
  508. package/src/dispatch/OperationExecutor.ts +0 -60
  509. package/src/dispatch/OutputProjector.ts +0 -32
  510. package/src/dispatch/PresenterArgumentResolver.ts +0 -25
  511. package/src/dispatch/RouteNotFoundError.ts +0 -29
  512. package/src/entry/DynamicFacade.ts +0 -28
  513. package/src/entry/FacadeEntry.ts +0 -32
  514. package/src/entry/TransportEntry.ts +0 -30
  515. package/src/orm.ts +0 -252
  516. package/src/scan/Fronds.ts +0 -73
  517. package/src/scan/frond.ts +0 -235
  518. /package/dist/{scan → descriptor}/frond.js +0 -0
  519. /package/dist/{contract → wire}/CallLog.js +0 -0
@@ -0,0 +1,24 @@
1
+ /** Which kind of destination served a call — it travels in a `CallRecord`. */
2
+ export type RouteKind = 'local' | 'remote' | 'system';
3
+ export interface RouteAddressInput {
4
+ entity: string;
5
+ operation: string;
6
+ surface?: string;
7
+ }
8
+ /** Canonical identity of one callable operation. */
9
+ export declare class RouteAddress {
10
+ readonly entity: string;
11
+ readonly operation: string;
12
+ readonly surface?: string;
13
+ /** Names one callable operation, and freezes it so a registry key cannot drift. */
14
+ constructor(input: RouteAddressInput);
15
+ /** Serializes the three segments so a route can be looked up in a `Map`. */
16
+ key(): string;
17
+ /** Compares two addresses by their key, so `surface` counts as much as the operation. */
18
+ equals(other: RouteAddress): boolean;
19
+ /** Writes the address the way a log and an error message name it. */
20
+ toString(): string;
21
+ /** Sends the address over the wire without `surface: undefined` riding along. */
22
+ toJSON(): RouteAddressInput;
23
+ }
24
+ //# sourceMappingURL=RouteAddress.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RouteAddress.d.ts","sourceRoot":"","sources":["../../src/wire/RouteAddress.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,MAAM,MAAM,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,QAAQ,CAAC;AAEtD,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB;AAaD,oDAAoD;AACpD,qBAAa,YAAY;IACvB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAE1B,mFAAmF;gBACvE,KAAK,EAAE,iBAAiB;IAOpC,4EAA4E;IAC5E,GAAG,IAAI,MAAM;IAIb,yFAAyF;IACzF,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO;IAIpC,qEAAqE;IACrE,QAAQ,IAAI,MAAM;IAKlB,iFAAiF;IACjF,MAAM,IAAI,iBAAiB;CAO5B"}
@@ -1,8 +1,10 @@
1
+ /** Refuses an empty segment, so no address can be built that nothing can serve. */
1
2
  function required(value, name) {
2
3
  if (value.trim().length === 0)
3
4
  throw new TypeError(`Route ${name} cannot be empty`);
4
5
  return value;
5
6
  }
7
+ /** Applies the same refusal to a segment that may be absent, but not blank. */
6
8
  function optional(value, name) {
7
9
  return value === undefined ? undefined : required(value, name);
8
10
  }
@@ -11,22 +13,27 @@ export class RouteAddress {
11
13
  entity;
12
14
  operation;
13
15
  surface;
16
+ /** Names one callable operation, and freezes it so a registry key cannot drift. */
14
17
  constructor(input) {
15
18
  this.entity = required(input.entity, 'entity');
16
19
  this.operation = required(input.operation, 'operation');
17
20
  this.surface = optional(input.surface, 'surface');
18
21
  Object.freeze(this);
19
22
  }
23
+ /** Serializes the three segments so a route can be looked up in a `Map`. */
20
24
  key() {
21
25
  return JSON.stringify([this.surface ?? null, this.entity, this.operation]);
22
26
  }
27
+ /** Compares two addresses by their key, so `surface` counts as much as the operation. */
23
28
  equals(other) {
24
29
  return this.key() === other.key();
25
30
  }
31
+ /** Writes the address the way a log and an error message name it. */
26
32
  toString() {
27
33
  const audience = this.surface ? `${this.surface}/` : '';
28
34
  return `${audience}${this.entity}.${this.operation}`;
29
35
  }
36
+ /** Sends the address over the wire without `surface: undefined` riding along. */
30
37
  toJSON() {
31
38
  return {
32
39
  entity: this.entity,
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RouteAddress.js","sourceRoot":"","sources":["../../src/wire/RouteAddress.ts"],"names":[],"mappings":"AASA,mFAAmF;AACnF,SAAS,QAAQ,CAAC,KAAa,EAAE,IAAY;IAC3C,IAAI,KAAK,CAAC,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC;QAAE,MAAM,IAAI,SAAS,CAAC,SAAS,IAAI,kBAAkB,CAAC,CAAC;IACpF,OAAO,KAAK,CAAC;AACf,CAAC;AAED,+EAA+E;AAC/E,SAAS,QAAQ,CAAC,KAAyB,EAAE,IAAY;IACvD,OAAO,KAAK,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,KAAK,EAAE,IAAI,CAAC,CAAC;AACjE,CAAC;AAED,oDAAoD;AACpD,MAAM,OAAO,YAAY;IACd,MAAM,CAAS;IACf,SAAS,CAAS;IAClB,OAAO,CAAU;IAE1B,mFAAmF;IACnF,YA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call by `resolveArgs`.
4
+ */
5
+ import type { Param } from './signature.js';
6
+ type ParamSource = {
7
+ kind: 'collector';
8
+ typeName: string;
9
+ }
10
+ /** `Fact<PostPublished>` — something that happened, not something a caller typed. */
11
+ | {
12
+ kind: 'fact';
13
+ factName: string;
14
+ } | {
15
+ kind: 'param';
16
+ name: string;
17
+ coerce?: 'number' | 'boolean';
18
+ } | {
19
+ kind: 'input';
20
+ } | {
21
+ kind: 'context';
22
+ }
23
+ /** The whole query bag, for an op whose argument IS the options (list). */
24
+ | {
25
+ kind: 'query';
26
+ };
27
+ interface ParamBinding {
28
+ name: string;
29
+ source: ParamSource;
30
+ optional: boolean;
31
+ }
32
+ export type BindingPlan = ParamBinding[];
33
+ /** Build a BindingPlan from parsed method params. */
34
+ export declare function computeBindingPlan(params: Param[], collectorTypeNames: Set<string>): BindingPlan;
35
+ export {};
36
+ //# sourceMappingURL=binding.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"binding.d.ts","sourceRoot":"","sources":["../../src/wire/binding.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAK5C,KAAK,WAAW,GACZ;IAAE,IAAI,EAAE,WAAW,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE;AACzC,qFAAqF;GACnF;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,GAClC;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAA;CAAE,GAC9D;IAAE,IAAI,EAAE,OAAO,CAAA;CAAE,GACjB;IAAE,IAAI,EAAE,SAAS,CAAA;CAAE;AACrB,2EAA2E;GACzE;IAAE,IAAI,EAAE,OAAO,CAAA;CAAE,CAAC;AAEtB,UAAU,YAAY;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,WAAW,CAAC;IACpB,QAAQ,EAAE,OAAO,CAAC;CACnB;AAED,MAAM,MAAM,WAAW,GAAG,YAAY,EAAE,CAAC;AAczC,qDAAqD;AACrD,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,KAAK,EAAE,EACf,kBAAkB,EAAE,GAAG,CAAC,MAAM,CAAC,GAC9B,WAAW,CA0Db"}
@@ -9,21 +9,16 @@ function coercionFor(typeName) {
9
9
  return undefined;
10
10
  }
11
11
  // ── Compute ───────────────────────────────────
12
- /**
13
- * Build a BindingPlan from parsed method params.
14
- *
15
- * @param params - Parsed parameter list from AST
16
- * @param collectorTypeNames - Registration keys of the types a Collector answers for
17
- */
12
+ /** Build a BindingPlan from parsed method params. */
18
13
  export function computeBindingPlan(params, collectorTypeNames) {
19
14
  return params.map((param) => {
20
15
  const typeName = param.type.name;
21
16
  // `lowerFirst`, never `toLowerCase()`: the collector set is keyed the way the
22
17
  // scan spells it, and the two agree on one word only — `AuthorUser` looked up as
23
- // `authoruser` missed `authorUser` and fell through to branch 4, the request body.
18
+ // `authoruser` missed `authorUser` and fell through to branch 4, the request input.
24
19
  const typeKey = lowerFirst(typeName);
25
20
  // 0. Fact — `Fact<X>` names itself, so nothing has to be known in advance. It comes
26
- // FIRST because branch 4 would otherwise hand it the caller's body under the name
21
+ // FIRST because branch 4 would otherwise hand it the caller's input under the name
27
22
  // of something that happened.
28
23
  const factOf = param.type.name === 'Fact' ? param.type.generics?.[0]?.name : undefined;
29
24
  if (factOf) {
@@ -61,64 +56,12 @@ export function computeBindingPlan(params, collectorTypeNames) {
61
56
  optional: param.optional ?? false,
62
57
  };
63
58
  }
64
- // 4. Everything else — body
59
+ // 4. Everything else — input
65
60
  return {
66
61
  name: param.name,
67
- source: { kind: 'body' },
62
+ source: { kind: 'input' },
68
63
  optional: param.optional ?? false,
69
64
  };
70
65
  });
71
66
  }
72
- /**
73
- * Resolve handler arguments from a BindingPlan + InvocationContext.
74
- */
75
- export async function resolveArgs(plan, ctx, resolveCollector) {
76
- const args = [];
77
- for (const binding of plan) {
78
- switch (binding.source.kind) {
79
- case 'collector': {
80
- const collector = resolveCollector?.(binding.source.typeName);
81
- args.push(collector ? await collector.collect(ctx) : undefined);
82
- break;
83
- }
84
- case 'context': {
85
- args.push(ctx);
86
- break;
87
- }
88
- case 'param': {
89
- // `null` is a value, not a miss. Nullish coalescing used to make an explicit
90
- // nullable path/GraphQL argument fall through to query (or become undefined),
91
- // collapsing `T | null` into `T | undefined`. Only undefined means absent.
92
- const fromParams = ctx.params[binding.source.name];
93
- let val = fromParams === undefined
94
- ? ctx.query[binding.source.name]
95
- : fromParams;
96
- if (val != null && binding.source.coerce === 'number')
97
- val = Number(val);
98
- if (val != null && binding.source.coerce === 'boolean')
99
- val = val === 'true' || val === '1' || val === true;
100
- args.push(val);
101
- break;
102
- }
103
- case 'fact': {
104
- // A fact IS the payload — the whole of what happened, never a piece of it.
105
- // Identical to `body` today, and deliberately not sharing its branch: the two
106
- // agree by coincidence, not by rule, and the day `body` learns to look up a
107
- // value by parameter name a subscriber would receive ONE FIELD of the fact it
108
- // subscribed to. Splitting it costs nothing and removes that trap.
109
- args.push(ctx.body);
110
- break;
111
- }
112
- case 'body': {
113
- args.push(ctx.body);
114
- break;
115
- }
116
- case 'query': {
117
- args.push(ctx.query);
118
- break;
119
- }
120
- }
121
- }
122
- return args;
123
- }
124
67
  //# sourceMappingURL=binding.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"binding.js","sourceRoot":"","sources":["../../src/wire/binding.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAsB7C,iDAAiD;AAEjD,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,CAAC,QAAQ,EAAE,QAAQ,EAAE,SAAS,CAAC,CAAC,CAAC;AAE5D,SAAS,WAAW,CAAC,QAAgB;IACnC,IAAI,QAAQ,KAAK,QAAQ;QAAE,OAAO,QAAQ,CAAC;IAC3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AK,CAAC,IAAI;gBAChB,MAAM,EAAE,EAAE,IAAI,EAAE,SAAkB,EAAE;gBACpC,QAAQ,EAAE,KAAK,CAAC,QAAQ,IAAI,KAAK;aAClC,CAAC;QACJ,CAAC;QAED,sDAAsD;QACtD,IAAI,UAAU,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC;YAC7B,OAAO;gBACL,IAAI,EAAE,KAAK,CAAC,IAAI;gBAChB,MAAM,EAAE;oBACN,IAAI,EAAE,OAAgB;oBACtB,IAAI,EAAE,KAAK,CAAC,IAAI;oBAChB,MAAM,EAAE,WAAW,CAAC,QAAQ,CAAC;iBAC9B;gBACD,QAAQ,EAAE,KAAK,CAAC,QAAQ,IAAI,KAAK;aAClC,CAAC;QACJ,CAAC;QAED,6BAA6B;QAC7B,OAAO;YACL,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,MAAM,EAAE,EAAE,IAAI,EAAE,OAAgB,EAAE;YAClC,QAAQ,EAAE,KAAK,CAAC,QAAQ,IAAI,KAAK;SAClC,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC"}
@@ -1,14 +1,13 @@
1
- /**
2
- * Call contract — a frond call is a value.
3
- *
4
- * (frond, entity, op, invocation) → result, or a thrown FougereError.
5
- * A transport is a function that executes this call elsewhere; the local
6
- * runner below is the reference realization. Transports move the value,
7
- * they never reshape it.
8
- */
1
+ /** Call contract — a frond call is a value. */
9
2
  import { type SchemaDescriptor } from '@fougere/schema';
10
- import type { InvocationContext } from '../contract/Invocation.js';
11
- import type { App } from '../boot/types.js';
3
+ import { Invocation, type InvocationContext, type PartialInvocation } from './Invocation.js';
4
+ import type { RouteAddress } from './RouteAddress.js';
5
+ /** One normalized request, frozen: where it goes and what the caller supplied. */
6
+ export declare class Call {
7
+ readonly address: RouteAddress;
8
+ readonly invocation: Invocation;
9
+ constructor(address: RouteAddress, invocation?: PartialInvocation);
10
+ }
12
11
  /** Target of a call — which façade operation, wherever it lives. */
13
12
  export interface FrondCall {
14
13
  /** Frond name, when the caller knows it. Routing hint only. */
@@ -21,45 +20,23 @@ export interface FrondCall {
21
20
  /** A transport executes a call somewhere else. Failures surface as thrown FougereError. */
22
21
  export type Transport = (call: FrondCall, invocation: InvocationContext) => Promise<unknown>;
23
22
  /** Reserved namespace — calls the runner answers itself, never a façade. */
24
- /**
25
- * What a receiver accepts before it stops reading a body.
26
- *
27
- * Stated once because it was stated FOUR times — `transport/http/policy.ts` said so in its
28
- * own comment ("spelled in four packages") while three doors kept their own literal, so
29
- * raising the cap here used to leave three of them refusing at the old one.
30
- *
31
- * `@fougere/http` keeps a fourth copy on purpose: it declares no Fougere dependency at all,
32
- * and giving a leaf port a dependency on the kernel to share a number is the wrong trade.
33
- */
23
+ /** What a receiver accepts before it stops reading an input. */
34
24
  export declare const MAX_BODY_BYTES: number;
35
25
  export declare const RPC_ENTITY = "rpc";
36
- /**
37
- * What an `rpc` op answers — the door for what the app says about ITSELF, never about a row.
38
- *
39
- * `discover` is core's own, registered like any other (`bootstrap.ts`): a package declares
40
- * its reading beside it, and an app that installed none serves none.
41
- */
26
+ /** What an `rpc` op answers — the door for what the app says about ITSELF, never about a row. */
42
27
  export type RpcAnswer = (invocation: InvocationContext, surface?: string) => unknown;
43
- /**
44
- * Everything a caller's envelope covers — the call as the sender meant it.
45
- *
46
- * Here and not beside the signing code because it is a CONTRACT: the sender binds it,
47
- * the receiver re-presents what arrived, and a frond written in another language reads
48
- * this shape without reading our crypto. `body` is bound by digest (arbitrary, possibly
49
- * large), the rest by value — which is what keeps a canonical-JSON dependency out.
50
- */
28
+ /** Everything a caller's envelope covers — the call as the sender meant it. */
51
29
  export interface SignedCall {
52
30
  entity: string;
53
31
  op: string;
54
32
  params?: Record<string, unknown>;
55
33
  query?: Record<string, unknown>;
56
- body?: unknown;
34
+ input?: unknown;
57
35
  state?: Record<string, unknown>;
58
36
  }
59
37
  /**
60
- * One operation, as a stranger meets it — its name, what it is for, what it takes
61
- * and whether it reads or writes. Everything here already existed on the contract;
62
- * it just never left the process.
38
+ * One operation, as a stranger meets it — its name, what it is for, what it takes and whether it
39
+ * reads or writes.
63
40
  */
64
41
  export interface CardOp {
65
42
  name: string;
@@ -71,56 +48,20 @@ export interface CardOp {
71
48
  output?: SchemaDescriptor;
72
49
  /** `query` reads, `command` writes — the same call REST turns into GET vs POST. */
73
50
  kind: 'query' | 'command';
74
- /**
75
- * How much `output` describes: one row, maybe one, many, a page, or nothing shaped.
76
- * `output` alone is the shape of a ROW, so a consumer generating a signature from
77
- * this card would otherwise have to guess — and `list` returning a page rather than
78
- * an array is exactly the guess it would get wrong.
79
- */
51
+ /** How much `output` describes. */
80
52
  cardinality?: 'one' | 'maybe' | 'many' | 'page' | 'none';
81
53
  }
82
- /**
83
- * What an app hosts — the wire projection of its scanned fronds.
84
- *
85
- * Two lists per frond, and they are duals: **what you may call**, and **what you will
86
- * receive**. A door is entered from outside; a fact leaves on its own.
87
- *
88
- * `doors` was called `entities` and the name lied: an entry is an ADDRESS, and the shape
89
- * behind it is optional (`facadeKeyOf` builds its key from a handler's name, which need not
90
- * be an entity's). The lie cost something real — `fougere sync` demanded a descriptor on
91
- * every entry and refused whole cards over a health check.
92
- */
54
+ /** What an app hosts — the wire projection of its scanned fronds. */
93
55
  export interface IdentityCard {
94
56
  fronds: {
95
57
  name: string;
96
58
  doors: {
97
59
  name: string;
98
60
  ops: CardOp[];
99
- /**
100
- * The shape stored under this name — **absent when nothing is**. A handler may
101
- * carry no entity (`bootstrap`: *pointing at nothing is legal*), and a door with
102
- * no rows behind it is ordinary: a health check, a computation, a search across
103
- * several shapes. A reader that needs the shape must say what it does without one.
104
- */
61
+ /** The shape stored under this name — **absent when nothing is**. */
105
62
  schema?: SchemaDescriptor;
106
63
  }[];
107
- /**
108
- * The facts this frond ANNOUNCES — one entry per `Emit<T>` its handlers inject.
109
- *
110
- * They carry no operation, which is why they cannot ride in `doors`: the rule there is
111
- * *hosting means answering*, and an entity with no façade is excluded on purpose (it
112
- * would publish the auth tables to anyone who asks). A fact is the opposite case —
113
- * someone WROTE that it leaves, so publishing its shape is honouring a statement, not
114
- * leaking one.
115
- *
116
- * Without this, a fact stopped at the repository boundary: `remotes:` gives the
117
- * location, colocation gives the contract, and across two repositories there is no
118
- * colocation. The subscriber had to hand-copy the emitter's declaration.
119
- *
120
- * `schema` is absent when the announced type is not a declared entity — legal (nothing
121
- * requires a fact to be one) and worth saying rather than hiding: the name travels, the
122
- * shape does not, and a consumer can see exactly that.
123
- */
64
+ /** The facts this frond ANNOUNCES — one entry per `Emit<T>` its handlers inject. */
124
65
  facts: {
125
66
  name: string;
126
67
  schema?: SchemaDescriptor;
@@ -141,17 +82,7 @@ export interface Edge {
141
82
  count: number;
142
83
  errors: number;
143
84
  }
144
- /**
145
- * The shape of the system as ONE process discovered it — the answer to `rpc.topology`.
146
- *
147
- * Here and not in the package that produces it, for the reason `SignedCall` is here: it
148
- * crosses a process boundary, so a reader consumes it without depending on the producer.
149
- * `@fougere/observability` fills it; a panel reads it; neither imports the other.
150
- *
151
- * Nothing in it is declared — a frond is `local` because this process scanned it, `remote`
152
- * because it answered a call nobody here hosts. `remotes:` states an intent, and the two
153
- * disagree exactly when something is misconfigured.
154
- */
85
+ /** The shape of the system as ONE process discovered it — the answer to `rpc.topology`. */
155
86
  export interface TopologyReport {
156
87
  /** When this process started counting — an edge count is read against it. */
157
88
  since: number;
@@ -160,93 +91,15 @@ export interface TopologyReport {
160
91
  fronds: FrondPlacement[];
161
92
  edges: Edge[];
162
93
  }
163
- /**
164
- * The shape a card must have to be walked — `fronds`, and each frond's `doors`.
165
- *
166
- * A card crosses a process boundary, so it is judged like anything else that does.
167
- * The check lives beside the type because two readers walk it: the boot indexes a
168
- * remote's doors, and `fougere sync` writes classes from them. `TypeError:
169
- * card.fronds is not iterable` was what a malformed card produced at the boot,
170
- * naming neither the remote nor the address.
171
- *
172
- * The descriptor behind a door is NOT checked here — `Card.toSchema` refuses it, and
173
- * only where one is consumed.
174
- */
94
+ /** The shape a card must have to be walked — `fronds`, and each frond's `doors`. */
175
95
  export declare function assertIdentityCard(value: unknown, source: string): IdentityCard;
176
- /**
177
- * The door built in front of a handler — the framework's second port, after `EntityOrm`.
178
- *
179
- * `Facade<PostHandler>` is what a neighbouring frond injects. It names what ARRIVES
180
- * rather than what is written: never the handler (nobody injects it, and its methods take
181
- * positional arguments), but the door, whose every op takes the invocation and whose
182
- * implementation is the local façade or a doublure. A signature therefore says nothing
183
- * about where the other frond runs, which is the whole point.
184
- *
185
- * `keyof T` is the right set by construction, not by approximation: the scan skips
186
- * `private` and `protected` (`handler-parser.ts`) because "TypeScript already has the
187
- * word for it", so a handler's public methods ARE its operations — and `keyof` excludes
188
- * the rest for the same reason.
189
- */
96
+ /** A façade as the runtime holds it: op names to functions, nothing typed about them. */
97
+ /** The door built in front of a handler — the framework's second port, after `Storage`. */
190
98
  export type Facade<T> = {
191
99
  [K in keyof T]: T[K] extends (...args: never[]) => infer R ? (invocation?: InvocationContext) => R : never;
192
100
  };
193
- /**
194
- * The container key of a façade — THE one place that spells the format.
195
- *
196
- * A surface is a named audience, and it is a key: `handlers/public/PostHandler.ts`
197
- * registers `public:postHandler` next to the default `postHandler`. The default
198
- * surface is the empty key, so callers that know nothing about surfaces keep
199
- * designating exactly what they designated before.
200
- *
201
- * Nobody outside this package builds this string: adapters ask `app.facadeFor()`,
202
- * which is why an adapter can stay structurally typed and core-free.
203
- */
101
+ /** The container key of a façade — THE one place that spells the format. */
204
102
  export declare function facadeKeyOf(entityName: string, surface?: string): string;
205
- /**
206
- * Where the contracts behind a façade live — the dual of `facadeKeyOf`.
207
- *
208
- * The façade answers calls; it does not say what it answers. That sentence used
209
- * to be true only inside `buildFacade`, so anything asking the app what it hosts
210
- * got bare names. A door and its terms are registered together, under the same
211
- * audience.
212
- */
103
+ /** Where the contracts behind a façade live — the dual of `facadeKeyOf`. */
213
104
  export declare function contractsKeyOf(entityName: string, surface?: string): string;
214
- /**
215
- * Serialize what the app hosts, for one audience. Served on `rpc.discover`,
216
- * cached by callers.
217
- *
218
- * Hosting means answering: an entity with no façade declares no operation, so
219
- * it is not among the DOORS — publishing its shape would hand an anonymous caller
220
- * the structure of tables it can never reach (the auth tables, typically), and
221
- * `fougere sync` would rebuild a schema with nothing to call on it.
222
- *
223
- * `facts` is the one thing that shape-without-a-door rule does not cover, and the
224
- * reason is the opposite of a leak: an entity nobody exposed is silent, whereas a
225
- * fact was explicitly declared to leave.
226
- *
227
- * `surface` makes that sentence audience-aware rather than app-wide: a door
228
- * answers with what IT serves. Nothing falls back to the full façade — under a
229
- * named surface, an entity with no façade of its own is simply not there.
230
- */
231
- export declare function identityCardOf(app: App, surface?: string): IdentityCard;
232
- /**
233
- * Build the local runner — the reference realization of Transport.
234
- *
235
- * Resolves strictly from the app's own container: a call that lands here is
236
- * judged here. A miss is a typed NOT_FOUND, never a forward to another remote.
237
- */
238
- export declare function createLocalRunner(app: App, surface?: string): Transport;
239
- /**
240
- * Build the app runner — same judgment, but resolution follows the app's
241
- * topology: local façades and remote doublures alike. This is the runner
242
- * an app's own entry points (browser endpoint, bridges) stand on.
243
- *
244
- * `surface` is the audience this runner serves, and it belongs to the DOOR that
245
- * builds the runner, never to the call: a caller cannot name its own audience
246
- * any more than it can name its own identity (`state` is stamped server-side
247
- * for the same reason). Reaching the admin door IS the proof. So `FrondCall`
248
- * gains nothing and the wire format gains nothing — a remote frond's audience
249
- * is simply which URL `remotes:` points at.
250
- */
251
- export declare function createAppRunner(app: App, surface?: string): Transport;
252
105
  //# sourceMappingURL=call.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../../src/wire/call.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,EAAQ,KAAK,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAE9D,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,2BAA2B,CAAC;AAEnE,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,kBAAkB,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