@noodleseed/one 0.22.0 → 0.24.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 (427) hide show
  1. package/dist/cli.d.ts.map +1 -1
  2. package/dist/cli.js +2 -1
  3. package/dist/cli.js.map +1 -1
  4. package/dist/commands/author-loop.d.ts +1 -0
  5. package/dist/commands/author-loop.d.ts.map +1 -1
  6. package/dist/commands/author-loop.js +6 -2
  7. package/dist/commands/author-loop.js.map +1 -1
  8. package/dist/commands/catalog-data-core.d.ts.map +1 -1
  9. package/dist/commands/catalog-data-core.js +17 -3
  10. package/dist/commands/catalog-data-core.js.map +1 -1
  11. package/dist/commands/catalog-data-resources.js +2 -2
  12. package/dist/commands/catalog-data-resources.js.map +1 -1
  13. package/dist/commands/catalog-dispatch.d.ts.map +1 -1
  14. package/dist/commands/catalog-dispatch.js +21 -2
  15. package/dist/commands/catalog-dispatch.js.map +1 -1
  16. package/dist/commands/catalog-render.d.ts.map +1 -1
  17. package/dist/commands/catalog-render.js +6 -0
  18. package/dist/commands/catalog-render.js.map +1 -1
  19. package/dist/commands/deploy-ops.d.ts.map +1 -1
  20. package/dist/commands/deploy-ops.js +30 -13
  21. package/dist/commands/deploy-ops.js.map +1 -1
  22. package/dist/commands/deploy-status-ops.d.ts +1 -1
  23. package/dist/commands/deploy-status-ops.d.ts.map +1 -1
  24. package/dist/commands/deploy-status-ops.js +8 -4
  25. package/dist/commands/deploy-status-ops.js.map +1 -1
  26. package/dist/commands/devtools.d.ts +11 -0
  27. package/dist/commands/devtools.d.ts.map +1 -0
  28. package/dist/commands/devtools.js +123 -0
  29. package/dist/commands/devtools.js.map +1 -0
  30. package/dist/commands/mcp-apps.d.ts +0 -1
  31. package/dist/commands/mcp-apps.d.ts.map +1 -1
  32. package/dist/commands/mcp-apps.js +71 -122
  33. package/dist/commands/mcp-apps.js.map +1 -1
  34. package/dist/commands/shared.d.ts +6 -0
  35. package/dist/commands/shared.d.ts.map +1 -1
  36. package/dist/commands/shared.js +19 -0
  37. package/dist/commands/shared.js.map +1 -1
  38. package/dist/deploy.d.ts +1 -1
  39. package/dist/deploy.d.ts.map +1 -1
  40. package/dist/deploy.js +5 -1
  41. package/dist/deploy.js.map +1 -1
  42. package/dist/dev.d.ts.map +1 -1
  43. package/dist/dev.js +13 -1
  44. package/dist/dev.js.map +1 -1
  45. package/dist/fire.js +1 -1
  46. package/dist/fire.js.map +1 -1
  47. package/dist/first-run.d.ts +11 -0
  48. package/dist/first-run.d.ts.map +1 -1
  49. package/dist/first-run.js +19 -4
  50. package/dist/first-run.js.map +1 -1
  51. package/dist/flavor.d.ts +1 -1
  52. package/dist/flavor.d.ts.map +1 -1
  53. package/dist/flavor.js +12 -2
  54. package/dist/flavor.js.map +1 -1
  55. package/dist/project-scaffold-templates.d.ts +11 -0
  56. package/dist/project-scaffold-templates.d.ts.map +1 -0
  57. package/dist/project-scaffold-templates.js +359 -0
  58. package/dist/project-scaffold-templates.js.map +1 -0
  59. package/dist/project.d.ts.map +1 -1
  60. package/dist/project.js +1 -323
  61. package/dist/project.js.map +1 -1
  62. package/dist/react.d.ts +2 -2
  63. package/dist/react.d.ts.map +1 -1
  64. package/dist/react.js +1 -1
  65. package/dist/react.js.map +1 -1
  66. package/dist/validate.d.ts +12 -0
  67. package/dist/validate.d.ts.map +1 -1
  68. package/dist/validate.js +11 -0
  69. package/dist/validate.js.map +1 -1
  70. package/node_modules/@noodle-borg/agent-kit/dist/skill-authoring-refs.js +4 -4
  71. package/node_modules/@noodle-borg/agent-kit/dist/skill-authoring-refs.js.map +1 -1
  72. package/node_modules/@noodle-borg/agent-kit/dist/skill-content.d.ts.map +1 -1
  73. package/node_modules/@noodle-borg/agent-kit/dist/skill-content.js +72 -13
  74. package/node_modules/@noodle-borg/agent-kit/dist/skill-content.js.map +1 -1
  75. package/node_modules/@noodle-borg/agent-kit/dist/skill-operations-refs.d.ts.map +1 -1
  76. package/node_modules/@noodle-borg/agent-kit/dist/skill-operations-refs.js +8 -3
  77. package/node_modules/@noodle-borg/agent-kit/dist/skill-operations-refs.js.map +1 -1
  78. package/node_modules/@noodle-borg/agent-kit/package.json +1 -1
  79. package/node_modules/@noodle-borg/authoring/dist/connectors.d.ts +18 -1
  80. package/node_modules/@noodle-borg/authoring/dist/connectors.d.ts.map +1 -1
  81. package/node_modules/@noodle-borg/authoring/dist/connectors.js +17 -4
  82. package/node_modules/@noodle-borg/authoring/dist/connectors.js.map +1 -1
  83. package/node_modules/@noodle-borg/authoring/dist/index.d.ts +3 -3
  84. package/node_modules/@noodle-borg/authoring/dist/index.d.ts.map +1 -1
  85. package/node_modules/@noodle-borg/authoring/dist/index.js +1 -1
  86. package/node_modules/@noodle-borg/authoring/dist/index.js.map +1 -1
  87. package/node_modules/@noodle-borg/authoring/dist/react/components.d.ts +302 -7
  88. package/node_modules/@noodle-borg/authoring/dist/react/components.d.ts.map +1 -1
  89. package/node_modules/@noodle-borg/authoring/dist/react/components.js +39 -7
  90. package/node_modules/@noodle-borg/authoring/dist/react/components.js.map +1 -1
  91. package/node_modules/@noodle-borg/authoring/dist/react/index.d.ts +4 -2
  92. package/node_modules/@noodle-borg/authoring/dist/react/index.d.ts.map +1 -1
  93. package/node_modules/@noodle-borg/authoring/dist/react/index.js +2 -1
  94. package/node_modules/@noodle-borg/authoring/dist/react/index.js.map +1 -1
  95. package/node_modules/@noodle-borg/authoring/dist/react/semantic-components.d.ts +2618 -0
  96. package/node_modules/@noodle-borg/authoring/dist/react/semantic-components.d.ts.map +1 -0
  97. package/node_modules/@noodle-borg/authoring/dist/react/semantic-components.js +110 -0
  98. package/node_modules/@noodle-borg/authoring/dist/react/semantic-components.js.map +1 -0
  99. package/node_modules/@noodle-borg/authoring/dist/react.d.ts +2 -2
  100. package/node_modules/@noodle-borg/authoring/dist/react.d.ts.map +1 -1
  101. package/node_modules/@noodle-borg/authoring/dist/react.js +1 -1
  102. package/node_modules/@noodle-borg/authoring/dist/react.js.map +1 -1
  103. package/node_modules/@noodle-borg/authoring/dist/recording.d.ts +1 -1
  104. package/node_modules/@noodle-borg/authoring/dist/recording.d.ts.map +1 -1
  105. package/node_modules/@noodle-borg/authoring/dist/recording.js +38 -6
  106. package/node_modules/@noodle-borg/authoring/dist/recording.js.map +1 -1
  107. package/node_modules/@noodle-borg/authoring/dist/server.d.ts +25 -2
  108. package/node_modules/@noodle-borg/authoring/dist/server.d.ts.map +1 -1
  109. package/node_modules/@noodle-borg/authoring/dist/server.js +64 -6
  110. package/node_modules/@noodle-borg/authoring/dist/server.js.map +1 -1
  111. package/node_modules/@noodle-borg/compiler/dist/compile.d.ts.map +1 -1
  112. package/node_modules/@noodle-borg/compiler/dist/compile.js +20 -8
  113. package/node_modules/@noodle-borg/compiler/dist/compile.js.map +1 -1
  114. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.d.ts +2 -0
  115. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.d.ts.map +1 -1
  116. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.js +6 -0
  117. package/node_modules/@noodle-borg/compiler/dist/manifest/schema.js.map +1 -1
  118. package/node_modules/@noodle-borg/connector-defs/dist/auth-variables.js +1 -1
  119. package/node_modules/@noodle-borg/connector-defs/dist/auth-variables.js.map +1 -1
  120. package/node_modules/@noodle-borg/connector-defs/dist/call-graph.d.ts +14 -0
  121. package/node_modules/@noodle-borg/connector-defs/dist/call-graph.d.ts.map +1 -0
  122. package/node_modules/@noodle-borg/connector-defs/dist/call-graph.js +66 -0
  123. package/node_modules/@noodle-borg/connector-defs/dist/call-graph.js.map +1 -0
  124. package/node_modules/@noodle-borg/connector-defs/dist/compile-auth.d.ts +21 -0
  125. package/node_modules/@noodle-borg/connector-defs/dist/compile-auth.d.ts.map +1 -0
  126. package/node_modules/@noodle-borg/connector-defs/dist/compile-auth.js +102 -0
  127. package/node_modules/@noodle-borg/connector-defs/dist/compile-auth.js.map +1 -0
  128. package/node_modules/@noodle-borg/connector-defs/dist/compile.d.ts +19 -4
  129. package/node_modules/@noodle-borg/connector-defs/dist/compile.d.ts.map +1 -1
  130. package/node_modules/@noodle-borg/connector-defs/dist/compile.js +67 -99
  131. package/node_modules/@noodle-borg/connector-defs/dist/compile.js.map +1 -1
  132. package/node_modules/@noodle-borg/connector-defs/dist/index.d.ts +1 -1
  133. package/node_modules/@noodle-borg/connector-defs/dist/index.d.ts.map +1 -1
  134. package/node_modules/@noodle-borg/connector-defs/dist/index.js.map +1 -1
  135. package/node_modules/@noodle-borg/connector-defs/dist/schema.d.ts +168 -10
  136. package/node_modules/@noodle-borg/connector-defs/dist/schema.d.ts.map +1 -1
  137. package/node_modules/@noodle-borg/connector-defs/dist/schema.js +72 -5
  138. package/node_modules/@noodle-borg/connector-defs/dist/schema.js.map +1 -1
  139. package/node_modules/@noodle-borg/connector-http/dist/http-connector.d.ts +6 -0
  140. package/node_modules/@noodle-borg/connector-http/dist/http-connector.d.ts.map +1 -1
  141. package/node_modules/@noodle-borg/connector-http/dist/http-connector.js +2 -0
  142. package/node_modules/@noodle-borg/connector-http/dist/http-connector.js.map +1 -1
  143. package/node_modules/@noodle-borg/connector-http/package.json +1 -1
  144. package/node_modules/@noodle-borg/protocol/dist/mapping.d.ts.map +1 -1
  145. package/node_modules/@noodle-borg/protocol/dist/mapping.js +8 -0
  146. package/node_modules/@noodle-borg/protocol/dist/mapping.js.map +1 -1
  147. package/node_modules/@noodle-borg/runtime/dist/execute.d.ts.map +1 -1
  148. package/node_modules/@noodle-borg/runtime/dist/execute.js +87 -62
  149. package/node_modules/@noodle-borg/runtime/dist/execute.js.map +1 -1
  150. package/node_modules/@noodle-borg/runtime/dist/result.d.ts +1 -1
  151. package/node_modules/@noodle-borg/runtime/dist/result.d.ts.map +1 -1
  152. package/node_modules/@noodle-borg/service/dist/credential-broker.d.ts.map +1 -1
  153. package/node_modules/@noodle-borg/service/dist/credential-broker.js +113 -11
  154. package/node_modules/@noodle-borg/service/dist/credential-broker.js.map +1 -1
  155. package/node_modules/@noodle-borg/service/dist/github/app-client.d.ts +28 -5
  156. package/node_modules/@noodle-borg/service/dist/github/app-client.d.ts.map +1 -1
  157. package/node_modules/@noodle-borg/service/dist/github/app-client.js +116 -7
  158. package/node_modules/@noodle-borg/service/dist/github/app-client.js.map +1 -1
  159. package/node_modules/@noodle-borg/service/dist/github/builder-auth.d.ts +12 -0
  160. package/node_modules/@noodle-borg/service/dist/github/builder-auth.d.ts.map +1 -0
  161. package/node_modules/@noodle-borg/service/dist/github/builder-auth.js +15 -0
  162. package/node_modules/@noodle-borg/service/dist/github/builder-auth.js.map +1 -0
  163. package/node_modules/@noodle-borg/service/dist/github/builder-main.d.ts +3 -0
  164. package/node_modules/@noodle-borg/service/dist/github/builder-main.d.ts.map +1 -0
  165. package/node_modules/@noodle-borg/service/dist/github/builder-main.js +9 -0
  166. package/node_modules/@noodle-borg/service/dist/github/builder-main.js.map +1 -0
  167. package/node_modules/@noodle-borg/service/dist/github/builder-runner.d.ts +21 -0
  168. package/node_modules/@noodle-borg/service/dist/github/builder-runner.d.ts.map +1 -0
  169. package/node_modules/@noodle-borg/service/dist/github/builder-runner.js +192 -0
  170. package/node_modules/@noodle-borg/service/dist/github/builder-runner.js.map +1 -0
  171. package/node_modules/@noodle-borg/service/dist/github/cloud-run-job-executor.d.ts +45 -0
  172. package/node_modules/@noodle-borg/service/dist/github/cloud-run-job-executor.d.ts.map +1 -0
  173. package/node_modules/@noodle-borg/service/dist/github/cloud-run-job-executor.js +60 -0
  174. package/node_modules/@noodle-borg/service/dist/github/cloud-run-job-executor.js.map +1 -0
  175. package/node_modules/@noodle-borg/service/dist/github/deploy-pipeline.d.ts +64 -0
  176. package/node_modules/@noodle-borg/service/dist/github/deploy-pipeline.d.ts.map +1 -0
  177. package/node_modules/@noodle-borg/service/dist/github/deploy-pipeline.js +121 -0
  178. package/node_modules/@noodle-borg/service/dist/github/deploy-pipeline.js.map +1 -0
  179. package/node_modules/@noodle-borg/service/dist/github/deploy-run-executor.d.ts +33 -0
  180. package/node_modules/@noodle-borg/service/dist/github/deploy-run-executor.d.ts.map +1 -0
  181. package/node_modules/@noodle-borg/service/dist/github/deploy-run-executor.js +14 -0
  182. package/node_modules/@noodle-borg/service/dist/github/deploy-run-executor.js.map +1 -0
  183. package/node_modules/@noodle-borg/service/dist/github/deploy-run-reconciler.d.ts +36 -0
  184. package/node_modules/@noodle-borg/service/dist/github/deploy-run-reconciler.d.ts.map +1 -0
  185. package/node_modules/@noodle-borg/service/dist/github/deploy-run-reconciler.js +107 -0
  186. package/node_modules/@noodle-borg/service/dist/github/deploy-run-reconciler.js.map +1 -0
  187. package/node_modules/@noodle-borg/service/dist/github/fast-lane-classifier.d.ts +38 -0
  188. package/node_modules/@noodle-borg/service/dist/github/fast-lane-classifier.d.ts.map +1 -0
  189. package/node_modules/@noodle-borg/service/dist/github/fast-lane-classifier.js +60 -0
  190. package/node_modules/@noodle-borg/service/dist/github/fast-lane-classifier.js.map +1 -0
  191. package/node_modules/@noodle-borg/service/dist/github/local-compile.d.ts +24 -0
  192. package/node_modules/@noodle-borg/service/dist/github/local-compile.d.ts.map +1 -0
  193. package/node_modules/@noodle-borg/service/dist/github/local-compile.js +98 -0
  194. package/node_modules/@noodle-borg/service/dist/github/local-compile.js.map +1 -0
  195. package/node_modules/@noodle-borg/service/dist/github/local-process-executor.d.ts +39 -0
  196. package/node_modules/@noodle-borg/service/dist/github/local-process-executor.d.ts.map +1 -0
  197. package/node_modules/@noodle-borg/service/dist/github/local-process-executor.js +67 -0
  198. package/node_modules/@noodle-borg/service/dist/github/local-process-executor.js.map +1 -0
  199. package/node_modules/@noodle-borg/service/dist/github/run-access-mode.d.ts +18 -0
  200. package/node_modules/@noodle-borg/service/dist/github/run-access-mode.d.ts.map +1 -0
  201. package/node_modules/@noodle-borg/service/dist/github/run-access-mode.js +32 -0
  202. package/node_modules/@noodle-borg/service/dist/github/run-access-mode.js.map +1 -0
  203. package/node_modules/@noodle-borg/service/dist/github/run-token.d.ts +41 -0
  204. package/node_modules/@noodle-borg/service/dist/github/run-token.d.ts.map +1 -0
  205. package/node_modules/@noodle-borg/service/dist/github/run-token.js +59 -0
  206. package/node_modules/@noodle-borg/service/dist/github/run-token.js.map +1 -0
  207. package/node_modules/@noodle-borg/service/dist/http-util.d.ts +7 -1
  208. package/node_modules/@noodle-borg/service/dist/http-util.d.ts.map +1 -1
  209. package/node_modules/@noodle-borg/service/dist/http-util.js +14 -0
  210. package/node_modules/@noodle-borg/service/dist/http-util.js.map +1 -1
  211. package/node_modules/@noodle-borg/service/dist/index.d.ts +13 -2
  212. package/node_modules/@noodle-borg/service/dist/index.d.ts.map +1 -1
  213. package/node_modules/@noodle-borg/service/dist/index.js +12 -1
  214. package/node_modules/@noodle-borg/service/dist/index.js.map +1 -1
  215. package/node_modules/@noodle-borg/service/dist/main.js +72 -0
  216. package/node_modules/@noodle-borg/service/dist/main.js.map +1 -1
  217. package/node_modules/@noodle-borg/service/dist/options.d.ts +26 -3
  218. package/node_modules/@noodle-borg/service/dist/options.d.ts.map +1 -1
  219. package/node_modules/@noodle-borg/service/dist/registry-helpers.d.ts +12 -0
  220. package/node_modules/@noodle-borg/service/dist/registry-helpers.d.ts.map +1 -1
  221. package/node_modules/@noodle-borg/service/dist/registry-helpers.js +3 -0
  222. package/node_modules/@noodle-borg/service/dist/registry-helpers.js.map +1 -1
  223. package/node_modules/@noodle-borg/service/dist/registry-types.d.ts +7 -0
  224. package/node_modules/@noodle-borg/service/dist/registry-types.d.ts.map +1 -1
  225. package/node_modules/@noodle-borg/service/dist/registry.d.ts +7 -29
  226. package/node_modules/@noodle-borg/service/dist/registry.d.ts.map +1 -1
  227. package/node_modules/@noodle-borg/service/dist/registry.js +62 -57
  228. package/node_modules/@noodle-borg/service/dist/registry.js.map +1 -1
  229. package/node_modules/@noodle-borg/service/dist/routes/asset-control-plane.d.ts +3 -2
  230. package/node_modules/@noodle-borg/service/dist/routes/asset-control-plane.d.ts.map +1 -1
  231. package/node_modules/@noodle-borg/service/dist/routes/asset-control-plane.js +36 -8
  232. package/node_modules/@noodle-borg/service/dist/routes/asset-control-plane.js.map +1 -1
  233. package/node_modules/@noodle-borg/service/dist/routes/control-plane.d.ts +3 -2
  234. package/node_modules/@noodle-borg/service/dist/routes/control-plane.d.ts.map +1 -1
  235. package/node_modules/@noodle-borg/service/dist/routes/control-plane.js +100 -12
  236. package/node_modules/@noodle-borg/service/dist/routes/control-plane.js.map +1 -1
  237. package/node_modules/@noodle-borg/service/dist/routes/github-dispatch.d.ts +7 -0
  238. package/node_modules/@noodle-borg/service/dist/routes/github-dispatch.d.ts.map +1 -1
  239. package/node_modules/@noodle-borg/service/dist/routes/github-dispatch.js +36 -1
  240. package/node_modules/@noodle-borg/service/dist/routes/github-dispatch.js.map +1 -1
  241. package/node_modules/@noodle-borg/service/dist/routes/github-run-claim.d.ts +13 -0
  242. package/node_modules/@noodle-borg/service/dist/routes/github-run-claim.d.ts.map +1 -0
  243. package/node_modules/@noodle-borg/service/dist/routes/github-run-claim.js +84 -0
  244. package/node_modules/@noodle-borg/service/dist/routes/github-run-claim.js.map +1 -0
  245. package/node_modules/@noodle-borg/service/dist/routes/github-run-status.d.ts +5 -0
  246. package/node_modules/@noodle-borg/service/dist/routes/github-run-status.d.ts.map +1 -0
  247. package/node_modules/@noodle-borg/service/dist/routes/github-run-status.js +73 -0
  248. package/node_modules/@noodle-borg/service/dist/routes/github-run-status.js.map +1 -0
  249. package/node_modules/@noodle-borg/service/dist/routes/github-webhook.d.ts +23 -1
  250. package/node_modules/@noodle-borg/service/dist/routes/github-webhook.d.ts.map +1 -1
  251. package/node_modules/@noodle-borg/service/dist/routes/github-webhook.js +41 -0
  252. package/node_modules/@noodle-borg/service/dist/routes/github-webhook.js.map +1 -1
  253. package/node_modules/@noodle-borg/service/dist/routes/paths.d.ts +4 -0
  254. package/node_modules/@noodle-borg/service/dist/routes/paths.d.ts.map +1 -1
  255. package/node_modules/@noodle-borg/service/dist/routes/paths.js +10 -0
  256. package/node_modules/@noodle-borg/service/dist/routes/paths.js.map +1 -1
  257. package/node_modules/@noodle-borg/service/dist/routes/run-deploy-auth.d.ts +85 -0
  258. package/node_modules/@noodle-borg/service/dist/routes/run-deploy-auth.d.ts.map +1 -0
  259. package/node_modules/@noodle-borg/service/dist/routes/run-deploy-auth.js +90 -0
  260. package/node_modules/@noodle-borg/service/dist/routes/run-deploy-auth.js.map +1 -0
  261. package/node_modules/@noodle-borg/service/dist/serve.d.ts.map +1 -1
  262. package/node_modules/@noodle-borg/service/dist/serve.js +31 -0
  263. package/node_modules/@noodle-borg/service/dist/serve.js.map +1 -1
  264. package/node_modules/@noodle-borg/service/dist/service.d.ts.map +1 -1
  265. package/node_modules/@noodle-borg/service/dist/service.js +8 -13
  266. package/node_modules/@noodle-borg/service/dist/service.js.map +1 -1
  267. package/node_modules/@noodle-borg/service/dist/store/github-connections-json-file.d.ts +1 -0
  268. package/node_modules/@noodle-borg/service/dist/store/github-connections-json-file.d.ts.map +1 -1
  269. package/node_modules/@noodle-borg/service/dist/store/github-connections-json-file.js +5 -0
  270. package/node_modules/@noodle-borg/service/dist/store/github-connections-json-file.js.map +1 -1
  271. package/node_modules/@noodle-borg/service/dist/store/github-connections.d.ts +1 -0
  272. package/node_modules/@noodle-borg/service/dist/store/github-connections.d.ts.map +1 -1
  273. package/node_modules/@noodle-borg/service/dist/store/github-connections.js +5 -0
  274. package/node_modules/@noodle-borg/service/dist/store/github-connections.js.map +1 -1
  275. package/node_modules/@noodle-borg/service/dist/store/github-deploy-run-contract.d.ts +120 -0
  276. package/node_modules/@noodle-borg/service/dist/store/github-deploy-run-contract.d.ts.map +1 -0
  277. package/node_modules/@noodle-borg/service/dist/store/github-deploy-run-contract.js +6 -0
  278. package/node_modules/@noodle-borg/service/dist/store/github-deploy-run-contract.js.map +1 -0
  279. package/node_modules/@noodle-borg/service/dist/store/github-runs-json-file.d.ts +6 -1
  280. package/node_modules/@noodle-borg/service/dist/store/github-runs-json-file.d.ts.map +1 -1
  281. package/node_modules/@noodle-borg/service/dist/store/github-runs-json-file.js +18 -1
  282. package/node_modules/@noodle-borg/service/dist/store/github-runs-json-file.js.map +1 -1
  283. package/node_modules/@noodle-borg/service/dist/store/github-runs.d.ts +22 -1
  284. package/node_modules/@noodle-borg/service/dist/store/github-runs.d.ts.map +1 -1
  285. package/node_modules/@noodle-borg/service/dist/store/github-runs.js +39 -2
  286. package/node_modules/@noodle-borg/service/dist/store/github-runs.js.map +1 -1
  287. package/node_modules/@noodle-borg/service/dist/store/postgres-github-runs.d.ts +13 -1
  288. package/node_modules/@noodle-borg/service/dist/store/postgres-github-runs.d.ts.map +1 -1
  289. package/node_modules/@noodle-borg/service/dist/store/postgres-github-runs.js +115 -1
  290. package/node_modules/@noodle-borg/service/dist/store/postgres-github-runs.js.map +1 -1
  291. package/node_modules/@noodle-borg/service/dist/store/postgres-github.d.ts +1 -0
  292. package/node_modules/@noodle-borg/service/dist/store/postgres-github.d.ts.map +1 -1
  293. package/node_modules/@noodle-borg/service/dist/store/postgres-github.js +6 -0
  294. package/node_modules/@noodle-borg/service/dist/store/postgres-github.js.map +1 -1
  295. package/node_modules/@noodle-borg/service/dist/store/postgres.d.ts +15 -1
  296. package/node_modules/@noodle-borg/service/dist/store/postgres.d.ts.map +1 -1
  297. package/node_modules/@noodle-borg/service/dist/store/postgres.js +22 -2
  298. package/node_modules/@noodle-borg/service/dist/store/postgres.js.map +1 -1
  299. package/node_modules/@noodle-borg/service/dist/store.d.ts +22 -99
  300. package/node_modules/@noodle-borg/service/dist/store.d.ts.map +1 -1
  301. package/node_modules/@noodle-borg/service/dist/store.js.map +1 -1
  302. package/node_modules/hono/dist/adapter/aws-lambda/handler.js +15 -21
  303. package/node_modules/hono/dist/adapter/bun/websocket.js +3 -1
  304. package/node_modules/hono/dist/adapter/lambda-edge/handler.js +8 -2
  305. package/node_modules/hono/dist/cjs/adapter/aws-lambda/handler.js +15 -21
  306. package/node_modules/hono/dist/cjs/adapter/bun/websocket.js +3 -1
  307. package/node_modules/hono/dist/cjs/adapter/lambda-edge/handler.js +8 -2
  308. package/node_modules/hono/dist/cjs/helper/css/common.js +3 -1
  309. package/node_modules/hono/dist/cjs/helper/css/index.js +9 -1
  310. package/node_modules/hono/dist/cjs/jsx/base.js +8 -14
  311. package/node_modules/hono/dist/cjs/jsx/components.js +41 -21
  312. package/node_modules/hono/dist/cjs/jsx/context.js +131 -5
  313. package/node_modules/hono/dist/cjs/jsx/streaming.js +9 -7
  314. package/node_modules/hono/dist/cjs/middleware/cors/index.js +2 -5
  315. package/node_modules/hono/dist/cjs/middleware/serve-static/index.js +2 -2
  316. package/node_modules/hono/dist/cjs/utils/body.js +12 -4
  317. package/node_modules/hono/dist/cjs/utils/buffer.js +2 -1
  318. package/node_modules/hono/dist/cjs/validator/validator.js +3 -3
  319. package/node_modules/hono/dist/helper/css/common.js +3 -1
  320. package/node_modules/hono/dist/helper/css/index.js +9 -1
  321. package/node_modules/hono/dist/jsx/base.js +15 -15
  322. package/node_modules/hono/dist/jsx/components.js +42 -22
  323. package/node_modules/hono/dist/jsx/context.js +129 -5
  324. package/node_modules/hono/dist/jsx/streaming.js +10 -8
  325. package/node_modules/hono/dist/middleware/cors/index.js +2 -5
  326. package/node_modules/hono/dist/middleware/serve-static/index.js +2 -2
  327. package/node_modules/hono/dist/types/adapter/aws-lambda/handler.d.ts +1 -1
  328. package/node_modules/hono/dist/types/jsx/base.d.ts +1 -3
  329. package/node_modules/hono/dist/types/jsx/context.d.ts +39 -0
  330. package/node_modules/hono/dist/types/middleware/context-storage/index.d.ts +2 -2
  331. package/node_modules/hono/dist/types/utils/body.d.ts +1 -1
  332. package/node_modules/hono/dist/utils/body.js +12 -4
  333. package/node_modules/hono/dist/utils/buffer.js +2 -1
  334. package/node_modules/hono/dist/validator/validator.js +3 -3
  335. package/node_modules/hono/package.json +9 -10
  336. package/node_modules/tailwindcss/dist/chunk-HMCCH6MG.mjs +1 -0
  337. package/node_modules/tailwindcss/dist/default-theme.mjs +1 -1
  338. package/node_modules/tailwindcss/dist/lib.js +13 -13
  339. package/node_modules/tailwindcss/dist/lib.mjs +18 -18
  340. package/node_modules/tailwindcss/package.json +2 -2
  341. package/node_modules/undici/README.md +3 -2
  342. package/node_modules/undici/docs/docs/api/Agent.md +248 -44
  343. package/node_modules/undici/docs/docs/api/BalancedPool.md +246 -48
  344. package/node_modules/undici/docs/docs/api/CacheStorage.md +171 -13
  345. package/node_modules/undici/docs/docs/api/CacheStore.md +294 -98
  346. package/node_modules/undici/docs/docs/api/Client.md +365 -178
  347. package/node_modules/undici/docs/docs/api/ClientStats.md +80 -14
  348. package/node_modules/undici/docs/docs/api/Connector.md +118 -36
  349. package/node_modules/undici/docs/docs/api/ContentType.md +65 -25
  350. package/node_modules/undici/docs/docs/api/Cookies.md +125 -47
  351. package/node_modules/undici/docs/docs/api/Debug.md +34 -18
  352. package/node_modules/undici/docs/docs/api/DiagnosticsChannel.md +364 -164
  353. package/node_modules/undici/docs/docs/api/Dispatcher.md +479 -1093
  354. package/node_modules/undici/docs/docs/api/EnvHttpProxyAgent.md +101 -87
  355. package/node_modules/undici/docs/docs/api/Errors.md +503 -40
  356. package/node_modules/undici/docs/docs/api/EventSource.md +294 -32
  357. package/node_modules/undici/docs/docs/api/Fetch.md +680 -31
  358. package/node_modules/undici/docs/docs/api/GlobalInstallation.md +78 -98
  359. package/node_modules/undici/docs/docs/api/H2CClient.md +298 -176
  360. package/node_modules/undici/docs/docs/api/Interceptors.md +355 -0
  361. package/node_modules/undici/docs/docs/api/MockAgent.md +314 -322
  362. package/node_modules/undici/docs/docs/api/MockCallHistory.md +272 -98
  363. package/node_modules/undici/docs/docs/api/MockCallHistoryLog.md +189 -26
  364. package/node_modules/undici/docs/docs/api/MockClient.md +151 -33
  365. package/node_modules/undici/docs/docs/api/MockErrors.md +56 -5
  366. package/node_modules/undici/docs/docs/api/MockPool.md +299 -263
  367. package/node_modules/undici/docs/docs/api/Pool.md +235 -43
  368. package/node_modules/undici/docs/docs/api/PoolStats.md +119 -13
  369. package/node_modules/undici/docs/docs/api/ProxyAgent.md +179 -160
  370. package/node_modules/undici/docs/docs/api/RedirectHandler.md +238 -63
  371. package/node_modules/undici/docs/docs/api/RetryAgent.md +113 -26
  372. package/node_modules/undici/docs/docs/api/RetryHandler.md +161 -77
  373. package/node_modules/undici/docs/docs/api/RoundRobinPool.md +166 -72
  374. package/node_modules/undici/docs/docs/api/SnapshotAgent.md +264 -542
  375. package/node_modules/undici/docs/docs/api/Socks5ProxyAgent.md +162 -186
  376. package/node_modules/undici/docs/docs/api/Util.md +68 -11
  377. package/node_modules/undici/docs/docs/api/WebSocket.md +475 -80
  378. package/node_modules/undici/docs/docs/api/api-lifecycle.md +100 -32
  379. package/node_modules/undici/docs/docs/best-practices/client-certificate.md +2 -0
  380. package/node_modules/undici/docs/docs/best-practices/crawling.md +3 -1
  381. package/node_modules/undici/docs/docs/best-practices/migrating-from-v7-to-v8.md +6 -4
  382. package/node_modules/undici/docs/docs/best-practices/mocking-request.md +9 -7
  383. package/node_modules/undici/docs/docs/best-practices/proxy.md +3 -1
  384. package/node_modules/undici/docs/docs/best-practices/undici-vs-builtin-fetch.md +10 -8
  385. package/node_modules/undici/docs/docs/best-practices/writing-tests.md +2 -0
  386. package/node_modules/undici/docs/docs/{GettingStarted.md → getting-started.md} +22 -19
  387. package/node_modules/undici/docs/docs/index.md +779 -0
  388. package/node_modules/undici/docs/docs/site.json +125 -0
  389. package/node_modules/undici/docs/docs/type-map.json +79 -0
  390. package/node_modules/undici/lib/api/api-request.js +7 -1
  391. package/node_modules/undici/lib/api/readable.js +47 -2
  392. package/node_modules/undici/lib/core/errors.js +20 -0
  393. package/node_modules/undici/lib/core/request.js +1 -1
  394. package/node_modules/undici/lib/core/util.js +24 -1
  395. package/node_modules/undici/lib/dispatcher/client-h1.js +92 -1
  396. package/node_modules/undici/lib/dispatcher/client-h2.js +322 -118
  397. package/node_modules/undici/lib/dispatcher/client.js +6 -2
  398. package/node_modules/undici/lib/dispatcher/dispatcher-base.js +1 -0
  399. package/node_modules/undici/lib/dispatcher/proxy-agent.js +42 -7
  400. package/node_modules/undici/lib/dispatcher/socks5-proxy-agent.js +4 -2
  401. package/node_modules/undici/lib/handler/redirect-handler.js +1 -0
  402. package/node_modules/undici/lib/handler/retry-handler.js +57 -19
  403. package/node_modules/undici/lib/util/cache.js +8 -2
  404. package/node_modules/undici/lib/web/cookies/parse.js +20 -27
  405. package/node_modules/undici/lib/web/cookies/util.js +1 -1
  406. package/node_modules/undici/lib/web/eventsource/eventsource.js +7 -18
  407. package/node_modules/undici/lib/web/eventsource/util.js +32 -1
  408. package/node_modules/undici/lib/web/fetch/body.js +43 -0
  409. package/node_modules/undici/lib/web/fetch/constants.js +1 -1
  410. package/node_modules/undici/lib/web/fetch/index.js +11 -2
  411. package/node_modules/undici/lib/web/fetch/request.js +1 -0
  412. package/node_modules/undici/lib/web/fetch/util.js +4 -1
  413. package/node_modules/undici/lib/web/websocket/receiver.js +20 -3
  414. package/node_modules/undici/lib/web/websocket/stream/websocketstream.js +8 -1
  415. package/node_modules/undici/lib/web/websocket/websocket.js +3 -1
  416. package/node_modules/undici/package.json +1 -1
  417. package/node_modules/undici/types/client.d.ts +6 -1
  418. package/node_modules/undici/types/cookies.d.ts +1 -1
  419. package/node_modules/undici/types/errors.d.ts +10 -0
  420. package/node_modules/undici/types/fetch.d.ts +1 -0
  421. package/node_modules/undici/types/handlers.d.ts +2 -0
  422. package/node_modules/undici/types/proxy-agent.d.ts +7 -0
  423. package/package.json +4 -4
  424. package/react/styles.css +510 -5
  425. package/react/styles.source.css +850 -0
  426. package/node_modules/hono/dist/tsconfig.build.tsbuildinfo +0 -1
  427. package/node_modules/tailwindcss/dist/chunk-XVOTX5KS.mjs +0 -1
@@ -1,102 +1,168 @@
1
- # Class: Client
2
-
3
- Extends: `undici.Dispatcher`
4
-
5
- A basic HTTP/1.1 client, mapped on top a single TCP/TLS connection. Pipelining is disabled by default.
6
-
7
- Requests are not guaranteed to be dispatched in order of invocation.
8
-
9
- ## `new Client(url[, options])`
10
-
11
- Arguments:
12
-
13
- * **url** `URL | string` - Should only include the **protocol, hostname, and port**.
14
- * **options** `ClientOptions` (optional)
15
-
16
- Returns: `Client`
17
-
18
- ### Parameter: `ClientOptions`
19
-
20
- * **bodyTimeout** `number | null` (optional) - Default: `300e3` - The timeout after which a request will time out, in milliseconds. Monitors time between receiving body data. Use `0` to disable it entirely. Defaults to 300 seconds. Please note the `timeout` will be reset if you keep writing data to the socket everytime.
21
- * **headersTimeout** `number | null` (optional) - Default: `300e3` - The amount of time, in milliseconds, the parser will wait to receive the complete HTTP headers while not sending the request. Defaults to 300 seconds.
22
- * **keepAliveMaxTimeout** `number | null` (optional) - Default: `600e3` - The maximum allowed `keepAliveTimeout`, in milliseconds, when overridden by *keep-alive* hints from the server. Defaults to 10 minutes.
23
- * **keepAliveTimeout** `number | null` (optional) - Default: `4e3` - The timeout, in milliseconds, after which a socket without active requests will time out. Monitors time between activity on a connected socket. This value may be overridden by *keep-alive* hints from the server. See [MDN: HTTP - Headers - Keep-Alive directives](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Keep-Alive#directives) for more details. Defaults to 4 seconds.
24
- * **keepAliveTimeoutThreshold** `number | null` (optional) - Default: `2e3` - A number of milliseconds subtracted from server *keep-alive* hints when overriding `keepAliveTimeout` to account for timing inaccuracies caused by e.g. transport latency. Defaults to 2 seconds.
25
- * **maxHeaderSize** `number | null` (optional) - Default: `--max-http-header-size` or `16384` - The maximum length of request headers in bytes. Defaults to Node.js' --max-http-header-size or 16KiB.
26
- * **maxResponseSize** `number | null` (optional) - Default: `-1` - The maximum length of response body in bytes. Set to `-1` to disable.
27
- * **webSocket** `WebSocketOptions` (optional) - WebSocket-specific configuration options.
28
- * **maxPayloadSize** `number` (optional) - Default: `134217728` (128 MB) - Maximum allowed payload size in bytes for WebSocket messages. Applied to uncompressed messages, compressed frame payloads, and decompressed (permessage-deflate) messages. Set to 0 to disable the limit.
29
- * **pipelining** `number | null` (optional) - Default: `1` - The amount of concurrent requests to be sent over the single TCP/TLS connection according to [RFC7230](https://tools.ietf.org/html/rfc7230#section-6.3.2). Carefully consider your workload and environment before enabling concurrent requests as pipelining may reduce performance if used incorrectly. Pipelining is sensitive to network stack settings as well as head of line blocking caused by e.g. long running requests. Set to `0` to disable keep-alive connections. This option has no effect once HTTP/2 is negotiated — see `maxConcurrentStreams` for the h2 dispatch ceiling.
30
- * **connect** `ConnectOptions | Function | null` (optional) - Default: `null` - Configures how undici establishes TCP/TLS connections. Accepts two forms:
31
- * **Object (`ConnectOptions`)**: Options passed directly to the internal [`buildConnector()`](/docs/docs/api/Connector.md). This is the simplest way to customize TLS or socket behavior (e.g., setting `rejectUnauthorized`, `ca`, `socketPath`). See [`ConnectOptions`](#parameter-connectoptions) for available fields.
32
- * **Function**: A custom connector with the signature `(options, callback)`, where `options` contains `{ hostname, host, protocol, port, servername, localAddress, httpSocket }` and `callback` follows `(error, socket)`. Useful when you need full control over socket creation, such as adding custom validation or proxy logic. When a function is provided, undici wraps it to automatically inject `socketPath` and `allowH2` into the `options` argument if those values are set on the client.
33
- * **strictContentLength** `Boolean` (optional) - Default: `true` - Whether to treat request content length mismatches as errors. If true, an error is thrown when the request content-length header doesn't match the length of the request body. **Security Warning:** Disabling this option can expose your application to HTTP Request Smuggling attacks, where mismatched content-length headers cause servers and proxies to interpret request boundaries differently. This can lead to cache poisoning, credential hijacking, and bypassing security controls. Only disable this in controlled environments where you fully trust the request source.
34
- * **autoSelectFamily**: `boolean` (optional) - Default: depends on local Node version, on Node 18.13.0 and above is `false`. Enables a family autodetection algorithm that loosely implements section 5 of [RFC 8305](https://tools.ietf.org/html/rfc8305#section-5). See [here](https://nodejs.org/api/net.html#socketconnectoptions-connectlistener) for more details. This option is ignored if not supported by the current Node version.
35
- * **autoSelectFamilyAttemptTimeout**: `number` - Default: depends on local Node version, on Node 18.13.0 and above is `250`. The amount of time in milliseconds to wait for a connection attempt to finish before trying the next address when using the `autoSelectFamily` option. See [here](https://nodejs.org/api/net.html#socketconnectoptions-connectlistener) for more details.
36
- * **allowH2**: `boolean` - Default: `true`. Enables support for H2 if the server has assigned bigger priority to it through ALPN negotiation.
37
- * **useH2c**: `boolean` - Default: `false`. Enforces h2c for non-https connections.
38
- * **maxConcurrentStreams**: `number` - Default: `100`. The maximum number of concurrent HTTP/2 streams per session. When `allowH2` negotiates h2, this — not `pipelining` (which is HTTP/1.1 only, per [RFC7230](https://tools.ietf.org/html/rfc7230#section-6.3.2)) — is the ceiling the Client uses to dispatch in-flight requests on a shared session. The same value is advertised to the server as `peerMaxConcurrentStreams`, capping how many streams the server may push back. The initial value is replaced by the server's `SETTINGS_MAX_CONCURRENT_STREAMS` whenever the server sends one, so a user-supplied value acts as a pre-`SETTINGS` default rather than a hard cap.
39
- * **initialWindowSize**: `number` (optional) - Default: `262144` (256KB). Sets the HTTP/2 stream-level flow-control window size (SETTINGS_INITIAL_WINDOW_SIZE). Must be a positive integer greater than 0. This default is higher than Node.js core's default (65535 bytes) to improve throughput, Node's choice is very conservative for current high-bandwith networks. See [RFC 7540 Section 6.9.2](https://datatracker.ietf.org/doc/html/rfc7540#section-6.9.2) for more details.
40
- * **connectionWindowSize**: `number` (optional) - Default `524288` (512KB). Sets the HTTP/2 connection-level flow-control window size using `ClientHttp2Session.setLocalWindowSize()`. Must be a positive integer greater than 0. This provides better flow control for the entire connection across multiple streams. See [Node.js HTTP/2 documentation](https://nodejs.org/api/http2.html#clienthttp2sessionsetlocalwindowsize) for more details.
41
- * **pingInterval**: `number` - Default: `60e3`. The time interval in milliseconds between PING frames sent to the server. Set to `0` to disable PING frames. This is only applicable for HTTP/2 connections. This will emit a `ping` event on the client with the duration of the ping in milliseconds.
42
-
43
- > **Notes about HTTP/2**
44
- > - It only works under TLS connections. h2c is not supported.
45
- > - The server must support HTTP/2 and choose it as the protocol during the ALPN negotiation.
46
- > - The server must not have a bigger priority for HTTP/1.1 than HTTP/2.
47
- > - Pseudo headers are automatically attached to the request. If you try to set them, they will be overwritten.
48
- > - The `:path` header is automatically set to the request path.
49
- > - The `:method` header is automatically set to the request method.
50
- > - The `:scheme` header is automatically set to the request scheme.
51
- > - The `:authority` header is automatically set to the request `host[:port]`.
52
- > - `PUSH` frames are yet not supported.
53
-
54
- #### Parameter: `ConnectOptions`
55
-
56
- Every Tls option, see [here](https://nodejs.org/api/tls.html#tls_tls_connect_options_callback).
57
- Furthermore, the following options can be passed:
58
-
59
- * **socketPath** `string | null` (optional) - Default: `null` - An IPC endpoint, either Unix domain socket or Windows named pipe.
60
- * **maxCachedSessions** `number | null` (optional) - Default: `100` - Maximum number of TLS cached sessions. Use 0 to disable TLS session caching. Default: 100.
61
- * **timeout** `number | null` (optional) - In milliseconds, Default `10e3`.
62
- * **servername** `string | null` (optional)
63
- * **keepAlive** `boolean | null` (optional) - Default: `true` - TCP keep-alive enabled
64
- * **keepAliveInitialDelay** `number | null` (optional) - Default: `60000` - TCP keep-alive interval for the socket in milliseconds
65
-
66
- ### Example - Basic Client instantiation
67
-
68
- This will instantiate the undici Client, but it will not connect to the origin until something is queued. Consider using `client.connect` to prematurely connect to the origin, or just call `client.request`.
69
-
70
- ```js
71
- 'use strict'
1
+ # Client
2
+
3
+ <!--introduced_in=v1.0.0-->
4
+
5
+ <!--type=module-->
6
+
7
+ <!-- source_link=lib/dispatcher/client.js -->
8
+
9
+ > Stability: 2 - Stable
10
+
11
+ A basic HTTP/1.1 client mapped on top of a single TCP/TLS connection. When the
12
+ server supports HTTP/2 and selects it during ALPN negotiation, the same
13
+ connection is used for HTTP/2. Pipelining is disabled by default.
14
+
15
+ `Client` extends [`Dispatcher`][] and is the lowest-level dispatcher in undici:
16
+ it manages exactly one origin over one connection. For pooling across multiple
17
+ connections use [`Pool`][], and for routing across multiple origins use
18
+ [`Agent`][]. Requests are not guaranteed to be dispatched in the order in which
19
+ they are invoked.
20
+
21
+ ```mjs
72
22
  import { Client } from 'undici'
73
23
 
74
24
  const client = new Client('http://localhost:3000')
25
+ const { statusCode, body } = await client.request({ path: '/', method: 'GET' })
75
26
  ```
76
27
 
77
- ### Example - Connect with TLS options (object form)
28
+ ## Class: `Client`
29
+
30
+ <!-- YAML
31
+ added: v1.0.0
32
+ -->
33
+
34
+ * Extends: {Dispatcher}
35
+
36
+ ### `new Client(url[, options])`
37
+
38
+ <!-- YAML
39
+ added: v1.0.0
40
+ -->
41
+
42
+ * `url` {URL|string} The origin to connect to. Only the protocol, hostname, and
43
+ port are used.
44
+ * `options` {Object} (optional)
45
+ * `bodyTimeout` {number|null} The timeout, in milliseconds, after which a
46
+ request times out while receiving body data. Monitors the time between
47
+ consecutive body chunks. Use `0` to disable it entirely. **Default:**
48
+ `300e3`.
49
+ * `headersTimeout` {number|null} The timeout, in milliseconds, the parser
50
+ waits to receive the complete HTTP headers before the request times out. Use
51
+ `0` to disable it entirely. **Default:** `300e3`.
52
+ * `connectTimeout` {number|null} The timeout, in milliseconds, for
53
+ establishing a socket connection. Use `0` to disable it entirely.
54
+ **Default:** `10e3`.
55
+ * `keepAliveTimeout` {number|null} The timeout, in milliseconds, after which a
56
+ socket with no active requests times out. Monitors the time between activity
57
+ on a connected socket. This value may be overridden by *keep-alive* hints
58
+ from the server. **Default:** `4e3`.
59
+ * `keepAliveMaxTimeout` {number|null} The maximum allowed `keepAliveTimeout`,
60
+ in milliseconds, when overridden by *keep-alive* hints from the server.
61
+ **Default:** `600e3`.
62
+ * `keepAliveTimeoutThreshold` {number|null} A number of milliseconds
63
+ subtracted from server *keep-alive* hints when overriding `keepAliveTimeout`,
64
+ to account for timing inaccuracies caused by e.g. transport latency.
65
+ **Default:** `2e3`.
66
+ * `maxHeaderSize` {number|null} The maximum length of request headers, in
67
+ bytes. **Default:** the value of Node.js' `--max-http-header-size` or
68
+ `16384` (16 KiB).
69
+ * `maxResponseSize` {number|null} The maximum length of a response body, in
70
+ bytes. Set to `-1` to disable it. **Default:** `-1`.
71
+ * `maxRequestsPerClient` {number|null} The maximum number of requests to send
72
+ over a single connection before the socket is reset. Use `0` to disable this
73
+ limit. **Default:** `null`.
74
+ * `localAddress` {string|null} The local IP address the socket should connect
75
+ from. **Default:** `null`.
76
+ * `pipelining` {number|null} The number of concurrent requests sent over the
77
+ single connection, per [RFC 7230, section 6.3.2][]. Only enable values
78
+ greater than `1` when the remote server is trusted. Set to `0` to disable
79
+ keep-alive connections. Has no effect once HTTP/2 is negotiated; see
80
+ `maxConcurrentStreams` for the HTTP/2 dispatch ceiling. **Default:** `1`.
81
+ * `connect` {Object|Function|null} Configures how connections are established.
82
+ Either a `ConnectOptions` object passed to the built-in
83
+ [`buildConnector`][] (every [`tls.connect()`][] option is accepted, plus the
84
+ fields below), or a custom connector function with the signature
85
+ `(options, callback)`. **Default:** `null`.
86
+ * `socketPath` {string|null} An IPC endpoint, either a Unix domain socket or
87
+ a Windows named pipe. **Default:** `null`.
88
+ * `maxCachedSessions` {number|null} The maximum number of cached TLS
89
+ sessions. Use `0` to disable TLS session caching. **Default:** `100`.
90
+ * `timeout` {number|null} The connection timeout, in milliseconds.
91
+ **Default:** `10e3`.
92
+ * `servername` {string|null} The TLS server name used for SNI.
93
+ * `keepAlive` {boolean|null} Whether TCP keep-alive is enabled on the socket.
94
+ **Default:** `true`.
95
+ * `keepAliveInitialDelay` {number|null} The TCP keep-alive interval for the
96
+ socket, in milliseconds. **Default:** `60000`.
97
+ * `strictContentLength` {boolean} Whether to throw when the request
98
+ `content-length` header does not match the length of the request body.
99
+ Disabling this exposes the application to HTTP request smuggling; only do so
100
+ in controlled environments where the request source is fully trusted.
101
+ **Default:** `true`.
102
+ * `autoSelectFamily` {boolean} Enables a family autodetection algorithm that
103
+ loosely implements section 5 of [RFC 8305][]. Ignored if unsupported by the
104
+ current Node.js version. **Default:** `false`.
105
+ * `autoSelectFamilyAttemptTimeout` {number} The time, in milliseconds, to wait
106
+ for a connection attempt to finish before trying the next address when
107
+ `autoSelectFamily` is enabled. **Default:** `250`.
108
+ * `allowH2` {boolean} Enables HTTP/2 support when the server assigns it a
109
+ higher priority through ALPN negotiation. **Default:** `true`.
110
+ * `useH2c` {boolean} Enforces h2c (HTTP/2 cleartext) for non-HTTPS
111
+ connections. **Default:** `false`.
112
+ * `maxConcurrentStreams` {number} The maximum number of concurrent HTTP/2
113
+ streams for a single session. Once h2 is negotiated this — not `pipelining`,
114
+ which is HTTP/1.1 only — is the ceiling used to dispatch in-flight requests.
115
+ It may be overridden by the server's `SETTINGS_MAX_CONCURRENT_STREAMS`
116
+ frame. **Default:** `100`.
117
+ * `initialWindowSize` {number} The HTTP/2 stream-level flow-control window
118
+ size (`SETTINGS_INITIAL_WINDOW_SIZE`). Must be a positive integer.
119
+ **Default:** `262144`.
120
+ * `connectionWindowSize` {number} The HTTP/2 connection-level flow-control
121
+ window size set via `ClientHttp2Session.setLocalWindowSize()`. Must be a
122
+ positive integer. **Default:** `524288`.
123
+ * `pingInterval` {number} The time interval, in milliseconds, between HTTP/2
124
+ PING frames. Set to `0` to disable PING frames. Applies only to HTTP/2
125
+ connections and emits a `ping` event on the client. **Default:** `60e3`.
126
+ * `webSocket` {Object} (optional) WebSocket-specific configuration.
127
+ * `maxFragments` {number} The maximum number of fragments in a message. Set
128
+ to `0` to disable the limit. **Default:** `131072`.
129
+ * `maxPayloadSize` {number} The maximum allowed payload size, in bytes, for
130
+ WebSocket messages. Applied to uncompressed messages, compressed frame
131
+ payloads, and decompressed (`permessage-deflate`) messages. Set to `0` to
132
+ disable the limit. **Default:** `134217728`.
133
+ * Returns: {Client}
134
+
135
+ Instantiating a `Client` does not open a connection; the connection is
136
+ established lazily once a request is queued. Call `client.connect()` to connect
137
+ eagerly.
138
+
139
+ > Notes about HTTP/2:
140
+ >
141
+ > * Pseudo headers (`:path`, `:method`, `:scheme`, `:authority`) are attached
142
+ > automatically and overwrite any user-provided values.
143
+ > * The server must support HTTP/2 and select it during ALPN negotiation, and
144
+ > must not give HTTP/1.1 a higher priority than HTTP/2.
145
+ > * `PUSH` frames are not supported.
146
+
147
+ ```mjs displayName="Basic instantiation"
148
+ import { Client } from 'undici'
78
149
 
79
- Pass a `ConnectOptions` object to customize the TLS connection. The options are forwarded to the internal `buildConnector()`.
150
+ const client = new Client('http://localhost:3000')
151
+ ```
80
152
 
81
- ```js
82
- 'use strict'
153
+ ```mjs displayName="TLS options (object connector)"
83
154
  import { Client } from 'undici'
84
- import fs from 'node:fs'
155
+ import { readFileSync } from 'node:fs'
85
156
 
86
157
  const client = new Client('https://localhost:3000', {
87
158
  connect: {
88
159
  rejectUnauthorized: false,
89
- ca: fs.readFileSync('./ca-cert.pem')
160
+ ca: readFileSync('./ca-cert.pem')
90
161
  }
91
162
  })
92
163
  ```
93
164
 
94
- ### Example - Connect via Unix domain socket
95
-
96
- Use the `socketPath` option to connect through an IPC endpoint instead of a TCP connection.
97
-
98
- ```js
99
- 'use strict'
165
+ ```mjs displayName="Unix domain socket"
100
166
  import { Client } from 'undici'
101
167
 
102
168
  const client = new Client('http://localhost:3000', {
@@ -106,14 +172,20 @@ const client = new Client('http://localhost:3000', {
106
172
  })
107
173
  ```
108
174
 
109
- ### Example - Custom connector (function form)
110
-
111
- Pass a function for full control over socket creation. This allows you to perform additional checks on the socket, use a proxy, or implement custom connection logic.
175
+ ```mjs displayName="Custom DNS lookup"
176
+ import { Client } from 'undici'
177
+ import dns from 'node:dns'
112
178
 
113
- > **Note:** When a function is provided, undici wraps it to automatically inject `socketPath` and `allowH2` into the first argument (`options`) when those values are set on the client.
179
+ const client = new Client('https://example.com', {
180
+ connect: {
181
+ lookup (hostname, options, callback) {
182
+ dns.lookup(hostname, { ...options, family: 4 }, callback)
183
+ }
184
+ }
185
+ })
186
+ ```
114
187
 
115
- ```js
116
- 'use strict'
188
+ ```mjs displayName="Custom connector (function)"
117
189
  import { Client, buildConnector } from 'undici'
118
190
 
119
191
  const connector = buildConnector({ rejectUnauthorized: false })
@@ -122,9 +194,6 @@ const client = new Client('https://localhost:3000', {
122
194
  connector(opts, (err, socket) => {
123
195
  if (err) {
124
196
  cb(err)
125
- } else if (/* assertion */) {
126
- socket.destroy()
127
- cb(new Error('kaboom'))
128
197
  } else {
129
198
  cb(null, socket)
130
199
  }
@@ -133,83 +202,180 @@ const client = new Client('https://localhost:3000', {
133
202
  })
134
203
  ```
135
204
 
136
- For more details on building custom connectors, see [Connector](/docs/docs/api/Connector.md).
205
+ When a connector function is provided, undici wraps it to automatically inject
206
+ `socketPath` and `allowH2` into the `options` argument when those values are set
207
+ on the client. See [`Connector`][] for details on building custom connectors.
208
+
209
+ ### `client.close([callback])`
210
+
211
+ <!-- YAML
212
+ added: v1.0.0
213
+ -->
214
+
215
+ Implements [`dispatcher.close([callback])`][]. Closes the client gracefully,
216
+ waiting for enqueued requests to complete before resolving.
217
+
218
+ ### `client.destroy([error[, callback]])`
219
+
220
+ <!-- YAML
221
+ added: v1.0.0
222
+ -->
223
+
224
+ Implements [`dispatcher.destroy([error[, callback]])`][]. Destroys the client
225
+ abruptly, aborting all pending and running requests, and waits until the socket
226
+ is closed before invoking `callback` (or resolving the returned promise).
227
+
228
+ ### `client.connect(options[, callback])`
229
+
230
+ <!-- YAML
231
+ added: v1.0.0
232
+ -->
233
+
234
+ * `options` {Object} The connect options, identical to
235
+ [`dispatcher.connect()`][] except that `origin` is omitted because the client
236
+ is bound to a single origin.
237
+ * `callback` {Function} (optional)
238
+ * Returns: {Promise|void} A promise when `callback` is not provided.
239
+
240
+ Starts a connection to the client's origin and tunnels a connection through it,
241
+ as defined by [`dispatcher.connect()`][].
137
242
 
138
- ## Instance Methods
243
+ ### `client.dispatch(options, handlers)`
139
244
 
140
- ### `Client.close([callback])`
245
+ <!-- YAML
246
+ added: v1.0.0
247
+ -->
141
248
 
142
- Implements [`Dispatcher.close([callback])`](/docs/docs/api/Dispatcher.md#dispatcherclosecallback-promise).
249
+ Implements [`dispatcher.dispatch(options, handler)`][]. This is the lowest-level
250
+ API used by all other request methods; prefer `client.request()` for most use
251
+ cases.
143
252
 
144
- ### `Client.destroy([error, callback])`
253
+ ### `client.pipeline(options, handler)`
145
254
 
146
- Implements [`Dispatcher.destroy([error, callback])`](/docs/docs/api/Dispatcher.md#dispatcherdestroyerror-callback-promise).
255
+ <!-- YAML
256
+ added: v1.0.0
257
+ -->
147
258
 
148
- Waits until socket is closed before invoking the callback (or returning a promise if no callback is provided).
259
+ See [`dispatcher.pipeline(options, handler)`][]. Sends a request and returns a
260
+ {Duplex} stream that the request body is written to and the response body is
261
+ read from.
149
262
 
150
- ### `Client.connect(options[, callback])`
263
+ ### `client.request(options[, callback])`
151
264
 
152
- See [`Dispatcher.connect(options[, callback])`](/docs/docs/api/Dispatcher.md#dispatcherconnectoptions-callback).
265
+ <!-- YAML
266
+ added: v1.0.0
267
+ -->
153
268
 
154
- ### `Client.dispatch(options, handlers)`
269
+ * `options` {Object}
270
+ * `callback` {Function} (optional)
271
+ * Returns: {Promise|void} A promise resolving to the response data when
272
+ `callback` is not provided.
155
273
 
156
- Implements [`Dispatcher.dispatch(options, handlers)`](/docs/docs/api/Dispatcher.md#dispatcherdispatchoptions-handler).
274
+ See [`dispatcher.request(options[, callback])`][]. Performs an HTTP request and
275
+ returns its status code, headers, trailers, and a readable body stream.
157
276
 
158
- ### `Client.pipeline(options, handler)`
277
+ ```mjs
278
+ import { Client } from 'undici'
279
+
280
+ const client = new Client('http://localhost:3000')
281
+ const { statusCode, headers, body } = await client.request({
282
+ path: '/',
283
+ method: 'GET'
284
+ })
285
+
286
+ console.log(statusCode)
287
+ for await (const chunk of body) {
288
+ console.log(chunk.toString())
289
+ }
290
+ ```
159
291
 
160
- See [`Dispatcher.pipeline(options, handler)`](/docs/docs/api/Dispatcher.md#dispatcherpipelineoptions-handler).
292
+ ### `client.stream(options, factory[, callback])`
161
293
 
162
- ### `Client.request(options[, callback])`
294
+ <!-- YAML
295
+ added: v1.0.0
296
+ -->
163
297
 
164
- See [`Dispatcher.request(options [, callback])`](/docs/docs/api/Dispatcher.md#dispatcherrequestoptions-callback).
298
+ * `options` {Object}
299
+ * `factory` {Function} Returns a {Writable} the response body is piped into.
300
+ * `callback` {Function} (optional)
301
+ * Returns: {Promise|void} A promise when `callback` is not provided.
165
302
 
166
- ### `Client.stream(options, factory[, callback])`
303
+ See [`dispatcher.stream(options, factory[, callback])`][]. A faster alternative
304
+ to `client.request()` when the destination of the response body is known in
305
+ advance.
167
306
 
168
- See [`Dispatcher.stream(options, factory[, callback])`](/docs/docs/api/Dispatcher.md#dispatcherstreamoptions-factory-callback).
307
+ ### `client.upgrade(options[, callback])`
169
308
 
170
- ### `Client.upgrade(options[, callback])`
309
+ <!-- YAML
310
+ added: v1.0.0
311
+ -->
171
312
 
172
- See [`Dispatcher.upgrade(options[, callback])`](/docs/docs/api/Dispatcher.md#dispatcherupgradeoptions-callback).
313
+ * `options` {Object}
314
+ * `callback` {Function} (optional)
315
+ * Returns: {Promise|void} A promise when `callback` is not provided.
173
316
 
174
- ## Instance Properties
317
+ See [`dispatcher.upgrade(options[, callback])`][]. Upgrades a connection to a
318
+ different protocol, such as for WebSocket or HTTP `CONNECT`.
175
319
 
176
- ### `Client.closed`
320
+ ### `client.closed`
177
321
 
178
- * `boolean`
322
+ <!-- YAML
323
+ added: v1.0.0
324
+ -->
325
+
326
+ * Type: {boolean}
179
327
 
180
328
  `true` after `client.close()` has been called.
181
329
 
182
- ### `Client.destroyed`
330
+ ### `client.destroyed`
183
331
 
184
- * `boolean`
332
+ <!-- YAML
333
+ added: v1.0.0
334
+ -->
185
335
 
186
- `true` after `client.destroyed()` has been called or `client.close()` has been called and the client shutdown has completed.
336
+ * Type: {boolean}
187
337
 
188
- ### `Client.pipelining`
338
+ `true` after `client.destroy()` has been called, or after `client.close()` has
339
+ been called and the client shutdown has completed.
189
340
 
190
- * `number`
341
+ ### `client.pipelining`
191
342
 
192
- Property to get and set the pipelining factor.
343
+ <!-- YAML
344
+ added: v1.0.0
345
+ -->
193
346
 
194
- ## Instance Events
347
+ * Type: {number}
195
348
 
196
- ### Event: `'connect'`
349
+ The pipelining factor. This property can be read and written to adjust the
350
+ number of concurrent requests sent over the connection. Only enable pipelining
351
+ with trusted remote servers.
197
352
 
198
- See [Dispatcher Event: `'connect'`](/docs/docs/api/Dispatcher.md#event-connect).
353
+ ### `client.stats`
199
354
 
200
- Parameters:
355
+ <!-- YAML
356
+ added: v7.9.0
357
+ -->
201
358
 
202
- * **origin** `URL`
203
- * **targets** `Array<Dispatcher>`
359
+ * Type: {ClientStats}
204
360
 
205
- Emitted when a socket has been created and connected. The client will connect once `client.size > 0`.
361
+ Aggregate statistics for the client. See [`ClientStats`][].
362
+
363
+ ### Event: `'connect'`
206
364
 
207
- #### Example - Client connect event
365
+ <!-- YAML
366
+ added: v1.0.0
367
+ -->
208
368
 
209
- ```js
210
- import { createServer } from 'http'
369
+ * `origin` {URL}
370
+ * `targets` {Array<Dispatcher>}
371
+
372
+ Emitted when a socket has been created and connected. The client connects once
373
+ `client.size > 0`. See [`Dispatcher` Event: `'connect'`][].
374
+
375
+ ```mjs
376
+ import { createServer } from 'node:http'
211
377
  import { Client } from 'undici'
212
- import { once } from 'events'
378
+ import { once } from 'node:events'
213
379
 
214
380
  const server = createServer((request, response) => {
215
381
  response.end('Hello, World!')
@@ -220,43 +386,40 @@ await once(server, 'listening')
220
386
  const client = new Client(`http://localhost:${server.address().port}`)
221
387
 
222
388
  client.on('connect', (origin) => {
223
- console.log(`Connected to ${origin}`) // should print before the request body statement
389
+ console.log(`Connected to ${origin}`)
224
390
  })
225
391
 
226
- try {
227
- const { body } = await client.request({
228
- path: '/',
229
- method: 'GET'
230
- })
231
- body.setEncoding('utf-8')
232
- body.on('data', console.log)
233
- client.close()
234
- server.close()
235
- } catch (error) {
236
- console.error(error)
237
- client.close()
238
- server.close()
239
- }
392
+ const { body } = await client.request({ path: '/', method: 'GET' })
393
+ body.setEncoding('utf8')
394
+ body.on('data', console.log)
395
+
396
+ client.close()
397
+ server.close()
240
398
  ```
241
399
 
242
400
  ### Event: `'disconnect'`
243
401
 
244
- See [Dispatcher Event: `'disconnect'`](/docs/docs/api/Dispatcher.md#event-disconnect).
245
-
246
- Parameters:
247
-
248
- * **origin** `URL`
249
- * **targets** `Array<Dispatcher>`
250
- * **error** `Error`
251
-
252
- Emitted when socket has disconnected. The error argument of the event is the error which caused the socket to disconnect. The client will reconnect if or once `client.size > 0`.
253
-
254
- #### Example - Client disconnect event
255
-
256
- ```js
257
- import { createServer } from 'http'
402
+ <!-- YAML
403
+ added: v1.0.0
404
+ changes:
405
+ - version: v4.0.0
406
+ pr-url: https://github.com/nodejs/undici/pull/771
407
+ description: The event is only emitted if the client had previously
408
+ connected.
409
+ -->
410
+
411
+ * `origin` {URL}
412
+ * `targets` {Array<Dispatcher>}
413
+ * `error` {Error}
414
+
415
+ Emitted when a socket has disconnected. The `error` argument is the error that
416
+ caused the disconnection. The client reconnects if or once `client.size > 0`.
417
+ See [`Dispatcher` Event: `'disconnect'`][].
418
+
419
+ ```mjs
420
+ import { createServer } from 'node:http'
258
421
  import { Client } from 'undici'
259
- import { once } from 'events'
422
+ import { once } from 'node:events'
260
423
 
261
424
  const server = createServer((request, response) => {
262
425
  response.destroy()
@@ -271,12 +434,10 @@ client.on('disconnect', (origin) => {
271
434
  })
272
435
 
273
436
  try {
274
- await client.request({
275
- path: '/',
276
- method: 'GET'
277
- })
437
+ await client.request({ path: '/', method: 'GET' })
278
438
  } catch (error) {
279
439
  console.error(error.message)
440
+ } finally {
280
441
  client.close()
281
442
  server.close()
282
443
  }
@@ -284,16 +445,19 @@ try {
284
445
 
285
446
  ### Event: `'drain'`
286
447
 
287
- Emitted when pipeline is no longer busy.
448
+ <!-- YAML
449
+ added: v1.0.0
450
+ -->
288
451
 
289
- See [Dispatcher Event: `'drain'`](/docs/docs/api/Dispatcher.md#event-drain).
452
+ * `origin` {URL}
290
453
 
291
- #### Example - Client drain event
454
+ Emitted when the pipeline is no longer busy. See
455
+ [`Dispatcher` Event: `'drain'`][].
292
456
 
293
- ```js
294
- import { createServer } from 'http'
457
+ ```mjs
458
+ import { createServer } from 'node:http'
295
459
  import { Client } from 'undici'
296
- import { once } from 'events'
460
+ import { once } from 'node:events'
297
461
 
298
462
  const server = createServer((request, response) => {
299
463
  response.end('Hello, World!')
@@ -309,17 +473,40 @@ client.on('drain', () => {
309
473
  server.close()
310
474
  })
311
475
 
312
- const requests = [
476
+ await Promise.all([
313
477
  client.request({ path: '/', method: 'GET' }),
314
478
  client.request({ path: '/', method: 'GET' }),
315
479
  client.request({ path: '/', method: 'GET' })
316
- ]
317
-
318
- await Promise.all(requests)
319
-
320
- console.log('requests completed')
480
+ ])
321
481
  ```
322
482
 
323
483
  ### Event: `'error'`
324
484
 
325
- Invoked for user errors such as throwing in the `onResponseError` handler.
485
+ <!-- YAML
486
+ added: v1.0.0
487
+ -->
488
+
489
+ * `error` {Error}
490
+
491
+ Emitted for user errors, such as throwing inside an `onResponseError` handler.
492
+
493
+ [RFC 7230, section 6.3.2]: https://tools.ietf.org/html/rfc7230#section-6.3.2
494
+ [RFC 8305]: https://tools.ietf.org/html/rfc8305#section-5
495
+ [`Agent`]: Agent.md#class-agent
496
+ [`ClientStats`]: ClientStats.md
497
+ [`Connector`]: Connector.md
498
+ [`Dispatcher` Event: `'connect'`]: Dispatcher.md#event-connect
499
+ [`Dispatcher` Event: `'disconnect'`]: Dispatcher.md#event-disconnect
500
+ [`Dispatcher` Event: `'drain'`]: Dispatcher.md#event-drain
501
+ [`Dispatcher`]: Dispatcher.md#class-dispatcher
502
+ [`Pool`]: Pool.md#class-pool
503
+ [`buildConnector`]: Connector.md
504
+ [`dispatcher.close([callback])`]: Dispatcher.md#dispatcherclosecallback
505
+ [`dispatcher.connect()`]: Dispatcher.md#dispatcherconnectoptions-callback
506
+ [`dispatcher.destroy([error[, callback]])`]: Dispatcher.md#dispatcherdestroyerror-callback
507
+ [`dispatcher.dispatch(options, handler)`]: Dispatcher.md#dispatcherdispatchoptions-handler
508
+ [`dispatcher.pipeline(options, handler)`]: Dispatcher.md#dispatcherpipelineoptions-handler
509
+ [`dispatcher.request(options[, callback])`]: Dispatcher.md#dispatcherrequestoptions-callback
510
+ [`dispatcher.stream(options, factory[, callback])`]: Dispatcher.md#dispatcherstreamoptions-factory-callback
511
+ [`dispatcher.upgrade(options[, callback])`]: Dispatcher.md#dispatcherupgradeoptions-callback
512
+ [`tls.connect()`]: https://nodejs.org/api/tls.html#tlsconnectoptions-callback