nx-kv 0.65.0 → 0.65.3

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 (155) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/package.json +1 -1
  3. package/src/core/db/seed-templates.ts +2 -86
  4. package/src/core/db/settings.ts +1 -1
  5. package/src/core/instruction-template.ts +1 -1
  6. package/src/core/workflow/plugin-registry.ts +1 -1
  7. package/src/core/workflow/types.ts +4 -4
  8. package/src/modules/claim/actions/_manifest.generated.ts +23 -0
  9. package/src/modules/{localtask → claim}/actions/localtask-claim.ts +4 -4
  10. package/src/modules/{localtask → claim}/actions/localtask-preview.ts +4 -4
  11. package/src/modules/{localtask → claim}/actions/localtask-wait.ts +4 -4
  12. package/src/modules/{tasktool → claim}/get.ts +3 -3
  13. package/src/modules/claim/index.ts +25 -0
  14. package/src/modules/{tasktool → claim}/panel-escort.ts +2 -2
  15. package/src/modules/{tasktool → claim}/params.ts +1 -1
  16. package/src/modules/claim/wait.ts +305 -0
  17. package/src/modules/{tasktool/plugins → claim}/waitgoal-config.ts +4 -28
  18. package/src/modules/delivery/assemble.ts +151 -0
  19. package/src/modules/{tasktool → delivery}/attach-resource.ts +2 -2
  20. package/src/modules/{tasktool → delivery}/attach-template.ts +1 -1
  21. package/src/modules/{tasktool → delivery}/attach.ts +1 -1
  22. package/src/modules/{tasktool → delivery}/delivery-text.ts +2 -2
  23. package/src/modules/{tasktool → delivery}/doc-inline.ts +1 -1
  24. package/src/modules/{tasktool → delivery}/groupctx.ts +1 -1
  25. package/src/modules/delivery/host.ts +231 -0
  26. package/src/modules/delivery/index.ts +18 -0
  27. package/src/modules/{tasktool → delivery}/preview.ts +5 -6
  28. package/src/modules/{tasktool → goals}/actions/timegoal-check.ts +1 -1
  29. package/src/modules/{tasktool → goals}/actions/timegoal-clear.ts +1 -1
  30. package/src/modules/{tasktool → goals}/actions/timegoal-list.ts +1 -1
  31. package/src/modules/{tasktool → goals}/actions/timegoal-log.ts +1 -1
  32. package/src/modules/{tasktool → goals}/actions/timegoal-set.ts +1 -1
  33. package/src/modules/{tasktool → goals}/actions/timegoal-show.ts +1 -1
  34. package/src/modules/{tasktool → goals}/actions/timegoal-update.ts +1 -1
  35. package/src/modules/goals/index.ts +25 -0
  36. package/src/modules/{tasktool → goals}/plugins/discover.ts +3 -3
  37. package/src/modules/{tasktool → goals}/plugins/index.ts +0 -2
  38. package/src/modules/{tasktool → goals}/plugins/taskgoal-store.ts +3 -3
  39. package/src/modules/{tasktool → goals}/plugins/timegoal-task-store.ts +2 -2
  40. package/src/modules/localtask/action-render.ts +1 -1
  41. package/src/modules/localtask/actions/_manifest.generated.ts +0 -9
  42. package/src/modules/localtask/actions/localtask-add.ts +2 -2
  43. package/src/modules/localtask/actions/localtask-attach-note.ts +1 -1
  44. package/src/modules/localtask/actions/localtask-attach.ts +1 -1
  45. package/src/modules/localtask/actions/localtask-attachments.ts +1 -1
  46. package/src/modules/localtask/actions/localtask-detach.ts +1 -1
  47. package/src/modules/localtask/actions/localtask-get.ts +1 -1
  48. package/src/modules/localtask/actions/localtask-reopen.ts +1 -1
  49. package/src/modules/localtask/actions/localtask-timegoalLog.ts +1 -1
  50. package/src/modules/localtask/actions/localtask-update.ts +2 -2
  51. package/src/modules/{tasktool → localtask}/add.ts +3 -3
  52. package/src/modules/localtask/engine.ts +1 -1
  53. package/src/modules/{tasktool → localtask}/group-store.ts +2 -2
  54. package/src/modules/localtask/mutator/index.ts +1 -1
  55. package/src/modules/localtask/panel-presence.ts +2 -2
  56. package/src/modules/localtask/scheduler/state-drive.ts +1 -1
  57. package/src/modules/{tasktool → localtask}/support.ts +1 -1
  58. package/src/modules/localtask/task-lifecycle.ts +5 -5
  59. package/src/modules/localtask/task-ops.ts +1 -1
  60. package/src/modules/localtask/task-templates.ts +1 -1
  61. package/src/modules/localtask/task-view.ts +1 -1
  62. package/src/modules/{tasktool → localtask}/update.ts +1 -1
  63. package/src/modules/localtask/waiters.ts +1 -1
  64. package/src/modules/localtask/writes.ts +1 -1
  65. package/src/modules/promptplug/factory.ts +5 -5
  66. package/src/modules/promptplug/index.ts +5 -5
  67. package/src/modules/promptplug/plugins/attachment.ts +1 -1
  68. package/src/modules/promptplug/plugins/context.ts +1 -1
  69. package/src/modules/promptplug/plugins/getloop.ts +8 -7
  70. package/src/modules/{tasktool/plugins/goal-template.ts → promptplug/plugins/goal-prompt.ts} +4 -3
  71. package/src/modules/repos/service/crud.ts +1 -1
  72. package/src/modules/templates/actions/templates-default.ts +2 -5
  73. package/src/modules/templates/actions/templates-update.ts +1 -3
  74. package/src/modules/templates/service.ts +11 -13
  75. package/src/modules/templates/support.ts +0 -15
  76. package/src/runtime/registry.ts +6 -2
  77. package/src/web/frontend/App.tsx +0 -12
  78. package/src/web/frontend/api/cli-tree.json +138 -138
  79. package/src/web/frontend/api/client.generated.ts +90 -88
  80. package/src/web/frontend/components/md/live-block.tsx +1 -5
  81. package/src/web/frontend/components/md/md-panes-root.tsx +0 -4
  82. package/src/web/frontend/components/md/md-panes.tsx +1 -11
  83. package/src/web/frontend/modules/md/styles/docs.css +0 -7
  84. package/src/web/frontend/modules/md/styles/editor.css +0 -17
  85. package/src/web/frontend/modules/md/use-templates.ts +3 -13
  86. package/src/web/frontend/page/dir/index.tsx +3 -15
  87. package/src/web/frontend/page/dir/task-actions.ts +1 -16
  88. package/src/web/frontend/page/dir/task.tsx +2 -16
  89. package/src/web/frontend/page/group/index.tsx +6 -19
  90. package/src/web/frontend/page/settings/index.tsx +1 -1
  91. package/src/web/frontend/page/templates/index.tsx +5 -54
  92. package/src/web/frontend/page/templates/manage.tsx +1 -5
  93. package/src/web/frontend/page/templates/style.css +1 -43
  94. package/src/web/frontend/page/templates/template-list.tsx +7 -15
  95. package/src/web/frontend/routes/route-eq.ts +2 -3
  96. package/src/web/frontend/routes/templates.ts +0 -10
  97. package/src/web/frontend/styles-v2/shell.css +7 -0
  98. package/src/web/frontend/types.ts +2 -1
  99. package/src/web/public/assets/{bar-csH6ZW39.js → bar-Dc5Tq1eE.js} +1 -1
  100. package/src/web/public/assets/{composer-launch-Ba9cBxhb.js → composer-launch-fp2IzGzQ.js} +1 -1
  101. package/src/web/public/assets/{composer-panel-7SHKllt5.js → composer-panel-Dh681iO6.js} +1 -1
  102. package/src/web/public/assets/dir-d16q1GLe.js +3 -0
  103. package/src/web/public/assets/{doc-BmGb9F-k.js → doc-DRSKD0Re.js} +1 -1
  104. package/src/web/public/assets/group-Dc3ZgW24.js +1 -0
  105. package/src/web/public/assets/{index-D1wpt-oL.css → index-BIVxGd6t.css} +1 -1
  106. package/src/web/public/assets/index-Bg0m8gbJ.js +2 -0
  107. package/src/web/public/assets/{md-history-DVI47hu4.js → md-history-DNtgaIdH.js} +6 -6
  108. package/src/web/public/assets/{refs-P8HrKv4T.js → refs-TzxZYy7T.js} +1 -1
  109. package/src/web/public/assets/{repo-form-modal-BiBZ63DZ.js → repo-form-modal-Dg3hJWUV.js} +1 -1
  110. package/src/web/public/assets/{repos-B9D8q6U7.js → repos-uNqSR5YB.js} +1 -1
  111. package/src/web/public/assets/task-DuFOXLPC.js +11 -0
  112. package/src/web/public/assets/{task-utils-DPGXUIOk.js → task-utils-DAPxKm4c.js} +1 -1
  113. package/src/web/public/assets/templates-CwYDIBYn.css +1 -0
  114. package/src/web/public/assets/templates-DNiGvmdq.js +10 -0
  115. package/src/web/public/assets/{use-rail-drag-TGx8CLcY.js → use-rail-drag-DxIYcszo.js} +1 -1
  116. package/src/web/public/index.html +6 -7
  117. package/src/core/workflow/edges.ts +0 -28
  118. package/src/core/workflow/layout.ts +0 -118
  119. package/src/modules/tasktool/facade/get.ts +0 -54
  120. package/src/modules/tasktool/facade/index.ts +0 -4
  121. package/src/modules/tasktool/facade/submit.ts +0 -61
  122. package/src/modules/tasktool/facade/wait.ts +0 -3
  123. package/src/modules/tasktool/getloop.ts +0 -2
  124. package/src/modules/tasktool/index.ts +0 -24
  125. package/src/modules/tasktool/plugins/runtime.ts +0 -73
  126. package/src/modules/tasktool/plugins/waitgoal.ts +0 -75
  127. package/src/modules/tasktool/wait.ts +0 -572
  128. package/src/web/frontend/modules/md/fill-session.ts +0 -36
  129. package/src/web/frontend/modules/md/new-task-from-template.ts +0 -22
  130. package/src/web/frontend/modules/md/task-intent.ts +0 -29
  131. package/src/web/frontend/modules/prompts/render-template-body.ts +0 -14
  132. package/src/web/frontend/modules/prompts/template-preview.ts +0 -62
  133. package/src/web/frontend/page/templates/fill.tsx +0 -126
  134. package/src/web/public/assets/dir-D5AImCiy.js +0 -3
  135. package/src/web/public/assets/fill-session-fHxQHFaD.js +0 -1
  136. package/src/web/public/assets/group-CTktws14.js +0 -1
  137. package/src/web/public/assets/index-Byb7MFTl.js +0 -2
  138. package/src/web/public/assets/new-task-from-template-DDWu4yR4.js +0 -1
  139. package/src/web/public/assets/render-template-body-bXdedFig.js +0 -1
  140. package/src/web/public/assets/task-BBk0TQZi.js +0 -11
  141. package/src/web/public/assets/task-intent-CX5DZccN.js +0 -1
  142. package/src/web/public/assets/templates-BN9i9-6c.js +0 -11
  143. package/src/web/public/assets/templates-plA8R7jJ.css +0 -1
  144. /package/src/modules/{tasktool → goals}/actions/_manifest.generated.ts +0 -0
  145. /package/src/modules/{tasktool → goals}/actions/timegoal-prune.ts +0 -0
  146. /package/src/modules/{tasktool → goals}/plugins/base.ts +0 -0
  147. /package/src/modules/{tasktool → goals}/plugins/blockgoal.ts +0 -0
  148. /package/src/modules/{tasktool → goals}/plugins/container.ts +0 -0
  149. /package/src/modules/{tasktool → goals}/plugins/taskgoal.ts +0 -0
  150. /package/src/modules/{tasktool → goals}/plugins/timegoal-core-store.ts +0 -0
  151. /package/src/modules/{tasktool → goals}/plugins/timegoal-cwd-store.ts +0 -0
  152. /package/src/modules/{tasktool → goals}/plugins/timegoal-store.ts +0 -0
  153. /package/src/modules/{tasktool → goals}/plugins/timegoal.ts +0 -0
  154. /package/src/modules/{tasktool → goals}/taskgoal.ts +0 -0
  155. /package/src/modules/{tasktool → goals}/timegoal.ts +0 -0
@@ -1274,21 +1274,6 @@
1274
1274
  },
1275
1275
  "children": []
1276
1276
  },
1277
- {
1278
- "name": "get",
1279
- "path": [
1280
- "localtask",
1281
- "get"
1282
- ],
1283
- "action": {
1284
- "id": "localtask.claim",
1285
- "module": "localtask",
1286
- "summary": "领取任务:有任务立即领(含任务级 timegoal 的 check 指令);没任务默认立即返回 timeout,项目开启「持续 get」后自动唤起阻塞窗口等人回填",
1287
- "usage": "localtask get",
1288
- "http": "POST /api/localtasks/claim"
1289
- },
1290
- "children": []
1291
- },
1292
1277
  {
1293
1278
  "name": "clone",
1294
1279
  "path": [
@@ -1454,21 +1439,6 @@
1454
1439
  },
1455
1440
  "children": []
1456
1441
  },
1457
- {
1458
- "name": "preview",
1459
- "path": [
1460
- "localtask",
1461
- "preview"
1462
- ],
1463
- "action": {
1464
- "id": "localtask.preview",
1465
- "module": "localtask",
1466
- "summary": "预览一条任务在 get/wait 时的交付提示词(只读:不领取、不写盘、不启动计时、不为附件发网);草稿用 --text 直接预览",
1467
- "usage": "localtask preview",
1468
- "http": "POST /api/localtasks/preview"
1469
- },
1470
- "children": []
1471
- },
1472
1442
  {
1473
1443
  "name": "prune",
1474
1444
  "path": [
@@ -1673,6 +1643,36 @@
1673
1643
  },
1674
1644
  "children": []
1675
1645
  },
1646
+ {
1647
+ "name": "get",
1648
+ "path": [
1649
+ "localtask",
1650
+ "get"
1651
+ ],
1652
+ "action": {
1653
+ "id": "localtask.claim",
1654
+ "module": "claim",
1655
+ "summary": "领取任务:有任务立即领(含任务级 timegoal 的 check 指令);没任务默认立即返回 timeout,项目开启「持续 get」后自动唤起阻塞窗口等人回填",
1656
+ "usage": "localtask get",
1657
+ "http": "POST /api/localtasks/claim"
1658
+ },
1659
+ "children": []
1660
+ },
1661
+ {
1662
+ "name": "preview",
1663
+ "path": [
1664
+ "localtask",
1665
+ "preview"
1666
+ ],
1667
+ "action": {
1668
+ "id": "localtask.preview",
1669
+ "module": "claim",
1670
+ "summary": "预览一条任务在 get/wait 时的交付提示词(只读:不领取、不写盘、不启动计时、不为附件发网);草稿用 --text 直接预览",
1671
+ "usage": "localtask preview",
1672
+ "http": "POST /api/localtasks/preview"
1673
+ },
1674
+ "children": []
1675
+ },
1676
1676
  {
1677
1677
  "name": "wait",
1678
1678
  "path": [
@@ -1681,7 +1681,7 @@
1681
1681
  ],
1682
1682
  "action": {
1683
1683
  "id": "localtask.wait",
1684
- "module": "localtask",
1684
+ "module": "claim",
1685
1685
  "summary": "针对某主题(按 cwd 目录名识别)阻塞等待用户回填(默认 3 分钟,最大 10 分钟);本地空时自动领取全局共享池的任务",
1686
1686
  "usage": "localtask wait",
1687
1687
  "http": null
@@ -1690,6 +1690,105 @@
1690
1690
  }
1691
1691
  ]
1692
1692
  },
1693
+ {
1694
+ "name": "template",
1695
+ "path": [
1696
+ "template"
1697
+ ],
1698
+ "action": null,
1699
+ "children": [
1700
+ {
1701
+ "name": "add",
1702
+ "path": [
1703
+ "template",
1704
+ "add"
1705
+ ],
1706
+ "action": {
1707
+ "id": "templates.add",
1708
+ "module": "templates",
1709
+ "summary": "新增任务模板(--body 给 Markdown 正文;多行正文用 --body-file <文件> 或 --body - 读管道;--setDefault 同时设为默认;--scope 设可见域、--topic 记创建主题并默认仅该主题可见)",
1710
+ "usage": "template add",
1711
+ "http": "POST /api/templates"
1712
+ },
1713
+ "children": []
1714
+ },
1715
+ {
1716
+ "name": "default",
1717
+ "path": [
1718
+ "template",
1719
+ "default"
1720
+ ],
1721
+ "action": {
1722
+ "id": "templates.default",
1723
+ "module": "templates",
1724
+ "summary": "设置默认模板(新建页的起始正文换成它);带 --body/--name/--scope 则改默认模板本身",
1725
+ "usage": "template default",
1726
+ "http": "PATCH /api/templates/default"
1727
+ },
1728
+ "children": []
1729
+ },
1730
+ {
1731
+ "name": "list",
1732
+ "path": [
1733
+ "template",
1734
+ "list"
1735
+ ],
1736
+ "action": {
1737
+ "id": "templates.list",
1738
+ "module": "templates",
1739
+ "summary": "列出任务模板(含默认模板 id;新建页的起始正文按默认模板取)",
1740
+ "usage": "template list",
1741
+ "http": "GET /api/templates"
1742
+ },
1743
+ "children": []
1744
+ },
1745
+ {
1746
+ "name": "remove",
1747
+ "path": [
1748
+ "template",
1749
+ "remove"
1750
+ ],
1751
+ "action": {
1752
+ "id": "templates.remove",
1753
+ "module": "templates",
1754
+ "summary": "删除任务模板(内置默认模板不可删;删的是默认模板则默认回落到内置)",
1755
+ "usage": "template remove",
1756
+ "http": "DELETE /api/templates/:id"
1757
+ },
1758
+ "children": []
1759
+ },
1760
+ {
1761
+ "name": "reorder",
1762
+ "path": [
1763
+ "template",
1764
+ "reorder"
1765
+ ],
1766
+ "action": {
1767
+ "id": "templates.reorder",
1768
+ "module": "templates",
1769
+ "summary": "调整任务模板顺序(--ids a,b,c 按新序落库 sort_order;未列出的模板保持原位)",
1770
+ "usage": "template reorder",
1771
+ "http": "PATCH /api/templates/reorder"
1772
+ },
1773
+ "children": []
1774
+ },
1775
+ {
1776
+ "name": "update",
1777
+ "path": [
1778
+ "template",
1779
+ "update"
1780
+ ],
1781
+ "action": {
1782
+ "id": "templates.update",
1783
+ "module": "templates",
1784
+ "summary": "编辑任务模板(--name 改名 / --body 改正文 / --scope 改可见域,只改传入项;多行正文用 --body-file;内置模板的正文也可改)",
1785
+ "usage": "template update",
1786
+ "http": "PATCH /api/templates/:id"
1787
+ },
1788
+ "children": []
1789
+ }
1790
+ ]
1791
+ },
1693
1792
  {
1694
1793
  "name": "timegoal",
1695
1794
  "path": [
@@ -1705,7 +1804,7 @@
1705
1804
  ],
1706
1805
  "action": {
1707
1806
  "id": "timegoal.check",
1708
- "module": "tasktool",
1807
+ "module": "goals",
1709
1808
  "summary": "时间运算 + 原文回显 prompt + 写入一次状态日志;每次必须提供当前现状 --summary",
1710
1809
  "usage": "timegoal check",
1711
1810
  "http": "GET /api/timegoals/check"
@@ -1720,7 +1819,7 @@
1720
1819
  ],
1721
1820
  "action": {
1722
1821
  "id": "timegoal.clear",
1723
- "module": "tasktool",
1822
+ "module": "goals",
1724
1823
  "summary": "清空本目录 timegoal(无则 no_goal,不抛错)",
1725
1824
  "usage": "timegoal clear",
1726
1825
  "http": "DELETE /api/timegoals"
@@ -1735,7 +1834,7 @@
1735
1834
  ],
1736
1835
  "action": {
1737
1836
  "id": "timegoal.list",
1738
- "module": "tasktool",
1837
+ "module": "goals",
1739
1838
  "summary": "列出所有有 timegoal 的目录(按截止升序;已到点的单列在归档区)",
1740
1839
  "usage": "timegoal list",
1741
1840
  "http": "GET /api/timegoals/all"
@@ -1750,7 +1849,7 @@
1750
1849
  ],
1751
1850
  "action": {
1752
1851
  "id": "timegoal.log",
1753
- "module": "tasktool",
1852
+ "module": "goals",
1754
1853
  "summary": "查看本目录 timegoal 的检查日志(每轮 check 的现状)",
1755
1854
  "usage": "timegoal log",
1756
1855
  "http": "GET /api/timegoals/log"
@@ -1765,7 +1864,7 @@
1765
1864
  ],
1766
1865
  "action": {
1767
1866
  "id": "timegoal.prune",
1768
- "module": "tasktool",
1867
+ "module": "goals",
1769
1868
  "summary": "彻底清除已到点 / 已归档的时间目标(到点本身已自动归档,这里是连归档区一起清)",
1770
1869
  "usage": "timegoal prune",
1771
1870
  "http": "POST /api/timegoals/prune"
@@ -1780,7 +1879,7 @@
1780
1879
  ],
1781
1880
  "action": {
1782
1881
  "id": "timegoal.set",
1783
- "module": "tasktool",
1882
+ "module": "goals",
1784
1883
  "summary": "为本目录设置/替换 timegoal:duration + 完整全局提示词(原文固化到 store)",
1785
1884
  "usage": "timegoal set",
1786
1885
  "http": "POST /api/timegoals"
@@ -1795,7 +1894,7 @@
1795
1894
  ],
1796
1895
  "action": {
1797
1896
  "id": "timegoal.show",
1798
- "module": "tasktool",
1897
+ "module": "goals",
1799
1898
  "summary": "查看当前 timegoal(不算时间):--cwd 目录级,--task 任务级(key 在领取交付里自带)",
1800
1899
  "usage": "timegoal show",
1801
1900
  "http": "GET /api/timegoals"
@@ -1810,7 +1909,7 @@
1810
1909
  ],
1811
1910
  "action": {
1812
1911
  "id": "timegoal.update",
1813
- "module": "tasktool",
1912
+ "module": "goals",
1814
1913
  "summary": "更新本目录 timegoal 的提示词(可选同时改时长,--duration;保留起点,不重置计时)",
1815
1914
  "usage": "timegoal update",
1816
1915
  "http": "PATCH /api/timegoals"
@@ -1819,105 +1918,6 @@
1819
1918
  }
1820
1919
  ]
1821
1920
  },
1822
- {
1823
- "name": "template",
1824
- "path": [
1825
- "template"
1826
- ],
1827
- "action": null,
1828
- "children": [
1829
- {
1830
- "name": "add",
1831
- "path": [
1832
- "template",
1833
- "add"
1834
- ],
1835
- "action": {
1836
- "id": "templates.add",
1837
- "module": "templates",
1838
- "summary": "新增任务模板(--body 给 Markdown 正文;多行正文用 --body-file <文件> 或 --body - 读管道;--setDefault 同时设为默认;--scope 设可见域、--topic 记创建主题并默认仅该主题可见)",
1839
- "usage": "template add",
1840
- "http": "POST /api/templates"
1841
- },
1842
- "children": []
1843
- },
1844
- {
1845
- "name": "default",
1846
- "path": [
1847
- "template",
1848
- "default"
1849
- ],
1850
- "action": {
1851
- "id": "templates.default",
1852
- "module": "templates",
1853
- "summary": "设置默认模板(新建页的起始正文换成它);带 --body/--name/--scope 则改默认模板本身",
1854
- "usage": "template default",
1855
- "http": "PATCH /api/templates/default"
1856
- },
1857
- "children": []
1858
- },
1859
- {
1860
- "name": "list",
1861
- "path": [
1862
- "template",
1863
- "list"
1864
- ],
1865
- "action": {
1866
- "id": "templates.list",
1867
- "module": "templates",
1868
- "summary": "列出任务模板(含默认模板 id;新建页的起始正文按默认模板取)",
1869
- "usage": "template list",
1870
- "http": "GET /api/templates"
1871
- },
1872
- "children": []
1873
- },
1874
- {
1875
- "name": "remove",
1876
- "path": [
1877
- "template",
1878
- "remove"
1879
- ],
1880
- "action": {
1881
- "id": "templates.remove",
1882
- "module": "templates",
1883
- "summary": "删除任务模板(内置默认模板不可删;删的是默认模板则默认回落到内置)",
1884
- "usage": "template remove",
1885
- "http": "DELETE /api/templates/:id"
1886
- },
1887
- "children": []
1888
- },
1889
- {
1890
- "name": "reorder",
1891
- "path": [
1892
- "template",
1893
- "reorder"
1894
- ],
1895
- "action": {
1896
- "id": "templates.reorder",
1897
- "module": "templates",
1898
- "summary": "调整任务模板顺序(--ids a,b,c 按新序落库 sort_order;未列出的模板保持原位)",
1899
- "usage": "template reorder",
1900
- "http": "PATCH /api/templates/reorder"
1901
- },
1902
- "children": []
1903
- },
1904
- {
1905
- "name": "update",
1906
- "path": [
1907
- "template",
1908
- "update"
1909
- ],
1910
- "action": {
1911
- "id": "templates.update",
1912
- "module": "templates",
1913
- "summary": "编辑任务模板(--name 改名 / --body 改正文 / --scope 改可见域,只改传入项;多行正文用 --body-file;内置模板的正文也可改)",
1914
- "usage": "template update",
1915
- "http": "PATCH /api/templates/:id"
1916
- },
1917
- "children": []
1918
- }
1919
- ]
1920
- },
1921
1921
  {
1922
1922
  "name": "file",
1923
1923
  "path": [
@@ -12,6 +12,10 @@ import type {
12
12
  BundledInstallAction,
13
13
  BundledListAction,
14
14
  } from '../../../modules/bundled/actions/_manifest.generated.js';
15
+ import type {
16
+ LocaltaskClaimAction,
17
+ LocaltaskPreviewAction,
18
+ } from '../../../modules/claim/actions/_manifest.generated.js';
15
19
  import type {
16
20
  DocAttachAction,
17
21
  DocAttachmentsAction,
@@ -40,6 +44,16 @@ import type {
40
44
  FilePruneAction,
41
45
  FileUploadAction,
42
46
  } from '../../../modules/file/actions/_manifest.generated.js';
47
+ import type {
48
+ TimegoalCheckAction,
49
+ TimegoalClearAction,
50
+ TimegoalListAction,
51
+ TimegoalLogAction,
52
+ TimegoalPruneAction,
53
+ TimegoalSetAction,
54
+ TimegoalShowAction,
55
+ TimegoalUpdateAction,
56
+ } from '../../../modules/goals/actions/_manifest.generated.js';
43
57
  import type {
44
58
  LocaltaskAddAction,
45
59
  LocaltaskAttachAction,
@@ -49,7 +63,6 @@ import type {
49
63
  LocaltaskCancelAction,
50
64
  LocaltaskCancelManyAction,
51
65
  LocaltaskChainAction,
52
- LocaltaskClaimAction,
53
66
  LocaltaskCloneAction,
54
67
  LocaltaskCloseManyAction,
55
68
  LocaltaskConfigAction,
@@ -61,7 +74,6 @@ import type {
61
74
  LocaltaskListAction,
62
75
  LocaltaskPlanAction,
63
76
  LocaltaskPresenceAction,
64
- LocaltaskPreviewAction,
65
77
  LocaltaskPruneAction,
66
78
  LocaltaskRemoveAction,
67
79
  LocaltaskRemoveManyAction,
@@ -135,16 +147,6 @@ import type {
135
147
  ContractAction,
136
148
  HealthAction,
137
149
  } from '../../../modules/system/actions/_manifest.generated.js';
138
- import type {
139
- TimegoalCheckAction,
140
- TimegoalClearAction,
141
- TimegoalListAction,
142
- TimegoalLogAction,
143
- TimegoalPruneAction,
144
- TimegoalSetAction,
145
- TimegoalShowAction,
146
- TimegoalUpdateAction,
147
- } from '../../../modules/tasktool/actions/_manifest.generated.js';
148
150
  import type {
149
151
  TemplatesAddAction,
150
152
  TemplatesDefaultAction,
@@ -310,8 +312,6 @@ export interface ApiClient {
310
312
  cancelMany(input: z.input<InstanceType<typeof LocaltaskCancelManyAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskCancelManyAction>['run']>>>;
311
313
  /** 查一条任务的链:history 节点(origin/reopen/comment/current)+ 旧 forkOf 祖先/子任务;面板点节点可旁路查看正文 */
312
314
  chain(input: z.input<InstanceType<typeof LocaltaskChainAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskChainAction>['run']>>>;
313
- /** 领取任务:有任务立即领(含任务级 timegoal 的 check 指令);没任务默认立即返回 timeout,项目开启「持续 get」后自动唤起阻塞窗口等人回填 */
314
- claim(input?: z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskClaimAction>['run']>>>;
315
315
  /** 克隆任务:复制正文内容为一条新任务(同主题;全局任务仍进全局池)。不带派生链、不继承时间目标与依赖——开新活用 */
316
316
  localtaskClone(input: z.input<InstanceType<typeof LocaltaskCloneAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskCloneAction>['run']>>>;
317
317
  /** 批量收口还没结束的任务(按 --ids,定位到 --cwd 主题或 --key):不要求先领取;--status done 写完成总结,cancelled 只改状态;待领取与已领取都能收(已领取的 agent 侧回执会被忽略),已完成/已取消跳过 */
@@ -334,8 +334,6 @@ export interface ApiClient {
334
334
  plan(input: z.input<InstanceType<typeof LocaltaskPlanAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskPlanAction>['run']>>>;
335
335
  /** 探测主面板上当前打开的「实时任务」标签数(活动 SSE 连接数;用于 wait 不重复开页) */
336
336
  presence(): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskPresenceAction>['run']>>>;
337
- /** 预览一条任务在 get/wait 时的交付提示词(只读:不领取、不写盘、不启动计时、不为附件发网);草稿用 --text 直接预览 */
338
- preview(input?: z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskPreviewAction>['run']>>>;
339
337
  /** 清理旧脏数据(旧模型无目录主题、空主题;--missing-dir 连目录已不存在的主题一起清;等待中一律保留) */
340
338
  localtaskPrune(input?: z.input<InstanceType<typeof LocaltaskPruneAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskPruneAction>['run']>>>;
341
339
  /** 删除一条任务(按 --id,定位到 --cwd 主题或 --key);删除是**可恢复**的(软删除),加 --purge 彻底清除 */
@@ -360,6 +358,22 @@ export interface ApiClient {
360
358
  topicRemoveMany(input?: z.input<InstanceType<typeof LocaltaskTopicRemoveManyAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskTopicRemoveManyAction>['run']>>>;
361
359
  /** 编辑任务内容(按 --id,定位到 --cwd 主题或 --key);可同时改时间目标声明(--duration/--goal-prompt/--clear-goal,仅未领取时可改——领取即计时,起表后声明是既成事实) */
362
360
  localtaskUpdate(input: z.input<InstanceType<typeof LocaltaskUpdateAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskUpdateAction>['run']>>>;
361
+ /** 领取任务:有任务立即领(含任务级 timegoal 的 check 指令);没任务默认立即返回 timeout,项目开启「持续 get」后自动唤起阻塞窗口等人回填 */
362
+ claim(input?: z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskClaimAction>['run']>>>;
363
+ /** 预览一条任务在 get/wait 时的交付提示词(只读:不领取、不写盘、不启动计时、不为附件发网);草稿用 --text 直接预览 */
364
+ preview(input?: z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof LocaltaskPreviewAction>['run']>>>;
365
+ /** 新增任务模板(--body 给 Markdown 正文;多行正文用 --body-file <文件> 或 --body - 读管道;--setDefault 同时设为默认;--scope 设可见域、--topic 记创建主题并默认仅该主题可见) */
366
+ templatesAdd(input: z.input<InstanceType<typeof TemplatesAddAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesAddAction>['run']>>>;
367
+ /** 设置默认模板(新建页的起始正文换成它);带 --body/--name/--scope 则改默认模板本身 */
368
+ default(input: z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesDefaultAction>['run']>>>;
369
+ /** 列出任务模板(含默认模板 id;新建页的起始正文按默认模板取) */
370
+ templatesList(input?: z.input<InstanceType<typeof TemplatesListAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesListAction>['run']>>>;
371
+ /** 删除任务模板(内置默认模板不可删;删的是默认模板则默认回落到内置) */
372
+ templatesRemove(input: z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesRemoveAction>['run']>>>;
373
+ /** 调整任务模板顺序(--ids a,b,c 按新序落库 sort_order;未列出的模板保持原位) */
374
+ templatesReorder(input: z.input<InstanceType<typeof TemplatesReorderAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesReorderAction>['run']>>>;
375
+ /** 编辑任务模板(--name 改名 / --body 改正文 / --scope 改可见域,只改传入项;多行正文用 --body-file;内置模板的正文也可改) */
376
+ templatesUpdate(input: z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesUpdateAction>['run']>>>;
363
377
  /** 时间运算 + 原文回显 prompt + 写入一次状态日志;每次必须提供当前现状 --summary */
364
378
  timegoalCheck(input: z.input<InstanceType<typeof TimegoalCheckAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TimegoalCheckAction>['run']>>>;
365
379
  /** 清空本目录 timegoal(无则 no_goal,不抛错) */
@@ -376,18 +390,6 @@ export interface ApiClient {
376
390
  show(input?: z.input<InstanceType<typeof TimegoalShowAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TimegoalShowAction>['run']>>>;
377
391
  /** 更新本目录 timegoal 的提示词(可选同时改时长,--duration;保留起点,不重置计时) */
378
392
  timegoalUpdate(input: z.input<InstanceType<typeof TimegoalUpdateAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TimegoalUpdateAction>['run']>>>;
379
- /** 新增任务模板(--body 给 Markdown 正文;多行正文用 --body-file <文件> 或 --body - 读管道;--setDefault 同时设为默认;--scope 设可见域、--topic 记创建主题并默认仅该主题可见) */
380
- templatesAdd(input: z.input<InstanceType<typeof TemplatesAddAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesAddAction>['run']>>>;
381
- /** 设置默认模板(新建页的起始正文换成它);带 --body/--name/--scope 则改默认模板本身 */
382
- default(input: z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesDefaultAction>['run']>>>;
383
- /** 列出任务模板(含默认模板 id;新建页的起始正文按默认模板取) */
384
- templatesList(input?: z.input<InstanceType<typeof TemplatesListAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesListAction>['run']>>>;
385
- /** 删除任务模板(内置默认模板不可删;删的是默认模板则默认回落到内置) */
386
- templatesRemove(input: z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesRemoveAction>['run']>>>;
387
- /** 调整任务模板顺序(--ids a,b,c 按新序落库 sort_order;未列出的模板保持原位) */
388
- templatesReorder(input: z.input<InstanceType<typeof TemplatesReorderAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesReorderAction>['run']>>>;
389
- /** 编辑任务模板(--name 改名 / --body 改正文 / --scope 改可见域,只改传入项;多行正文用 --body-file;内置模板的正文也可改) */
390
- templatesUpdate(input: z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof TemplatesUpdateAction>['run']>>>;
391
393
  /** 取附件本体:面板内联预览;CLI 打印本机路径 */
392
394
  content(input: z.input<InstanceType<typeof FileContentAction>['_input']>): Promise<Awaited<ReturnType<InstanceType<typeof FileContentAction>['run']>>>;
393
395
  /** 查单个附件的元数据与本机路径 */
@@ -986,13 +988,6 @@ export function createApiClient(transport: Transport): ApiClient {
986
988
  if (query) path += path.includes('?') ? '&' + query : '?' + query;
987
989
  return (await transport.request("GET", path)) as Awaited<ReturnType<InstanceType<typeof LocaltaskChainAction>['run']>>;
988
990
  },
989
- // action: localtask.claim
990
- async claim(input?: z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>) {
991
- const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>);
992
- const path = `/api/localtasks/claim`;
993
- const body = { "cwd": inp["cwd"], "timeout": inp["timeout"], "no-open": inp["no-open"], "param": inp["param"] };
994
- return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof LocaltaskClaimAction>['run']>>;
995
- },
996
991
  // action: localtask.clone
997
992
  async localtaskClone(input: z.input<InstanceType<typeof LocaltaskCloneAction>['_input']>) {
998
993
  const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskCloneAction>['_input']>);
@@ -1077,13 +1072,6 @@ export function createApiClient(transport: Transport): ApiClient {
1077
1072
  const path = `/api/localtasks/presence`;
1078
1073
  return (await transport.request("GET", path)) as Awaited<ReturnType<InstanceType<typeof LocaltaskPresenceAction>['run']>>;
1079
1074
  },
1080
- // action: localtask.preview
1081
- async preview(input?: z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>) {
1082
- const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>);
1083
- const path = `/api/localtasks/preview`;
1084
- const body = { "id": inp["id"], "cwd": inp["cwd"], "key": inp["key"], "text": inp["text"], "param": inp["param"] };
1085
- return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof LocaltaskPreviewAction>['run']>>;
1086
- },
1087
1075
  // action: localtask.prune
1088
1076
  async localtaskPrune(input?: z.input<InstanceType<typeof LocaltaskPruneAction>['_input']>) {
1089
1077
  const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskPruneAction>['_input']>);
@@ -1178,6 +1166,66 @@ export function createApiClient(transport: Transport): ApiClient {
1178
1166
  const body = { "id": inp["id"], "text": inp["text"], "cwd": inp["cwd"], "key": inp["key"], "duration": inp["duration"], "goal-prompt": inp["goal-prompt"], "goalPrompt": inp["goalPrompt"], "clear-goal": inp["clear-goal"], "clearGoal": inp["clearGoal"], "block-by": inp["block-by"], "blockBy": inp["blockBy"], "clear-block-by": inp["clear-block-by"], "clearBlockBy": inp["clearBlockBy"], "gate": inp["gate"] };
1179
1167
  return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof LocaltaskUpdateAction>['run']>>;
1180
1168
  },
1169
+ // action: localtask.claim
1170
+ async claim(input?: z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>) {
1171
+ const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskClaimAction>['_input']>);
1172
+ const path = `/api/localtasks/claim`;
1173
+ const body = { "cwd": inp["cwd"], "timeout": inp["timeout"], "no-open": inp["no-open"], "param": inp["param"] };
1174
+ return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof LocaltaskClaimAction>['run']>>;
1175
+ },
1176
+ // action: localtask.preview
1177
+ async preview(input?: z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>) {
1178
+ const inp = input ?? ({} as z.input<InstanceType<typeof LocaltaskPreviewAction>['_input']>);
1179
+ const path = `/api/localtasks/preview`;
1180
+ const body = { "id": inp["id"], "cwd": inp["cwd"], "key": inp["key"], "text": inp["text"], "param": inp["param"] };
1181
+ return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof LocaltaskPreviewAction>['run']>>;
1182
+ },
1183
+ // action: templates.add
1184
+ async templatesAdd(input: z.input<InstanceType<typeof TemplatesAddAction>['_input']>) {
1185
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesAddAction>['_input']>);
1186
+ const path = `/api/templates`;
1187
+ const body = { "name": inp["name"], "body": inp["body"], "bodyFile": inp["bodyFile"], "body-file": inp["body-file"], "setDefault": inp["setDefault"], "set-default": inp["set-default"], "scope": inp["scope"], "topic": inp["topic"], "cwd": inp["cwd"] };
1188
+ return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesAddAction>['run']>>;
1189
+ },
1190
+ // action: templates.default
1191
+ async default(input: z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>) {
1192
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>);
1193
+ const path = `/api/templates/default`;
1194
+ const body = { "id": inp["id"], "name": inp["name"], "body": inp["body"], "scope": inp["scope"] };
1195
+ return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesDefaultAction>['run']>>;
1196
+ },
1197
+ // action: templates.list
1198
+ async templatesList(input?: z.input<InstanceType<typeof TemplatesListAction>['_input']>) {
1199
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesListAction>['_input']>);
1200
+ let path = `/api/templates`;
1201
+ const q = new URLSearchParams();
1202
+ if (inp["topic"] !== undefined) q.set("topic", String(inp["topic"]));
1203
+ if (inp["group"] !== undefined) q.set("group", String(inp["group"]));
1204
+ if (inp["repo"] !== undefined) q.set("repo", String(inp["repo"]));
1205
+ const query = q.toString();
1206
+ if (query) path += path.includes('?') ? '&' + query : '?' + query;
1207
+ return (await transport.request("GET", path)) as Awaited<ReturnType<InstanceType<typeof TemplatesListAction>['run']>>;
1208
+ },
1209
+ // action: templates.remove
1210
+ async templatesRemove(input: z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>) {
1211
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>);
1212
+ const path = `/api/templates/${encodeURIComponent(String(inp["id"]))}`;
1213
+ return (await transport.request("DELETE", path, undefined)) as Awaited<ReturnType<InstanceType<typeof TemplatesRemoveAction>['run']>>;
1214
+ },
1215
+ // action: templates.reorder
1216
+ async templatesReorder(input: z.input<InstanceType<typeof TemplatesReorderAction>['_input']>) {
1217
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesReorderAction>['_input']>);
1218
+ const path = `/api/templates/reorder`;
1219
+ const body = { "ids": inp["ids"] };
1220
+ return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesReorderAction>['run']>>;
1221
+ },
1222
+ // action: templates.update
1223
+ async templatesUpdate(input: z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>) {
1224
+ const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>);
1225
+ const path = `/api/templates/${encodeURIComponent(String(inp["id"]))}`;
1226
+ const body = { "name": inp["name"], "body": inp["body"], "bodyFile": inp["bodyFile"], "body-file": inp["body-file"], "scope": inp["scope"] };
1227
+ return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesUpdateAction>['run']>>;
1228
+ },
1181
1229
  // action: timegoal.check
1182
1230
  async timegoalCheck(input: z.input<InstanceType<typeof TimegoalCheckAction>['_input']>) {
1183
1231
  const inp = input ?? ({} as z.input<InstanceType<typeof TimegoalCheckAction>['_input']>);
@@ -1242,52 +1290,6 @@ export function createApiClient(transport: Transport): ApiClient {
1242
1290
  const body = { "cwd": inp["cwd"], "prompt": inp["prompt"], "duration": inp["duration"] };
1243
1291
  return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TimegoalUpdateAction>['run']>>;
1244
1292
  },
1245
- // action: templates.add
1246
- async templatesAdd(input: z.input<InstanceType<typeof TemplatesAddAction>['_input']>) {
1247
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesAddAction>['_input']>);
1248
- const path = `/api/templates`;
1249
- const body = { "name": inp["name"], "body": inp["body"], "bodyFile": inp["bodyFile"], "body-file": inp["body-file"], "setDefault": inp["setDefault"], "set-default": inp["set-default"], "scope": inp["scope"], "topic": inp["topic"], "cwd": inp["cwd"] };
1250
- return (await transport.request("POST", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesAddAction>['run']>>;
1251
- },
1252
- // action: templates.default
1253
- async default(input: z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>) {
1254
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesDefaultAction>['_input']>);
1255
- const path = `/api/templates/default`;
1256
- const body = { "id": inp["id"], "name": inp["name"], "body": inp["body"], "values": inp["values"], "scope": inp["scope"] };
1257
- return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesDefaultAction>['run']>>;
1258
- },
1259
- // action: templates.list
1260
- async templatesList(input?: z.input<InstanceType<typeof TemplatesListAction>['_input']>) {
1261
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesListAction>['_input']>);
1262
- let path = `/api/templates`;
1263
- const q = new URLSearchParams();
1264
- if (inp["topic"] !== undefined) q.set("topic", String(inp["topic"]));
1265
- if (inp["group"] !== undefined) q.set("group", String(inp["group"]));
1266
- if (inp["repo"] !== undefined) q.set("repo", String(inp["repo"]));
1267
- const query = q.toString();
1268
- if (query) path += path.includes('?') ? '&' + query : '?' + query;
1269
- return (await transport.request("GET", path)) as Awaited<ReturnType<InstanceType<typeof TemplatesListAction>['run']>>;
1270
- },
1271
- // action: templates.remove
1272
- async templatesRemove(input: z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>) {
1273
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesRemoveAction>['_input']>);
1274
- const path = `/api/templates/${encodeURIComponent(String(inp["id"]))}`;
1275
- return (await transport.request("DELETE", path, undefined)) as Awaited<ReturnType<InstanceType<typeof TemplatesRemoveAction>['run']>>;
1276
- },
1277
- // action: templates.reorder
1278
- async templatesReorder(input: z.input<InstanceType<typeof TemplatesReorderAction>['_input']>) {
1279
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesReorderAction>['_input']>);
1280
- const path = `/api/templates/reorder`;
1281
- const body = { "ids": inp["ids"] };
1282
- return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesReorderAction>['run']>>;
1283
- },
1284
- // action: templates.update
1285
- async templatesUpdate(input: z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>) {
1286
- const inp = input ?? ({} as z.input<InstanceType<typeof TemplatesUpdateAction>['_input']>);
1287
- const path = `/api/templates/${encodeURIComponent(String(inp["id"]))}`;
1288
- const body = { "name": inp["name"], "body": inp["body"], "bodyFile": inp["bodyFile"], "body-file": inp["body-file"], "scope": inp["scope"], "values": inp["values"] };
1289
- return (await transport.request("PATCH", path, body)) as Awaited<ReturnType<InstanceType<typeof TemplatesUpdateAction>['run']>>;
1290
- },
1291
1293
  // action: file.content
1292
1294
  async content(input: z.input<InstanceType<typeof FileContentAction>['_input']>) {
1293
1295
  const inp = input ?? ({} as z.input<InstanceType<typeof FileContentAction>['_input']>);