@hotmeshio/long-tail 0.5.10 → 0.5.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/api/controlplane.d.ts +1 -0
- package/build/api/controlplane.js +1 -0
- package/build/api/diagnostics.d.ts +8 -1
- package/build/api/diagnostics.js +5 -1
- package/build/api/escalations/list.d.ts +2 -0
- package/build/api/escalations/list.js +2 -0
- package/build/api/settings.d.ts +3 -2
- package/build/api/settings.js +13 -2
- package/build/api/workflows/invocation.d.ts +6 -0
- package/build/api/workflows/invocation.js +6 -2
- package/build/modules/features.d.ts +19 -0
- package/build/modules/features.js +16 -0
- package/build/modules/version.d.ts +16 -0
- package/build/modules/version.js +34 -0
- package/build/routes/controlplane.js +1 -0
- package/build/routes/diagnostics.js +32 -11
- package/build/routes/escalations/list.js +2 -0
- package/build/routes/workflows/invocation.js +12 -4
- package/build/sdk/index.d.ts +2 -0
- package/build/services/controlplane/index.js +3 -2
- package/build/services/controlplane/stream-messages-sql.d.ts +4 -3
- package/build/services/controlplane/stream-messages-sql.js +12 -7
- package/build/services/controlplane/types.d.ts +2 -0
- package/build/services/diagnostics/index.d.ts +53 -7
- package/build/services/diagnostics/index.js +124 -36
- package/build/services/diagnostics/patterns.d.ts +13 -3
- package/build/services/diagnostics/patterns.js +25 -14
- package/build/services/escalation/queries.d.ts +2 -0
- package/build/services/escalation/queries.js +84 -2
- package/build/services/escalation/sql.d.ts +7 -0
- package/build/services/escalation/sql.js +50 -1
- package/build/services/task/resolve.d.ts +5 -3
- package/build/services/task/resolve.js +9 -6
- package/build/services/task/sql.d.ts +6 -1
- package/build/services/task/sql.js +7 -1
- package/build/start/adapters.js +3 -0
- package/build/system/mcp-servers/admin/diagnostics.d.ts +11 -4
- package/build/system/mcp-servers/admin/diagnostics.js +34 -22
- package/build/system/mcp-servers/admin/escalations.d.ts +6 -0
- package/build/system/mcp-servers/admin/escalations.js +182 -54
- package/build/system/mcp-servers/admin/index.js +3 -3
- package/build/system/mcp-servers/admin/schemas.d.ts +101 -6
- package/build/system/mcp-servers/admin/schemas.js +43 -6
- package/build/system/mcp-servers/admin/workflows.js +23 -12
- package/build/system/seed/tool-manifests-admin.d.ts +1324 -562
- package/build/system/seed/tool-manifests-admin.js +10 -2
- package/build/tsconfig.tsbuildinfo +1 -1
- package/build/types/auth.d.ts +1 -1
- package/build/types/startup.d.ts +9 -0
- package/dashboard/dist/assets/{AdminDashboard-0LSslIQ7.js → AdminDashboard-LTiYLuzq.js} +2 -2
- package/dashboard/dist/assets/{AdminDashboard-0LSslIQ7.js.map → AdminDashboard-LTiYLuzq.js.map} +1 -1
- package/dashboard/dist/assets/{AgentConfigPage-hqBr1540.js → AgentConfigPage-nlOudfpZ.js} +7 -7
- package/dashboard/dist/assets/{AgentConfigPage-hqBr1540.js.map → AgentConfigPage-nlOudfpZ.js.map} +1 -1
- package/dashboard/dist/assets/AgentDetailPage-BSUnDvGp.js +4 -0
- package/dashboard/dist/assets/AgentDetailPage-BSUnDvGp.js.map +1 -0
- package/dashboard/dist/assets/AgentsPage-DpS0cCYe.js +2 -0
- package/dashboard/dist/assets/AgentsPage-DpS0cCYe.js.map +1 -0
- package/dashboard/dist/assets/AvailableEscalationsPage-BEylRqjP.js +2 -0
- package/dashboard/dist/assets/AvailableEscalationsPage-BEylRqjP.js.map +1 -0
- package/dashboard/dist/assets/{BotPicker-fFE4GAaO.js → BotPicker-BhKmq7M7.js} +2 -2
- package/dashboard/dist/assets/{BotPicker-fFE4GAaO.js.map → BotPicker-BhKmq7M7.js.map} +1 -1
- package/dashboard/dist/assets/CapabilitiesPage-DLIleX2L.js +2 -0
- package/dashboard/dist/assets/{CapabilitiesPage-DotZ7iQc.js.map → CapabilitiesPage-DLIleX2L.js.map} +1 -1
- package/dashboard/dist/assets/{CollapsibleSection-D97SYypF.js → CollapsibleSection-D7SVwNVk.js} +2 -2
- package/dashboard/dist/assets/{CollapsibleSection-D97SYypF.js.map → CollapsibleSection-D7SVwNVk.js.map} +1 -1
- package/dashboard/dist/assets/{CredentialsPage-C08U6dlv.js → CredentialsPage-fat5Z2U9.js} +2 -2
- package/dashboard/dist/assets/{CredentialsPage-C08U6dlv.js.map → CredentialsPage-fat5Z2U9.js.map} +1 -1
- package/dashboard/dist/assets/{CronLabel-C2TuCl4h.js → CronLabel-OOP4P2mJ.js} +2 -2
- package/dashboard/dist/assets/{CronLabel-C2TuCl4h.js.map → CronLabel-OOP4P2mJ.js.map} +1 -1
- package/dashboard/dist/assets/{CustomDurationPicker-C3zGsESx.js → CustomDurationPicker-COacSAXO.js} +2 -2
- package/dashboard/dist/assets/{CustomDurationPicker-C3zGsESx.js.map → CustomDurationPicker-COacSAXO.js.map} +1 -1
- package/dashboard/dist/assets/{DropZone-Dwpgbueb.js → DropZone-Bfw2YLVS.js} +2 -2
- package/dashboard/dist/assets/{DropZone-Dwpgbueb.js.map → DropZone-Bfw2YLVS.js.map} +1 -1
- package/dashboard/dist/assets/{ElapsedCell-DF4m0cv_.js → ElapsedCell-CkfCD-m7.js} +2 -2
- package/dashboard/dist/assets/{ElapsedCell-DF4m0cv_.js.map → ElapsedCell-CkfCD-m7.js.map} +1 -1
- package/dashboard/dist/assets/{EscalationsOverview-blGOYKtJ.js → EscalationsOverview-BmI8jxlh.js} +2 -2
- package/dashboard/dist/assets/{EscalationsOverview-blGOYKtJ.js.map → EscalationsOverview-BmI8jxlh.js.map} +1 -1
- package/dashboard/dist/assets/EventTable-CeKfFk3m.js +2 -0
- package/dashboard/dist/assets/EventTable-CeKfFk3m.js.map +1 -0
- package/dashboard/dist/assets/{GraphInvokePage-QVAUHmjI.js → GraphInvokePage-BZBPBCSq.js} +2 -2
- package/dashboard/dist/assets/{GraphInvokePage-QVAUHmjI.js.map → GraphInvokePage-BZBPBCSq.js.map} +1 -1
- package/dashboard/dist/assets/{HomePage-DvYgvCcO.js → HomePage-dM7U2tl6.js} +2 -2
- package/dashboard/dist/assets/{HomePage-DvYgvCcO.js.map → HomePage-dM7U2tl6.js.map} +1 -1
- package/dashboard/dist/assets/{ListToolbar-D6tQ3ZG2.js → ListToolbar-BJaCzAXS.js} +2 -2
- package/dashboard/dist/assets/{ListToolbar-D6tQ3ZG2.js.map → ListToolbar-BJaCzAXS.js.map} +1 -1
- package/dashboard/dist/assets/{McpOverview-BClbGYb8.js → McpOverview-CvnDG5OB.js} +2 -2
- package/dashboard/dist/assets/{McpOverview-BClbGYb8.js.map → McpOverview-CvnDG5OB.js.map} +1 -1
- package/dashboard/dist/assets/{McpQueryDetailPage-DHjfDRdm.js → McpQueryDetailPage-DwmSIcIL.js} +3 -3
- package/dashboard/dist/assets/{McpQueryDetailPage-DHjfDRdm.js.map → McpQueryDetailPage-DwmSIcIL.js.map} +1 -1
- package/dashboard/dist/assets/McpQueryPage-CU6FMEEk.js +2 -0
- package/dashboard/dist/assets/McpQueryPage-CU6FMEEk.js.map +1 -0
- package/dashboard/dist/assets/McpRunDetailPage-8a6lsehv.js +2 -0
- package/dashboard/dist/assets/{McpRunDetailPage-DRbIZMU2.js.map → McpRunDetailPage-8a6lsehv.js.map} +1 -1
- package/dashboard/dist/assets/McpRunsPage-CPMYWgm_.js +2 -0
- package/dashboard/dist/assets/McpRunsPage-CPMYWgm_.js.map +1 -0
- package/dashboard/dist/assets/{NamespacePill-DnJl4Lre.js → NamespacePill-D6btr6e8.js} +2 -2
- package/dashboard/dist/assets/{NamespacePill-DnJl4Lre.js.map → NamespacePill-D6btr6e8.js.map} +1 -1
- package/dashboard/dist/assets/OperatorDashboard-g9o7I925.js +2 -0
- package/dashboard/dist/assets/OperatorDashboard-g9o7I925.js.map +1 -0
- package/dashboard/dist/assets/{PageHeader-Bnt2iQQa.js → PageHeader-Dk2Pe44Q.js} +2 -2
- package/dashboard/dist/assets/{PageHeader-Bnt2iQQa.js.map → PageHeader-Dk2Pe44Q.js.map} +1 -1
- package/dashboard/dist/assets/{PageHeaderWithStats-BuKc9MKt.js → PageHeaderWithStats-DJQCZ0FR.js} +2 -2
- package/dashboard/dist/assets/{PageHeaderWithStats-BuKc9MKt.js.map → PageHeaderWithStats-DJQCZ0FR.js.map} +1 -1
- package/dashboard/dist/assets/{ProcessDetailPage-DjQuNERz.js → ProcessDetailPage-ByyWCs2A.js} +2 -2
- package/dashboard/dist/assets/{ProcessDetailPage-DjQuNERz.js.map → ProcessDetailPage-ByyWCs2A.js.map} +1 -1
- package/dashboard/dist/assets/ProcessesListPage-BTsXds4l.js +2 -0
- package/dashboard/dist/assets/ProcessesListPage-BTsXds4l.js.map +1 -0
- package/dashboard/dist/assets/{RolePill-DQTT1s9v.js → RolePill-Du-aNnjR.js} +2 -2
- package/dashboard/dist/assets/{RolePill-DQTT1s9v.js.map → RolePill-Du-aNnjR.js.map} +1 -1
- package/dashboard/dist/assets/{RolesPage-CFCN_mRF.js → RolesPage-B2Kdf-L9.js} +2 -2
- package/dashboard/dist/assets/{RolesPage-CFCN_mRF.js.map → RolesPage-B2Kdf-L9.js.map} +1 -1
- package/dashboard/dist/assets/{RunAsSelector-sBxAvlRf.js → RunAsSelector-BzkZXpSX.js} +2 -2
- package/dashboard/dist/assets/{RunAsSelector-sBxAvlRf.js.map → RunAsSelector-BzkZXpSX.js.map} +1 -1
- package/dashboard/dist/assets/StreamMessageDetail-B6ch-6SY.js +2 -0
- package/dashboard/dist/assets/StreamMessageDetail-B6ch-6SY.js.map +1 -0
- package/dashboard/dist/assets/SwimlaneTimeline-CjvfUkls.js +2 -0
- package/dashboard/dist/assets/SwimlaneTimeline-CjvfUkls.js.map +1 -0
- package/dashboard/dist/assets/{TagInput-B00uqhjX.js → TagInput-CZSeyesi.js} +2 -2
- package/dashboard/dist/assets/{TagInput-B00uqhjX.js.map → TagInput-CZSeyesi.js.map} +1 -1
- package/dashboard/dist/assets/{TaskDetailPage-CgFN5uWn.js → TaskDetailPage-BjHU6opi.js} +2 -2
- package/dashboard/dist/assets/{TaskDetailPage-CgFN5uWn.js.map → TaskDetailPage-BjHU6opi.js.map} +1 -1
- package/dashboard/dist/assets/{TaskQueuePill-CUsofm0X.js → TaskQueuePill-CQrXrSxk.js} +2 -2
- package/dashboard/dist/assets/{TaskQueuePill-CUsofm0X.js.map → TaskQueuePill-CQrXrSxk.js.map} +1 -1
- package/dashboard/dist/assets/{TasksListPage-qj25rRZL.js → TasksListPage-Bem44zd0.js} +2 -2
- package/dashboard/dist/assets/{TasksListPage-qj25rRZL.js.map → TasksListPage-Bem44zd0.js.map} +1 -1
- package/dashboard/dist/assets/{TimeAgo-C7LylVjP.js → TimeAgo-CUIYqSt_.js} +2 -2
- package/dashboard/dist/assets/{TimeAgo-C7LylVjP.js.map → TimeAgo-CUIYqSt_.js.map} +1 -1
- package/dashboard/dist/assets/{TimestampCell-CrCtoBlo.js → TimestampCell--tnreI1i.js} +2 -2
- package/dashboard/dist/assets/{TimestampCell-CrCtoBlo.js.map → TimestampCell--tnreI1i.js.map} +1 -1
- package/dashboard/dist/assets/{ToolPill-DjvedZSn.js → ToolPill-O09jsTQM.js} +2 -2
- package/dashboard/dist/assets/{ToolPill-DjvedZSn.js.map → ToolPill-O09jsTQM.js.map} +1 -1
- package/dashboard/dist/assets/{ToolTestPanel-DYGlB-QW.js → ToolTestPanel-OD99H7Pk.js} +2 -2
- package/dashboard/dist/assets/{ToolTestPanel-DYGlB-QW.js.map → ToolTestPanel-OD99H7Pk.js.map} +1 -1
- package/dashboard/dist/assets/{TopicDetailPage-DLY6X_R6.js → TopicDetailPage-rh_dsTJI.js} +3 -3
- package/dashboard/dist/assets/{TopicDetailPage-DLY6X_R6.js.map → TopicDetailPage-rh_dsTJI.js.map} +1 -1
- package/dashboard/dist/assets/{TopicsPage-C5nOLsLx.js → TopicsPage-CD_40_v-.js} +2 -2
- package/dashboard/dist/assets/{TopicsPage-C5nOLsLx.js.map → TopicsPage-CD_40_v-.js.map} +1 -1
- package/dashboard/dist/assets/{UserName-CgUZyiwm.js → UserName-C__c8BN0.js} +2 -2
- package/dashboard/dist/assets/{UserName-CgUZyiwm.js.map → UserName-C__c8BN0.js.map} +1 -1
- package/dashboard/dist/assets/WorkflowExecutionPage-Bw6QdtUO.js +2 -0
- package/dashboard/dist/assets/{WorkflowExecutionPage-CDr5CTM2.js.map → WorkflowExecutionPage-Bw6QdtUO.js.map} +1 -1
- package/dashboard/dist/assets/{WorkflowPill-F1oKUzmc.js → WorkflowPill-CS-IsR0U.js} +2 -2
- package/dashboard/dist/assets/{WorkflowPill-F1oKUzmc.js.map → WorkflowPill-CS-IsR0U.js.map} +1 -1
- package/dashboard/dist/assets/WorkflowsDashboard-BgI-iOP6.js +2 -0
- package/dashboard/dist/assets/WorkflowsDashboard-BgI-iOP6.js.map +1 -0
- package/dashboard/dist/assets/{WorkflowsOverview-CaMeZwde.js → WorkflowsOverview-BRc0QbA7.js} +2 -2
- package/dashboard/dist/assets/{WorkflowsOverview-CaMeZwde.js.map → WorkflowsOverview-BRc0QbA7.js.map} +1 -1
- package/dashboard/dist/assets/{YamlWorkflowDetailPage-C3uyCiIX.js → YamlWorkflowDetailPage-DdzspNQR.js} +2 -2
- package/dashboard/dist/assets/{YamlWorkflowDetailPage-C3uyCiIX.js.map → YamlWorkflowDetailPage-DdzspNQR.js.map} +1 -1
- package/dashboard/dist/assets/{YamlWorkflowsPage-DRnYgsvA.js → YamlWorkflowsPage-Djw5ZbgQ.js} +2 -2
- package/dashboard/dist/assets/{YamlWorkflowsPage-DRnYgsvA.js.map → YamlWorkflowsPage-Djw5ZbgQ.js.map} +1 -1
- package/dashboard/dist/assets/{agents-HMkTc425.js → agents-xstNkF6c.js} +2 -2
- package/dashboard/dist/assets/{agents-HMkTc425.js.map → agents-xstNkF6c.js.map} +1 -1
- package/dashboard/dist/assets/api-path-u2Jf9QXS.js +2 -0
- package/dashboard/dist/assets/api-path-u2Jf9QXS.js.map +1 -0
- package/dashboard/dist/assets/{bots-CDe2jXNx.js → bots-BztAI0s_.js} +2 -2
- package/dashboard/dist/assets/{bots-CDe2jXNx.js.map → bots-BztAI0s_.js.map} +1 -1
- package/dashboard/dist/assets/{capabilities-DhnM7Ztb.js → capabilities-CEDwtxNL.js} +2 -2
- package/dashboard/dist/assets/{capabilities-DhnM7Ztb.js.map → capabilities-CEDwtxNL.js.map} +1 -1
- package/dashboard/dist/assets/{controlplane-BwIJ9ZC_.js → controlplane-BlGEsRKe.js} +2 -2
- package/dashboard/dist/assets/{controlplane-BwIJ9ZC_.js.map → controlplane-BlGEsRKe.js.map} +1 -1
- package/dashboard/dist/assets/{escalation-columns-BKqSywVA.js → escalation-columns-nVYVt7Gl.js} +2 -2
- package/dashboard/dist/assets/{escalation-columns-BKqSywVA.js.map → escalation-columns-nVYVt7Gl.js.map} +1 -1
- package/dashboard/dist/assets/{escalation-Djk5XKmX.js → escalation-iI4QKlP-.js} +2 -2
- package/dashboard/dist/assets/{escalation-Djk5XKmX.js.map → escalation-iI4QKlP-.js.map} +1 -1
- package/dashboard/dist/assets/{index-BW-fIquS.js → index-B5qsp8lb.js} +2 -2
- package/dashboard/dist/assets/{index-BW-fIquS.js.map → index-B5qsp8lb.js.map} +1 -1
- package/dashboard/dist/assets/{index-DBi9Q9Hw.js → index-B7VC0vjf.js} +2 -2
- package/dashboard/dist/assets/{index-DBi9Q9Hw.js.map → index-B7VC0vjf.js.map} +1 -1
- package/dashboard/dist/assets/{index-CPIYW81T.js → index-BUmnJ4eT.js} +2 -2
- package/dashboard/dist/assets/{index-CPIYW81T.js.map → index-BUmnJ4eT.js.map} +1 -1
- package/dashboard/dist/assets/{index-BNkpns_E.js → index-CAqEy2Db.js} +2 -2
- package/dashboard/dist/assets/{index-BNkpns_E.js.map → index-CAqEy2Db.js.map} +1 -1
- package/dashboard/dist/assets/{index-BYpWOUEe.js → index-CMviPjXQ.js} +2 -2
- package/dashboard/dist/assets/{index-BYpWOUEe.js.map → index-CMviPjXQ.js.map} +1 -1
- package/dashboard/dist/assets/index-CP0JEQhZ.js +6 -0
- package/dashboard/dist/assets/{index-E2hQ8DIi.js.map → index-CP0JEQhZ.js.map} +1 -1
- package/dashboard/dist/assets/index-CUfgt3mV.js +2 -0
- package/dashboard/dist/assets/index-CUfgt3mV.js.map +1 -0
- package/dashboard/dist/assets/index-ClvYSNZd.css +1 -0
- package/dashboard/dist/assets/{index-BFQ2t-p1.js → index-D1xVY4JR.js} +27 -27
- package/dashboard/dist/assets/index-D1xVY4JR.js.map +1 -0
- package/dashboard/dist/assets/{index-rUST2YsO.js → index-DPLy-jwO.js} +2 -2
- package/dashboard/dist/assets/{index-rUST2YsO.js.map → index-DPLy-jwO.js.map} +1 -1
- package/dashboard/dist/assets/{index-DRIJM1L-.js → index-DjJ6VCuc.js} +2 -2
- package/dashboard/dist/assets/{index-DRIJM1L-.js.map → index-DjJ6VCuc.js.map} +1 -1
- package/dashboard/dist/assets/{index-Dhy2PVAw.js → index-Dsi5o7dx.js} +2 -2
- package/dashboard/dist/assets/{index-Dhy2PVAw.js.map → index-Dsi5o7dx.js.map} +1 -1
- package/dashboard/dist/assets/{index-mEQ6kCnt.js → index-DzVYjoex.js} +3 -3
- package/dashboard/dist/assets/{index-mEQ6kCnt.js.map → index-DzVYjoex.js.map} +1 -1
- package/dashboard/dist/assets/index-FuhiJuHL.js +2 -0
- package/dashboard/dist/assets/index-FuhiJuHL.js.map +1 -0
- package/dashboard/dist/assets/{knowledge-jQE3dBVi.js → knowledge-BKg0cr39.js} +2 -2
- package/dashboard/dist/assets/{knowledge-jQE3dBVi.js.map → knowledge-BKg0cr39.js.map} +1 -1
- package/dashboard/dist/assets/{mcp-DtEGfZiz.js → mcp-CVdHpKlz.js} +2 -2
- package/dashboard/dist/assets/{mcp-DtEGfZiz.js.map → mcp-CVdHpKlz.js.map} +1 -1
- package/dashboard/dist/assets/{mcp-query-CiTLVuDC.js → mcp-query-CYxZcbwQ.js} +2 -2
- package/dashboard/dist/assets/{mcp-query-CiTLVuDC.js.map → mcp-query-CYxZcbwQ.js.map} +1 -1
- package/dashboard/dist/assets/{pipelines-ClNdzuUK.js → pipelines-BOEv7P6O.js} +2 -2
- package/dashboard/dist/assets/{pipelines-ClNdzuUK.js.map → pipelines-BOEv7P6O.js.map} +1 -1
- package/dashboard/dist/assets/{roles-BmHbRaPT.js → roles-c5cV2QYQ.js} +2 -2
- package/dashboard/dist/assets/{roles-BmHbRaPT.js.map → roles-c5cV2QYQ.js.map} +1 -1
- package/dashboard/dist/assets/{tasks-BPONxLcq.js → tasks-JV3BjeEF.js} +2 -2
- package/dashboard/dist/assets/{tasks-BPONxLcq.js.map → tasks-JV3BjeEF.js.map} +1 -1
- package/dashboard/dist/assets/{topics-XREPRxwo.js → topics-BDaPnhnQ.js} +2 -2
- package/dashboard/dist/assets/{topics-XREPRxwo.js.map → topics-BDaPnhnQ.js.map} +1 -1
- package/dashboard/dist/assets/useDebouncedValue-BA5S7V54.js +2 -0
- package/dashboard/dist/assets/useDebouncedValue-BA5S7V54.js.map +1 -0
- package/dashboard/dist/assets/{useEventHooks-M7SaEfel.js → useEventHooks-a7Dnh8G4.js} +2 -2
- package/dashboard/dist/assets/{useEventHooks-M7SaEfel.js.map → useEventHooks-a7Dnh8G4.js.map} +1 -1
- package/dashboard/dist/assets/{useNamespace-BQHGkdBv.js → useNamespace-BSwEV0e9.js} +2 -2
- package/dashboard/dist/assets/{useNamespace-BQHGkdBv.js.map → useNamespace-BSwEV0e9.js.map} +1 -1
- package/dashboard/dist/assets/{useYamlActivityEvents-B7JtUGSE.js → useYamlActivityEvents-BuqvL-cn.js} +2 -2
- package/dashboard/dist/assets/{useYamlActivityEvents-B7JtUGSE.js.map → useYamlActivityEvents-BuqvL-cn.js.map} +1 -1
- package/dashboard/dist/assets/{users-BpjSNhQe.js → users-Pn85K_3C.js} +2 -2
- package/dashboard/dist/assets/{users-BpjSNhQe.js.map → users-Pn85K_3C.js.map} +1 -1
- package/dashboard/dist/assets/{vendor-icons-Dj2F0Jrb.js → vendor-icons-D5ycKPA2.js} +114 -109
- package/dashboard/dist/assets/vendor-icons-D5ycKPA2.js.map +1 -0
- package/dashboard/dist/assets/{workflows-k4jE0ECC.js → workflows-DF-9Voyi.js} +2 -2
- package/dashboard/dist/assets/{workflows-k4jE0ECC.js.map → workflows-DF-9Voyi.js.map} +1 -1
- package/dashboard/dist/assets/{yaml-workflows-DpviSLEL.js → yaml-workflows-2roKaSSK.js} +2 -2
- package/dashboard/dist/assets/{yaml-workflows-DpviSLEL.js.map → yaml-workflows-2roKaSSK.js.map} +1 -1
- package/dashboard/dist/index.html +3 -3
- package/docs/api/mcp/admin.md +242 -5
- package/docs/mcp.md +102 -0
- package/package.json +1 -1
- package/dashboard/dist/assets/AgentDetailPage-bnXR1ezD.js +0 -4
- package/dashboard/dist/assets/AgentDetailPage-bnXR1ezD.js.map +0 -1
- package/dashboard/dist/assets/AgentsPage-tJIlrnfM.js +0 -2
- package/dashboard/dist/assets/AgentsPage-tJIlrnfM.js.map +0 -1
- package/dashboard/dist/assets/AvailableEscalationsPage-B7gEfcw3.js +0 -2
- package/dashboard/dist/assets/AvailableEscalationsPage-B7gEfcw3.js.map +0 -1
- package/dashboard/dist/assets/CapabilitiesPage-DotZ7iQc.js +0 -2
- package/dashboard/dist/assets/EventTable-DzrMH-ux.js +0 -2
- package/dashboard/dist/assets/EventTable-DzrMH-ux.js.map +0 -1
- package/dashboard/dist/assets/McpQueryPage-qtEuMDrd.js +0 -2
- package/dashboard/dist/assets/McpQueryPage-qtEuMDrd.js.map +0 -1
- package/dashboard/dist/assets/McpRunDetailPage-DRbIZMU2.js +0 -2
- package/dashboard/dist/assets/McpRunsPage-CMfwXQ4R.js +0 -2
- package/dashboard/dist/assets/McpRunsPage-CMfwXQ4R.js.map +0 -1
- package/dashboard/dist/assets/OperatorDashboard-Dq2pfV68.js +0 -2
- package/dashboard/dist/assets/OperatorDashboard-Dq2pfV68.js.map +0 -1
- package/dashboard/dist/assets/ProcessesListPage-vJimii8-.js +0 -2
- package/dashboard/dist/assets/ProcessesListPage-vJimii8-.js.map +0 -1
- package/dashboard/dist/assets/SwimlaneTimeline-2Eet4OOL.js +0 -2
- package/dashboard/dist/assets/SwimlaneTimeline-2Eet4OOL.js.map +0 -1
- package/dashboard/dist/assets/WorkflowExecutionPage-CDr5CTM2.js +0 -2
- package/dashboard/dist/assets/WorkflowsDashboard-tCBP0i0Y.js +0 -2
- package/dashboard/dist/assets/WorkflowsDashboard-tCBP0i0Y.js.map +0 -1
- package/dashboard/dist/assets/index-BFQ2t-p1.js.map +0 -1
- package/dashboard/dist/assets/index-Cydgj_Co.js +0 -2
- package/dashboard/dist/assets/index-Cydgj_Co.js.map +0 -1
- package/dashboard/dist/assets/index-DSki_Ub6.css +0 -1
- package/dashboard/dist/assets/index-E2hQ8DIi.js +0 -6
- package/dashboard/dist/assets/index-u08vQUaw.js +0 -2
- package/dashboard/dist/assets/index-u08vQUaw.js.map +0 -1
- package/dashboard/dist/assets/vendor-icons-Dj2F0Jrb.js.map +0 -1
|
@@ -1,15 +1,22 @@
|
|
|
1
|
+
import type { DiagnoseSection, DiagnoseVerbosity } from '../services/diagnostics';
|
|
1
2
|
import type { LTApiResult } from '../types/sdk';
|
|
2
3
|
export declare function diagnose(input: {
|
|
3
4
|
workflowId: string;
|
|
4
5
|
appId?: string;
|
|
6
|
+
maxEvents?: number;
|
|
7
|
+
/** Heavy sections to include (events, streams). Default: verdict only. */
|
|
8
|
+
include?: DiagnoseSection[];
|
|
9
|
+
/** Shorthand: 'full' includes events + streams; 'summary' (default) includes neither. */
|
|
10
|
+
verbosity?: DiagnoseVerbosity;
|
|
5
11
|
}): Promise<LTApiResult>;
|
|
6
12
|
export declare function stalledJobs(input: {
|
|
7
13
|
appId?: string;
|
|
8
|
-
|
|
14
|
+
idleMinutes?: number;
|
|
9
15
|
workflowType?: string;
|
|
10
16
|
limit?: number;
|
|
11
17
|
}): Promise<LTApiResult>;
|
|
12
18
|
export declare function orphanedSignals(input: {
|
|
13
19
|
appId?: string;
|
|
20
|
+
withinHours?: number;
|
|
14
21
|
limit?: number;
|
|
15
22
|
}): Promise<LTApiResult>;
|
package/build/api/diagnostics.js
CHANGED
|
@@ -6,7 +6,11 @@ exports.orphanedSignals = orphanedSignals;
|
|
|
6
6
|
const diagnostics_1 = require("../services/diagnostics");
|
|
7
7
|
async function diagnose(input) {
|
|
8
8
|
try {
|
|
9
|
-
const diagnosis = await (0, diagnostics_1.diagnoseJob)(input.workflowId, input.appId
|
|
9
|
+
const diagnosis = await (0, diagnostics_1.diagnoseJob)(input.workflowId, input.appId, {
|
|
10
|
+
maxEvents: input.maxEvents,
|
|
11
|
+
include: input.include,
|
|
12
|
+
verbosity: input.verbosity,
|
|
13
|
+
});
|
|
10
14
|
return { status: 200, data: diagnosis };
|
|
11
15
|
}
|
|
12
16
|
catch (err) {
|
|
@@ -30,6 +30,7 @@ export declare function listEscalations(input: {
|
|
|
30
30
|
offset?: number;
|
|
31
31
|
sort_by?: string;
|
|
32
32
|
order?: string;
|
|
33
|
+
search?: string;
|
|
33
34
|
}, auth: LTApiAuth): Promise<LTApiResult>;
|
|
34
35
|
/**
|
|
35
36
|
* List escalations available for claim (pending and not actively claimed).
|
|
@@ -57,6 +58,7 @@ export declare function listAvailableEscalations(input: {
|
|
|
57
58
|
offset?: number;
|
|
58
59
|
sort_by?: string;
|
|
59
60
|
order?: string;
|
|
61
|
+
search?: string;
|
|
60
62
|
}, auth: LTApiAuth): Promise<LTApiResult>;
|
|
61
63
|
/**
|
|
62
64
|
* List all distinct escalation type values.
|
|
@@ -77,6 +77,7 @@ async function listEscalations(input, auth) {
|
|
|
77
77
|
offset: input.offset,
|
|
78
78
|
sort_by: input.sort_by,
|
|
79
79
|
order: input.order,
|
|
80
|
+
search: input.search,
|
|
80
81
|
visibleRoles,
|
|
81
82
|
});
|
|
82
83
|
return { status: 200, data: result };
|
|
@@ -117,6 +118,7 @@ async function listAvailableEscalations(input, auth) {
|
|
|
117
118
|
offset: input.offset,
|
|
118
119
|
sort_by: input.sort_by,
|
|
119
120
|
order: input.order,
|
|
121
|
+
search: input.search,
|
|
120
122
|
visibleRoles,
|
|
121
123
|
});
|
|
122
124
|
return { status: 200, data: result };
|
package/build/api/settings.d.ts
CHANGED
|
@@ -4,9 +4,10 @@ import type { LTApiResult } from '../types/sdk';
|
|
|
4
4
|
* Return platform settings for the current deployment.
|
|
5
5
|
*
|
|
6
6
|
* Includes telemetry configuration (trace URL), escalation claim duration
|
|
7
|
-
* options,
|
|
7
|
+
* options, event transport details (socket.io, NATS, or none), and an
|
|
8
|
+
* environment block (long-tail + HotMesh versions, Node env/version).
|
|
8
9
|
*
|
|
9
10
|
* @param req — the incoming HTTP request, used to derive NATS WS URL from headers when proxying
|
|
10
|
-
* @returns `{ status: 200, data: { telemetry, escalation, events } }`
|
|
11
|
+
* @returns `{ status: 200, data: { telemetry, escalation, events, auth, ai, features, environment } }`
|
|
11
12
|
*/
|
|
12
13
|
export declare function getSettings(req?: IncomingMessage): Promise<LTApiResult>;
|
package/build/api/settings.js
CHANGED
|
@@ -7,6 +7,8 @@ const nats_1 = require("../lib/events/nats");
|
|
|
7
7
|
const socketio_1 = require("../lib/events/socketio");
|
|
8
8
|
const nats_ws_proxy_1 = require("../lib/events/nats-ws-proxy");
|
|
9
9
|
const config_1 = require("../modules/config");
|
|
10
|
+
const features_1 = require("../modules/features");
|
|
11
|
+
const version_1 = require("../modules/version");
|
|
10
12
|
const sso_1 = require("../modules/sso");
|
|
11
13
|
const defaults_1 = require("../modules/defaults");
|
|
12
14
|
const llm_1 = require("../services/llm");
|
|
@@ -33,10 +35,11 @@ function resolveNatsWsUrl(adapter, req) {
|
|
|
33
35
|
* Return platform settings for the current deployment.
|
|
34
36
|
*
|
|
35
37
|
* Includes telemetry configuration (trace URL), escalation claim duration
|
|
36
|
-
* options,
|
|
38
|
+
* options, event transport details (socket.io, NATS, or none), and an
|
|
39
|
+
* environment block (long-tail + HotMesh versions, Node env/version).
|
|
37
40
|
*
|
|
38
41
|
* @param req — the incoming HTTP request, used to derive NATS WS URL from headers when proxying
|
|
39
|
-
* @returns `{ status: 200, data: { telemetry, escalation, events } }`
|
|
42
|
+
* @returns `{ status: 200, data: { telemetry, escalation, events, auth, ai, features, environment } }`
|
|
40
43
|
*/
|
|
41
44
|
async function getSettings(req) {
|
|
42
45
|
try {
|
|
@@ -68,6 +71,14 @@ async function getSettings(req) {
|
|
|
68
71
|
ai: {
|
|
69
72
|
enabled: (0, llm_1.hasLLMApiKey)(),
|
|
70
73
|
},
|
|
74
|
+
features: (0, features_1.getFeatureFlags)(),
|
|
75
|
+
environment: {
|
|
76
|
+
longTailVersion: version_1.LONG_TAIL_VERSION,
|
|
77
|
+
hotmeshVersion: version_1.HOTMESH_VERSION,
|
|
78
|
+
nodeEnv: config_1.config.NODE_ENV,
|
|
79
|
+
nodeVersion: process.version,
|
|
80
|
+
eventTransport: transport,
|
|
81
|
+
},
|
|
71
82
|
},
|
|
72
83
|
};
|
|
73
84
|
}
|
|
@@ -23,12 +23,16 @@ export declare function invokeWorkflow(input: {
|
|
|
23
23
|
*
|
|
24
24
|
* Returns the HotMesh status code (0 = completed, 1 = running).
|
|
25
25
|
* Resolves the workflow handle via task record or worker registry.
|
|
26
|
+
* `appId` selects the namespace for the job-entity fallback so a child
|
|
27
|
+
* running in another app resolves instead of 404ing against `durable`.
|
|
26
28
|
*
|
|
27
29
|
* @param input.workflowId — HotMesh workflow ID
|
|
30
|
+
* @param input.appId — HotMesh namespace for resolution (default: durable)
|
|
28
31
|
* @returns `{ status: 200, data: { workflowId, status } }` or 404
|
|
29
32
|
*/
|
|
30
33
|
export declare function getWorkflowStatus(input: {
|
|
31
34
|
workflowId: string;
|
|
35
|
+
appId?: string;
|
|
32
36
|
}): Promise<LTApiResult>;
|
|
33
37
|
/**
|
|
34
38
|
* Get the result of a completed workflow.
|
|
@@ -37,10 +41,12 @@ export declare function getWorkflowStatus(input: {
|
|
|
37
41
|
* payload when complete. Never blocks — always returns immediately.
|
|
38
42
|
*
|
|
39
43
|
* @param input.workflowId — HotMesh workflow ID
|
|
44
|
+
* @param input.appId — HotMesh namespace for resolution (default: durable)
|
|
40
45
|
* @returns `{ status: 200, data: { workflowId, result } }` or 202 if running
|
|
41
46
|
*/
|
|
42
47
|
export declare function getWorkflowResult(input: {
|
|
43
48
|
workflowId: string;
|
|
49
|
+
appId?: string;
|
|
44
50
|
}): Promise<LTApiResult>;
|
|
45
51
|
/**
|
|
46
52
|
* Terminate a running workflow.
|
|
@@ -87,13 +87,16 @@ async function invokeWorkflow(input, auth) {
|
|
|
87
87
|
*
|
|
88
88
|
* Returns the HotMesh status code (0 = completed, 1 = running).
|
|
89
89
|
* Resolves the workflow handle via task record or worker registry.
|
|
90
|
+
* `appId` selects the namespace for the job-entity fallback so a child
|
|
91
|
+
* running in another app resolves instead of 404ing against `durable`.
|
|
90
92
|
*
|
|
91
93
|
* @param input.workflowId — HotMesh workflow ID
|
|
94
|
+
* @param input.appId — HotMesh namespace for resolution (default: durable)
|
|
92
95
|
* @returns `{ status: 200, data: { workflowId, status } }` or 404
|
|
93
96
|
*/
|
|
94
97
|
async function getWorkflowStatus(input) {
|
|
95
98
|
try {
|
|
96
|
-
const resolved = await (0, task_1.resolveWorkflowHandle)(input.workflowId);
|
|
99
|
+
const resolved = await (0, task_1.resolveWorkflowHandle)(input.workflowId, input.appId);
|
|
97
100
|
const client = (0, workers_1.createClient)();
|
|
98
101
|
const handle = await client.workflow.getHandle(resolved.taskQueue, resolved.workflowName, input.workflowId);
|
|
99
102
|
const status = await handle.status();
|
|
@@ -115,11 +118,12 @@ async function getWorkflowStatus(input) {
|
|
|
115
118
|
* payload when complete. Never blocks — always returns immediately.
|
|
116
119
|
*
|
|
117
120
|
* @param input.workflowId — HotMesh workflow ID
|
|
121
|
+
* @param input.appId — HotMesh namespace for resolution (default: durable)
|
|
118
122
|
* @returns `{ status: 200, data: { workflowId, result } }` or 202 if running
|
|
119
123
|
*/
|
|
120
124
|
async function getWorkflowResult(input) {
|
|
121
125
|
try {
|
|
122
|
-
const resolved = await (0, task_1.resolveWorkflowHandle)(input.workflowId);
|
|
126
|
+
const resolved = await (0, task_1.resolveWorkflowHandle)(input.workflowId, input.appId);
|
|
123
127
|
const client = (0, workers_1.createClient)();
|
|
124
128
|
const handle = await client.workflow.getHandle(resolved.taskQueue, resolved.workflowName, input.workflowId);
|
|
125
129
|
const status = await handle.status();
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime feature flags surfaced to the dashboard via /api/settings.
|
|
3
|
+
*
|
|
4
|
+
* These gate UI affordances (nav entries, routes) that some deployments want to
|
|
5
|
+
* hide. Defaults are permissive (everything on); a deployment opts OUT through
|
|
6
|
+
* the `features` block of the `start()` config. The dashboard reads the resolved
|
|
7
|
+
* flags from `settings.features` and hides the corresponding nav item + route.
|
|
8
|
+
*/
|
|
9
|
+
export interface FeatureFlags {
|
|
10
|
+
/**
|
|
11
|
+
* Show the DB Maintenance admin page (nav entry + route).
|
|
12
|
+
* Default: true. Set `features.dbMaintenance: false` in start config to hide it.
|
|
13
|
+
*/
|
|
14
|
+
dbMaintenance: boolean;
|
|
15
|
+
}
|
|
16
|
+
/** Merge a partial set of flags from the start config. Unspecified flags keep their default. */
|
|
17
|
+
export declare function configureFeatureFlags(patch?: Partial<FeatureFlags>): void;
|
|
18
|
+
/** The resolved feature flags reported to the dashboard. */
|
|
19
|
+
export declare function getFeatureFlags(): FeatureFlags;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.configureFeatureFlags = configureFeatureFlags;
|
|
4
|
+
exports.getFeatureFlags = getFeatureFlags;
|
|
5
|
+
const DEFAULT_FLAGS = {
|
|
6
|
+
dbMaintenance: true,
|
|
7
|
+
};
|
|
8
|
+
let flags = { ...DEFAULT_FLAGS };
|
|
9
|
+
/** Merge a partial set of flags from the start config. Unspecified flags keep their default. */
|
|
10
|
+
function configureFeatureFlags(patch) {
|
|
11
|
+
flags = { ...DEFAULT_FLAGS, ...(patch ?? {}) };
|
|
12
|
+
}
|
|
13
|
+
/** The resolved feature flags reported to the dashboard. */
|
|
14
|
+
function getFeatureFlags() {
|
|
15
|
+
return { ...flags };
|
|
16
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Runtime version constants for the environment block surfaced by /api/settings.
|
|
3
|
+
*
|
|
4
|
+
* The HotMesh SDK version is read from its package.json — node module
|
|
5
|
+
* resolution finds it in both dev (source) and prod (the runtime image's
|
|
6
|
+
* node_modules), and resolveJsonModule handles the static import at compile time.
|
|
7
|
+
*/
|
|
8
|
+
export declare const HOTMESH_VERSION: string;
|
|
9
|
+
/**
|
|
10
|
+
* The long-tail app version. Read from the root package.json at runtime via the
|
|
11
|
+
* process working directory (which is the app root in both dev and the Docker
|
|
12
|
+
* image, where CMD runs `node build/index.js` from /app). A static
|
|
13
|
+
* `../package.json` import would resolve to build/package.json after compile —
|
|
14
|
+
* a path the Dockerfile does not copy — so this reads from cwd instead.
|
|
15
|
+
*/
|
|
16
|
+
export declare const LONG_TAIL_VERSION: string;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.LONG_TAIL_VERSION = exports.HOTMESH_VERSION = void 0;
|
|
7
|
+
const fs_1 = require("fs");
|
|
8
|
+
const path_1 = require("path");
|
|
9
|
+
const package_json_1 = __importDefault(require("@hotmeshio/hotmesh/package.json"));
|
|
10
|
+
/**
|
|
11
|
+
* Runtime version constants for the environment block surfaced by /api/settings.
|
|
12
|
+
*
|
|
13
|
+
* The HotMesh SDK version is read from its package.json — node module
|
|
14
|
+
* resolution finds it in both dev (source) and prod (the runtime image's
|
|
15
|
+
* node_modules), and resolveJsonModule handles the static import at compile time.
|
|
16
|
+
*/
|
|
17
|
+
exports.HOTMESH_VERSION = package_json_1.default.version ?? 'unknown';
|
|
18
|
+
/**
|
|
19
|
+
* The long-tail app version. Read from the root package.json at runtime via the
|
|
20
|
+
* process working directory (which is the app root in both dev and the Docker
|
|
21
|
+
* image, where CMD runs `node build/index.js` from /app). A static
|
|
22
|
+
* `../package.json` import would resolve to build/package.json after compile —
|
|
23
|
+
* a path the Dockerfile does not copy — so this reads from cwd instead.
|
|
24
|
+
*/
|
|
25
|
+
exports.LONG_TAIL_VERSION = readLongTailVersion();
|
|
26
|
+
function readLongTailVersion() {
|
|
27
|
+
try {
|
|
28
|
+
const raw = (0, fs_1.readFileSync)((0, path_1.resolve)(process.cwd(), 'package.json'), 'utf8');
|
|
29
|
+
return JSON.parse(raw).version ?? 'unknown';
|
|
30
|
+
}
|
|
31
|
+
catch {
|
|
32
|
+
return 'unknown';
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -123,6 +123,7 @@ router.get('/stream-messages', auth_1.requireBuilder, async (req, res) => {
|
|
|
123
123
|
workflow_name: req.query.workflow_name || undefined,
|
|
124
124
|
jid: req.query.jid || undefined,
|
|
125
125
|
aid: req.query.aid || undefined,
|
|
126
|
+
dad: req.query.dad || undefined,
|
|
126
127
|
});
|
|
127
128
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
128
129
|
});
|
|
@@ -37,34 +37,51 @@ const express_1 = require("express");
|
|
|
37
37
|
const api = __importStar(require("../api/diagnostics"));
|
|
38
38
|
const auth_1 = require("../modules/auth");
|
|
39
39
|
const router = (0, express_1.Router)();
|
|
40
|
+
const VALID_SECTIONS = new Set(['events', 'streams']);
|
|
41
|
+
/** Parse a comma-separated `include` query param into the recognized heavy sections. */
|
|
42
|
+
function parseInclude(raw) {
|
|
43
|
+
if (typeof raw !== 'string' || raw.trim() === '')
|
|
44
|
+
return undefined;
|
|
45
|
+
const sections = raw.split(',').map((s) => s.trim()).filter((s) => VALID_SECTIONS.has(s));
|
|
46
|
+
return sections.length > 0 ? sections : undefined;
|
|
47
|
+
}
|
|
40
48
|
/**
|
|
41
49
|
* GET /api/diagnostics/jobs/:workflowId
|
|
42
|
-
*
|
|
50
|
+
* Compact diagnosis for a single workflow job — the verdict only by default
|
|
51
|
+
* (status, idle time, stream counts, escalation, findings).
|
|
43
52
|
*
|
|
44
53
|
* Query params:
|
|
45
|
-
* app_id
|
|
54
|
+
* app_id — HotMesh namespace (default: durable)
|
|
55
|
+
* max_events — cap on events returned when included (most recent kept; default: 500)
|
|
56
|
+
* include — comma-separated heavy sections to add: events, streams
|
|
57
|
+
* verbosity — 'summary' (default, verdict only) or 'full' (events + streams)
|
|
46
58
|
*/
|
|
47
59
|
router.get('/jobs/:workflowId', auth_1.requireAdmin, async (req, res) => {
|
|
48
60
|
const result = await api.diagnose({
|
|
49
61
|
workflowId: req.params.workflowId,
|
|
50
62
|
appId: typeof req.query.app_id === 'string' ? req.query.app_id : undefined,
|
|
63
|
+
maxEvents: req.query.max_events ? Number(req.query.max_events) : undefined,
|
|
64
|
+
include: parseInclude(req.query.include),
|
|
65
|
+
verbosity: req.query.verbosity === 'full' ? 'full' : undefined,
|
|
51
66
|
});
|
|
52
67
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
53
68
|
});
|
|
54
69
|
/**
|
|
55
70
|
* GET /api/diagnostics/stalled
|
|
56
|
-
* Running jobs with no recent
|
|
71
|
+
* Running jobs with no recent status change. A frozen updated_at is the NORMAL
|
|
72
|
+
* signature of a workflow waiting at a condition()/waitFor()/sleepFor() — each
|
|
73
|
+
* row is classified `likely: waiting | no_recent_progress` accordingly.
|
|
57
74
|
*
|
|
58
75
|
* Query params:
|
|
59
|
-
* app_id
|
|
60
|
-
*
|
|
61
|
-
* workflow_type
|
|
62
|
-
* limit
|
|
76
|
+
* app_id — HotMesh namespace (default: durable)
|
|
77
|
+
* idle_minutes — minimum minutes since last status change (default: 5)
|
|
78
|
+
* workflow_type — filter by workflow function name
|
|
79
|
+
* limit — max results (default: 50, max: 200)
|
|
63
80
|
*/
|
|
64
81
|
router.get('/stalled', auth_1.requireAdmin, async (req, res) => {
|
|
65
82
|
const result = await api.stalledJobs({
|
|
66
83
|
appId: typeof req.query.app_id === 'string' ? req.query.app_id : undefined,
|
|
67
|
-
|
|
84
|
+
idleMinutes: req.query.idle_minutes ? Number(req.query.idle_minutes) : undefined,
|
|
68
85
|
workflowType: typeof req.query.workflow_type === 'string' ? req.query.workflow_type : undefined,
|
|
69
86
|
limit: req.query.limit ? Number(req.query.limit) : undefined,
|
|
70
87
|
});
|
|
@@ -72,15 +89,19 @@ router.get('/stalled', auth_1.requireAdmin, async (req, res) => {
|
|
|
72
89
|
});
|
|
73
90
|
/**
|
|
74
91
|
* GET /api/diagnostics/orphaned-signals
|
|
75
|
-
* Suspended
|
|
92
|
+
* Suspended waiters with no escalation row, within a recent time window. The
|
|
93
|
+
* window keeps this off a full-history scan of the partitioned worker_streams
|
|
94
|
+
* table — widen `within_hours` deliberately to reach older orphans.
|
|
76
95
|
*
|
|
77
96
|
* Query params:
|
|
78
|
-
* app_id
|
|
79
|
-
*
|
|
97
|
+
* app_id — HotMesh namespace (default: durable)
|
|
98
|
+
* within_hours — recent window to scan (default: 24, max: 720)
|
|
99
|
+
* limit — max results (default: 100, max: 500)
|
|
80
100
|
*/
|
|
81
101
|
router.get('/orphaned-signals', auth_1.requireAdmin, async (req, res) => {
|
|
82
102
|
const result = await api.orphanedSignals({
|
|
83
103
|
appId: typeof req.query.app_id === 'string' ? req.query.app_id : undefined,
|
|
104
|
+
withinHours: req.query.within_hours ? Number(req.query.within_hours) : undefined,
|
|
84
105
|
limit: req.query.limit ? Number(req.query.limit) : undefined,
|
|
85
106
|
});
|
|
86
107
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
@@ -76,6 +76,7 @@ function registerListRoutes(router) {
|
|
|
76
76
|
offset: req.query.offset ? parseInt(req.query.offset, 10) : undefined,
|
|
77
77
|
sort_by: req.query.sort_by,
|
|
78
78
|
order: req.query.order,
|
|
79
|
+
search: req.query.search,
|
|
79
80
|
}, req.auth);
|
|
80
81
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
81
82
|
});
|
|
@@ -94,6 +95,7 @@ function registerListRoutes(router) {
|
|
|
94
95
|
offset: req.query.offset ? parseInt(req.query.offset, 10) : undefined,
|
|
95
96
|
sort_by: req.query.sort_by,
|
|
96
97
|
order: req.query.order,
|
|
98
|
+
search: req.query.search,
|
|
97
99
|
}, req.auth);
|
|
98
100
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
99
101
|
});
|
|
@@ -66,19 +66,27 @@ router.post('/:type/invoke', async (req, res) => {
|
|
|
66
66
|
// ── Workflow observation ────────────────────────────────────────────────────
|
|
67
67
|
/**
|
|
68
68
|
* GET /api/workflows/:workflowId/status
|
|
69
|
-
* Get the status of a workflow.
|
|
69
|
+
* Get the status of a workflow. Optional `app_id` query param selects the
|
|
70
|
+
* HotMesh namespace for resolution (default: durable).
|
|
70
71
|
*/
|
|
71
72
|
router.get('/:workflowId/status', async (req, res) => {
|
|
72
|
-
const result = await api.getWorkflowStatus({
|
|
73
|
+
const result = await api.getWorkflowStatus({
|
|
74
|
+
workflowId: req.params.workflowId,
|
|
75
|
+
appId: typeof req.query.app_id === 'string' ? req.query.app_id : undefined,
|
|
76
|
+
});
|
|
73
77
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
74
78
|
});
|
|
75
79
|
/**
|
|
76
80
|
* GET /api/workflows/:workflowId/result
|
|
77
81
|
* Return the workflow result if complete, or 202 if still running.
|
|
78
|
-
* Never blocks — always returns immediately.
|
|
82
|
+
* Never blocks — always returns immediately. Optional `app_id` query param
|
|
83
|
+
* selects the HotMesh namespace for resolution (default: durable).
|
|
79
84
|
*/
|
|
80
85
|
router.get('/:workflowId/result', async (req, res) => {
|
|
81
|
-
const result = await api.getWorkflowResult({
|
|
86
|
+
const result = await api.getWorkflowResult({
|
|
87
|
+
workflowId: req.params.workflowId,
|
|
88
|
+
appId: typeof req.query.app_id === 'string' ? req.query.app_id : undefined,
|
|
89
|
+
});
|
|
82
90
|
res.status(result.status).json(result.data ?? { error: result.error });
|
|
83
91
|
});
|
|
84
92
|
/**
|
package/build/sdk/index.d.ts
CHANGED
|
@@ -95,6 +95,7 @@ export declare function createClient(options?: LTClientOptions): {
|
|
|
95
95
|
offset?: number;
|
|
96
96
|
sort_by?: string;
|
|
97
97
|
order?: string;
|
|
98
|
+
search?: string;
|
|
98
99
|
}, auth?: LTApiAuth) => Promise<LTApiResult<any>>;
|
|
99
100
|
listAvailable: (input: {
|
|
100
101
|
role?: string;
|
|
@@ -105,6 +106,7 @@ export declare function createClient(options?: LTClientOptions): {
|
|
|
105
106
|
offset?: number;
|
|
106
107
|
sort_by?: string;
|
|
107
108
|
order?: string;
|
|
109
|
+
search?: string;
|
|
108
110
|
}, auth?: LTApiAuth) => Promise<LTApiResult<any>>;
|
|
109
111
|
listTypes: typeof escalationsApi.listDistinctTypes;
|
|
110
112
|
getStats: (input: {
|
|
@@ -129,9 +129,10 @@ async function getStreamMessages(schema, params) {
|
|
|
129
129
|
const workflowName = params.workflow_name ?? null;
|
|
130
130
|
const jid = params.jid ?? null;
|
|
131
131
|
const aid = params.aid ?? null;
|
|
132
|
+
const dad = params.dad ?? null;
|
|
132
133
|
const pool = (0, db_1.getPool)();
|
|
133
|
-
const queryParams = [streamName, status, msgType, topic, workflowName, jid, aid, limit, offset];
|
|
134
|
-
const countParams = [streamName, status, msgType, topic, workflowName, jid, aid];
|
|
134
|
+
const queryParams = [streamName, status, msgType, topic, workflowName, jid, aid, dad, limit, offset];
|
|
135
|
+
const countParams = [streamName, status, msgType, topic, workflowName, jid, aid, dad];
|
|
135
136
|
const [messagesRes, countRes] = await Promise.all([
|
|
136
137
|
pool.query((0, stream_messages_sql_1.LIST_STREAM_MESSAGES)(schema, sortColumn, sortOrder, source), queryParams).catch(() => ({ rows: [] })),
|
|
137
138
|
pool.query((0, stream_messages_sql_1.COUNT_STREAM_MESSAGES)(schema, source), countParams).catch(() => ({ rows: [{ count: 0 }] })),
|
|
@@ -9,13 +9,14 @@ export declare const VALID_SORT_ORDERS: Set<string>;
|
|
|
9
9
|
* with different schemas and must never be commingled in a single query.
|
|
10
10
|
*
|
|
11
11
|
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type,
|
|
12
|
-
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid,
|
|
13
|
-
* $
|
|
12
|
+
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid, $8 = dad,
|
|
13
|
+
* $9 = limit, $10 = offset
|
|
14
14
|
*/
|
|
15
15
|
export declare function LIST_STREAM_MESSAGES(schema: string, sortColumn: string, sortOrder: string, source: 'engine' | 'worker'): string;
|
|
16
16
|
/**
|
|
17
17
|
* Count stream messages matching the filter criteria.
|
|
18
18
|
*
|
|
19
|
-
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type
|
|
19
|
+
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type,
|
|
20
|
+
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid, $8 = dad
|
|
20
21
|
*/
|
|
21
22
|
export declare function COUNT_STREAM_MESSAGES(schema: string, source: 'engine' | 'worker'): string;
|
|
@@ -42,8 +42,10 @@ const STATUS_CASE = `
|
|
|
42
42
|
* $5 = workflow_name filter (NULL = all, worker-only)
|
|
43
43
|
* $6 = jid filter (NULL = all, worker-only)
|
|
44
44
|
* $7 = aid filter (NULL = all, worker-only)
|
|
45
|
+
* $8 = dad filter (NULL = all, worker-only — pins one execution dimension)
|
|
45
46
|
*/
|
|
46
|
-
/** Engine WHERE: supports stream_name, status, and jid (v0.18.0).
|
|
47
|
+
/** Engine WHERE: supports stream_name, status, and jid (v0.18.0). engine_streams
|
|
48
|
+
* has no aid/dad columns, so $7/$8 are accepted but inert here. */
|
|
47
49
|
const ENGINE_WHERE_CLAUSE = `
|
|
48
50
|
WHERE ($1::text IS NULL OR stream_name ILIKE $1)
|
|
49
51
|
AND ($2::text IS NULL OR ${STATUS_CASE} = $2)
|
|
@@ -51,7 +53,8 @@ const ENGINE_WHERE_CLAUSE = `
|
|
|
51
53
|
AND ($4::text IS NULL)
|
|
52
54
|
AND ($5::text IS NULL)
|
|
53
55
|
AND ($6::text IS NULL OR jid = $6)
|
|
54
|
-
AND ($7::text IS NULL)
|
|
56
|
+
AND ($7::text IS NULL)
|
|
57
|
+
AND ($8::text IS NULL)`;
|
|
55
58
|
const WORKER_WHERE_CLAUSE = `
|
|
56
59
|
WHERE ($1::text IS NULL OR stream_name ILIKE $1)
|
|
57
60
|
AND ($2::text IS NULL OR ${STATUS_CASE} = $2)
|
|
@@ -59,7 +62,8 @@ const WORKER_WHERE_CLAUSE = `
|
|
|
59
62
|
AND ($4::text IS NULL OR topic = $4)
|
|
60
63
|
AND ($5::text IS NULL OR workflow_name = $5)
|
|
61
64
|
AND ($6::text IS NULL OR jid = $6)
|
|
62
|
-
AND ($7::text IS NULL OR aid = $7)
|
|
65
|
+
AND ($7::text IS NULL OR aid = $7)
|
|
66
|
+
AND ($8::text IS NULL OR dad = $8)`;
|
|
63
67
|
/**
|
|
64
68
|
* List stream messages with pagination, filtering, and sorting.
|
|
65
69
|
*
|
|
@@ -67,8 +71,8 @@ const WORKER_WHERE_CLAUSE = `
|
|
|
67
71
|
* with different schemas and must never be commingled in a single query.
|
|
68
72
|
*
|
|
69
73
|
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type,
|
|
70
|
-
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid,
|
|
71
|
-
* $
|
|
74
|
+
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid, $8 = dad,
|
|
75
|
+
* $9 = limit, $10 = offset
|
|
72
76
|
*/
|
|
73
77
|
function LIST_STREAM_MESSAGES(schema, sortColumn, sortOrder, source) {
|
|
74
78
|
const select = source === 'engine'
|
|
@@ -94,12 +98,13 @@ function LIST_STREAM_MESSAGES(schema, sortColumn, sortOrder, source) {
|
|
|
94
98
|
return `
|
|
95
99
|
SELECT * FROM (${select}) AS q
|
|
96
100
|
ORDER BY ${sortColumn} ${sortOrder}, id DESC
|
|
97
|
-
LIMIT $
|
|
101
|
+
LIMIT $9::int OFFSET $10::int`;
|
|
98
102
|
}
|
|
99
103
|
/**
|
|
100
104
|
* Count stream messages matching the filter criteria.
|
|
101
105
|
*
|
|
102
|
-
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type
|
|
106
|
+
* Parameters: $1 = stream_name, $2 = status, $3 = msg_type,
|
|
107
|
+
* $4 = topic, $5 = workflow_name, $6 = jid, $7 = aid, $8 = dad
|
|
103
108
|
*/
|
|
104
109
|
function COUNT_STREAM_MESSAGES(schema, source) {
|
|
105
110
|
const table = source === 'engine' ? 'engine_streams' : 'worker_streams';
|
|
@@ -51,6 +51,8 @@ export interface StreamMessagesParams {
|
|
|
51
51
|
workflow_name?: string | null;
|
|
52
52
|
jid?: string | null;
|
|
53
53
|
aid?: string | null;
|
|
54
|
+
/** Dimension/ancestor path (worker-only) — pins one execution among siblings sharing an aid. */
|
|
55
|
+
dad?: string | null;
|
|
54
56
|
}
|
|
55
57
|
export interface StreamMessagesResult {
|
|
56
58
|
messages: StreamMessage[];
|
|
@@ -17,26 +17,70 @@ export interface StreamSummary {
|
|
|
17
17
|
pending: number;
|
|
18
18
|
in_flight: number;
|
|
19
19
|
}
|
|
20
|
+
/** A large string field replaced with a bounded summary instead of the full payload. */
|
|
21
|
+
export interface TruncatedString {
|
|
22
|
+
bytes: number;
|
|
23
|
+
preview: string;
|
|
24
|
+
truncated: true;
|
|
25
|
+
}
|
|
26
|
+
/** Pointer to the stream browser for the raw, untruncated message payloads. */
|
|
27
|
+
export interface RawMessagesHint {
|
|
28
|
+
hint: string;
|
|
29
|
+
jid: string;
|
|
30
|
+
}
|
|
31
|
+
/** A stream message whose large `message` payload may have been summarized. */
|
|
32
|
+
export type SummarizedStreamMessage = Omit<StreamMessage, 'message'> & {
|
|
33
|
+
message: string | TruncatedString;
|
|
34
|
+
};
|
|
20
35
|
export interface JobDiagnosis {
|
|
21
36
|
workflow_id: string;
|
|
22
37
|
app_id: string;
|
|
23
38
|
status: 'running' | 'completed' | 'failed' | 'not_found';
|
|
24
|
-
|
|
39
|
+
/**
|
|
40
|
+
* Milliseconds since the last execution event. NOT a fault signal on its own —
|
|
41
|
+
* a workflow can sit at a condition()/waitFor()/sleepFor() for days legitimately.
|
|
42
|
+
* Read `findings` for the actual interpretation.
|
|
43
|
+
*/
|
|
44
|
+
idle_for_ms: number | null;
|
|
25
45
|
workflow_type: string | null;
|
|
26
46
|
last_event_at: string | null;
|
|
27
47
|
stream_summary: StreamSummary;
|
|
28
48
|
escalation: EscalationSummary;
|
|
29
49
|
findings: Finding[];
|
|
30
|
-
execution_events
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
50
|
+
/** Total events before any cap was applied (execution_events may be truncated to the most recent `maxEvents`). */
|
|
51
|
+
total_events: number;
|
|
52
|
+
events_truncated: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Full event timeline — present only when `include` contains `'events'` (or
|
|
55
|
+
* `verbosity: 'full'`). Large string attributes are summarized to
|
|
56
|
+
* `{ bytes, preview, truncated }`. Omitted by default to keep the verdict compact.
|
|
57
|
+
*/
|
|
58
|
+
execution_events?: unknown[];
|
|
59
|
+
/**
|
|
60
|
+
* Raw engine + worker stream messages — present only when `include` contains
|
|
61
|
+
* `'streams'` (or `verbosity: 'full'`). Large `message` payloads are summarized.
|
|
62
|
+
* Omitted by default; see `raw_messages` for where to fetch the full payloads.
|
|
63
|
+
*/
|
|
64
|
+
stream_messages?: {
|
|
65
|
+
worker: SummarizedStreamMessage[];
|
|
66
|
+
engine: SummarizedStreamMessage[];
|
|
34
67
|
};
|
|
68
|
+
/** Pointer to `list_stream_messages` for the raw payloads (present when streams are omitted). */
|
|
69
|
+
raw_messages?: RawMessagesHint;
|
|
70
|
+
}
|
|
71
|
+
export type DiagnoseVerbosity = 'summary' | 'full';
|
|
72
|
+
export type DiagnoseSection = 'events' | 'streams';
|
|
73
|
+
export interface DiagnoseOptions {
|
|
74
|
+
maxEvents?: number;
|
|
75
|
+
/** Heavy sections to include in the response. Default: none (verdict only). */
|
|
76
|
+
include?: DiagnoseSection[];
|
|
77
|
+
/** Shorthand: `'full'` includes both events and streams; `'summary'` (default) includes neither. */
|
|
78
|
+
verbosity?: DiagnoseVerbosity;
|
|
35
79
|
}
|
|
36
|
-
export declare function diagnoseJob(workflowId: string, appId?: string): Promise<JobDiagnosis>;
|
|
80
|
+
export declare function diagnoseJob(workflowId: string, appId?: string, options?: DiagnoseOptions): Promise<JobDiagnosis>;
|
|
37
81
|
export declare function findStalledJobs(params: {
|
|
38
82
|
appId?: string;
|
|
39
|
-
|
|
83
|
+
idleMinutes?: number;
|
|
40
84
|
workflowType?: string | null;
|
|
41
85
|
limit?: number;
|
|
42
86
|
}): Promise<{
|
|
@@ -45,8 +89,10 @@ export declare function findStalledJobs(params: {
|
|
|
45
89
|
}>;
|
|
46
90
|
export declare function findOrphanedSignals(params: {
|
|
47
91
|
appId?: string;
|
|
92
|
+
withinHours?: number;
|
|
48
93
|
limit?: number;
|
|
49
94
|
}): Promise<{
|
|
50
95
|
orphans: unknown[];
|
|
51
96
|
total: number;
|
|
97
|
+
within_hours: number;
|
|
52
98
|
}>;
|