@wootsup/yt-builder-mcp 1.12.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (857) hide show
  1. package/README.md +128 -30
  2. package/bin/node-floor.d.ts +28 -0
  3. package/bin/node-floor.js +123 -0
  4. package/bin/yt-builder-mcp.js +51 -10
  5. package/dist/auth.d.ts +3 -121
  6. package/dist/auth.d.ts.map +1 -1
  7. package/dist/auth.js +40 -170
  8. package/dist/auth.js.map +1 -1
  9. package/dist/catalog/build-catalog.d.ts +4 -49
  10. package/dist/catalog/build-catalog.d.ts.map +1 -1
  11. package/dist/catalog/build-catalog.js +15 -126
  12. package/dist/catalog/build-catalog.js.map +1 -1
  13. package/dist/catalog/json-schema.d.ts +3 -0
  14. package/dist/catalog/json-schema.d.ts.map +1 -0
  15. package/dist/catalog/json-schema.js +68 -0
  16. package/dist/catalog/json-schema.js.map +1 -0
  17. package/dist/catalog/output-shapes.d.ts +6 -0
  18. package/dist/catalog/output-shapes.d.ts.map +1 -0
  19. package/dist/catalog/output-shapes.js +89 -0
  20. package/dist/catalog/output-shapes.js.map +1 -0
  21. package/dist/catalog/tool-catalog-markdown.d.ts +1 -37
  22. package/dist/catalog/tool-catalog-markdown.d.ts.map +1 -1
  23. package/dist/catalog/tool-catalog-markdown.js +8 -52
  24. package/dist/catalog/tool-catalog-markdown.js.map +1 -1
  25. package/dist/cli/doctor-command.d.ts +2 -7
  26. package/dist/cli/doctor-command.d.ts.map +1 -1
  27. package/dist/cli/doctor-command.js +21 -62
  28. package/dist/cli/doctor-command.js.map +1 -1
  29. package/dist/cli/invocation-decision.d.ts +4 -52
  30. package/dist/cli/invocation-decision.d.ts.map +1 -1
  31. package/dist/cli/invocation-decision.js +45 -54
  32. package/dist/cli/invocation-decision.js.map +1 -1
  33. package/dist/client.d.ts +3 -107
  34. package/dist/client.d.ts.map +1 -1
  35. package/dist/client.js +34 -115
  36. package/dist/client.js.map +1 -1
  37. package/dist/clients/claude-code.d.ts +0 -15
  38. package/dist/clients/claude-code.d.ts.map +1 -1
  39. package/dist/clients/claude-code.js +0 -22
  40. package/dist/clients/claude-code.js.map +1 -1
  41. package/dist/clients/claude-desktop.d.ts +0 -16
  42. package/dist/clients/claude-desktop.d.ts.map +1 -1
  43. package/dist/clients/claude-desktop.js +0 -18
  44. package/dist/clients/claude-desktop.js.map +1 -1
  45. package/dist/clients/cline.d.ts +0 -23
  46. package/dist/clients/cline.d.ts.map +1 -1
  47. package/dist/clients/cline.js +0 -33
  48. package/dist/clients/cline.js.map +1 -1
  49. package/dist/clients/codex-cli.d.ts +0 -39
  50. package/dist/clients/codex-cli.d.ts.map +1 -1
  51. package/dist/clients/codex-cli.js +0 -137
  52. package/dist/clients/codex-cli.js.map +1 -1
  53. package/dist/clients/continue.d.ts +0 -10
  54. package/dist/clients/continue.d.ts.map +1 -1
  55. package/dist/clients/continue.js +0 -26
  56. package/dist/clients/continue.js.map +1 -1
  57. package/dist/clients/cursor.d.ts +0 -9
  58. package/dist/clients/cursor.d.ts.map +1 -1
  59. package/dist/clients/cursor.js +0 -11
  60. package/dist/clients/cursor.js.map +1 -1
  61. package/dist/clients/gemini-cli.d.ts +0 -15
  62. package/dist/clients/gemini-cli.d.ts.map +1 -1
  63. package/dist/clients/gemini-cli.js +0 -17
  64. package/dist/clients/gemini-cli.js.map +1 -1
  65. package/dist/clients/home.d.ts +0 -12
  66. package/dist/clients/home.d.ts.map +1 -1
  67. package/dist/clients/home.js +0 -12
  68. package/dist/clients/home.js.map +1 -1
  69. package/dist/clients/index.d.ts +0 -150
  70. package/dist/clients/index.d.ts.map +1 -1
  71. package/dist/clients/index.js +0 -112
  72. package/dist/clients/index.js.map +1 -1
  73. package/dist/clients/roo-code.d.ts +0 -20
  74. package/dist/clients/roo-code.d.ts.map +1 -1
  75. package/dist/clients/roo-code.js +0 -22
  76. package/dist/clients/roo-code.js.map +1 -1
  77. package/dist/clients/zed.d.ts +0 -9
  78. package/dist/clients/zed.d.ts.map +1 -1
  79. package/dist/clients/zed.js +0 -18
  80. package/dist/clients/zed.js.map +1 -1
  81. package/dist/compat-floor.d.ts +35 -0
  82. package/dist/compat-floor.d.ts.map +1 -0
  83. package/dist/compat-floor.js +84 -0
  84. package/dist/compat-floor.js.map +1 -0
  85. package/dist/compat-probe.d.ts +6 -0
  86. package/dist/compat-probe.d.ts.map +1 -0
  87. package/dist/compat-probe.js +20 -0
  88. package/dist/compat-probe.js.map +1 -0
  89. package/dist/diagnostics/ca-reexec.d.ts +0 -30
  90. package/dist/diagnostics/ca-reexec.d.ts.map +1 -1
  91. package/dist/diagnostics/ca-reexec.js +0 -62
  92. package/dist/diagnostics/ca-reexec.js.map +1 -1
  93. package/dist/diagnostics/ca-trust.d.ts +0 -22
  94. package/dist/diagnostics/ca-trust.d.ts.map +1 -1
  95. package/dist/diagnostics/ca-trust.js +3 -42
  96. package/dist/diagnostics/ca-trust.js.map +1 -1
  97. package/dist/diagnostics/diagnose-network-error.d.ts +1 -38
  98. package/dist/diagnostics/diagnose-network-error.d.ts.map +1 -1
  99. package/dist/diagnostics/diagnose-network-error.js +26 -37
  100. package/dist/diagnostics/diagnose-network-error.js.map +1 -1
  101. package/dist/diagnostics/doctor.d.ts +1 -85
  102. package/dist/diagnostics/doctor.d.ts.map +1 -1
  103. package/dist/diagnostics/doctor.js +5 -90
  104. package/dist/diagnostics/doctor.js.map +1 -1
  105. package/dist/diagnostics/startup-self-probe.d.ts +3 -25
  106. package/dist/diagnostics/startup-self-probe.d.ts.map +1 -1
  107. package/dist/diagnostics/startup-self-probe.js +11 -48
  108. package/dist/diagnostics/startup-self-probe.js.map +1 -1
  109. package/dist/errors/hints.d.ts +0 -44
  110. package/dist/errors/hints.d.ts.map +1 -1
  111. package/dist/errors/hints.js +0 -32
  112. package/dist/errors/hints.js.map +1 -1
  113. package/dist/errors/mask.d.ts +0 -31
  114. package/dist/errors/mask.d.ts.map +1 -1
  115. package/dist/errors/mask.js +0 -32
  116. package/dist/errors/mask.js.map +1 -1
  117. package/dist/errors/redact-credentials.d.ts +2 -0
  118. package/dist/errors/redact-credentials.d.ts.map +1 -0
  119. package/dist/errors/redact-credentials.js +13 -0
  120. package/dist/errors/redact-credentials.js.map +1 -0
  121. package/dist/errors/sanitize.d.ts +0 -29
  122. package/dist/errors/sanitize.d.ts.map +1 -1
  123. package/dist/errors/sanitize.js +0 -40
  124. package/dist/errors/sanitize.js.map +1 -1
  125. package/dist/errors.d.ts +6 -17
  126. package/dist/errors.d.ts.map +1 -1
  127. package/dist/errors.js +16 -21
  128. package/dist/errors.js.map +1 -1
  129. package/dist/gateway/advanced-read-tool.d.ts +0 -32
  130. package/dist/gateway/advanced-read-tool.d.ts.map +1 -1
  131. package/dist/gateway/advanced-read-tool.js +43 -111
  132. package/dist/gateway/advanced-read-tool.js.map +1 -1
  133. package/dist/gateway/advanced-tool/discovery.d.ts +1 -12
  134. package/dist/gateway/advanced-tool/discovery.d.ts.map +1 -1
  135. package/dist/gateway/advanced-tool/discovery.js +15 -24
  136. package/dist/gateway/advanced-tool/discovery.js.map +1 -1
  137. package/dist/gateway/advanced-tool/domains.d.ts +7 -66
  138. package/dist/gateway/advanced-tool/domains.d.ts.map +1 -1
  139. package/dist/gateway/advanced-tool/domains.js +36 -80
  140. package/dist/gateway/advanced-tool/domains.js.map +1 -1
  141. package/dist/gateway/advanced-tool/execute.d.ts +0 -25
  142. package/dist/gateway/advanced-tool/execute.d.ts.map +1 -1
  143. package/dist/gateway/advanced-tool/execute.js +13 -49
  144. package/dist/gateway/advanced-tool/execute.js.map +1 -1
  145. package/dist/gateway/advanced-tool/index.d.ts +1 -32
  146. package/dist/gateway/advanced-tool/index.d.ts.map +1 -1
  147. package/dist/gateway/advanced-tool/index.js +1 -35
  148. package/dist/gateway/advanced-tool/index.js.map +1 -1
  149. package/dist/gateway/advanced-tool/register.d.ts +0 -14
  150. package/dist/gateway/advanced-tool/register.d.ts.map +1 -1
  151. package/dist/gateway/advanced-tool/register.js +22 -58
  152. package/dist/gateway/advanced-tool/register.js.map +1 -1
  153. package/dist/gateway/advanced-tool.d.ts +0 -11
  154. package/dist/gateway/advanced-tool.d.ts.map +1 -1
  155. package/dist/gateway/advanced-tool.js +0 -11
  156. package/dist/gateway/advanced-tool.js.map +1 -1
  157. package/dist/gateway/capturing-server.d.ts +3 -88
  158. package/dist/gateway/capturing-server.d.ts.map +1 -1
  159. package/dist/gateway/capturing-server.js +0 -77
  160. package/dist/gateway/capturing-server.js.map +1 -1
  161. package/dist/gateway/essentials.d.ts +1 -63
  162. package/dist/gateway/essentials.d.ts.map +1 -1
  163. package/dist/gateway/essentials.js +9 -178
  164. package/dist/gateway/essentials.js.map +1 -1
  165. package/dist/gateway/test-support.d.ts +0 -28
  166. package/dist/gateway/test-support.d.ts.map +1 -1
  167. package/dist/gateway/test-support.js +0 -29
  168. package/dist/gateway/test-support.js.map +1 -1
  169. package/dist/health-response.d.ts +2 -0
  170. package/dist/health-response.d.ts.map +1 -0
  171. package/dist/health-response.js +7 -0
  172. package/dist/health-response.js.map +1 -0
  173. package/dist/icon-data.js +0 -3
  174. package/dist/icon-data.js.map +1 -1
  175. package/dist/index.d.ts +7 -23
  176. package/dist/index.d.ts.map +1 -1
  177. package/dist/index.js +46 -130
  178. package/dist/index.js.map +1 -1
  179. package/dist/install-skill.d.ts +0 -44
  180. package/dist/install-skill.d.ts.map +1 -1
  181. package/dist/install-skill.js +5 -46
  182. package/dist/install-skill.js.map +1 -1
  183. package/dist/net/extra-headers.d.ts +0 -58
  184. package/dist/net/extra-headers.d.ts.map +1 -1
  185. package/dist/net/extra-headers.js +0 -67
  186. package/dist/net/extra-headers.js.map +1 -1
  187. package/dist/net/internal-host.d.ts +0 -31
  188. package/dist/net/internal-host.d.ts.map +1 -1
  189. package/dist/net/internal-host.js +7 -65
  190. package/dist/net/internal-host.js.map +1 -1
  191. package/dist/net/proxy-dispatcher.d.ts +0 -37
  192. package/dist/net/proxy-dispatcher.d.ts.map +1 -1
  193. package/dist/net/proxy-dispatcher.js +0 -40
  194. package/dist/net/proxy-dispatcher.js.map +1 -1
  195. package/dist/net/public-fetch.d.ts +53 -0
  196. package/dist/net/public-fetch.d.ts.map +1 -0
  197. package/dist/net/public-fetch.js +143 -0
  198. package/dist/net/public-fetch.js.map +1 -0
  199. package/dist/net/public-page-report.d.ts +26 -0
  200. package/dist/net/public-page-report.d.ts.map +1 -0
  201. package/dist/net/public-page-report.js +145 -0
  202. package/dist/net/public-page-report.js.map +1 -0
  203. package/dist/net/redirect-safe-fetch.d.ts +14 -0
  204. package/dist/net/redirect-safe-fetch.d.ts.map +1 -0
  205. package/dist/net/redirect-safe-fetch.js +61 -0
  206. package/dist/net/redirect-safe-fetch.js.map +1 -0
  207. package/dist/net/session-recovery-fetch.d.ts +7 -0
  208. package/dist/net/session-recovery-fetch.d.ts.map +1 -0
  209. package/dist/net/session-recovery-fetch.js +139 -0
  210. package/dist/net/session-recovery-fetch.js.map +1 -0
  211. package/dist/net/site-basic-auth.d.ts +1 -59
  212. package/dist/net/site-basic-auth.d.ts.map +1 -1
  213. package/dist/net/site-basic-auth.js +5 -94
  214. package/dist/net/site-basic-auth.js.map +1 -1
  215. package/dist/package-version.d.ts +2 -0
  216. package/dist/package-version.d.ts.map +1 -0
  217. package/dist/package-version.js +15 -0
  218. package/dist/package-version.js.map +1 -0
  219. package/dist/platform/detect.d.ts +0 -54
  220. package/dist/platform/detect.d.ts.map +1 -1
  221. package/dist/platform/detect.js +0 -53
  222. package/dist/platform/detect.js.map +1 -1
  223. package/dist/platform/index.d.ts +0 -100
  224. package/dist/platform/index.d.ts.map +1 -1
  225. package/dist/platform/index.js +0 -106
  226. package/dist/platform/index.js.map +1 -1
  227. package/dist/platform/joomla.d.ts +0 -35
  228. package/dist/platform/joomla.d.ts.map +1 -1
  229. package/dist/platform/joomla.js +0 -35
  230. package/dist/platform/joomla.js.map +1 -1
  231. package/dist/proxy/bridge.d.ts +36 -76
  232. package/dist/proxy/bridge.d.ts.map +1 -1
  233. package/dist/proxy/bridge.js +443 -136
  234. package/dist/proxy/bridge.js.map +1 -1
  235. package/dist/proxy/confirm-elicitation.d.ts +22 -0
  236. package/dist/proxy/confirm-elicitation.d.ts.map +1 -0
  237. package/dist/proxy/confirm-elicitation.js +170 -0
  238. package/dist/proxy/confirm-elicitation.js.map +1 -0
  239. package/dist/proxy/confirm-question-contract.d.ts +6 -0
  240. package/dist/proxy/confirm-question-contract.d.ts.map +1 -0
  241. package/dist/proxy/confirm-question-contract.js +9 -0
  242. package/dist/proxy/confirm-question-contract.js.map +1 -0
  243. package/dist/proxy/confirm-question.d.ts +2 -0
  244. package/dist/proxy/confirm-question.d.ts.map +1 -0
  245. package/dist/proxy/confirm-question.js +125 -0
  246. package/dist/proxy/confirm-question.js.map +1 -0
  247. package/dist/proxy/instructions.d.ts +4 -0
  248. package/dist/proxy/instructions.d.ts.map +1 -0
  249. package/dist/proxy/instructions.js +12 -0
  250. package/dist/proxy/instructions.js.map +1 -0
  251. package/dist/proxy/mode.d.ts +14 -9
  252. package/dist/proxy/mode.d.ts.map +1 -1
  253. package/dist/proxy/mode.js +58 -34
  254. package/dist/proxy/mode.js.map +1 -1
  255. package/dist/proxy/multi-site.d.ts +42 -0
  256. package/dist/proxy/multi-site.d.ts.map +1 -0
  257. package/dist/proxy/multi-site.js +134 -0
  258. package/dist/proxy/multi-site.js.map +1 -0
  259. package/dist/proxy/request-headers.d.ts +9 -0
  260. package/dist/proxy/request-headers.d.ts.map +1 -0
  261. package/dist/proxy/request-headers.js +17 -0
  262. package/dist/proxy/request-headers.js.map +1 -0
  263. package/dist/proxy/shadow-tools.d.ts +9 -0
  264. package/dist/proxy/shadow-tools.d.ts.map +1 -0
  265. package/dist/proxy/shadow-tools.js +42 -0
  266. package/dist/proxy/shadow-tools.js.map +1 -0
  267. package/dist/proxy/tools-list-cap.d.ts +7 -0
  268. package/dist/proxy/tools-list-cap.d.ts.map +1 -0
  269. package/dist/proxy/tools-list-cap.js +14 -0
  270. package/dist/proxy/tools-list-cap.js.map +1 -0
  271. package/dist/proxy/transport-uncertainty.d.ts +2 -0
  272. package/dist/proxy/transport-uncertainty.d.ts.map +1 -0
  273. package/dist/proxy/transport-uncertainty.js +8 -0
  274. package/dist/proxy/transport-uncertainty.js.map +1 -0
  275. package/dist/proxy/upstream-error.d.ts +7 -0
  276. package/dist/proxy/upstream-error.d.ts.map +1 -0
  277. package/dist/proxy/upstream-error.js +35 -0
  278. package/dist/proxy/upstream-error.js.map +1 -0
  279. package/dist/proxy/wire-dialect.d.ts +5 -0
  280. package/dist/proxy/wire-dialect.d.ts.map +1 -0
  281. package/dist/proxy/wire-dialect.js +33 -0
  282. package/dist/proxy/wire-dialect.js.map +1 -0
  283. package/dist/server.d.ts +14 -82
  284. package/dist/server.d.ts.map +1 -1
  285. package/dist/server.js +107 -203
  286. package/dist/server.js.map +1 -1
  287. package/dist/setup/banner-color.d.ts +13 -0
  288. package/dist/setup/banner-color.d.ts.map +1 -0
  289. package/dist/setup/banner-color.js +93 -0
  290. package/dist/setup/banner-color.js.map +1 -0
  291. package/dist/setup/banner.d.ts +22 -0
  292. package/dist/setup/banner.d.ts.map +1 -0
  293. package/dist/setup/banner.js +119 -0
  294. package/dist/setup/banner.js.map +1 -0
  295. package/dist/setup/ca-recovery.d.ts +20 -0
  296. package/dist/setup/ca-recovery.d.ts.map +1 -0
  297. package/dist/setup/ca-recovery.js +92 -0
  298. package/dist/setup/ca-recovery.js.map +1 -0
  299. package/dist/setup/closing.d.ts +15 -0
  300. package/dist/setup/closing.d.ts.map +1 -0
  301. package/dist/setup/closing.js +43 -0
  302. package/dist/setup/closing.js.map +1 -0
  303. package/dist/setup/corporate-ca.d.ts +16 -0
  304. package/dist/setup/corporate-ca.d.ts.map +1 -0
  305. package/dist/setup/corporate-ca.js +32 -0
  306. package/dist/setup/corporate-ca.js.map +1 -0
  307. package/dist/setup/host-platform.d.ts +8 -0
  308. package/dist/setup/host-platform.d.ts.map +1 -0
  309. package/dist/setup/host-platform.js +21 -0
  310. package/dist/setup/host-platform.js.map +1 -0
  311. package/dist/setup/install-configs.d.ts +18 -0
  312. package/dist/setup/install-configs.d.ts.map +1 -0
  313. package/dist/setup/install-configs.js +70 -0
  314. package/dist/setup/install-configs.js.map +1 -0
  315. package/dist/setup/multi-site-loop.d.ts +14 -0
  316. package/dist/setup/multi-site-loop.d.ts.map +1 -0
  317. package/dist/setup/multi-site-loop.js +20 -0
  318. package/dist/setup/multi-site-loop.js.map +1 -0
  319. package/dist/setup/phases.d.ts +18 -0
  320. package/dist/setup/phases.d.ts.map +1 -0
  321. package/dist/setup/phases.js +55 -0
  322. package/dist/setup/phases.js.map +1 -0
  323. package/dist/setup/registry-remedy.d.ts +12 -0
  324. package/dist/setup/registry-remedy.d.ts.map +1 -0
  325. package/dist/setup/registry-remedy.js +37 -0
  326. package/dist/setup/registry-remedy.js.map +1 -0
  327. package/dist/setup/resume.d.ts +28 -0
  328. package/dist/setup/resume.d.ts.map +1 -0
  329. package/dist/setup/resume.js +99 -0
  330. package/dist/setup/resume.js.map +1 -0
  331. package/dist/setup-ca-env.d.ts +0 -30
  332. package/dist/setup-ca-env.d.ts.map +1 -1
  333. package/dist/setup-ca-env.js +0 -28
  334. package/dist/setup-ca-env.js.map +1 -1
  335. package/dist/setup-ca-reprobe.d.ts +0 -25
  336. package/dist/setup-ca-reprobe.d.ts.map +1 -1
  337. package/dist/setup-ca-reprobe.js +0 -34
  338. package/dist/setup-ca-reprobe.js.map +1 -1
  339. package/dist/setup-cli-confirm.d.ts +0 -34
  340. package/dist/setup-cli-confirm.d.ts.map +1 -1
  341. package/dist/setup-cli-confirm.js +0 -36
  342. package/dist/setup-cli-confirm.js.map +1 -1
  343. package/dist/setup-cli.d.ts +6 -167
  344. package/dist/setup-cli.d.ts.map +1 -1
  345. package/dist/setup-cli.js +161 -173
  346. package/dist/setup-cli.js.map +1 -1
  347. package/dist/setup-npx-spec.d.ts +0 -36
  348. package/dist/setup-npx-spec.d.ts.map +1 -1
  349. package/dist/setup-npx-spec.js +0 -38
  350. package/dist/setup-npx-spec.js.map +1 -1
  351. package/dist/setup-prompts.d.ts +5 -70
  352. package/dist/setup-prompts.d.ts.map +1 -1
  353. package/dist/setup-prompts.js +67 -107
  354. package/dist/setup-prompts.js.map +1 -1
  355. package/dist/setup-token.d.ts +0 -34
  356. package/dist/setup-token.d.ts.map +1 -1
  357. package/dist/setup-token.js +0 -40
  358. package/dist/setup-token.js.map +1 -1
  359. package/dist/setup-wizard-defaults.d.ts +0 -36
  360. package/dist/setup-wizard-defaults.d.ts.map +1 -1
  361. package/dist/setup-wizard-defaults.js +0 -75
  362. package/dist/setup-wizard-defaults.js.map +1 -1
  363. package/dist/setup-wizard-handshake.d.ts +1 -19
  364. package/dist/setup-wizard-handshake.d.ts.map +1 -1
  365. package/dist/setup-wizard-handshake.js +8 -45
  366. package/dist/setup-wizard-handshake.js.map +1 -1
  367. package/dist/setup-wizard-types.d.ts +16 -209
  368. package/dist/setup-wizard-types.d.ts.map +1 -1
  369. package/dist/setup-wizard-types.js +0 -9
  370. package/dist/setup-wizard-types.js.map +1 -1
  371. package/dist/setup-wizard.d.ts +0 -28
  372. package/dist/setup-wizard.d.ts.map +1 -1
  373. package/dist/setup-wizard.js +167 -412
  374. package/dist/setup-wizard.js.map +1 -1
  375. package/dist/setup.d.ts +0 -15
  376. package/dist/setup.d.ts.map +1 -1
  377. package/dist/setup.js +0 -15
  378. package/dist/setup.js.map +1 -1
  379. package/dist/sites/bootstrap.d.ts +0 -38
  380. package/dist/sites/bootstrap.d.ts.map +1 -1
  381. package/dist/sites/bootstrap.js +0 -44
  382. package/dist/sites/bootstrap.js.map +1 -1
  383. package/dist/sites/cli/add-site.d.ts +0 -76
  384. package/dist/sites/cli/add-site.d.ts.map +1 -1
  385. package/dist/sites/cli/add-site.js +0 -71
  386. package/dist/sites/cli/add-site.js.map +1 -1
  387. package/dist/sites/cli/list-sites.d.ts +0 -31
  388. package/dist/sites/cli/list-sites.d.ts.map +1 -1
  389. package/dist/sites/cli/list-sites.js +0 -45
  390. package/dist/sites/cli/list-sites.js.map +1 -1
  391. package/dist/sites/cli/remove-site.d.ts +0 -37
  392. package/dist/sites/cli/remove-site.d.ts.map +1 -1
  393. package/dist/sites/cli/remove-site.js +0 -37
  394. package/dist/sites/cli/remove-site.js.map +1 -1
  395. package/dist/sites/cli/set-default.d.ts +0 -25
  396. package/dist/sites/cli/set-default.d.ts.map +1 -1
  397. package/dist/sites/cli/set-default.js +0 -22
  398. package/dist/sites/cli/set-default.js.map +1 -1
  399. package/dist/sites/cli/test-site.d.ts +0 -44
  400. package/dist/sites/cli/test-site.d.ts.map +1 -1
  401. package/dist/sites/cli/test-site.js +0 -39
  402. package/dist/sites/cli/test-site.js.map +1 -1
  403. package/dist/sites/client-pool.d.ts +11 -164
  404. package/dist/sites/client-pool.d.ts.map +1 -1
  405. package/dist/sites/client-pool.js +73 -194
  406. package/dist/sites/client-pool.js.map +1 -1
  407. package/dist/sites/config-problem.d.ts +2 -0
  408. package/dist/sites/config-problem.d.ts.map +1 -0
  409. package/dist/sites/config-problem.js +13 -0
  410. package/dist/sites/config-problem.js.map +1 -0
  411. package/dist/sites/env-bridge.d.ts +0 -69
  412. package/dist/sites/env-bridge.d.ts.map +1 -1
  413. package/dist/sites/env-bridge.js +2 -71
  414. package/dist/sites/env-bridge.js.map +1 -1
  415. package/dist/sites/op-inject.d.ts +23 -0
  416. package/dist/sites/op-inject.d.ts.map +1 -0
  417. package/dist/sites/op-inject.js +131 -0
  418. package/dist/sites/op-inject.js.map +1 -0
  419. package/dist/sites/paths.d.ts +0 -19
  420. package/dist/sites/paths.d.ts.map +1 -1
  421. package/dist/sites/paths.js +0 -19
  422. package/dist/sites/paths.js.map +1 -1
  423. package/dist/sites/probe.d.ts +1 -47
  424. package/dist/sites/probe.d.ts.map +1 -1
  425. package/dist/sites/probe.js +4 -46
  426. package/dist/sites/probe.js.map +1 -1
  427. package/dist/sites/registry.d.ts +4 -135
  428. package/dist/sites/registry.d.ts.map +1 -1
  429. package/dist/sites/registry.js +4 -98
  430. package/dist/sites/registry.js.map +1 -1
  431. package/dist/sites/schema.d.ts +3 -51
  432. package/dist/sites/schema.d.ts.map +1 -1
  433. package/dist/sites/schema.js +6 -52
  434. package/dist/sites/schema.js.map +1 -1
  435. package/dist/sites/secret-resolver.d.ts +6 -76
  436. package/dist/sites/secret-resolver.d.ts.map +1 -1
  437. package/dist/sites/secret-resolver.js +39 -104
  438. package/dist/sites/secret-resolver.js.map +1 -1
  439. package/dist/sites/store.d.ts +12 -69
  440. package/dist/sites/store.d.ts.map +1 -1
  441. package/dist/sites/store.js +37 -86
  442. package/dist/sites/store.js.map +1 -1
  443. package/dist/sites/substituted-registry.d.ts +11 -0
  444. package/dist/sites/substituted-registry.d.ts.map +1 -0
  445. package/dist/sites/substituted-registry.js +13 -0
  446. package/dist/sites/substituted-registry.js.map +1 -0
  447. package/dist/sites/tools/fetch-public-url.d.ts +4 -0
  448. package/dist/sites/tools/fetch-public-url.d.ts.map +1 -0
  449. package/dist/sites/tools/fetch-public-url.js +231 -0
  450. package/dist/sites/tools/fetch-public-url.js.map +1 -0
  451. package/dist/sites/tools/index.d.ts +2 -26
  452. package/dist/sites/tools/index.d.ts.map +1 -1
  453. package/dist/sites/tools/index.js +5 -28
  454. package/dist/sites/tools/index.js.map +1 -1
  455. package/dist/sites/tools/sites-list.d.ts +3 -47
  456. package/dist/sites/tools/sites-list.d.ts.map +1 -1
  457. package/dist/sites/tools/sites-list.js +65 -79
  458. package/dist/sites/tools/sites-list.js.map +1 -1
  459. package/dist/sites/tools/sites-overview.d.ts +4 -0
  460. package/dist/sites/tools/sites-overview.d.ts.map +1 -0
  461. package/dist/sites/tools/sites-overview.js +209 -0
  462. package/dist/sites/tools/sites-overview.js.map +1 -0
  463. package/dist/sites/tools/sites-test.d.ts +2 -45
  464. package/dist/sites/tools/sites-test.d.ts.map +1 -1
  465. package/dist/sites/tools/sites-test.js +0 -55
  466. package/dist/sites/tools/sites-test.js.map +1 -1
  467. package/dist/sites/tools/use-site.d.ts +2 -45
  468. package/dist/sites/tools/use-site.d.ts.map +1 -1
  469. package/dist/sites/tools/use-site.js +29 -78
  470. package/dist/sites/tools/use-site.js.map +1 -1
  471. package/dist/sites/unknown-name-result.d.ts +10 -0
  472. package/dist/sites/unknown-name-result.d.ts.map +1 -0
  473. package/dist/sites/unknown-name-result.js +13 -0
  474. package/dist/sites/unknown-name-result.js.map +1 -0
  475. package/dist/skill-instructions.d.ts +7 -0
  476. package/dist/skill-instructions.d.ts.map +1 -0
  477. package/dist/skill-instructions.js +84 -0
  478. package/dist/skill-instructions.js.map +1 -0
  479. package/dist/skill-loader.d.ts +0 -102
  480. package/dist/skill-loader.d.ts.map +1 -1
  481. package/dist/skill-loader.js +4 -142
  482. package/dist/skill-loader.js.map +1 -1
  483. package/dist/skill-manifest.d.ts +0 -20
  484. package/dist/skill-manifest.d.ts.map +1 -1
  485. package/dist/skill-manifest.js +1 -21
  486. package/dist/skill-manifest.js.map +1 -1
  487. package/dist/skill-topics.d.ts +19 -0
  488. package/dist/skill-topics.d.ts.map +1 -0
  489. package/dist/skill-topics.js +181 -0
  490. package/dist/skill-topics.js.map +1 -0
  491. package/dist/tools/active-site.d.ts +16 -0
  492. package/dist/tools/active-site.d.ts.map +1 -0
  493. package/dist/tools/active-site.js +55 -0
  494. package/dist/tools/active-site.js.map +1 -0
  495. package/dist/tools/bind-guidance.d.ts +2 -72
  496. package/dist/tools/bind-guidance.d.ts.map +1 -1
  497. package/dist/tools/bind-guidance.js +2 -72
  498. package/dist/tools/bind-guidance.js.map +1 -1
  499. package/dist/tools/budgeted-table.d.ts +14 -19
  500. package/dist/tools/budgeted-table.d.ts.map +1 -1
  501. package/dist/tools/budgeted-table.js +171 -105
  502. package/dist/tools/budgeted-table.js.map +1 -1
  503. package/dist/tools/elements/bind-output-schema.d.ts +69 -0
  504. package/dist/tools/elements/bind-output-schema.d.ts.map +1 -0
  505. package/dist/tools/elements/bind-output-schema.js +64 -0
  506. package/dist/tools/elements/bind-output-schema.js.map +1 -0
  507. package/dist/tools/elements/builders.d.ts +1 -22
  508. package/dist/tools/elements/builders.d.ts.map +1 -1
  509. package/dist/tools/elements/builders.js +147 -133
  510. package/dist/tools/elements/builders.js.map +1 -1
  511. package/dist/tools/elements/index.d.ts +0 -26
  512. package/dist/tools/elements/index.d.ts.map +1 -1
  513. package/dist/tools/elements/index.js +0 -25
  514. package/dist/tools/elements/index.js.map +1 -1
  515. package/dist/tools/elements/read-output-schemas.d.ts +121 -0
  516. package/dist/tools/elements/read-output-schemas.d.ts.map +1 -0
  517. package/dist/tools/elements/read-output-schemas.js +225 -0
  518. package/dist/tools/elements/read-output-schemas.js.map +1 -0
  519. package/dist/tools/elements/write-output-schemas.d.ts +185 -0
  520. package/dist/tools/elements/write-output-schemas.d.ts.map +1 -0
  521. package/dist/tools/elements/write-output-schemas.js +98 -0
  522. package/dist/tools/elements/write-output-schemas.js.map +1 -0
  523. package/dist/tools/elements.d.ts +0 -11
  524. package/dist/tools/elements.d.ts.map +1 -1
  525. package/dist/tools/elements.js +0 -11
  526. package/dist/tools/elements.js.map +1 -1
  527. package/dist/tools/format/health-format.d.ts +26 -43
  528. package/dist/tools/format/health-format.d.ts.map +1 -1
  529. package/dist/tools/format/health-format.js +28 -60
  530. package/dist/tools/format/health-format.js.map +1 -1
  531. package/dist/tools/format/inspection-format.d.ts +2 -54
  532. package/dist/tools/format/inspection-format.d.ts.map +1 -1
  533. package/dist/tools/format/inspection-format.js +33 -119
  534. package/dist/tools/format/inspection-format.js.map +1 -1
  535. package/dist/tools/format/pages-format.d.ts +32 -69
  536. package/dist/tools/format/pages-format.d.ts.map +1 -1
  537. package/dist/tools/format/pages-format.js +114 -139
  538. package/dist/tools/format/pages-format.js.map +1 -1
  539. package/dist/tools/format/sources-format.d.ts +5 -39
  540. package/dist/tools/format/sources-format.d.ts.map +1 -1
  541. package/dist/tools/format/sources-format.js +57 -87
  542. package/dist/tools/format/sources-format.js.map +1 -1
  543. package/dist/tools/health-output-schemas.d.ts +82 -0
  544. package/dist/tools/health-output-schemas.d.ts.map +1 -0
  545. package/dist/tools/health-output-schemas.js +130 -0
  546. package/dist/tools/health-output-schemas.js.map +1 -0
  547. package/dist/tools/health.d.ts +2 -20
  548. package/dist/tools/health.d.ts.map +1 -1
  549. package/dist/tools/health.js +46 -232
  550. package/dist/tools/health.js.map +1 -1
  551. package/dist/tools/index.d.ts +1 -26
  552. package/dist/tools/index.d.ts.map +1 -1
  553. package/dist/tools/index.js +12 -39
  554. package/dist/tools/index.js.map +1 -1
  555. package/dist/tools/inspection.d.ts +4 -34
  556. package/dist/tools/inspection.d.ts.map +1 -1
  557. package/dist/tools/inspection.js +164 -536
  558. package/dist/tools/inspection.js.map +1 -1
  559. package/dist/tools/library.d.ts +115 -127
  560. package/dist/tools/library.d.ts.map +1 -1
  561. package/dist/tools/library.js +706 -454
  562. package/dist/tools/library.js.map +1 -1
  563. package/dist/tools/local-content/builders.d.ts +1 -17
  564. package/dist/tools/local-content/builders.d.ts.map +1 -1
  565. package/dist/tools/local-content/builders.js +103 -46
  566. package/dist/tools/local-content/builders.js.map +1 -1
  567. package/dist/tools/local-content/index.d.ts +0 -15
  568. package/dist/tools/local-content/index.d.ts.map +1 -1
  569. package/dist/tools/local-content/index.js +0 -14
  570. package/dist/tools/local-content/index.js.map +1 -1
  571. package/dist/tools/local-content/schemas.d.ts +31 -47
  572. package/dist/tools/local-content/schemas.d.ts.map +1 -1
  573. package/dist/tools/local-content/schemas.js +33 -62
  574. package/dist/tools/local-content/schemas.js.map +1 -1
  575. package/dist/tools/modules/builders.d.ts +4 -0
  576. package/dist/tools/modules/builders.d.ts.map +1 -0
  577. package/dist/tools/modules/builders.js +58 -0
  578. package/dist/tools/modules/builders.js.map +1 -0
  579. package/dist/tools/modules/index.d.ts +2 -0
  580. package/dist/tools/modules/index.d.ts.map +1 -0
  581. package/dist/tools/modules/index.js +2 -0
  582. package/dist/tools/modules/index.js.map +1 -0
  583. package/dist/tools/modules/module-id-schema.d.ts +4 -0
  584. package/dist/tools/modules/module-id-schema.d.ts.map +1 -0
  585. package/dist/tools/modules/module-id-schema.js +14 -0
  586. package/dist/tools/modules/module-id-schema.js.map +1 -0
  587. package/dist/tools/modules/module-type-fields.d.ts +10 -0
  588. package/dist/tools/modules/module-type-fields.d.ts.map +1 -0
  589. package/dist/tools/modules/module-type-fields.js +34 -0
  590. package/dist/tools/modules/module-type-fields.js.map +1 -0
  591. package/dist/tools/modules/modules-create.d.ts +59 -0
  592. package/dist/tools/modules/modules-create.d.ts.map +1 -0
  593. package/dist/tools/modules/modules-create.js +154 -0
  594. package/dist/tools/modules/modules-create.js.map +1 -0
  595. package/dist/tools/modules/modules-delete.d.ts +51 -0
  596. package/dist/tools/modules/modules-delete.d.ts.map +1 -0
  597. package/dist/tools/modules/modules-delete.js +180 -0
  598. package/dist/tools/modules/modules-delete.js.map +1 -0
  599. package/dist/tools/modules/modules-update.d.ts +43 -0
  600. package/dist/tools/modules/modules-update.d.ts.map +1 -0
  601. package/dist/tools/modules/modules-update.js +177 -0
  602. package/dist/tools/modules/modules-update.js.map +1 -0
  603. package/dist/tools/modules/placement-hints.d.ts +5 -0
  604. package/dist/tools/modules/placement-hints.d.ts.map +1 -0
  605. package/dist/tools/modules/placement-hints.js +90 -0
  606. package/dist/tools/modules/placement-hints.js.map +1 -0
  607. package/dist/tools/modules/placement-ways.d.ts +13 -0
  608. package/dist/tools/modules/placement-ways.d.ts.map +1 -0
  609. package/dist/tools/modules/placement-ways.js +61 -0
  610. package/dist/tools/modules/placement-ways.js.map +1 -0
  611. package/dist/tools/multi-items/builders.d.ts +1 -21
  612. package/dist/tools/multi-items/builders.d.ts.map +1 -1
  613. package/dist/tools/multi-items/builders.js +22 -65
  614. package/dist/tools/multi-items/builders.js.map +1 -1
  615. package/dist/tools/multi-items/index.d.ts +0 -15
  616. package/dist/tools/multi-items/index.d.ts.map +1 -1
  617. package/dist/tools/multi-items/index.js +0 -15
  618. package/dist/tools/multi-items/index.js.map +1 -1
  619. package/dist/tools/multi-items/item-container-map.d.ts +0 -35
  620. package/dist/tools/multi-items/item-container-map.d.ts.map +1 -1
  621. package/dist/tools/multi-items/item-container-map.js +0 -35
  622. package/dist/tools/multi-items/item-container-map.js.map +1 -1
  623. package/dist/tools/multi-items/output-schemas.d.ts +101 -0
  624. package/dist/tools/multi-items/output-schemas.d.ts.map +1 -0
  625. package/dist/tools/multi-items/output-schemas.js +74 -0
  626. package/dist/tools/multi-items/output-schemas.js.map +1 -0
  627. package/dist/tools/navigation/builders.d.ts +1 -16
  628. package/dist/tools/navigation/builders.d.ts.map +1 -1
  629. package/dist/tools/navigation/builders.js +5 -27
  630. package/dist/tools/navigation/builders.js.map +1 -1
  631. package/dist/tools/navigation/index.d.ts +0 -13
  632. package/dist/tools/navigation/index.d.ts.map +1 -1
  633. package/dist/tools/navigation/index.js +0 -12
  634. package/dist/tools/navigation/index.js.map +1 -1
  635. package/dist/tools/navigation/schemas.d.ts +0 -30
  636. package/dist/tools/navigation/schemas.d.ts.map +1 -1
  637. package/dist/tools/navigation/schemas.js +0 -30
  638. package/dist/tools/navigation/schemas.js.map +1 -1
  639. package/dist/tools/output-schema-metadata.d.ts +5 -0
  640. package/dist/tools/output-schema-metadata.d.ts.map +1 -0
  641. package/dist/tools/output-schema-metadata.js +83 -0
  642. package/dist/tools/output-schema-metadata.js.map +1 -0
  643. package/dist/tools/pages/builders.d.ts +1 -41
  644. package/dist/tools/pages/builders.d.ts.map +1 -1
  645. package/dist/tools/pages/builders.js +320 -405
  646. package/dist/tools/pages/builders.js.map +1 -1
  647. package/dist/tools/pages/header-transparency.d.ts +2 -32
  648. package/dist/tools/pages/header-transparency.d.ts.map +1 -1
  649. package/dist/tools/pages/header-transparency.js +9 -43
  650. package/dist/tools/pages/header-transparency.js.map +1 -1
  651. package/dist/tools/pages/index.d.ts +1 -19
  652. package/dist/tools/pages/index.d.ts.map +1 -1
  653. package/dist/tools/pages/index.js +1 -19
  654. package/dist/tools/pages/index.js.map +1 -1
  655. package/dist/tools/pages/schemas.d.ts +323 -241
  656. package/dist/tools/pages/schemas.d.ts.map +1 -1
  657. package/dist/tools/pages/schemas.js +514 -549
  658. package/dist/tools/pages/schemas.js.map +1 -1
  659. package/dist/tools/pages/write-output-schemas.d.ts +139 -0
  660. package/dist/tools/pages/write-output-schemas.d.ts.map +1 -0
  661. package/dist/tools/pages/write-output-schemas.js +138 -0
  662. package/dist/tools/pages/write-output-schemas.js.map +1 -0
  663. package/dist/tools/pages.d.ts +0 -11
  664. package/dist/tools/pages.d.ts.map +1 -1
  665. package/dist/tools/pages.js +0 -11
  666. package/dist/tools/pages.js.map +1 -1
  667. package/dist/tools/pool-resolve-helper.d.ts +0 -52
  668. package/dist/tools/pool-resolve-helper.d.ts.map +1 -1
  669. package/dist/tools/pool-resolve-helper.js +29 -104
  670. package/dist/tools/pool-resolve-helper.js.map +1 -1
  671. package/dist/tools/progress-phases.d.ts +0 -42
  672. package/dist/tools/progress-phases.d.ts.map +1 -1
  673. package/dist/tools/progress-phases.js +0 -44
  674. package/dist/tools/progress-phases.js.map +1 -1
  675. package/dist/tools/response-budget.d.ts +0 -69
  676. package/dist/tools/response-budget.d.ts.map +1 -1
  677. package/dist/tools/response-budget.js +0 -127
  678. package/dist/tools/response-budget.js.map +1 -1
  679. package/dist/tools/shared-schemas.d.ts +11 -65
  680. package/dist/tools/shared-schemas.d.ts.map +1 -1
  681. package/dist/tools/shared-schemas.js +40 -123
  682. package/dist/tools/shared-schemas.js.map +1 -1
  683. package/dist/tools/skill/builders.d.ts +3 -0
  684. package/dist/tools/skill/builders.d.ts.map +1 -0
  685. package/dist/tools/skill/builders.js +81 -0
  686. package/dist/tools/skill/builders.js.map +1 -0
  687. package/dist/tools/sources/builders.d.ts +1 -11
  688. package/dist/tools/sources/builders.d.ts.map +1 -1
  689. package/dist/tools/sources/builders.js +194 -170
  690. package/dist/tools/sources/builders.js.map +1 -1
  691. package/dist/tools/sources/index.d.ts +0 -17
  692. package/dist/tools/sources/index.d.ts.map +1 -1
  693. package/dist/tools/sources/index.js +0 -16
  694. package/dist/tools/sources/index.js.map +1 -1
  695. package/dist/tools/sources/read-output-schemas.d.ts +101 -0
  696. package/dist/tools/sources/read-output-schemas.d.ts.map +1 -0
  697. package/dist/tools/sources/read-output-schemas.js +105 -0
  698. package/dist/tools/sources/read-output-schemas.js.map +1 -0
  699. package/dist/tools/sources/source-name-argument.d.ts +17 -0
  700. package/dist/tools/sources/source-name-argument.d.ts.map +1 -0
  701. package/dist/tools/sources/source-name-argument.js +64 -0
  702. package/dist/tools/sources/source-name-argument.js.map +1 -0
  703. package/dist/tools/sources/write-output-schemas.d.ts +100 -0
  704. package/dist/tools/sources/write-output-schemas.d.ts.map +1 -0
  705. package/dist/tools/sources/write-output-schemas.js +61 -0
  706. package/dist/tools/sources/write-output-schemas.js.map +1 -0
  707. package/dist/tools/sources.d.ts +0 -12
  708. package/dist/tools/sources.d.ts.map +1 -1
  709. package/dist/tools/sources.js +0 -12
  710. package/dist/tools/sources.js.map +1 -1
  711. package/dist/tools/sparse-fields.d.ts +16 -232
  712. package/dist/tools/sparse-fields.d.ts.map +1 -1
  713. package/dist/tools/sparse-fields.js +178 -242
  714. package/dist/tools/sparse-fields.js.map +1 -1
  715. package/dist/tools/strict-input.d.ts +5 -0
  716. package/dist/tools/strict-input.d.ts.map +1 -0
  717. package/dist/tools/strict-input.js +55 -0
  718. package/dist/tools/strict-input.js.map +1 -0
  719. package/dist/tools/sublayout/builders.d.ts +1 -21
  720. package/dist/tools/sublayout/builders.d.ts.map +1 -1
  721. package/dist/tools/sublayout/builders.js +10 -39
  722. package/dist/tools/sublayout/builders.js.map +1 -1
  723. package/dist/tools/sublayout/index.d.ts +1 -11
  724. package/dist/tools/sublayout/index.d.ts.map +1 -1
  725. package/dist/tools/sublayout/index.js +1 -11
  726. package/dist/tools/sublayout/index.js.map +1 -1
  727. package/dist/tools/sublayout/output-schemas.d.ts +57 -0
  728. package/dist/tools/sublayout/output-schemas.d.ts.map +1 -0
  729. package/dist/tools/sublayout/output-schemas.js +51 -0
  730. package/dist/tools/sublayout/output-schemas.js.map +1 -0
  731. package/dist/tools/tool-builder/annotations.d.ts +1 -49
  732. package/dist/tools/tool-builder/annotations.d.ts.map +1 -1
  733. package/dist/tools/tool-builder/annotations.js +9 -49
  734. package/dist/tools/tool-builder/annotations.js.map +1 -1
  735. package/dist/tools/tool-builder/confirm-preview.d.ts +24 -0
  736. package/dist/tools/tool-builder/confirm-preview.d.ts.map +1 -0
  737. package/dist/tools/tool-builder/confirm-preview.js +37 -0
  738. package/dist/tools/tool-builder/confirm-preview.js.map +1 -0
  739. package/dist/tools/tool-builder/define.d.ts +6 -26
  740. package/dist/tools/tool-builder/define.d.ts.map +1 -1
  741. package/dist/tools/tool-builder/define.js +0 -25
  742. package/dist/tools/tool-builder/define.js.map +1 -1
  743. package/dist/tools/tool-builder/index.d.ts +3 -26
  744. package/dist/tools/tool-builder/index.d.ts.map +1 -1
  745. package/dist/tools/tool-builder/index.js +2 -25
  746. package/dist/tools/tool-builder/index.js.map +1 -1
  747. package/dist/tools/tool-builder/results.d.ts +4 -124
  748. package/dist/tools/tool-builder/results.d.ts.map +1 -1
  749. package/dist/tools/tool-builder/results.js +258 -263
  750. package/dist/tools/tool-builder/results.js.map +1 -1
  751. package/dist/tools/tool-builder/types.d.ts +5 -59
  752. package/dist/tools/tool-builder/types.d.ts.map +1 -1
  753. package/dist/tools/tool-builder/types.js +0 -7
  754. package/dist/tools/tool-builder/types.js.map +1 -1
  755. package/dist/tools/tool-builder.d.ts +0 -14
  756. package/dist/tools/tool-builder.d.ts.map +1 -1
  757. package/dist/tools/tool-builder.js +0 -14
  758. package/dist/tools/tool-builder.js.map +1 -1
  759. package/dist/uninstall-skill.d.ts +0 -41
  760. package/dist/uninstall-skill.d.ts.map +1 -1
  761. package/dist/uninstall-skill.js +0 -49
  762. package/dist/uninstall-skill.js.map +1 -1
  763. package/dist/uninstall.d.ts +0 -41
  764. package/dist/uninstall.d.ts.map +1 -1
  765. package/dist/uninstall.js +1 -29
  766. package/dist/uninstall.js.map +1 -1
  767. package/dist/update/update-check.d.ts +0 -26
  768. package/dist/update/update-check.d.ts.map +1 -1
  769. package/dist/update/update-check.js +0 -25
  770. package/dist/update/update-check.js.map +1 -1
  771. package/manifest.json +4 -5
  772. package/package.json +4 -4
  773. package/skills/yt-builder-mcp/SKILL.md +1857 -400
  774. package/dist/tools/elements/handlers-write.d.ts +0 -89
  775. package/dist/tools/elements/handlers-write.d.ts.map +0 -1
  776. package/dist/tools/elements/handlers-write.js +0 -797
  777. package/dist/tools/elements/handlers-write.js.map +0 -1
  778. package/dist/tools/elements/handlers.d.ts +0 -130
  779. package/dist/tools/elements/handlers.d.ts.map +0 -1
  780. package/dist/tools/elements/handlers.js +0 -581
  781. package/dist/tools/elements/handlers.js.map +0 -1
  782. package/dist/tools/elements/layout-hierarchy-rules.d.ts +0 -62
  783. package/dist/tools/elements/layout-hierarchy-rules.d.ts.map +0 -1
  784. package/dist/tools/elements/layout-hierarchy-rules.js +0 -154
  785. package/dist/tools/elements/layout-hierarchy-rules.js.map +0 -1
  786. package/dist/tools/elements/schema-validation.d.ts +0 -218
  787. package/dist/tools/elements/schema-validation.d.ts.map +0 -1
  788. package/dist/tools/elements/schema-validation.js +0 -685
  789. package/dist/tools/elements/schema-validation.js.map +0 -1
  790. package/dist/tools/elicitation.d.ts +0 -87
  791. package/dist/tools/elicitation.d.ts.map +0 -1
  792. package/dist/tools/elicitation.js +0 -100
  793. package/dist/tools/elicitation.js.map +0 -1
  794. package/dist/tools/format/elements-format.d.ts +0 -75
  795. package/dist/tools/format/elements-format.d.ts.map +0 -1
  796. package/dist/tools/format/elements-format.js +0 -368
  797. package/dist/tools/format/elements-format.js.map +0 -1
  798. package/dist/tools/format/source-schema-format.d.ts +0 -74
  799. package/dist/tools/format/source-schema-format.d.ts.map +0 -1
  800. package/dist/tools/format/source-schema-format.js +0 -208
  801. package/dist/tools/format/source-schema-format.js.map +0 -1
  802. package/dist/tools/layout-flatten.d.ts +0 -84
  803. package/dist/tools/layout-flatten.d.ts.map +0 -1
  804. package/dist/tools/layout-flatten.js +0 -129
  805. package/dist/tools/layout-flatten.js.map +0 -1
  806. package/dist/tools/local-content/handlers.d.ts +0 -56
  807. package/dist/tools/local-content/handlers.d.ts.map +0 -1
  808. package/dist/tools/local-content/handlers.js +0 -320
  809. package/dist/tools/local-content/handlers.js.map +0 -1
  810. package/dist/tools/multi-items/clean-implode-handler.d.ts +0 -37
  811. package/dist/tools/multi-items/clean-implode-handler.d.ts.map +0 -1
  812. package/dist/tools/multi-items/clean-implode-handler.js +0 -65
  813. package/dist/tools/multi-items/clean-implode-handler.js.map +0 -1
  814. package/dist/tools/multi-items/format/inspection-format.d.ts +0 -41
  815. package/dist/tools/multi-items/format/inspection-format.d.ts.map +0 -1
  816. package/dist/tools/multi-items/format/inspection-format.js +0 -64
  817. package/dist/tools/multi-items/format/inspection-format.js.map +0 -1
  818. package/dist/tools/multi-items/inspect-handler.d.ts +0 -97
  819. package/dist/tools/multi-items/inspect-handler.d.ts.map +0 -1
  820. package/dist/tools/multi-items/inspect-handler.js +0 -323
  821. package/dist/tools/multi-items/inspect-handler.js.map +0 -1
  822. package/dist/tools/multi-items/inspection-cache.d.ts +0 -85
  823. package/dist/tools/multi-items/inspection-cache.d.ts.map +0 -1
  824. package/dist/tools/multi-items/inspection-cache.js +0 -126
  825. package/dist/tools/multi-items/inspection-cache.js.map +0 -1
  826. package/dist/tools/navigation/handlers.d.ts +0 -30
  827. package/dist/tools/navigation/handlers.d.ts.map +0 -1
  828. package/dist/tools/navigation/handlers.js +0 -41
  829. package/dist/tools/navigation/handlers.js.map +0 -1
  830. package/dist/tools/pages/handlers-audit.d.ts +0 -140
  831. package/dist/tools/pages/handlers-audit.d.ts.map +0 -1
  832. package/dist/tools/pages/handlers-audit.js +0 -714
  833. package/dist/tools/pages/handlers-audit.js.map +0 -1
  834. package/dist/tools/pages/handlers-read.d.ts +0 -133
  835. package/dist/tools/pages/handlers-read.d.ts.map +0 -1
  836. package/dist/tools/pages/handlers-read.js +0 -1061
  837. package/dist/tools/pages/handlers-read.js.map +0 -1
  838. package/dist/tools/pages/handlers-write.d.ts +0 -212
  839. package/dist/tools/pages/handlers-write.d.ts.map +0 -1
  840. package/dist/tools/pages/handlers-write.js +0 -419
  841. package/dist/tools/pages/handlers-write.js.map +0 -1
  842. package/dist/tools/pages/target.d.ts +0 -162
  843. package/dist/tools/pages/target.d.ts.map +0 -1
  844. package/dist/tools/pages/target.js +0 -239
  845. package/dist/tools/pages/target.js.map +0 -1
  846. package/dist/tools/sources/handlers-bind.d.ts +0 -148
  847. package/dist/tools/sources/handlers-bind.d.ts.map +0 -1
  848. package/dist/tools/sources/handlers-bind.js +0 -657
  849. package/dist/tools/sources/handlers-bind.js.map +0 -1
  850. package/dist/tools/sources/handlers.d.ts +0 -116
  851. package/dist/tools/sources/handlers.d.ts.map +0 -1
  852. package/dist/tools/sources/handlers.js +0 -289
  853. package/dist/tools/sources/handlers.js.map +0 -1
  854. package/dist/tools/sublayout/inspect-sublayout-handler.d.ts +0 -95
  855. package/dist/tools/sublayout/inspect-sublayout-handler.d.ts.map +0 -1
  856. package/dist/tools/sublayout/inspect-sublayout-handler.js +0 -181
  857. package/dist/tools/sublayout/inspect-sublayout-handler.js.map +0 -1
@@ -1,92 +1,30 @@
1
- /**
2
- * Page-tool builders — pure `defineTool` factory list.
3
- *
4
- * Split out of `src/tools/pages.ts` (Round-2 R2-A2-CRIT1). Handler
5
- * bodies live in `./handlers-read.ts` (pages_list, page_get_layout,
6
- * page_get_schema, get_etag, template_summary) and `./handlers-write.ts`
7
- * (page_save, page_publish, pages_create, pages_delete — 3-phase
8
- * progress contract).
9
- *
10
- * Surface: 9 page-level tools (pre-C4: 7; v1.2 C4 added pages_create +
11
- * pages_delete wrapping POST /pages and DELETE /pages/{id}).
12
- *
13
- * @license MIT
14
- */
15
1
  import { z } from 'zod';
16
- import { withSiteRetry, withWriteSiteRetry } from '../pool-resolve-helper.js';
17
- import { ETAG as ETAG_STRICT, INCLUDE_META_SCHEMA, POST_ID, RESOLVE_URL, SITE_ID_SCHEMA, TEMPLATE_ID, TEMPLATE_ID_OPTIONAL, } from '../shared-schemas.js';
2
+ import { ETAG as ETAG_STRICT, ETAG_PREVIEW_OPTIONAL, INCLUDE_META_SCHEMA, RESOLVE_URL, SITE_ID_SCHEMA, LAYOUT_ID, LAYOUT_ID_OPTIONAL, } from '../shared-schemas.js';
18
3
  import { FIELDS, FLAT, MAX_CHARS } from '../sparse-fields.js';
19
- import { creating, defineTool, destructive, mutating, readOnly, withSiteMeta, } from '../tool-builder.js';
20
- import { handlePagesAudit } from './handlers-audit.js';
21
- import { handleHeaderTransparencySet, HEADER_TRANSPARENCY_SET_INPUT, } from './header-transparency.js';
22
- import { handleGetEtag, handleHeadingOutline, handlePageGetLayout, handlePageGetSchema, handlePagesList, handlePagesResolve, handleRenderPreview, handleTemplateSummary, } from './handlers-read.js';
23
- import { handlePageDynamize, handlePagePublish, handlePagesCreate, handlePagesDelete, handlePageSave, handleTemplateSetType, TEMPLATE_SET_TYPE_OUTPUT_SCHEMA, } from './handlers-write.js';
24
- import { ETAG_OUTPUT_SCHEMA, HEADING_OUTLINE_OUTPUT_SCHEMA, PAGE_DYNAMIZE_INPUT, PAGES_AUDIT_INPUT, PAGES_AUDIT_OUTPUT_SCHEMA, PAGES_CREATE_INPUT, PAGES_DELETE_INPUT, PAGES_DELETE_OUTPUT_SCHEMA, PAGES_LIST_OUTPUT_SCHEMA, PAGES_RESOLVE_INPUT, PAGES_RESOLVE_OUTPUT_SCHEMA, RENDER_PREVIEW_OUTPUT_SCHEMA, SCHEMA_OUTPUT_SCHEMA, TEMPLATE_SUMMARY_OUTPUT_SCHEMA, } from './schemas.js';
25
- // F-14: page-level save/publish accept OPTIONAL ETag (no precondition lock
26
- // at template level — element/binding mutations REQUIRE one via the strict
27
- // ETAG in shared-schemas.ts). Schema and description now agree: optional
28
- // here, recommended for safety. When provided, 412 Precondition Failed is
29
- // raised on stale snapshots; when omitted, the save proceeds unconditionally.
30
- const ETAG = z
31
- .string()
32
- .optional()
33
- .describe('Optimistic-lock ETag (from yootheme_builder_get_etag). ' +
34
- 'Optional; when provided, optimistic-lock is enforced (412 on conflict). ' +
35
- 'When omitted, last-write-wins applies. Recommended for collaborative edits.');
36
- /**
37
- * Build the {@link RenderContext} from the data reachable in a page
38
- * builder. Pure: no I/O, no `any`. Missing `parentTemplateId` / `locale`
39
- * collapse to `null`.
40
- */
41
- export function buildRenderContext(input) {
42
- return {
43
- parent_template_id: input.parentTemplateId ?? null,
44
- locale: input.locale ?? null,
45
- site_url: input.siteUrl,
46
- };
47
- }
48
- /**
49
- * Best-effort locale extraction from a resolved site. The registry does
50
- * not (yet) carry an explicit locale, so we read it from the platform
51
- * descriptor when present; otherwise `null` (the consumer-stable
52
- * "unknown" value). Kept narrow + guarded so this stays `any`-free.
53
- */
54
- function localeForSite(site) {
55
- const platform = site.platform;
56
- if (typeof platform === 'object' && platform !== null && 'locale' in platform) {
57
- const value = platform.locale;
58
- if (typeof value === 'string' && value !== '') {
59
- return value;
60
- }
61
- }
62
- return null;
63
- }
64
- /**
65
- * Stamp a {@link RenderContext} into a tool result's free-form
66
- * result-level `_meta` (next to the site-meta `withSiteMeta` adds).
67
- * Never touches `structuredContent` — that stays schema-pure so it keeps
68
- * validating against the tool's `outputSchema`. Pure: returns a new
69
- * result, does not mutate the input.
70
- */
71
- function withRenderContext(result, ctx) {
72
- const base = result._meta;
73
- const mergedMeta = base !== undefined && base !== null && typeof base === 'object'
74
- ? { ...base, render_context: ctx }
75
- : { render_context: ctx };
76
- return { ...result, _meta: mergedMeta };
77
- }
78
- export function buildPagesTools(pool) {
4
+ import { creating, defineTool, destructive, mutating, readOnly, } from '../tool-builder.js';
5
+ import { HEADER_TRANSPARENCY_SET_INPUT } from './header-transparency.js';
6
+ import { PAGES_CREATE_OUTPUT_SCHEMA, PAGE_GENERATE_DYNAMIC_OUTPUT_SCHEMA, PAGE_PUBLISH_OUTPUT_SCHEMA, PAGE_SAVE_OUTPUT_SCHEMA, TEMPLATE_SET_TYPE_OUTPUT_SCHEMA, } from './write-output-schemas.js';
7
+ import { ETAG_OUTPUT_SCHEMA, HEADING_OUTLINE_OUTPUT_SCHEMA, PAGE_GENERATE_DYNAMIC_INPUT, PAGE_GET_LAYOUT_OUTPUT_SCHEMA, PAGES_AUDIT_INPUT, PAGES_AUDIT_OUTPUT_SCHEMA, PAGES_CREATE_INPUT, PAGES_DELETE_INPUT, PAGES_DELETE_OUTPUT_SCHEMA, PAGES_LIST_OUTPUT_SCHEMA, PAGES_RESOLVE_INPUT, PAGES_RESOLVE_OUTPUT_SCHEMA, PAGES_RESTORE_INPUT, PAGES_RESTORE_OUTPUT_SCHEMA, PAGES_SET_STATUS_INPUT, PAGES_SET_STATUS_OUTPUT_SCHEMA, RENDER_PREVIEW_OUTPUT_SCHEMA, TEMPLATE_SUMMARY_OUTPUT_SCHEMA, } from './schemas.js';
8
+ export function buildPagesTools() {
79
9
  return [
80
10
  defineTool({
81
11
  name: 'yootheme_builder_pages_list',
82
- description: 'List pages, templates, and layouts in the YOOtheme Pro builder ' +
83
- '(id, label, type, elements_count, frontend_url, builder_url, ' +
84
- 'serves_context_kind, serves_context_ids, page_role per row). ' +
85
- 'CALL THIS FIRST to discover template IDs before page_get_layout / element_list / ' +
86
- 'page_get_schema. Paginates: up to `limit` rows (default 50) plus `total` and a ' +
87
- '`next_cursor` (pass it back as `cursor`) when more remain. Filter with ' +
88
- '`label_contains`. Slim rows with `fields:["id","label"]`; bound output ' +
89
- 'with `max_chars`.',
12
+ description: 'List pages, templates and layouts. Each row returns `kind` ' +
13
+ '(content | theme_template) plus serves_context_kind, serves_context_ids and ' +
14
+ 'page_role the template ROLE (WHICH objects it renders for), NOT a data ' +
15
+ 'binding; for who-binds-what call layout_query with no layout_id. The ' +
16
+ 'envelope returns `totals`. Call first for layout_id ' +
17
+ '(page_get_layout/element_list). ' +
18
+ '`type` = PAGE type, not element type (those filter on `element_type`). ' +
19
+ 'Rows with a CMS status carry `visibility`: public | hidden | undetermined, never ' +
20
+ 'empty. Reads STORED FIELDS only — status, plus WordPress password protection ' +
21
+ '(`hidden`, with the reason). It does NOT read the menu route, the access level, ' +
22
+ 'or whether the permalink resolves, so Joomla rows stay `undetermined`; for THAT ' +
23
+ 'verdict read `cms_visibility.findable_by_visitor` from pages_set_status / ' +
24
+ 'page_publish — a different, per-page question. ' +
25
+ 'Page contents (SEO/structure/links/modules): yootheme_builder_pages_audit. ' +
26
+ '`is_public_homepage` marks the one row served at / (the site front page); ' +
27
+ 'no tool here moves it.',
90
28
  inputSchema: {
91
29
  site_id: SITE_ID_SCHEMA,
92
30
  fields: FIELDS,
@@ -106,59 +44,78 @@ export function buildPagesTools(pool) {
106
44
  .optional()
107
45
  .describe('Case-insensitive substring filter on the page label / id / type / frontend_url ' +
108
46
  '(also matches a slug or URL fragment, e.g. "blog" or "product-launch").'),
47
+ visibility: z
48
+ .enum(['public', 'hidden', 'undetermined', 'no_cms_status'])
49
+ .optional()
50
+ .describe('Keep only rows whose `visibility` reads this word (no_cms_status = a theme ' +
51
+ 'template, which has none). `totals.visibility` counts all four over the ' +
52
+ 'same filtered set, so one call answers how many are hidden without ' +
53
+ 'reading the rows.'),
109
54
  max_chars: MAX_CHARS,
55
+ sort: z
56
+ .enum(['recent'])
57
+ .optional()
58
+ .describe('Order the rows. "recent" = most recently modified first (rows with no '
59
+ + 'timestamp go last, never first). Omit to keep the default order '
60
+ + '(theme templates, then per-page). The answer reports `sorted_over` '
61
+ + '("all" or "this_page") so a paged result cannot read as a site-wide '
62
+ + 'verdict.'),
110
63
  include_meta: INCLUDE_META_SCHEMA,
111
64
  },
112
65
  outputSchema: PAGES_LIST_OUTPUT_SCHEMA,
113
66
  annotations: readOnly('List Pages'),
114
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handlePagesList(client, rest), site)),
115
67
  }),
116
68
  defineTool({
117
69
  name: 'yootheme_builder_page_get_layout',
118
- // B-1 (SEO-routing fix, 2026-07-21): a generic "SEO audit" prompt
119
- // from a COLD agent (no SKILL.md) otherwise loops this tool
120
- // page-by-page into its Max-Iterations limit instead of the one-call
121
- // pages_audit sweep (empirically confirmed on a customer site —
122
- // followup_pages_audit_routing_generic_seo_request). The negative
123
- // steer at the tail routes a whole-site audit to pages_audit (an L2
124
- // read-only tool reached via yootheme_builder_advanced_read). The
125
- // per-arg details dropped from this prose (bindings-skeleton / force
126
- // / cursor semantics) already live in each param's own .describe().
127
- description: 'Get the layout tree for one template — address it by `template_id` ' +
128
- '(from pages_list), `post_id`, or `url`. `mode:"bindings_only"` for ' +
129
- 'dynamize/bind; `mode:"full"` (default) is nested `{layout, etag}`, ' +
130
- '`flat:true` a depth-first array. `max_chars` bounds the text; a clipped ' +
131
- 'read returns `next_cursor` to page the rest. For a site-wide ' +
132
- 'SEO/structure/content/links audit (h1, image alt, thin pages, dead ' +
133
- 'links) do NOT loop this tool page-by-page — call ' +
134
- 'yootheme_builder_pages_audit (one sweep via ' +
135
- 'yootheme_builder_advanced_read).',
70
+ description: 'Get the layout tree for one layout — address by `layout_id` or `url`. `mode:"bindings_only"` for dynamize/bind. Over `max_chars` whole ' +
71
+ 'entries DROP (`truncated`+`omitted_count`; outline cuts its text) and NOTHING ' +
72
+ 'pages the rest no cursor in any mode. Narrow instead: `mode:"outline"` to ' +
73
+ 'map, then element_list(root_path). ' +
74
+ 'For a site-wide SEO/structure ' +
75
+ 'audit do NOT loop this tool page-by-page call yootheme_builder_pages_audit ' +
76
+ '(gateway-only). ' +
77
+ 'For ONE narrow question (e.g. "where is the binding" or "which elements have ' +
78
+ 'type X") this whole-template read is heavier than it needs to be — prefer ' +
79
+ 'yootheme_builder_layout_query (gateway-only; has_binding/element_type/' +
80
+ 'name_matches filters) or element_list with `root_path` to scope the walk.',
136
81
  inputSchema: {
137
82
  site_id: SITE_ID_SCHEMA,
138
- // G-A (Track-C URL→layout): three interchangeable addressing modes
139
- // (exactly one required) so ONE call reaches a layout from a
140
- // template_id, a bare numeric post/article id, or a pasted URL.
141
- template_id: TEMPLATE_ID_OPTIONAL,
142
- post_id: POST_ID,
83
+ layout_id: LAYOUT_ID_OPTIONAL,
143
84
  url: RESOLVE_URL,
144
- // F195 (P0): bindings_only returns the trimmed binding skeleton —
145
- // recommended for dynamize/bind workflows (token-efficient).
146
- // G1 (V3): outline returns a token-efficient INDENTED semantic
147
- // outline — one line per node, cheapest way to orient in a large
148
- // layout before reading specifics.
149
85
  mode: z
150
86
  .enum(['full', 'bindings_only', 'outline'])
151
87
  .optional()
152
88
  .describe('full (default) = whole nested layout; bindings_only = trimmed ' +
153
89
  'binding skeleton (path/type/name/has_binding/source/children, ' +
154
- 'no style props); outline = a token-efficient INDENTED text ' +
155
- 'tree (one line per node: label type (bound: …) [sN]) for ' +
156
- 'cheap orientation in a large layout. Each outline line carries ' +
157
- 'a per-read handle [sN] AND the node’s real JSON-Pointer ' +
158
- 'path; the handle is a short alias that is STATE-SCOPED re-read ' +
159
- 'after any mutation. Prefer bindings_only for dynamize/bind, ' +
160
- 'outline to first map an unfamiliar template.'),
161
- // F195 (P0): bypass the per-process unchanged-read dedup.
90
+ 'no style props). It compares each binding SOURCE against the ' +
91
+ 'sources this site registers: one that is gone carries ' +
92
+ '`unresolved:true` and is named once in `unresolved_sources`, with ' +
93
+ '`unresolved_sources_note` beside it saying what to repair. That ' +
94
+ 'list is present but EMPTY when nothing is dead, and replaced by ' +
95
+ '`unresolved_sources_not_checked` when the registered-source list ' +
96
+ 'could not be read at all (then an unmarked binding means ' +
97
+ 'nothing). The field ' +
98
+ 'VALUES inside a source that DOES resolve are not compared: one ' +
99
+ 'naming a field that does not exist looks exactly like one that ' +
100
+ 'does here, and renders blank — element_get_binding names those ' +
101
+ 'for ONE element. pages_audit reports the same dead sources ' +
102
+ 'site-wide as dangling-source. outline = an INDENTED text ' +
103
+ 'tree (one line per node: label ▸ type (bound: …) [sN] ' +
104
+ '/children/…) for cheap orientation in a large layout — the tree ' +
105
+ 'arrives on ' +
106
+ 'BOTH legs: as the TEXT content, and as `outline_text` in ' +
107
+ 'structuredContent, the same string under the same `max_chars` ' +
108
+ 'cap. structuredContent also carries a SUMMARY beside it ' +
109
+ '(named_sections with a node_count each, total_elements, etag) ' +
110
+ 'to pick WHICH section to open; the raw per-node array is not ' +
111
+ 'sent on either leg — call element_list(root_path, depth) for ' +
112
+ 'one section\'s actual nodes. Each outline line ENDS in that ' +
113
+ 'node\'s `element_path` — the RELATIVE address element_update_settings, ' +
114
+ 'element_move and element_delete take — so you can edit straight from ' +
115
+ 'this read. The [sN] handle before it is a per-read alias, ' +
116
+ 'STATE-SCOPED: re-read after any mutation. Prefer bindings_only for ' +
117
+ 'dynamize/bind, outline to first map an unfamiliar template. Neither ' +
118
+ 'cheap mode can be combined with include_modules:true — see that argument.'),
162
119
  force: z
163
120
  .boolean()
164
121
  .optional()
@@ -166,115 +123,92 @@ export function buildPagesTools(pool) {
166
123
  'already read this session (bypasses the [unchanged] dedup).'),
167
124
  flat: FLAT,
168
125
  fields: FIELDS,
169
- max_chars: MAX_CHARS,
170
- // B7 (customer continuation cursor): resume a clipped full/
171
- // bindings_only text leg from its char offset. Opaque
172
- // base64url `o:<n>` — the SAME offset-cursor contract
173
- // pages_list/sources_list use. Omit to read from the start.
174
- cursor: z
175
- .string()
126
+ max_chars: MAX_CHARS.describe('Cap (chars) on the text output. For `mode:"full"`/`"bindings_only"` both ' +
127
+ 'legs carry the same shortened payload, so structuredContent is not a way ' +
128
+ 'around the cap. For `mode:"outline"` this bounds ONLY the outline text ' +
129
+ '(the text content and `outline_text` in structuredContent) — the summary ' +
130
+ 'beside it (`named_sections`, `total_elements`, `etag`) is never shortened ' +
131
+ 'and always arrives complete, whatever this cap did to the outline text. ' +
132
+ 'A `[site @ host] ` prefix is added AFTER, so delivery is ' +
133
+ 'longer by it. ' +
134
+ 'Raising it stops helping at the limit your own client puts on a single tool ' +
135
+ 'result, which this server cannot see. ' +
136
+ 'Out of range, the cap that actually applied comes back as `max_chars`.'),
137
+ include_modules: z
138
+ .boolean()
176
139
  .optional()
177
- .describe('Char-offset cursor from a clipped response\'s next_cursor resumes ' +
178
- 'the same dump at that offset (use with max_chars).'),
140
+ .describe('mode:"full" (the default) ONLY including with flat:true, which is a ' +
141
+ 'projection of mode:"full" and serves it. In ' +
142
+ 'mode:"outline"/"bindings_only" the ' +
143
+ 'server cannot serve it and the response says so in ' +
144
+ '`modules_on_page_unavailable` (it does NOT mean the page has no ' +
145
+ 'modules). When true, attach `modules_on_page` — the widgets/modules that render ' +
146
+ 'on THIS page, split into `from_elements` (a module/module_position ' +
147
+ 'element placed directly in this page\'s own layout) and ' +
148
+ '`from_positions` (a site-wide theme position — navbar/header/footer ' +
149
+ '— rendering here with no element in this page\'s own layout at all). ' +
150
+ 'On Joomla, a site-wide module can still be assignment-EXCLUDED from ' +
151
+ 'this specific page (`except`); when that decision cannot be resolved ' +
152
+ '(no menu item addresses this page, or more than one does), the row ' +
153
+ 'lands in `from_positions_undecidable` instead of being guessed in or ' +
154
+ 'out. A builder-content module (Joomla mod_yootheme_builder, WP ' +
155
+ 'builderwidget) carries its embedded layout SUMMARIZED here as ' +
156
+ '`{omitted_for_size:true, node_count:N}`, not the full tree (B25) — ' +
157
+ '`layout_root` still names its root type; for the actual content call ' +
158
+ 'local_content_read(kind:"modules") on that id. Default false — omit ' +
159
+ 'for the pre-existing response shape, unchanged.'),
179
160
  },
180
- // No outputSchema: the response shape is a union (nested OR flat with
181
- // optional projection) and the JSON-Pointer-keyed nested shape is
182
- // structurally open-ended — modelling it precisely buys nothing here.
161
+ outputSchema: PAGE_GET_LAYOUT_OUTPUT_SCHEMA,
183
162
  annotations: readOnly('Get Page Layout'),
184
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handlePageGetLayout(client, rest), site)),
185
163
  }),
186
- defineTool({
187
- name: 'yootheme_builder_page_get_schema',
188
- description: 'Get the flat schema for a template — nodes with their JSON-Pointer ' +
189
- 'paths and element types. Lighter than page_get_layout, enough to locate ' +
190
- 'elements before editing. Address by `template_id` (pages_list), `post_id`, ' +
191
- 'or `url`. `fields[]` slims each node; `max_chars` bounds output.',
192
- inputSchema: {
193
- site_id: SITE_ID_SCHEMA,
194
- // G-A (Track-C URL→layout): three interchangeable addressing modes.
195
- template_id: TEMPLATE_ID_OPTIONAL,
196
- post_id: POST_ID,
197
- url: RESOLVE_URL,
198
- fields: FIELDS,
199
- max_chars: MAX_CHARS,
200
- include_meta: INCLUDE_META_SCHEMA,
201
- },
202
- outputSchema: SCHEMA_OUTPUT_SCHEMA,
203
- annotations: readOnly('Get Page Schema'),
204
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handlePageGetSchema(client, rest), site)),
205
- }),
206
- // ─── G-A (Track-C URL→layout) — pages_resolve ─────────────────
207
- // THE core "paste a URL → reach a layout in ≤1 MCP call" tool. An
208
- // agent handed only a public page URL resolves it to the per-page
209
- // template_id that every read tool accepts. L1 essential so a cold
210
- // agent reaches it directly (the whole point of the gap fix).
211
164
  defineTool({
212
165
  name: 'yootheme_builder_pages_resolve',
213
- description: 'Resolve a public page/article/archive URL to the template_id that renders it ' +
214
- 'paste a URL, get the layout id. Pretty/SEF permalinks resolve on WordPress AND ' +
215
- 'Joomla (incl. deep sub-category paths), not only raw ?option= URLs. A singular page ' +
216
- ' its per-page layout; a category/tag/CPT/author archive → the governing THEME ' +
217
- 'TEMPLATE, and for a category/term the SPECIFICALLY-ASSIGNED template (honoring ' +
218
- 'include-child-categories), not a generic one. Or a `target`. Returns {template_id, ' +
219
- 'post_id, type, frontend_url, context, resolved_via}.',
166
+ description: 'Resolve a page/article/archive URL to the layout_id that renders it. SEF/pretty ' +
167
+ 'permalinks resolve on both WordPress and Joomla. A category/term resolves to the ' +
168
+ 'SPECIFICALLY-ASSIGNED template (honoring include-child-categories), not a generic ' +
169
+ 'one. Returns {layout_id, post_id, type, frontend_url, context, resolved_via}.',
220
170
  inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_RESOLVE_INPUT },
221
171
  outputSchema: PAGES_RESOLVE_OUTPUT_SCHEMA,
222
172
  annotations: readOnly('Resolve URL to Template'),
223
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handlePagesResolve(client, rest), site)),
224
173
  }),
225
174
  defineTool({
226
175
  name: 'yootheme_builder_get_etag',
227
- description: 'Get the current ETag (state revision) for the YOOtheme builder. Returns a ' +
228
- 'sha256+revision string for optimistic locking. This ETag is SITE-WIDE: it covers ' +
229
- 'the ENTIRE builder state, so ANY write to ANY template (by any client) bumps it — ' +
230
- 'a 412 means the site state advanced, not necessarily that YOUR template changed. ' +
231
- 'It is the SAME token the read tools (page_get_layout, element_list) return in ' +
232
- 'their `etag`. Pass it back as `etag` on any write tool; on 412, re-read and retry.',
176
+ description: 'Get the current site-wide ETag for optimistic locking. ANY write to ANY ' +
177
+ 'template bumps it a 412 means the site state advanced, not necessarily ' +
178
+ 'your template. Same token page_get_layout/element_list return. Pass back as ' +
179
+ '`etag` on writes; on 412, re-read and retry. The ETag is SITE-wide, not per ' +
180
+ 'template that is why this tool takes no `layout_id`.',
233
181
  inputSchema: { site_id: SITE_ID_SCHEMA },
234
182
  outputSchema: ETAG_OUTPUT_SCHEMA,
235
183
  annotations: readOnly('Get ETag'),
236
- handler: async ({ site_id }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handleGetEtag(client), site)),
237
184
  }),
238
185
  defineTool({
239
186
  name: 'yootheme_builder_template_summary',
240
- description: 'Token-efficient template overview: element counts by type, binding ' +
241
- 'count, max nesting depth, and named landmark sections, computed ' +
242
- 'server-side in one call. Use this to grasp a large template before ' +
243
- 'pulling element_list or page_get_layout. Pass `include_nodes:true` for a ' +
187
+ description: 'Token-efficient template overview: element counts by type, bindings, max ' +
188
+ 'depth, named sections computed server-side in one call. Use before ' +
189
+ 'element_list/page_get_layout on a large template. `include_nodes:true` adds a ' +
244
190
  '`content_nodes` per-node breakdown (status/effective_visible/headings/alts), ' +
245
- 'pageable via `limit`/`cursor`. Pass ' +
246
- '`template_ids:[...]` for a batch: response carries `summaries` + ' +
247
- '`not_found`. ' +
248
- // F206 (P3): concrete first-call example. The Desktop client
249
- // rejected the first guessed call because no example showed the
250
- // exact arg shape (the whole yt-builder package used none, while
251
- // apimapper's schema.ts does). Mirrors apimapper's 'Example:'
252
- // pattern.
253
- 'Example: yootheme_builder_template_summary({ template_id: "default" }).',
191
+ 'pageable via `limit`/`cursor`. `layout_ids:[...]` batches several: response ' +
192
+ 'carries `summaries`, `not_found` and `forbidden`. ' +
193
+ 'Example: yootheme_builder_template_summary({ layout_id: "default" }).',
254
194
  inputSchema: {
255
195
  site_id: SITE_ID_SCHEMA,
256
- template_id: TEMPLATE_ID.optional().describe('Template ID (e.g. "default"). Provide this OR `template_ids` (batch) - ' +
257
- 'exactly one, not both. Use yootheme_builder_pages_list to discover.'),
258
- // T-C5 (mega-push plan 2026-07-24-02, customer P1.5): batch mode -
259
- // one REST round-trip for N templates instead of N calls.
260
- template_ids: z
196
+ layout_id: LAYOUT_ID.optional().describe('Which layout: "page:42", "article:12", "default", or a bare id (42). ' +
197
+ 'Provide this OR `layout_ids` (batch) - exactly one, not both. ' +
198
+ 'Use yootheme_builder_pages_list to discover.'),
199
+ layout_ids: z
261
200
  .array(z.string().min(1))
262
201
  .min(1)
263
202
  .optional()
264
- .describe('Batch of template IDs (2+) - one call instead of N. Provide this OR ' +
265
- '`template_id` (single) - exactly one, not both. Response carries ' +
266
- '`summaries` (keyed by id) + `not_found`.'),
267
- // T-E2 (mega-push plan 2026-07-24-02, Thomas-Entscheid C):
268
- // content_nodes is opt-in - omit for the compact aggregate-only
269
- // shape, pass true to also get the per-node breakdown.
203
+ .describe('Batch of layout ids (2+) - one call instead of N. Provide this OR ' +
204
+ '`layout_id` (single) - exactly one, not both. Response carries ' +
205
+ '`summaries` (keyed by id), `not_found` and `forbidden`.'),
270
206
  include_nodes: z
271
207
  .boolean()
272
208
  .optional()
273
209
  .describe('When true, also return `content_nodes` (per-node status/' +
274
210
  'effective_visible/hidden_on_mobile/headings/alts). Default false ' +
275
211
  '(the compact aggregate-only shape).'),
276
- // T-C5: page content_nodes when include_nodes:true (same
277
- // limit/cursor contract as pages_list/element_list).
278
212
  limit: z
279
213
  .number()
280
214
  .int()
@@ -292,58 +226,42 @@ export function buildPagesTools(pool) {
292
226
  },
293
227
  outputSchema: TEMPLATE_SUMMARY_OUTPUT_SCHEMA,
294
228
  annotations: readOnly('Template Summary'),
295
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handleTemplateSummary(client, rest), site)),
296
229
  }),
297
- // ─── Task 6 (pages_audit design, 2026-07-19) — pages_audit ────
298
- // L2 (advanced_read): a site-wide, severity-sorted SEO/structure/
299
- // content/links sweep computed server-side in ONE call. Deliberately
300
- // NOT in ESSENTIAL_TOOLS (keeps first-class tools/list at 41) —
301
- // `readOnly()` annotation routes it into the `advanced_read` gateway
302
- // automatically (annotation-driven, no allowlist edit).
303
230
  defineTool({
304
231
  name: 'yootheme_builder_pages_audit',
305
- description: 'One-call site-wide SEO/structure/content/links/design audit — severity-sorted findings ' +
306
- 'with fix_hints (a props fragment to merge: supply template_id+path from the ' +
307
- 'locator). Covers h1/headings, thin pages, image alt, duplicate layouts, title ' +
308
- 'collisions, non-pretty URLs, dead anchors. Only active (non-disabled) nodes ' +
309
- 'produce findings. A site sweep caps hits/page, drops content_snippet; `target` ' +
310
- 'scopes to ONE page for the full set (cap 100). Filter with `types`/`checks`. ' +
311
- 'Disclaimer: SEO-plugin meta (title/description/OG) NOT covered.',
232
+ description: 'One-call site-wide SEO / structure / content / links / design audit — ' +
233
+ 'severity-sorted findings with fix_hints (a props fragment to merge). Covers ' +
234
+ 'heading structure and accessibility (h1/heading-skip), image alt text, thin ' +
235
+ 'content, duplicate layouts, title collisions, broken in-page anchor links ' +
236
+ '(same-page `#id` jumps only no external link is ever fetched or resolved), ' +
237
+ 'and design consistency (markup outside the UIkit design system, header/' +
238
+ 'navigation contrast). Only active (non-disabled) nodes produce findings. ' +
239
+ '`target` scopes to ONE page for the full set. SEO-plugin meta (title/' +
240
+ 'description/OG) NOT covered.',
312
241
  inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_AUDIT_INPUT },
313
242
  outputSchema: PAGES_AUDIT_OUTPUT_SCHEMA,
314
243
  annotations: readOnly('Pages Audit'),
315
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handlePagesAudit(client, rest), site)),
316
244
  }),
317
- // ─── F5 + N5 (customer HANDOFF-4/5) — render_preview ───────────
318
- // The authenticated post-write render HEALTHCHECK. READ-ONLY: renders
319
- // the template server-side over the existing Bearer channel and reports
320
- // {rendered, item_count, empty, error?} + a cache_purge_hint — answering
321
- // "does my saved page actually render, with how many items?" where an
322
- // external cURL 401s behind QA Basic-Auth. L2 (advanced-read) — reached
323
- // via yootheme_builder_advanced_read, NOT in ESSENTIAL_TOOLS, so the L1
324
- // token-baseline stays at 32. Addressing mirrors page_get_layout:
325
- // template_id OR url (exactly one).
326
245
  defineTool({
327
246
  name: 'yootheme_builder_render_preview',
328
- description: 'Render-check a saved template does it actually render, with how many items, or ' +
329
- 'is it blank? Address by `template_id` (from pages_list), `post_id`, or `url` ' +
330
- '(resolved for you) exactly one. `item_count` = items yielded by the ' +
331
- 'template\'s dynamic/Multi-Items bindings (rendered repeat-source rows); 0 with ' +
332
- 'empty:true means a binding returned nothing. Returns {rendered, item_count, empty, ' +
333
- 'error?, cache_purge_hint}; with `expect`, also {matched, snippet}. Use AFTER a ' +
334
- 'save/bind to catch a silently-empty page. Read-only.',
247
+ description: 'Render-check a SAVED layout. Address by ' +
248
+ '`layout_id` or `url`. rendered_item_wrapper_count counts the ' +
249
+ 'repeat-item wrappers rendered, BOUND OR NOT, so a 0 is not evidence a ' +
250
+ 'binding failed (per-source rows: `source_item_counts`). Distinct from ' +
251
+ 'pages_list `elements_count` (all tree nodes). A source the registry cannot ' +
252
+ 'resolve is named in `unresolved_sources`, not just a smaller count. Renders ' +
253
+ 'ONLY the page\'s own layout tree, never the theme wrapper: a MISS with ' +
254
+ '`expect` proves nothing beyond the tree (adds {matched, snippet, ' +
255
+ 'match_conclusive, match_note, mismatch_hints, stored_but_not_rendered — the ' +
256
+ 'last names elements that DO store the text but rendered no rows}). A Joomla ' +
257
+ 'module/module_position element sharpens this — EXCLUDED (fallback_used:true) ' +
258
+ 'or silently empty (dropped_count:0) — but match_conclusive:false marks EVERY ' +
259
+ 'inconclusive miss. Reports CMS status in `cms_status`/`cms_status_note` (absent ' +
260
+ 'for a theme template); pages_set_status remains the tool that changes it.',
335
261
  inputSchema: {
336
262
  site_id: SITE_ID_SCHEMA,
337
- // WAVE-1 follow-up (a): render_preview threads the SAME three
338
- // addressing modes page_get_layout uses (template_id | post_id |
339
- // url, exactly one) — the handler already resolved post_id via
340
- // resolveEffectiveTemplateId; this exposes it at the MCP boundary.
341
- template_id: TEMPLATE_ID_OPTIONAL,
342
- post_id: POST_ID,
263
+ layout_id: LAYOUT_ID_OPTIONAL,
343
264
  url: RESOLVE_URL,
344
- // customer HANDOFF-6 #4: optional substring the rendered HTML must
345
- // contain. When set, the response adds {matched, snippet} so "did
346
- // my edit reach the render?" is answerable in one call.
347
265
  expect: z
348
266
  .string()
349
267
  .min(1)
@@ -357,26 +275,18 @@ export function buildPagesTools(pool) {
357
275
  },
358
276
  outputSchema: RENDER_PREVIEW_OUTPUT_SCHEMA,
359
277
  annotations: readOnly('Render Preview'),
360
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handleRenderPreview(client, rest), site)),
361
278
  }),
362
- // ─── T-A5 (heading_outline tool, mega-push plan 2026-07-24-02) ────
363
- // L2 (advanced_read): a real, doc-order H1-H6 outline of ONE
364
- // template attributed to its source element, plus the alt-status of
365
- // every image. Deliberately NOT in ESSENTIAL_TOOLS — `readOnly()`
366
- // routes it into the advanced_read gateway automatically, same as
367
- // pages_audit/layout_query.
368
279
  defineTool({
369
280
  name: 'yootheme_builder_heading_outline',
370
- description: 'A real, doc-order H1-H6 outline of ONE template: each heading with its TEXT ' +
371
- 'and the source element that carries it (`element_type`/`path`), plus the ' +
372
- 'alt-status of every image (including images inside html/text/code raw markup). ' +
373
- 'Read-only STRUCTURE inspection, not findings; use yootheme_builder_pages_audit ' +
374
- 'for severity-sorted SEO findings across the whole site. Returns ' +
375
- '{outline, images, h1_count, has_level_skip, images_missing_alt}. Address by ' +
376
- '`template_id` (from pages_list or pages_resolve).',
281
+ description: 'A real, doc-order H1-H6 outline of ONE template, each heading with its source ' +
282
+ 'element, plus alt-status of every image. Structure inspection, not findings ' +
283
+ 'use pages_audit for site-wide SEO findings. ' +
284
+ 'One row per CARRIER: a container whose bound item repeats appears once, ' +
285
+ 'while template_summary.heading_levels counts it once per rendered row.',
377
286
  inputSchema: {
378
287
  site_id: SITE_ID_SCHEMA,
379
- template_id: TEMPLATE_ID,
288
+ layout_id: LAYOUT_ID,
289
+ max_chars: MAX_CHARS,
380
290
  mode: z
381
291
  .enum(['builder', 'rendered'])
382
292
  .optional()
@@ -386,27 +296,35 @@ export function buildPagesTools(pool) {
386
296
  'engine render_preview / pages_audit use) and reads the ACTUAL DOM - ' +
387
297
  'element_type is empty ("") in this mode, since there is no builder ' +
388
298
  'node to point at; locate a heading by its `path` (a synthetic ' +
389
- '"rendered:heading:N" marker) or the page\'s frontend_url instead.'),
299
+ '"rendered:heading:N" marker) or the page\'s frontend_url instead. A ' +
300
+ 'Joomla page with module/module_position renders via a tolerant ' +
301
+ 'fallback (that subtree excluded) rather than failing; the response ' +
302
+ 'then carries render_fallback_used:true + render_dropped_count:N — ' +
303
+ 'treat h1_count/has_level_skip/the outline as possibly incomplete when ' +
304
+ 'that flag is true. A genuine render failure returns error:"render_failed".'),
390
305
  },
391
306
  outputSchema: HEADING_OUTLINE_OUTPUT_SCHEMA,
392
307
  annotations: readOnly('Heading Outline'),
393
- handler: async ({ site_id, ...rest }) => withSiteRetry(pool, site_id, async (client, site) => withSiteMeta(await handleHeadingOutline(client, rest), site)),
394
308
  }),
395
309
  defineTool({
396
310
  name: 'yootheme_builder_page_save',
397
- description: 'Re-run save-transforms + flush caches. Optionally REPLACE the template tree by ' +
398
- 'passing the INNER {type:"layout",children:[...]} tree as `layout` — page_get_layout\'s ' +
399
- '`.layout` child, NOT the whole response it returns (rejected 422, would blank the ' +
400
- 'page). Validated + ETag-locked; nothing persists on reject. Does NOT change CMS ' +
401
- 'post status a draft stays invisible to visitors; set status via pages_create. ' +
402
- '`dry_run:true` preflights; success carries `previous_layout` for rollback. ETag ' +
403
- 'optional (412 on conflict; else last-write-wins).',
311
+ description: 'Re-run save-transforms + flush the plugin\'s own caches. Optional whole-tree ' +
312
+ 'replace via `layout` — ' +
313
+ 'the INNER {type:"layout",children:[...]} tree, NOT page_get_layout\'s whole ' +
314
+ 'response (rejected 422). ' +
315
+ 'THREE separate steps, and this is the first: (1) page_save replaces or ' +
316
+ 're-normalises the stored tree every write, element or whole-tree, runs the ' +
317
+ 'same save-transforms; (2) page_publish snapshots the ETag and flushes them; ' +
318
+ '(3) pages_set_status decides whether a visitor may see the page at all. This ' +
319
+ 'call does NOT do (2) or (3). ' +
320
+ 'Response `previous_layout` is the tree right before THIS call, not before your ' +
321
+ 'edits (element writes already landed) — identical to what you just wrote is normal ' +
322
+ 'when the transforms change nothing. ' +
323
+ '`dry_run:true` preflights, no ETag. ETag on the save (428/412).',
404
324
  inputSchema: {
405
325
  site_id: SITE_ID_SCHEMA,
406
- template_id: TEMPLATE_ID,
407
- etag: ETAG,
408
- // F85: optional whole-layout atomic replacement (ARTICLE/page
409
- // templates + theme templates). Same shape as pages_create.layout.
326
+ layout_id: LAYOUT_ID,
327
+ etag: ETAG_PREVIEW_OPTIONAL.optional(),
410
328
  layout: z
411
329
  .record(z.string(), z.unknown())
412
330
  .optional()
@@ -415,9 +333,9 @@ export function buildPagesTools(pool) {
415
333
  'child, NOT the whole response it returns (passing that is rejected ' +
416
334
  'as a double-nest). Replaces the template tree atomically. Validated ' +
417
335
  '+ ETag-locked, BUT prop KEYS are NOT schema-validated on a whole-tree ' +
418
- 'save — YT-Pro silently drops unknown keys; use element_update_settings ' +
419
- 'for validated per-element edits. Omit to just re-run save-transforms.'),
420
- // U3/F3 (customer HANDOFF-4): optional render preflight.
336
+ 'save — an unknown key is stored as sent, not dropped and not reported ' +
337
+ 'here; element_update_settings keeps it too, but reports it back as ' +
338
+ '`unknown_prop_keys`. Omit to just re-run save-transforms.'),
421
339
  dry_run: z
422
340
  .boolean()
423
341
  .optional()
@@ -425,7 +343,6 @@ export function buildPagesTools(pool) {
425
343
  'render dry-run and return a validation_report WITHOUT persisting ' +
426
344
  '(no write, no cache flush, no ETag bump). Use to verify a binding ' +
427
345
  'renders before it can blank the live page. Omit to actually save.'),
428
- // Task 8 (design §7): opt-in advisory quick_check on save.
429
346
  quick_check: z
430
347
  .boolean()
431
348
  .optional()
@@ -437,26 +354,62 @@ export function buildPagesTools(pool) {
437
354
  'Advisory only — the save always succeeds. Site-wide checks ' +
438
355
  '(duplicate-layout, title-collision) need pages_audit.'),
439
356
  },
357
+ outputSchema: PAGE_SAVE_OUTPUT_SCHEMA,
440
358
  annotations: mutating('Save Page'),
441
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_page_save', async (client, site) => withRenderContext(withSiteMeta(await handlePageSave(client, rest, extra), site), buildRenderContext({
442
- siteUrl: site.url,
443
- parentTemplateId: rest.template_id,
444
- locale: localeForSite(site),
445
- }))),
446
359
  }),
447
360
  defineTool({
448
361
  name: 'yootheme_builder_page_publish',
449
- description: 'Publish a template — persist state, flush YT + WP caches, snapshot the ' +
450
- 'published-state ETag. YOOtheme templates already publish on save, so this is a ' +
451
- 'cache-flush + state-snapshot op. Neither publish nor save changes the CMS post ' +
452
- 'status a draft page stays invisible to visitors; set status at creation via ' +
453
- 'pages_create/library_insert. ETag optional when provided, 412 on conflict; when ' +
454
- 'omitted, last-write-wins.',
362
+ description: 'Publish a template\'s LAYOUT — persist state, flush the plugin\'s own caches ' +
363
+ '(a page-cache/CDN plugin is NOT purged: purge it yourself, then verify with ' +
364
+ 'fetch_public_url), snapshot the ETag; ' +
365
+ '"publish" ALSO means the CMS post status, and this tool does not change that, ' +
366
+ 'so a draft page stays invisible. ' +
367
+ 'Step (2) of the three page_save describes; pages_set_status is step (3). ' +
368
+ 'ETag required — 412 on conflict. ' +
369
+ 'Answers `cms_visibility.findable_by_visitor`: can a visitor FIND this one page via ' +
370
+ 'a navigation path? It reads the menu route AND the access level, which the ' +
371
+ 'per-row `visibility` of pages_list does not. ' +
372
+ 'Optional `cms_status` folds step (3) into this call for the common ' +
373
+ 'build-it-and-make-it-live case; without it nothing about the CMS status changes.',
455
374
  inputSchema: {
456
375
  site_id: SITE_ID_SCHEMA,
457
- template_id: TEMPLATE_ID,
458
- etag: ETAG,
459
- // Task 8 (design §7): the publish QuickCheck is DEFAULT-ON.
376
+ layout_id: LAYOUT_ID,
377
+ etag: ETAG_STRICT,
378
+ cms_status: z
379
+ .enum([
380
+ 'publish',
381
+ 'draft',
382
+ 'pending',
383
+ 'private',
384
+ 'future',
385
+ 'published',
386
+ 'unpublished',
387
+ 'archived',
388
+ ])
389
+ .optional()
390
+ .describe('Optional. Also set the CMS status in THIS call, so the common ' +
391
+ '"build it and make it live" case is one call instead of three. Same ' +
392
+ 'words and same refusals as yootheme_builder_pages_set_status — ' +
393
+ 'WordPress publish/draft/pending/private/future, Joomla ' +
394
+ 'published/unpublished/archived; the other platform\'s word is refused ' +
395
+ 'and NOTHING is published. Needs a page:/article: template (a theme ' +
396
+ 'template has no single page). To trash or delete use ' +
397
+ 'yootheme_builder_pages_delete; no status value here removes anything. ' +
398
+ 'Omit to leave the CMS status untouched. ' +
399
+ 'The response carries `cms_status_applied` with the STORED status after ' +
400
+ 'the write, and `cms_visibility` then reflects the NEW status.'),
401
+ menu_item: z
402
+ .union([z.boolean(), z.string().min(1).max(64)])
403
+ .optional()
404
+ .describe('Joomla only. Also create a SEF route for the article: true = the ' +
405
+ 'dedicated hidden menutype, a string picks the menutype ("mainmenu" is ' +
406
+ 'refused so generated routes never enter the site navigation). The ' +
407
+ 'article must end up published — pass cms_status:"published" here or ' +
408
+ 'publish it first; otherwise the call is refused rather than handing ' +
409
+ 'back a route to an unpublished article, whose url no visitor can ' +
410
+ 'open. Response carries `menu_item_id`. On WordPress this argument is ' +
411
+ 'REFUSED, never ignored: a WP page is served at its permalink as soon ' +
412
+ 'as its status is publish, so there is no route to create.'),
460
413
  quick_check: z
461
414
  .boolean()
462
415
  .optional()
@@ -466,38 +419,23 @@ export function buildPagesTools(pool) {
466
419
  'report for THIS page, with fix_hints, or `{clean:true}`. Set false to ' +
467
420
  'OPT OUT (e.g. bulk publishes). Advisory only — publish ALWAYS ' +
468
421
  'succeeds; findings never block it. Site-wide checks (duplicate-layout, ' +
469
- 'title-collision) still need pages_audit.'),
422
+ 'title-collision) still need pages_audit. `render_check:{ok,worst,' +
423
+ 'findings}` rides next to `published` with the render verdict — ' +
424
+ '`ok:false` names a QUALITY finding, not a failed publish: the ' +
425
+ 'publish above it already succeeded regardless.'),
470
426
  },
471
- // Stream D3 T3: publish is idempotent — re-running on an
472
- // unchanged template snapshots the same ETag and flushes
473
- // the same caches. Matrix marks `idempotentHint:true`.
427
+ outputSchema: PAGE_PUBLISH_OUTPUT_SCHEMA,
474
428
  annotations: mutating('Publish Page'),
475
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_page_publish', async (client, site) => withRenderContext(withSiteMeta(await handlePagePublish(client, rest, extra), site), buildRenderContext({
476
- siteUrl: site.url,
477
- parentTemplateId: rest.template_id,
478
- locale: localeForSite(site),
479
- }))),
480
429
  }),
481
- // ─── N3 (customer HANDOFF-5) — template_set_type ───────────────
482
- // L2 (advanced): set which archive/single a YOOtheme theme template
483
- // is assigned to (the `templates.<id>.type` condition pages_list
484
- // reads). The #1 missing step in a taxonomy/CPT-rename workflow —
485
- // after categoryFaq→categoryHelp the `taxonomy-category_faq` /
486
- // `single-example_faq` templates are orphaned and must be re-typed.
487
430
  defineTool({
488
431
  name: 'yootheme_builder_template_set_type',
489
- description:
490
- // N3 (customer HANDOFF-5) archive/single TYPE reassignment.
491
- 'Reassign which archive/single a YOOtheme THEME template applies to ' +
492
- 'set its `type` condition (the value pages_list shows) in ONE ETag-locked ' +
493
- 'write. Use after a taxonomy/CPT rename orphans a template (e.g. re-type ' +
494
- '"taxonomy-category_faq" → "taxonomy-category_help"). Returns ' +
495
- '{type, previous_type, new_etag}. Site-wide + immediate — preview with ' +
496
- 'dry_run:true, reversible via previous_type. ' +
497
- 'THEME templates only: page:/article: is refused (422). ETag req.',
432
+ description: 'Reassign which archive/single a YOOtheme THEME template applies to — set its ' +
433
+ '`type` condition in ONE ETag-locked write. Use after a taxonomy/CPT rename ' +
434
+ 'orphans a template. Site-wide + immediate preview with dry_run:true, ' +
435
+ 'reversible via previous_type. THEME templates only: page:/article: refused (422).',
498
436
  inputSchema: {
499
437
  site_id: SITE_ID_SCHEMA,
500
- template_id: TEMPLATE_ID,
438
+ layout_id: LAYOUT_ID,
501
439
  type: z
502
440
  .string()
503
441
  .min(1)
@@ -506,15 +444,13 @@ export function buildPagesTools(pool) {
506
444
  '"single-example_help", "archive-post", or the bare "template". ' +
507
445
  'Read the current value via pages_list (the `type` column) or ' +
508
446
  'GET the template first. `page`/`article` are NOT valid here.'),
509
- // Required strict ETag (the re-type is a real mutation; the PHP
510
- // controller enforces If-Match → 428 if omitted, 412 on stale).
511
- etag: ETAG_STRICT,
512
- // PAGES_LIBRARY_MEDIA-14: preflight the re-type without persisting.
447
+ etag: ETAG_PREVIEW_OPTIONAL.optional(),
513
448
  dry_run: z
514
449
  .boolean()
515
450
  .optional()
516
451
  .describe('Preflight ONLY. When true, validate the re-type (authz + ETag ' +
517
- 'lock + theme-template-only + type validity + template-exists) ' +
452
+ 'staleness, though a missing ETag is fine on a preview + ' +
453
+ 'theme-template-only + type validity + template-exists) ' +
518
454
  'and return {previous_type, would_change, dry_run:true} WITHOUT ' +
519
455
  'persisting — the template TYPE assignment governs which items ' +
520
456
  'render this layout SITE-WIDE and applies immediately once ' +
@@ -523,112 +459,91 @@ export function buildPagesTools(pool) {
523
459
  },
524
460
  outputSchema: TEMPLATE_SET_TYPE_OUTPUT_SCHEMA,
525
461
  annotations: mutating('Set Template Type'),
526
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_template_set_type', async (client, site) => withRenderContext(withSiteMeta(await handleTemplateSetType(client, rest, extra), site), buildRenderContext({
527
- siteUrl: site.url,
528
- parentTemplateId: rest.template_id,
529
- locale: localeForSite(site),
530
- }))),
531
462
  }),
532
- // ─── C4 (v1.2) — pages_create + pages_delete ──────────────────
533
- // First-class customer-facing page-level mutations. Both wrap
534
- // Phase B REST endpoints (POST /pages, DELETE /pages/{id}) and
535
- // are L1 essentials (see gateway/essentials.ts).
536
463
  defineTool({
537
464
  name: 'yootheme_builder_pages_create',
538
- description: 'Create a page (WordPress) or article (Joomla 5/6) with a YOOtheme per-page ' +
539
- 'layout. Required: title. Optional: slug, status (default draft), published ' +
540
- '(default false live on true: WP publish / Joomla state 1), layout (JSON), ' +
541
- 'menu_item (Joomla SEF route), dry_run (preflight, no persist). Returns page_id ' +
542
- '(WP) / article_id (Joomla), slug, template_id (page:{id} or article:{id}), etag, ' +
543
- 'warnings. Joomla: a published article has NO SEF route until a menu item points ' +
544
- 'at it — pass menu_item, else frontend_url may 404.',
465
+ description: 'Create a page (WordPress) or article (Joomla 5/6) with a per-page layout. ' +
466
+ 'Required: title. Optional: status (default draft), layout, menu_item, ' +
467
+ 'dry_run (preflight, no persist). Joomla: a published article has NO SEF route ' +
468
+ 'until a menu item points at it pass menu_item for a navigable url. ' +
469
+ 'Cannot make it the site front page: which page answers / is a CMS menu ' +
470
+ 'setting this server never writes. pages_list marks the current one with ' +
471
+ 'is_public_homepage.',
545
472
  inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_CREATE_INPUT },
546
- // No outputSchema: the response shape is a discriminated union
547
- // (201 wet vs 200 dry-run). page_get_layout uses the same pattern.
548
- annotations: mutating('Create Page'),
549
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_pages_create', async (client, site) => withRenderContext(withSiteMeta(await handlePagesCreate(client, rest, extra), site), buildRenderContext({
550
- siteUrl: site.url,
551
- // A new page has no caller-supplied parent
552
- // template; null until the REST response carries
553
- // one (kept stable rather than absent).
554
- parentTemplateId: null,
555
- locale: localeForSite(site),
556
- }))),
473
+ outputSchema: PAGES_CREATE_OUTPUT_SCHEMA,
474
+ annotations: creating('Create Page'),
557
475
  }),
558
- // ─── P-G (Goldstandard wave 3) — page_dynamize ────────────────
559
- // THE one-call canonical path to dynamize an existing designed
560
- // section. L1 essential: an agent must reach it directly INSTEAD
561
- // of hand-editing layout JSON (the recipe is CODE, server-side).
562
476
  defineTool({
563
- name: 'yootheme_builder_page_dynamize',
564
- description: 'One-call way to dynamize a designed section: copies the layout ' +
565
- 'byte-identically and swaps only what you map. Use INSTEAD of ' +
566
- 'hand-editing JSON. Give a REFERENCE (section_name from ' +
567
- 'template_summary, or element_path) + list_source_name + a leaf_map ' +
568
- '(original leaf field-name flat flow field; #parent + tuned props kept). ' +
569
- 'A section with several source blocks dynamizes in ONE ' +
570
- 'call via source_map ({match, source_name, leaf_map?}[]). Sub-query panels: ' +
571
- 'key by "<subquery>.<leaf>". Returns page + `summary`. Preview with dry_run:true.',
572
- inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGE_DYNAMIZE_INPUT },
573
- // No outputSchema: the response is the create wire-shape (WP
574
- // page_id / Joomla article_id discriminated union) plus the
575
- // `summary` object pages_create uses the same no-outputSchema
576
- // pattern for its discriminated union.
577
- annotations: creating('Dynamize Page'),
578
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_page_dynamize', async (client, site) => withRenderContext(withSiteMeta(await handlePageDynamize(client, rest, extra), site), buildRenderContext({
579
- siteUrl: site.url,
580
- parentTemplateId: null,
581
- locale: localeForSite(site),
582
- }))),
477
+ name: 'yootheme_builder_page_generate_dynamic',
478
+ description: 'Copies a designed section byte-identically into a NEW, unpublished, unlinked ' +
479
+ 'page and swaps only what you map it never edits the reference. Requires ' +
480
+ 'output:"new_page" (today\'s only value; "in_place" is not yet available). Give ' +
481
+ 'a REFERENCE (section_name or element_path) + list_source_name + a leaf_map. A ' +
482
+ 'section with several source blocks dynamizes in ONE call via source_map. ' +
483
+ 'Preview with dry_run:true (a would_change:false answer carries `reason`). Live ' +
484
+ 'at once stage hidden with element_set_status(status:false). The response ' +
485
+ 'carries `cms_visibility.findable_by_visitor`: can a visitor FIND this one page ' +
486
+ 'via a navigation path? It reads the menu route AND the access level, which the ' +
487
+ 'per-row `visibility` of pages_list does not. ' +
488
+ 'Cannot make it the site front page (a CMS menu setting).',
489
+ inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGE_GENERATE_DYNAMIC_INPUT },
490
+ outputSchema: PAGE_GENERATE_DYNAMIC_OUTPUT_SCHEMA,
491
+ annotations: creating('Generate Dynamic Page'),
583
492
  }),
584
- // ─── Task 5 (transparent-header plan) — header_transparency_set ───
585
- // L2 (advanced): inspect + repair the three `header_transparent*`
586
- // props on the section that actually governs the site header. NOT an
587
- // L1 essential — it is the remediation for ONE specific
588
- // misconfiguration, reached from a `header-contrast-*` finding's
589
- // fix_hint or from an explicit customer request, not a hot path. The
590
- // tool budget (~40 in `tools/list`) is spent on the workflow spine.
591
493
  defineTool({
592
494
  name: 'yootheme_builder_header_transparency_set',
593
- description:
594
- // ≤600 chars (catalog constraint). Every clause is a behaviour
595
- // an agent gets WRONG without it see the behavior-truth pins.
596
- 'Inspect + repair the transparent header (nav over the hero). Always targets ' +
597
- 'the FIRST section YOOtheme reads these props there only; later ones are ' +
598
- 'silently dead. dry_run defaults TRUE: returns current state, the ' +
599
- 'theme-declared --uk-inverse, risk_class, confidence, recommendation, ' +
600
- 'would_change. mode:"auto" writes the theme-declared colour; over a hero ' +
601
- 'image/video it writes NO colour and says to LOOK. mode:"explicit" refuses a ' +
602
- 'colour contradicting the theme (409) unless acknowledge_contrast_risk. ' +
603
- 'transparent:false is always allowed.',
495
+ description: 'Inspect + repair the transparent header. Always targets the FIRST section — ' +
496
+ 'later ones are silently dead. dry_run defaults TRUE: returns current state + ' +
497
+ 'the theme-declared --uk-inverse, risk_class, recommendation. mode:"auto" writes ' +
498
+ 'the theme-declared colour; over a hero image/video it writes NONE and says LOOK. ' +
499
+ 'mode:"explicit" refuses a colour contradicting the theme (409) unless ' +
500
+ 'acknowledge_contrast_risk. transparent:false is always allowed.',
604
501
  inputSchema: HEADER_TRANSPARENCY_SET_INPUT,
605
- // No outputSchema: the payload is a rich diagnosis object whose
606
- // `changes` map is keyed by whichever props moved — a strict
607
- // structuredContent schema would either be permissive to the point
608
- // of uselessness or reject a legitimate response.
609
502
  annotations: mutating('Set Header Transparency'),
610
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_header_transparency_set', async (client, site) => withRenderContext(withSiteMeta(await handleHeaderTransparencySet(client, rest, extra), site), buildRenderContext({
611
- siteUrl: site.url,
612
- parentTemplateId: rest.template_id,
613
- locale: localeForSite(site),
614
- }))),
615
503
  }),
616
504
  defineTool({
617
505
  name: 'yootheme_builder_pages_delete',
618
- description: 'Delete a page (WordPress) or article (Joomla 5/6) with its YOOtheme per-page ' +
619
- 'layout. Requires confirm:true (gate against accidental deletion). Default: trash ' +
620
- '(recoverable). force:true: permanent delete. Refuses non-page/article types with ' +
621
- '403 (Layer 9 defense). Returns deleted:true, page_id (WP) / article_id (Joomla), ' +
622
- 'force_deleted, bumped etag.',
506
+ description: 'Delete a page (WordPress) or article (Joomla 5/6). OMIT confirm to preview: ' +
507
+ 'returns 200 with label, elements_count, what happens to media, and the intents ' +
508
+ 'this page\'s state allows, and deletes nothing. confirm:true + an intent carries ' +
509
+ 'it out. Already-trashed returns 200 {deleted:false, already_trashed:true}, ' +
510
+ 'not an error.',
623
511
  inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_DELETE_INPUT },
624
512
  outputSchema: PAGES_DELETE_OUTPUT_SCHEMA,
625
- // A page/article delete (force:true = PERMANENT, non-idempotent) is
626
- // destructive — annotate it so, matching yootheme_builder_element_delete
627
- // and so an MCP host's destructive-approval gate fires (audit fix F9,
628
- // 2026-07-16). The confirm:z.literal(true) guard already satisfies the
629
- // destructive()+confirm contract.
630
513
  annotations: destructive('Delete Page'),
631
- handler: async ({ site_id, ...rest }, extra) => withWriteSiteRetry(pool, site_id, 'yootheme_builder_pages_delete', async (client, site) => withSiteMeta(await handlePagesDelete(client, rest, extra), site)),
514
+ }),
515
+ defineTool({
516
+ name: 'yootheme_builder_pages_set_status',
517
+ description: 'Change the CMS status of an EXISTING page (WordPress) or article (Joomla) — ' +
518
+ 'keeps its id and URL. Step (3) of the three page_save describes. ' +
519
+ 'Use YOUR platform\'s own words: WordPress publish, draft, ' +
520
+ 'pending, private, future; Joomla published, unpublished, archived — the other ' +
521
+ 'platform\'s word is refused (422). Status is RE-READ after the write. To trash ' +
522
+ 'or delete use yootheme_builder_pages_delete; a page already IN the trash is ' +
523
+ 'refused (409) — use yootheme_builder_pages_restore first. ' +
524
+ 'The response carries `cms_visibility.findable_by_visitor`: can a visitor FIND ' +
525
+ 'this one page via a navigation path? It reads the menu route AND the access ' +
526
+ 'level, which the per-row `visibility` of pages_list does not.',
527
+ inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_SET_STATUS_INPUT },
528
+ outputSchema: PAGES_SET_STATUS_OUTPUT_SCHEMA,
529
+ annotations: mutating('Set Page Status'),
530
+ }),
531
+ defineTool({
532
+ name: 'yootheme_builder_pages_restore',
533
+ description: 'Restore a TRASHED page (WordPress) or article (Joomla) — the one correct way ' +
534
+ 'back (pages_set_status refuses a trashed page with 409 naming this tool). ' +
535
+ 'WordPress: reinstates the EXACT pre-trash status (core defaults restores to ' +
536
+ 'draft since 5.6) and attempts to reclaim the pre-trash slug — a hand-rolled ' +
537
+ 'write leaves the "__trashed" suffix instead; a slug another page has since ' +
538
+ 'taken comes back different — check the response\'s frontend_url. Joomla stores ' +
539
+ 'no pre-trash status, so this can only set state to unpublished (visible to ' +
540
+ 'editors, not visitors); call yootheme_builder_pages_set_status with ' +
541
+ 'status:"published" afterwards to make it visible. Not currently trashed → ' +
542
+ 'refused (409). Find a trashed id with ' +
543
+ 'yootheme_builder_local_content_read({kind:"entities", status:"trash"}).',
544
+ inputSchema: { site_id: SITE_ID_SCHEMA, ...PAGES_RESTORE_INPUT },
545
+ outputSchema: PAGES_RESTORE_OUTPUT_SCHEMA,
546
+ annotations: creating('Restore Page'),
632
547
  }),
633
548
  ];
634
549
  }