@jini-ai/provider-plugins 0.7.2 → 0.7.3-next.1

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 (254) hide show
  1. package/CHANGELOG.md +2 -4
  2. package/README.md +1 -1
  3. package/catalog.json +20 -20
  4. package/dist/observability-opentelemetry/contract.d.ts +114 -0
  5. package/dist/observability-opentelemetry/contract.js +1 -0
  6. package/dist/observability-opentelemetry/otel-port.d.ts +31 -0
  7. package/dist/observability-opentelemetry/otel-port.js +187 -0
  8. package/package.json +26 -18
  9. package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +3 -3
  10. package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/package-license.json +1 -1
  11. package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/README.md +1 -1
  12. package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +6 -16
  13. package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/package-license.json +1 -1
  14. package/plugins/analytics-posthog/0.7.3-next.1/server/consent-adapter.mjs +1 -0
  15. package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/server/index.mjs +73 -90
  16. package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/client/provider.js +16 -16
  17. package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +4 -10
  18. package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/package-license.json +1 -1
  19. package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/client/provider.js +47 -47
  20. package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +5 -11
  21. package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/package-license.json +1 -1
  22. package/plugins/fixture-provider/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +3 -3
  23. package/plugins/fixture-provider/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  24. package/plugins/formspree/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +3 -3
  25. package/plugins/formspree/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  26. package/plugins/google-forms/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +3 -3
  27. package/plugins/google-forms/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  28. package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/README.md +1 -1
  29. package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +6 -15
  30. package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_core/package-license.json +1 -1
  31. package/plugins/observability-opentelemetry/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  32. package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/server/index.mjs +246 -1190
  33. package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/README.md +1 -1
  34. package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +6 -10
  35. package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_core/package-license.json +1 -1
  36. package/plugins/observability-sentry/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  37. package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/server/index.mjs +85 -1045
  38. package/plugins/payments-stripe/{0.7.2 → 0.7.3-next.1}/jini.plugin.json +4 -9
  39. package/plugins/payments-stripe/0.7.3-next.1/licenses/_jini-ai_provider-plugins/package-license.json +5 -0
  40. package/plugins/payments-stripe/{0.7.2 → 0.7.3-next.1}/server/index.mjs +64 -63
  41. package/plugins/analytics-posthog/0.7.2/licenses/_jini-ai_cookie-consent/LICENSE-SOURCE +0 -1
  42. package/plugins/analytics-posthog/0.7.2/licenses/_jini-ai_cookie-consent/package-license.json +0 -5
  43. package/plugins/analytics-posthog/0.7.2/licenses/_jini-ai_core/package-license.json +0 -5
  44. package/plugins/analytics-posthog/0.7.2/licenses/_jini-ai_diagnostics/package-license.json +0 -5
  45. package/plugins/analytics-posthog/0.7.2/licenses/js-tokens/LICENSE +0 -21
  46. package/plugins/analytics-posthog/0.7.2/licenses/js-tokens/package-license.json +0 -5
  47. package/plugins/analytics-posthog/0.7.2/server/consent-adapter.mjs +0 -1
  48. package/plugins/charts-echarts/0.7.2/licenses/_jini-ai_ui/LICENSE-SOURCE +0 -1
  49. package/plugins/charts-echarts/0.7.2/licenses/_jini-ai_ui/package-license.json +0 -5
  50. package/plugins/charts-echarts/0.7.2/licenses/zod/LICENSE +0 -21
  51. package/plugins/charts-echarts/0.7.2/licenses/zod/package-license.json +0 -5
  52. package/plugins/charts-recharts/0.7.2/licenses/_jini-ai_ui/LICENSE-SOURCE +0 -1
  53. package/plugins/charts-recharts/0.7.2/licenses/_jini-ai_ui/package-license.json +0 -5
  54. package/plugins/charts-recharts/0.7.2/licenses/zod/LICENSE +0 -21
  55. package/plugins/charts-recharts/0.7.2/licenses/zod/package-license.json +0 -5
  56. package/plugins/fixture-provider/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  57. package/plugins/formspree/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  58. package/plugins/google-forms/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  59. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_diagnostics/package-license.json +0 -5
  60. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_plugins/LICENSE +0 -201
  61. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_plugins/LICENSE-SOURCE +0 -1
  62. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_plugins/package-license.json +0 -5
  63. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_provider-plugins/LICENSE +0 -201
  64. package/plugins/observability-opentelemetry/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  65. package/plugins/observability-opentelemetry/0.7.2/licenses/js-tokens/LICENSE +0 -21
  66. package/plugins/observability-opentelemetry/0.7.2/licenses/js-tokens/package-license.json +0 -5
  67. package/plugins/observability-opentelemetry/0.7.2/licenses/semver/LICENSE +0 -15
  68. package/plugins/observability-opentelemetry/0.7.2/licenses/semver/package-license.json +0 -5
  69. package/plugins/observability-sentry/0.7.2/LICENSE +0 -201
  70. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_core/LICENSE +0 -201
  71. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_diagnostics/LICENSE +0 -201
  72. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_diagnostics/package-license.json +0 -5
  73. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_provider-plugins/LICENSE +0 -201
  74. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_provider-plugins/NOTICE +0 -28
  75. package/plugins/observability-sentry/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  76. package/plugins/observability-sentry/0.7.2/licenses/js-tokens/LICENSE +0 -21
  77. package/plugins/observability-sentry/0.7.2/licenses/js-tokens/package-license.json +0 -5
  78. package/plugins/payments-stripe/0.7.2/LICENSE +0 -201
  79. package/plugins/payments-stripe/0.7.2/NOTICE +0 -28
  80. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_commerce/LICENSE +0 -201
  81. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_commerce/NOTICE +0 -28
  82. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_commerce/package-license.json +0 -5
  83. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_core/LICENSE +0 -201
  84. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_core/package-license.json +0 -5
  85. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_provider-plugins/LICENSE +0 -201
  86. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_provider-plugins/NOTICE +0 -28
  87. package/plugins/payments-stripe/0.7.2/licenses/_jini-ai_provider-plugins/package-license.json +0 -5
  88. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/CHANGELOG.md +0 -0
  89. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/LICENSE +0 -0
  90. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/NOTICE +0 -0
  91. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/README.md +0 -0
  92. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/LICENSE +0 -0
  93. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  94. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse/LICENSE +0 -0
  95. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse/LICENSE-SOURCE +0 -0
  96. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse/SOURCE +0 -0
  97. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse/package-license.json +0 -0
  98. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse-core/LICENSE +0 -0
  99. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse-core/LICENSE-SOURCE +0 -0
  100. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse-core/SOURCE +0 -0
  101. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/langfuse-core/package-license.json +0 -0
  102. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/mustache/LICENSE +0 -0
  103. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/licenses/mustache/package-license.json +0 -0
  104. /package/plugins/ai-trace-langfuse/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  105. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/CHANGELOG.md +0 -0
  106. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/LICENSE +0 -0
  107. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/NOTICE +0 -0
  108. /package/plugins/analytics-posthog/{0.7.2/licenses/_jini-ai_cookie-consent → 0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  109. /package/plugins/analytics-posthog/{0.7.2/licenses/_jini-ai_cookie-consent → 0.7.3-next.1/licenses/_jini-ai_provider-plugins}/NOTICE +0 -0
  110. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/_posthog_core/LICENSE +0 -0
  111. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/_posthog_core/package-license.json +0 -0
  112. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/posthog-js/LICENSE +0 -0
  113. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/posthog-js/package-license.json +0 -0
  114. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/posthog-node/LICENSE +0 -0
  115. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/licenses/posthog-node/package-license.json +0 -0
  116. /package/plugins/analytics-posthog/{0.7.2 → 0.7.3-next.1}/server/posthog-browser.js +0 -0
  117. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/client/styles.css +0 -0
  118. /package/plugins/{analytics-posthog/0.7.2/licenses/_jini-ai_core → charts-echarts/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  119. /package/plugins/{analytics-posthog/0.7.2 → charts-echarts/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  120. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/echarts/LICENSE +0 -0
  121. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/echarts/NOTICE +0 -0
  122. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/echarts/package-license.json +0 -0
  123. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/tslib/LICENSE.txt +0 -0
  124. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/tslib/package-license.json +0 -0
  125. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/zrender/LICENSE +0 -0
  126. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/licenses/zrender/package-license.json +0 -0
  127. /package/plugins/charts-echarts/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  128. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/client/styles.css +0 -0
  129. /package/plugins/{analytics-posthog/0.7.2/licenses/_jini-ai_diagnostics → charts-recharts/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  130. /package/plugins/{charts-echarts/0.7.2 → charts-recharts/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  131. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/_reduxjs_toolkit/LICENSE +0 -0
  132. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/_reduxjs_toolkit/package-license.json +0 -0
  133. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/clsx/license +0 -0
  134. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/clsx/package-license.json +0 -0
  135. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-array/LICENSE +0 -0
  136. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-array/package-license.json +0 -0
  137. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-color/LICENSE +0 -0
  138. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-color/package-license.json +0 -0
  139. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-format/LICENSE +0 -0
  140. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-format/package-license.json +0 -0
  141. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-interpolate/LICENSE +0 -0
  142. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-interpolate/package-license.json +0 -0
  143. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-path/LICENSE +0 -0
  144. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-path/package-license.json +0 -0
  145. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-scale/LICENSE +0 -0
  146. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-scale/package-license.json +0 -0
  147. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-shape/LICENSE +0 -0
  148. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-shape/package-license.json +0 -0
  149. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-time/LICENSE +0 -0
  150. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-time/package-license.json +0 -0
  151. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-time-format/LICENSE +0 -0
  152. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/d3-time-format/package-license.json +0 -0
  153. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/decimal.js-light/LICENCE.md +0 -0
  154. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/decimal.js-light/package-license.json +0 -0
  155. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/es-toolkit/LICENSE +0 -0
  156. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/es-toolkit/package-license.json +0 -0
  157. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/eventemitter3/LICENSE +0 -0
  158. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/eventemitter3/package-license.json +0 -0
  159. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/immer/LICENSE +0 -0
  160. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/immer/package-license.json +0 -0
  161. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/internmap/LICENSE +0 -0
  162. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/internmap/package-license.json +0 -0
  163. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react/LICENSE +0 -0
  164. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react/package-license.json +0 -0
  165. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-dom/LICENSE +0 -0
  166. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-dom/package-license.json +0 -0
  167. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-is/LICENSE +0 -0
  168. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-is/package-license.json +0 -0
  169. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-redux/LICENSE.md +0 -0
  170. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/react-redux/package-license.json +0 -0
  171. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/recharts/LICENSE +0 -0
  172. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/recharts/package-license.json +0 -0
  173. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/redux/LICENSE.md +0 -0
  174. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/redux/package-license.json +0 -0
  175. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/redux-thunk/LICENSE.md +0 -0
  176. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/redux-thunk/package-license.json +0 -0
  177. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/reselect/LICENSE +0 -0
  178. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/reselect/package-license.json +0 -0
  179. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/scheduler/LICENSE +0 -0
  180. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/scheduler/package-license.json +0 -0
  181. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/tiny-invariant/LICENSE +0 -0
  182. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/tiny-invariant/package-license.json +0 -0
  183. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/use-sync-external-store/LICENSE +0 -0
  184. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/use-sync-external-store/package-license.json +0 -0
  185. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/victory-vendor/LICENSE.txt +0 -0
  186. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/licenses/victory-vendor/package-license.json +0 -0
  187. /package/plugins/charts-recharts/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  188. /package/plugins/{analytics-posthog/0.7.2 → fixture-provider/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/LICENSE +0 -0
  189. /package/plugins/{charts-echarts/0.7.2/licenses/_jini-ai_ui → fixture-provider/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/NOTICE +0 -0
  190. /package/plugins/fixture-provider/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  191. /package/plugins/{charts-echarts/0.7.2 → formspree/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/LICENSE +0 -0
  192. /package/plugins/{charts-recharts/0.7.2 → formspree/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  193. /package/plugins/formspree/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  194. /package/plugins/{charts-echarts/0.7.2/licenses/_jini-ai_ui → google-forms/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  195. /package/plugins/{charts-recharts/0.7.2/licenses/_jini-ai_ui → google-forms/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/NOTICE +0 -0
  196. /package/plugins/google-forms/{0.7.2 → 0.7.3-next.1}/server/index.mjs +0 -0
  197. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/CHANGELOG.md +0 -0
  198. /package/plugins/{charts-recharts/0.7.2/licenses/_jini-ai_provider-plugins → observability-opentelemetry/0.7.3-next.1}/LICENSE +0 -0
  199. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/NOTICE +0 -0
  200. /package/plugins/{charts-recharts/0.7.2/licenses/_jini-ai_ui → observability-opentelemetry/0.7.3-next.1/licenses/_jini-ai_core}/LICENSE +0 -0
  201. /package/plugins/{fixture-provider/0.7.2 → observability-opentelemetry/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/LICENSE +0 -0
  202. /package/plugins/{fixture-provider/0.7.2 → observability-opentelemetry/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  203. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api/LICENSE +0 -0
  204. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api/package-license.json +0 -0
  205. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api-logs/LICENSE +0 -0
  206. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api-logs/package-license.json +0 -0
  207. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_context-async-hooks/LICENSE +0 -0
  208. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_context-async-hooks/package-license.json +0 -0
  209. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_core/LICENSE +0 -0
  210. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_core/package-license.json +0 -0
  211. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_otlp-exporter-base/LICENSE +0 -0
  212. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_otlp-exporter-base/package-license.json +0 -0
  213. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_otlp-transformer/LICENSE +0 -0
  214. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_otlp-transformer/package-license.json +0 -0
  215. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_resources/LICENSE +0 -0
  216. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_resources/package-license.json +0 -0
  217. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-metrics/LICENSE +0 -0
  218. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-metrics/package-license.json +0 -0
  219. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace/LICENSE +0 -0
  220. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace/package-license.json +0 -0
  221. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace-base/LICENSE +0 -0
  222. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace-base/package-license.json +0 -0
  223. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace-node/LICENSE +0 -0
  224. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_sdk-trace-node/package-license.json +0 -0
  225. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_semantic-conventions/LICENSE +0 -0
  226. /package/plugins/observability-opentelemetry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_semantic-conventions/package-license.json +0 -0
  227. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/CHANGELOG.md +0 -0
  228. /package/plugins/{formspree/0.7.2/licenses/_jini-ai_provider-plugins → observability-sentry/0.7.3-next.1}/LICENSE +0 -0
  229. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/NOTICE +0 -0
  230. /package/plugins/{google-forms/0.7.2/licenses/_jini-ai_provider-plugins → observability-sentry/0.7.3-next.1/licenses/_jini-ai_core}/LICENSE +0 -0
  231. /package/plugins/{observability-opentelemetry/0.7.2 → observability-sentry/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  232. /package/plugins/{formspree/0.7.2 → observability-sentry/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
  233. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api/LICENSE +0 -0
  234. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_opentelemetry_api/package-license.json +0 -0
  235. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_conventions/LICENSE +0 -0
  236. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_conventions/package-license.json +0 -0
  237. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_core/LICENSE +0 -0
  238. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_core/package-license.json +0 -0
  239. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_node/LICENSE +0 -0
  240. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_node/package-license.json +0 -0
  241. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_opentelemetry/LICENSE +0 -0
  242. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_opentelemetry/package-license.json +0 -0
  243. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-runtime-injection/LICENSE +0 -0
  244. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-runtime-injection/LICENSE-SOURCE +0 -0
  245. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-runtime-injection/package-license.json +0 -0
  246. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-utils/LICENSE +0 -0
  247. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-utils/LICENSE-SOURCE +0 -0
  248. /package/plugins/observability-sentry/{0.7.2 → 0.7.3-next.1}/licenses/_sentry_server-utils/package-license.json +0 -0
  249. /package/plugins/payments-stripe/{0.7.2 → 0.7.3-next.1}/CHANGELOG.md +0 -0
  250. /package/plugins/{observability-opentelemetry/0.7.2/licenses/_jini-ai_core → payments-stripe/0.7.3-next.1}/LICENSE +0 -0
  251. /package/plugins/{google-forms/0.7.2/licenses/_jini-ai_provider-plugins → payments-stripe/0.7.3-next.1}/NOTICE +0 -0
  252. /package/plugins/payments-stripe/{0.7.2 → 0.7.3-next.1}/README.md +0 -0
  253. /package/plugins/{observability-opentelemetry/0.7.2/licenses/_jini-ai_diagnostics → payments-stripe/0.7.3-next.1/licenses/_jini-ai_provider-plugins}/LICENSE +0 -0
  254. /package/plugins/{observability-opentelemetry/0.7.2 → payments-stripe/0.7.3-next.1}/licenses/_jini-ai_provider-plugins/NOTICE +0 -0
@@ -48,426 +48,6 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
48
48
  ));
49
49
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
50
50
 
51
- // ../../node_modules/.pnpm/js-tokens@9.0.1/node_modules/js-tokens/index.js
52
- var require_js_tokens = __commonJS({
53
- "../../node_modules/.pnpm/js-tokens@9.0.1/node_modules/js-tokens/index.js"(exports, module) {
54
- var HashbangComment;
55
- var Identifier;
56
- var JSXIdentifier;
57
- var JSXPunctuator;
58
- var JSXString;
59
- var JSXText;
60
- var KeywordsWithExpressionAfter;
61
- var KeywordsWithNoLineTerminatorAfter;
62
- var LineTerminatorSequence;
63
- var MultiLineComment;
64
- var Newline;
65
- var NumericLiteral;
66
- var Punctuator;
67
- var RegularExpressionLiteral;
68
- var SingleLineComment;
69
- var StringLiteral;
70
- var Template;
71
- var TokensNotPrecedingObjectLiteral;
72
- var TokensPrecedingExpression;
73
- var WhiteSpace;
74
- var jsTokens2;
75
- RegularExpressionLiteral = /\/(?![*\/])(?:\[(?:[^\]\\\n\r\u2028\u2029]+|\\.)*\]?|[^\/[\\\n\r\u2028\u2029]+|\\.)*(\/[$_\u200C\u200D\p{ID_Continue}]*|\\)?/yu;
76
- Punctuator = /--|\+\+|=>|\.{3}|\??\.(?!\d)|(?:&&|\|\||\?\?|[+\-%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2}|\/(?![\/*]))=?|[?~,:;[\](){}]/y;
77
- Identifier = /(\x23?)(?=[$_\p{ID_Start}\\])(?:[$_\u200C\u200D\p{ID_Continue}]+|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+/yu;
78
- StringLiteral = /(['"])(?:[^'"\\\n\r]+|(?!\1)['"]|\\(?:\r\n|[^]))*(\1)?/y;
79
- NumericLiteral = /(?:0[xX][\da-fA-F](?:_?[\da-fA-F])*|0[oO][0-7](?:_?[0-7])*|0[bB][01](?:_?[01])*)n?|0n|[1-9](?:_?\d)*n|(?:(?:0(?!\d)|0\d*[89]\d*|[1-9](?:_?\d)*)(?:\.(?:\d(?:_?\d)*)?)?|\.\d(?:_?\d)*)(?:[eE][+-]?\d(?:_?\d)*)?|0[0-7]+/y;
80
- Template = /[`}](?:[^`\\$]+|\\[^]|\$(?!\{))*(`|\$\{)?/y;
81
- WhiteSpace = /[\t\v\f\ufeff\p{Zs}]+/yu;
82
- LineTerminatorSequence = /\r?\n|[\r\u2028\u2029]/y;
83
- MultiLineComment = /\/\*(?:[^*]+|\*(?!\/))*(\*\/)?/y;
84
- SingleLineComment = /\/\/.*/y;
85
- HashbangComment = /^#!.*/;
86
- JSXPunctuator = /[<>.:={}]|\/(?![\/*])/y;
87
- JSXIdentifier = /[$_\p{ID_Start}][$_\u200C\u200D\p{ID_Continue}-]*/yu;
88
- JSXString = /(['"])(?:[^'"]+|(?!\1)['"])*(\1)?/y;
89
- JSXText = /[^<>{}]+/y;
90
- TokensPrecedingExpression = /^(?:[\/+-]|\.{3}|\?(?:InterpolationIn(?:JSX|Template)|NoLineTerminatorHere|NonExpressionParenEnd|UnaryIncDec))?$|[{}([,;<>=*%&|^!~?:]$/;
91
- TokensNotPrecedingObjectLiteral = /^(?:=>|[;\]){}]|else|\?(?:NoLineTerminatorHere|NonExpressionParenEnd))?$/;
92
- KeywordsWithExpressionAfter = /^(?:await|case|default|delete|do|else|instanceof|new|return|throw|typeof|void|yield)$/;
93
- KeywordsWithNoLineTerminatorAfter = /^(?:return|throw|yield)$/;
94
- Newline = RegExp(LineTerminatorSequence.source);
95
- module.exports = jsTokens2 = function* (input, { jsx = false } = {}) {
96
- var braces, firstCodePoint, isExpression, lastIndex, lastSignificantToken, length, match, mode, nextLastIndex, nextLastSignificantToken, parenNesting, postfixIncDec, punctuator, stack;
97
- ({ length } = input);
98
- lastIndex = 0;
99
- lastSignificantToken = "";
100
- stack = [
101
- { tag: "JS" }
102
- ];
103
- braces = [];
104
- parenNesting = 0;
105
- postfixIncDec = false;
106
- if (match = HashbangComment.exec(input)) {
107
- yield {
108
- type: "HashbangComment",
109
- value: match[0]
110
- };
111
- lastIndex = match[0].length;
112
- }
113
- while (lastIndex < length) {
114
- mode = stack[stack.length - 1];
115
- switch (mode.tag) {
116
- case "JS":
117
- case "JSNonExpressionParen":
118
- case "InterpolationInTemplate":
119
- case "InterpolationInJSX":
120
- if (input[lastIndex] === "/" && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
121
- RegularExpressionLiteral.lastIndex = lastIndex;
122
- if (match = RegularExpressionLiteral.exec(input)) {
123
- lastIndex = RegularExpressionLiteral.lastIndex;
124
- lastSignificantToken = match[0];
125
- postfixIncDec = true;
126
- yield {
127
- type: "RegularExpressionLiteral",
128
- value: match[0],
129
- closed: match[1] !== void 0 && match[1] !== "\\"
130
- };
131
- continue;
132
- }
133
- }
134
- Punctuator.lastIndex = lastIndex;
135
- if (match = Punctuator.exec(input)) {
136
- punctuator = match[0];
137
- nextLastIndex = Punctuator.lastIndex;
138
- nextLastSignificantToken = punctuator;
139
- switch (punctuator) {
140
- case "(":
141
- if (lastSignificantToken === "?NonExpressionParenKeyword") {
142
- stack.push({
143
- tag: "JSNonExpressionParen",
144
- nesting: parenNesting
145
- });
146
- }
147
- parenNesting++;
148
- postfixIncDec = false;
149
- break;
150
- case ")":
151
- parenNesting--;
152
- postfixIncDec = true;
153
- if (mode.tag === "JSNonExpressionParen" && parenNesting === mode.nesting) {
154
- stack.pop();
155
- nextLastSignificantToken = "?NonExpressionParenEnd";
156
- postfixIncDec = false;
157
- }
158
- break;
159
- case "{":
160
- Punctuator.lastIndex = 0;
161
- isExpression = !TokensNotPrecedingObjectLiteral.test(lastSignificantToken) && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken));
162
- braces.push(isExpression);
163
- postfixIncDec = false;
164
- break;
165
- case "}":
166
- switch (mode.tag) {
167
- case "InterpolationInTemplate":
168
- if (braces.length === mode.nesting) {
169
- Template.lastIndex = lastIndex;
170
- match = Template.exec(input);
171
- lastIndex = Template.lastIndex;
172
- lastSignificantToken = match[0];
173
- if (match[1] === "${") {
174
- lastSignificantToken = "?InterpolationInTemplate";
175
- postfixIncDec = false;
176
- yield {
177
- type: "TemplateMiddle",
178
- value: match[0]
179
- };
180
- } else {
181
- stack.pop();
182
- postfixIncDec = true;
183
- yield {
184
- type: "TemplateTail",
185
- value: match[0],
186
- closed: match[1] === "`"
187
- };
188
- }
189
- continue;
190
- }
191
- break;
192
- case "InterpolationInJSX":
193
- if (braces.length === mode.nesting) {
194
- stack.pop();
195
- lastIndex += 1;
196
- lastSignificantToken = "}";
197
- yield {
198
- type: "JSXPunctuator",
199
- value: "}"
200
- };
201
- continue;
202
- }
203
- }
204
- postfixIncDec = braces.pop();
205
- nextLastSignificantToken = postfixIncDec ? "?ExpressionBraceEnd" : "}";
206
- break;
207
- case "]":
208
- postfixIncDec = true;
209
- break;
210
- case "++":
211
- case "--":
212
- nextLastSignificantToken = postfixIncDec ? "?PostfixIncDec" : "?UnaryIncDec";
213
- break;
214
- case "<":
215
- if (jsx && (TokensPrecedingExpression.test(lastSignificantToken) || KeywordsWithExpressionAfter.test(lastSignificantToken))) {
216
- stack.push({ tag: "JSXTag" });
217
- lastIndex += 1;
218
- lastSignificantToken = "<";
219
- yield {
220
- type: "JSXPunctuator",
221
- value: punctuator
222
- };
223
- continue;
224
- }
225
- postfixIncDec = false;
226
- break;
227
- default:
228
- postfixIncDec = false;
229
- }
230
- lastIndex = nextLastIndex;
231
- lastSignificantToken = nextLastSignificantToken;
232
- yield {
233
- type: "Punctuator",
234
- value: punctuator
235
- };
236
- continue;
237
- }
238
- Identifier.lastIndex = lastIndex;
239
- if (match = Identifier.exec(input)) {
240
- lastIndex = Identifier.lastIndex;
241
- nextLastSignificantToken = match[0];
242
- switch (match[0]) {
243
- case "for":
244
- case "if":
245
- case "while":
246
- case "with":
247
- if (lastSignificantToken !== "." && lastSignificantToken !== "?.") {
248
- nextLastSignificantToken = "?NonExpressionParenKeyword";
249
- }
250
- }
251
- lastSignificantToken = nextLastSignificantToken;
252
- postfixIncDec = !KeywordsWithExpressionAfter.test(match[0]);
253
- yield {
254
- type: match[1] === "#" ? "PrivateIdentifier" : "IdentifierName",
255
- value: match[0]
256
- };
257
- continue;
258
- }
259
- StringLiteral.lastIndex = lastIndex;
260
- if (match = StringLiteral.exec(input)) {
261
- lastIndex = StringLiteral.lastIndex;
262
- lastSignificantToken = match[0];
263
- postfixIncDec = true;
264
- yield {
265
- type: "StringLiteral",
266
- value: match[0],
267
- closed: match[2] !== void 0
268
- };
269
- continue;
270
- }
271
- NumericLiteral.lastIndex = lastIndex;
272
- if (match = NumericLiteral.exec(input)) {
273
- lastIndex = NumericLiteral.lastIndex;
274
- lastSignificantToken = match[0];
275
- postfixIncDec = true;
276
- yield {
277
- type: "NumericLiteral",
278
- value: match[0]
279
- };
280
- continue;
281
- }
282
- Template.lastIndex = lastIndex;
283
- if (match = Template.exec(input)) {
284
- lastIndex = Template.lastIndex;
285
- lastSignificantToken = match[0];
286
- if (match[1] === "${") {
287
- lastSignificantToken = "?InterpolationInTemplate";
288
- stack.push({
289
- tag: "InterpolationInTemplate",
290
- nesting: braces.length
291
- });
292
- postfixIncDec = false;
293
- yield {
294
- type: "TemplateHead",
295
- value: match[0]
296
- };
297
- } else {
298
- postfixIncDec = true;
299
- yield {
300
- type: "NoSubstitutionTemplate",
301
- value: match[0],
302
- closed: match[1] === "`"
303
- };
304
- }
305
- continue;
306
- }
307
- break;
308
- case "JSXTag":
309
- case "JSXTagEnd":
310
- JSXPunctuator.lastIndex = lastIndex;
311
- if (match = JSXPunctuator.exec(input)) {
312
- lastIndex = JSXPunctuator.lastIndex;
313
- nextLastSignificantToken = match[0];
314
- switch (match[0]) {
315
- case "<":
316
- stack.push({ tag: "JSXTag" });
317
- break;
318
- case ">":
319
- stack.pop();
320
- if (lastSignificantToken === "/" || mode.tag === "JSXTagEnd") {
321
- nextLastSignificantToken = "?JSX";
322
- postfixIncDec = true;
323
- } else {
324
- stack.push({ tag: "JSXChildren" });
325
- }
326
- break;
327
- case "{":
328
- stack.push({
329
- tag: "InterpolationInJSX",
330
- nesting: braces.length
331
- });
332
- nextLastSignificantToken = "?InterpolationInJSX";
333
- postfixIncDec = false;
334
- break;
335
- case "/":
336
- if (lastSignificantToken === "<") {
337
- stack.pop();
338
- if (stack[stack.length - 1].tag === "JSXChildren") {
339
- stack.pop();
340
- }
341
- stack.push({ tag: "JSXTagEnd" });
342
- }
343
- }
344
- lastSignificantToken = nextLastSignificantToken;
345
- yield {
346
- type: "JSXPunctuator",
347
- value: match[0]
348
- };
349
- continue;
350
- }
351
- JSXIdentifier.lastIndex = lastIndex;
352
- if (match = JSXIdentifier.exec(input)) {
353
- lastIndex = JSXIdentifier.lastIndex;
354
- lastSignificantToken = match[0];
355
- yield {
356
- type: "JSXIdentifier",
357
- value: match[0]
358
- };
359
- continue;
360
- }
361
- JSXString.lastIndex = lastIndex;
362
- if (match = JSXString.exec(input)) {
363
- lastIndex = JSXString.lastIndex;
364
- lastSignificantToken = match[0];
365
- yield {
366
- type: "JSXString",
367
- value: match[0],
368
- closed: match[2] !== void 0
369
- };
370
- continue;
371
- }
372
- break;
373
- case "JSXChildren":
374
- JSXText.lastIndex = lastIndex;
375
- if (match = JSXText.exec(input)) {
376
- lastIndex = JSXText.lastIndex;
377
- lastSignificantToken = match[0];
378
- yield {
379
- type: "JSXText",
380
- value: match[0]
381
- };
382
- continue;
383
- }
384
- switch (input[lastIndex]) {
385
- case "<":
386
- stack.push({ tag: "JSXTag" });
387
- lastIndex++;
388
- lastSignificantToken = "<";
389
- yield {
390
- type: "JSXPunctuator",
391
- value: "<"
392
- };
393
- continue;
394
- case "{":
395
- stack.push({
396
- tag: "InterpolationInJSX",
397
- nesting: braces.length
398
- });
399
- lastIndex++;
400
- lastSignificantToken = "?InterpolationInJSX";
401
- postfixIncDec = false;
402
- yield {
403
- type: "JSXPunctuator",
404
- value: "{"
405
- };
406
- continue;
407
- }
408
- }
409
- WhiteSpace.lastIndex = lastIndex;
410
- if (match = WhiteSpace.exec(input)) {
411
- lastIndex = WhiteSpace.lastIndex;
412
- yield {
413
- type: "WhiteSpace",
414
- value: match[0]
415
- };
416
- continue;
417
- }
418
- LineTerminatorSequence.lastIndex = lastIndex;
419
- if (match = LineTerminatorSequence.exec(input)) {
420
- lastIndex = LineTerminatorSequence.lastIndex;
421
- postfixIncDec = false;
422
- if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
423
- lastSignificantToken = "?NoLineTerminatorHere";
424
- }
425
- yield {
426
- type: "LineTerminatorSequence",
427
- value: match[0]
428
- };
429
- continue;
430
- }
431
- MultiLineComment.lastIndex = lastIndex;
432
- if (match = MultiLineComment.exec(input)) {
433
- lastIndex = MultiLineComment.lastIndex;
434
- if (Newline.test(match[0])) {
435
- postfixIncDec = false;
436
- if (KeywordsWithNoLineTerminatorAfter.test(lastSignificantToken)) {
437
- lastSignificantToken = "?NoLineTerminatorHere";
438
- }
439
- }
440
- yield {
441
- type: "MultiLineComment",
442
- value: match[0],
443
- closed: match[1] !== void 0
444
- };
445
- continue;
446
- }
447
- SingleLineComment.lastIndex = lastIndex;
448
- if (match = SingleLineComment.exec(input)) {
449
- lastIndex = SingleLineComment.lastIndex;
450
- postfixIncDec = false;
451
- yield {
452
- type: "SingleLineComment",
453
- value: match[0]
454
- };
455
- continue;
456
- }
457
- firstCodePoint = String.fromCodePoint(input.codePointAt(lastIndex));
458
- lastIndex += firstCodePoint.length;
459
- lastSignificantToken = firstCodePoint;
460
- postfixIncDec = false;
461
- yield {
462
- type: mode.tag.startsWith("JSX") ? "JSXInvalid" : "Invalid",
463
- value: firstCodePoint
464
- };
465
- }
466
- return void 0;
467
- };
468
- }
469
- });
470
-
471
51
  // ../../node_modules/.pnpm/@opentelemetry+api@1.10.0/node_modules/@opentelemetry/api/dist/diag/types.cjs
472
52
  var require_types = __commonJS({
473
53
  "../../node_modules/.pnpm/@opentelemetry+api@1.10.0/node_modules/@opentelemetry/api/dist/diag/types.cjs"(exports) {
@@ -2323,13 +1903,13 @@ var require_utils3 = __commonJS({
2323
1903
  }
2324
1904
  exports.parsePairKeyValue = parsePairKeyValue;
2325
1905
  function parseBaggageHeaderString(value, baggage, count, totalSize) {
2326
- let start = 0;
2327
- while (start < value.length && count < constants_1.BAGGAGE_MAX_NAME_VALUE_PAIRS) {
2328
- const end = value.indexOf(constants_1.BAGGAGE_ITEMS_SEPARATOR, start);
1906
+ let start2 = 0;
1907
+ while (start2 < value.length && count < constants_1.BAGGAGE_MAX_NAME_VALUE_PAIRS) {
1908
+ const end = value.indexOf(constants_1.BAGGAGE_ITEMS_SEPARATOR, start2);
2329
1909
  const entryEnd = end === -1 ? value.length : end;
2330
- const entryLength = entryEnd - start;
1910
+ const entryLength = entryEnd - start2;
2331
1911
  if (entryLength <= constants_1.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS) {
2332
- const keyPair = parsePairKeyValue(value.substring(start, entryEnd));
1912
+ const keyPair = parsePairKeyValue(value.substring(start2, entryEnd));
2333
1913
  if (keyPair) {
2334
1914
  const entrySize = (count === 0 ? 0 : 1) + entryLength;
2335
1915
  if (totalSize + entrySize > constants_1.BAGGAGE_MAX_TOTAL_LENGTH)
@@ -2341,7 +1921,7 @@ var require_utils3 = __commonJS({
2341
1921
  }
2342
1922
  if (end === -1)
2343
1923
  break;
2344
- start = end + 1;
1924
+ start2 = end + 1;
2345
1925
  }
2346
1926
  return [count, totalSize];
2347
1927
  }
@@ -6635,7 +6215,7 @@ var require_common_serializer = __commonJS({
6635
6215
  exports.writeAnyValue = writeAnyValue;
6636
6216
  function writeInstrumentationScope(writer, scope, fieldNumber) {
6637
6217
  writer.writeTag(fieldNumber, 2);
6638
- const start = writer.startLengthDelimited();
6218
+ const start2 = writer.startLengthDelimited();
6639
6219
  const startPos = writer.pos;
6640
6220
  writer.writeTag(1, 2);
6641
6221
  writer.writeString(scope.name);
@@ -6650,7 +6230,7 @@ var require_common_serializer = __commonJS({
6650
6230
  writer.writeTag(4, 0);
6651
6231
  writer.writeVarint(scope.droppedAttributesCount);
6652
6232
  }
6653
- writer.finishLengthDelimited(start, writer.pos - startPos);
6233
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
6654
6234
  }
6655
6235
  exports.writeInstrumentationScope = writeInstrumentationScope;
6656
6236
  function writeResource(writer, resource, fieldNumber) {
@@ -11715,7 +11295,7 @@ var require_metrics_serializer = __commonJS({
11715
11295
  var protobuf_size_estimator_1 = require_protobuf_size_estimator();
11716
11296
  var protobuf_writer_1 = require_protobuf_writer();
11717
11297
  function serializeNumberDataPoint(writer, dataPoint, valueType) {
11718
- const start = writer.startLengthDelimited();
11298
+ const start2 = writer.startLengthDelimited();
11719
11299
  const startPos = writer.pos;
11720
11300
  writer.writeTag(2, 1);
11721
11301
  (0, common_serializer_1.writeHrTimeAsFixed64)(writer, dataPoint.startTime);
@@ -11731,10 +11311,10 @@ var require_metrics_serializer = __commonJS({
11731
11311
  if (dataPoint.attributes) {
11732
11312
  (0, common_serializer_1.writeAttributes)(writer, dataPoint.attributes, 7);
11733
11313
  }
11734
- writer.finishLengthDelimited(start, writer.pos - startPos);
11314
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11735
11315
  }
11736
11316
  function serializeHistogramDataPoint(writer, dataPoint) {
11737
- const start = writer.startLengthDelimited();
11317
+ const start2 = writer.startLengthDelimited();
11738
11318
  const startPos = writer.pos;
11739
11319
  const histogram = dataPoint.value;
11740
11320
  writer.writeTag(2, 1);
@@ -11776,10 +11356,10 @@ var require_metrics_serializer = __commonJS({
11776
11356
  writer.writeTag(12, 1);
11777
11357
  writer.writeDouble(histogram.max);
11778
11358
  }
11779
- writer.finishLengthDelimited(start, writer.pos - startPos);
11359
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11780
11360
  }
11781
11361
  function serializeExponentialBuckets(writer, offset, bucketCounts) {
11782
- const start = writer.startLengthDelimited();
11362
+ const start2 = writer.startLengthDelimited();
11783
11363
  const startPos = writer.pos;
11784
11364
  if (offset !== 0) {
11785
11365
  writer.writeTag(1, 0);
@@ -11794,10 +11374,10 @@ var require_metrics_serializer = __commonJS({
11794
11374
  }
11795
11375
  writer.finishLengthDelimited(bcStart, writer.pos - bcStartPos);
11796
11376
  }
11797
- writer.finishLengthDelimited(start, writer.pos - startPos);
11377
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11798
11378
  }
11799
11379
  function serializeExponentialHistogramDataPoint(writer, dataPoint) {
11800
- const start = writer.startLengthDelimited();
11380
+ const start2 = writer.startLengthDelimited();
11801
11381
  const startPos = writer.pos;
11802
11382
  const histogram = dataPoint.value;
11803
11383
  if (dataPoint.attributes) {
@@ -11831,7 +11411,7 @@ var require_metrics_serializer = __commonJS({
11831
11411
  writer.writeTag(13, 1);
11832
11412
  writer.writeDouble(histogram.max);
11833
11413
  }
11834
- writer.finishLengthDelimited(start, writer.pos - startPos);
11414
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11835
11415
  }
11836
11416
  function serializeMetric(writer, metricData) {
11837
11417
  const metricStart = writer.startLengthDelimited();
@@ -11871,16 +11451,16 @@ var require_metrics_serializer = __commonJS({
11871
11451
  writer.finishLengthDelimited(metricStart, writer.pos - metricStartPos);
11872
11452
  }
11873
11453
  function serializeGauge(writer, metricData) {
11874
- const start = writer.startLengthDelimited();
11454
+ const start2 = writer.startLengthDelimited();
11875
11455
  const startPos = writer.pos;
11876
11456
  for (const dataPoint of metricData.dataPoints) {
11877
11457
  writer.writeTag(1, 2);
11878
11458
  serializeNumberDataPoint(writer, dataPoint, metricData.descriptor.valueType);
11879
11459
  }
11880
- writer.finishLengthDelimited(start, writer.pos - startPos);
11460
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11881
11461
  }
11882
11462
  function serializeSum(writer, metricData) {
11883
- const start = writer.startLengthDelimited();
11463
+ const start2 = writer.startLengthDelimited();
11884
11464
  const startPos = writer.pos;
11885
11465
  for (const dataPoint of metricData.dataPoints) {
11886
11466
  writer.writeTag(1, 2);
@@ -11895,10 +11475,10 @@ var require_metrics_serializer = __commonJS({
11895
11475
  writer.writeTag(3, 0);
11896
11476
  writer.writeVarint(1);
11897
11477
  }
11898
- writer.finishLengthDelimited(start, writer.pos - startPos);
11478
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11899
11479
  }
11900
11480
  function serializeHistogramMetric(writer, metricData) {
11901
- const start = writer.startLengthDelimited();
11481
+ const start2 = writer.startLengthDelimited();
11902
11482
  const startPos = writer.pos;
11903
11483
  for (const dataPoint of metricData.dataPoints) {
11904
11484
  writer.writeTag(1, 2);
@@ -11909,10 +11489,10 @@ var require_metrics_serializer = __commonJS({
11909
11489
  writer.writeTag(2, 0);
11910
11490
  writer.writeVarint(temporality);
11911
11491
  }
11912
- writer.finishLengthDelimited(start, writer.pos - startPos);
11492
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11913
11493
  }
11914
11494
  function serializeExponentialHistogramMetric(writer, metricData) {
11915
- const start = writer.startLengthDelimited();
11495
+ const start2 = writer.startLengthDelimited();
11916
11496
  const startPos = writer.pos;
11917
11497
  for (const dataPoint of metricData.dataPoints) {
11918
11498
  writer.writeTag(1, 2);
@@ -11923,7 +11503,7 @@ var require_metrics_serializer = __commonJS({
11923
11503
  writer.writeTag(2, 0);
11924
11504
  writer.writeVarint(temporality);
11925
11505
  }
11926
- writer.finishLengthDelimited(start, writer.pos - startPos);
11506
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11927
11507
  }
11928
11508
  function serializeScopeMetrics(writer, scopeMetrics) {
11929
11509
  const scopeStart = writer.startLengthDelimited();
@@ -11940,7 +11520,7 @@ var require_metrics_serializer = __commonJS({
11940
11520
  writer.finishLengthDelimited(scopeStart, writer.pos - scopeStartPos);
11941
11521
  }
11942
11522
  function serializeResourceMetrics(writer, resourceMetrics) {
11943
- const start = writer.startLengthDelimited();
11523
+ const start2 = writer.startLengthDelimited();
11944
11524
  const startPos = writer.pos;
11945
11525
  (0, common_serializer_1.writeResource)(writer, resourceMetrics.resource, 1);
11946
11526
  for (const scopeMetrics of resourceMetrics.scopeMetrics) {
@@ -11951,7 +11531,7 @@ var require_metrics_serializer = __commonJS({
11951
11531
  writer.writeTag(3, 2);
11952
11532
  writer.writeString(resourceMetrics.resource.schemaUrl);
11953
11533
  }
11954
- writer.finishLengthDelimited(start, writer.pos - startPos);
11534
+ writer.finishLengthDelimited(start2, writer.pos - startPos);
11955
11535
  }
11956
11536
  function toProtoAggregationTemporality(temporality) {
11957
11537
  switch (temporality) {
@@ -13104,13 +12684,13 @@ var require_utils9 = __commonJS({
13104
12684
  }
13105
12685
  exports.parsePairKeyValue = parsePairKeyValue;
13106
12686
  function parseBaggageHeaderString(value, baggage, count, totalSize) {
13107
- let start = 0;
13108
- while (start < value.length && count < constants_1.BAGGAGE_MAX_NAME_VALUE_PAIRS) {
13109
- const end = value.indexOf(constants_1.BAGGAGE_ITEMS_SEPARATOR, start);
12687
+ let start2 = 0;
12688
+ while (start2 < value.length && count < constants_1.BAGGAGE_MAX_NAME_VALUE_PAIRS) {
12689
+ const end = value.indexOf(constants_1.BAGGAGE_ITEMS_SEPARATOR, start2);
13110
12690
  const entryEnd = end === -1 ? value.length : end;
13111
- const entryLength = entryEnd - start;
12691
+ const entryLength = entryEnd - start2;
13112
12692
  if (entryLength <= constants_1.BAGGAGE_MAX_PER_NAME_VALUE_PAIRS) {
13113
- const keyPair = parsePairKeyValue(value.substring(start, entryEnd));
12693
+ const keyPair = parsePairKeyValue(value.substring(start2, entryEnd));
13114
12694
  if (keyPair) {
13115
12695
  const entrySize = (count === 0 ? 0 : 1) + entryLength;
13116
12696
  if (totalSize + entrySize > constants_1.BAGGAGE_MAX_TOTAL_LENGTH)
@@ -13122,7 +12702,7 @@ var require_utils9 = __commonJS({
13122
12702
  }
13123
12703
  if (end === -1)
13124
12704
  break;
13125
- start = end + 1;
12705
+ start2 = end + 1;
13126
12706
  }
13127
12707
  return [count, totalSize];
13128
12708
  }
@@ -17711,168 +17291,6 @@ var require_src10 = __commonJS({
17711
17291
  }
17712
17292
  });
17713
17293
 
17714
- // ../core/dist/redact.js
17715
- var PEM_PATTERN_NAME = "PEM private key block";
17716
- var PRIVATE_KEY_BLOCK = /-----BEGIN ([A-Z ]*)PRIVATE KEY-----[\s\S]*?(?:-----END \1PRIVATE KEY-----|$)/;
17717
- var SECRET_SHAPE_PATTERNS = [
17718
- { name: "Google API key (AIza)", pattern: /(?<![A-Za-z0-9_-])AIza[0-9A-Za-z_-]{35}(?![A-Za-z0-9_-])/ },
17719
- { name: "Anthropic API key (sk-ant-)", pattern: /(?<![A-Za-z0-9_-])sk-ant-[A-Za-z0-9_-]{90,}/ },
17720
- { name: "generic sk- secret key (OpenAI-shaped)", pattern: /(?<![A-Za-z0-9_-])sk-[A-Za-z0-9]{40,}/ },
17721
- { name: "GitHub personal access token (classic, ghp_)", pattern: /(?<!\w)ghp_\w{36}(?!\w)/ },
17722
- { name: "GitHub OAuth token (gho_)", pattern: /(?<!\w)gho_\w{36}(?!\w)/ },
17723
- { name: "GitHub fine-grained PAT", pattern: /(?<!\w)github_pat_\w{80,}/ },
17724
- { name: "npm access token", pattern: /(?<!\w)npm_\w{36}(?!\w)/ },
17725
- { name: "Slack token", pattern: /(?<![A-Za-z0-9-])xox[baprs]-[A-Za-z0-9-]{12,}/ },
17726
- { name: "AWS access key ID", pattern: /(?<![0-9A-Z])AKIA[0-9A-Z]{16}(?![0-9A-Z])/ },
17727
- { name: "Fastmail app password (fm2_)", pattern: /(?<![A-Za-z0-9+/=])fm2_[A-Za-z0-9+/=]{20,}/ },
17728
- { name: PEM_PATTERN_NAME, pattern: PRIVATE_KEY_BLOCK }
17729
- ];
17730
- var AGENT_FAILURE_TOKEN_SHAPES = [
17731
- /AIza[\w-]+/,
17732
- // Google API key
17733
- /AQ\.[\w.\/-]+/,
17734
- // AI Studio key
17735
- /sk-[\w.-]+/,
17736
- // OpenAI-style secret key
17737
- /gh[pousr]_\w+/,
17738
- // GitHub token
17739
- /github_pat_\w+/,
17740
- // GitHub fine-grained token
17741
- /ya29\.[\w.-]+/,
17742
- // Google OAuth access token
17743
- /eyJ[\w-]+\.[\w-]+(?:\.[\w-]+)?/
17744
- // JWT
17745
- ];
17746
- var AGENT_FAILURE_SECRET_SHAPE_RE = new RegExp(`\\b(?:${AGENT_FAILURE_TOKEN_SHAPES.map((shape) => shape.source).join("|")})`, "g");
17747
- var IPV4_OCTET = "(?:25[0-5]|2[0-4]\\d|[01]?\\d?\\d)";
17748
- var PHONE_SEPARATOR = "[\\s.-]?";
17749
- var PHONE_COUNTRY_CODE = /(?:\+?\d{1,3}[\s.-]?)?/;
17750
- var PHONE_AREA_CODE = /(?:\(\d{3}\)|\d{3})/;
17751
- var PATTERNS = [
17752
- // Langfuse public/secret keys (pk-lf- / sk-lf-). Must run before the
17753
- // generic sk- rule so the more specific label wins.
17754
- { name: "langfuse_key", regex: /\b(?:pk|sk)-lf-[A-Za-z0-9-]{16,}\b/g },
17755
- // Anthropic / OpenAI-style keys: 'sk-' + optional sub-prefix + base64-ish.
17756
- // Both vendors plus a long tail of OpenAI-compatible providers (DeepSeek,
17757
- // MiniMax, Together, etc.) ship keys in this shape, so a single rule
17758
- // covers most "sk-..." secrets a user might paste into a prompt.
17759
- { name: "sk_key", regex: /\bsk-(?:proj-|live-|test-|ant-)?[A-Za-z0-9_-]{20,}\b/g },
17760
- // GitHub personal / OAuth / server / user-server / refresh tokens.
17761
- { name: "github_token", regex: /\bgh[opsur]_[A-Za-z0-9]{36,}\b/g },
17762
- // GitHub legacy 40-hex personal access tokens that ship with no prefix
17763
- // are indistinguishable from a sha1 hash, so we don't try to match them
17764
- // here — false positives would be brutal in commit logs / artifact slugs.
17765
- // AWS access key id. The matching secret access key is just 40 base64
17766
- // chars with no fixed shape, so we cannot reliably redact it without
17767
- // huge collateral damage; flagging the access key id at least
17768
- // signals a paste happened.
17769
- { name: "aws_access_key", regex: /\bAKIA[0-9A-Z]{16}\b/g },
17770
- // Google API keys — legacy AIza… (Maps / AI Studio) and service-account-
17771
- // bound AQ.… keys AI Studio now issues. AQ. must run before the generic
17772
- // sk_ rule would mis-label unrelated tokens.
17773
- { name: "google_api_key", regex: /\bAQ\.[A-Za-z0-9_-]{20,}\b/g },
17774
- { name: "google_api_key", regex: /\bAIza[0-9A-Za-z_-]{35}\b/g },
17775
- // Slack tokens.
17776
- { name: "slack_token", regex: /\bxox[abprs]-[0-9A-Za-z-]{10,}\b/g },
17777
- // Stripe keys.
17778
- { name: "stripe_key", regex: /\b(?:sk|pk|rk)_(?:live|test)_[0-9a-zA-Z]{16,}\b/g },
17779
- // JSON Web Tokens. The "header.payload.signature" triple is distinctive
17780
- // enough that false positives are rare (the literal "eyJ" prefix is the
17781
- // base64 encoding of '{"' which is how every JOSE header starts).
17782
- { name: "jwt", regex: /(?<!\w)(?<!(?<!\w)eyJ[A-Za-z0-9_-]*?)eyJ[A-Za-z0-9_-]+\.eyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\b/g },
17783
- // Bearer tokens in HTTP Authorization header copy/paste. We only match
17784
- // the value, not the literal 'Bearer ', so the marker stays readable in
17785
- // the redacted output ("Authorization: Bearer [REDACTED:bearer_token]").
17786
- // The leading lookahead only lets the lookbehind run where a value can start, so a long
17787
- // whitespace run is not rescanned from every position inside it.
17788
- { name: "bearer_token", regex: /(?=[A-Za-z0-9._~+/-])(?<=\bBearer\s+)[A-Za-z0-9._~+/-]{16,}={0,2}/g },
17789
- // Email addresses. Conservative enough to require a TLD-like trailer. The local part is
17790
- // bounded at the RFC 5321 limit of 64: an unbounded run rescanned the suffix from every word
17791
- // boundary, so `'a.'.repeat(20000)` blocked ~3 s on a large tool response. Matching starts at
17792
- // the `@` and reads the local part in a lookbehind (captured as `local`): starting at every word
17793
- // boundary still cost up to 64 steps per position, ~2.5 s on 10 MiB of `'eyJ-'`.
17794
- // Alphabetic TLDs preserve versioned package paths in error stacks (e.g. pkg@1.2.3).
17795
- { name: "email", regex: /@(?<=\b(?<local>[\w.+-]{1,64})@)(?:[\w-]+\.)+[A-Za-z]{2,}\b/g },
17796
- // IPv4. Reject all-zero / 255.255.255.255-ish junk shapes by gating on
17797
- // each octet being 0-255.
17798
- {
17799
- name: "ipv4",
17800
- regex: new RegExp(`\\b(?:${IPV4_OCTET}\\.){3}${IPV4_OCTET}\\b`, "g")
17801
- },
17802
- // Phone numbers. Tight US-leaning shape; a global PII detector would
17803
- // need a real lib. We keep this so US-based test prompts ('call me at
17804
- // (415) 555-...') don't ship. Note: no leading \b — '(' isn't a word
17805
- // char, so a starting boundary would refuse to match `(415)`. Reject
17806
- // adjacent word characters or hyphens so digit segments of UUIDs,
17807
- // hashes and identifiers stay readable; separators within phones still match.
17808
- {
17809
- name: "phone",
17810
- regex: new RegExp(`(?<![\\w-])${PHONE_COUNTRY_CODE.source}${PHONE_AREA_CODE.source}${PHONE_SEPARATOR}\\d{3}${PHONE_SEPARATOR}\\d{4}(?![\\w-])`, "g")
17811
- }
17812
- ];
17813
- var CATEGORY = {
17814
- exactSecret: "exact_secret",
17815
- credential: "credential",
17816
- urlCredentials: "url_credentials",
17817
- signedQuery: "signed_query",
17818
- apiKeyHeader: "api_key_header",
17819
- apiKeyQuery: "api_key_query",
17820
- bearerToken: "bearer_token",
17821
- labeledSecret: "labeled_secret",
17822
- urlSecretParam: "url_secret_param",
17823
- opaqueToken: "opaque_token",
17824
- creditCard: "credit_card"
17825
- };
17826
- var GENERATED_CATEGORIES = [...PATTERNS.map(({ name }) => name), ...Object.values(CATEGORY)];
17827
- function escapeRegExp(text2) {
17828
- return text2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
17829
- }
17830
- function markerSource(categories) {
17831
- return `\\[REDACTED:(?:${[...new Set(categories)].map(escapeRegExp).join("|")})\\]`;
17832
- }
17833
- var GENERATED_MARKER = markerSource(GENERATED_CATEGORIES);
17834
- var GENERATED_MARKER_RE = new RegExp(GENERATED_MARKER, "g");
17835
- var QUOTED_SECRET_VALUE = String.raw`"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'`;
17836
- var API_KEY_HEADER = new RegExp(`(^|[^?&\\w])(["']?)(x-api-key|api-key|x-goog-api-key)\\2(\\s*[:=]\\s*)(${QUOTED_SECRET_VALUE}|[^\\s,;"'#}]+)`, "gi");
17837
- var SECRET_LABELS = "authorization|bearer|api[-_]?key|access[-_]?token|refresh[-_]?token|client[-_]?secret|password|secret|cookie";
17838
- var SERIALIZED_SECRET_LABELS = `${SECRET_LABELS}|x[-_](?:goog[-_])?api[-_]?key|api key|token|set[-_]cookie|private[-_]?key`;
17839
- var EMPTY_QUOTED_ASSIGNMENT_RE = new RegExp(`\\b(?:${SERIALIZED_SECRET_LABELS})\\s*[:=]\\s*$`, "i");
17840
- var LABELED_SECRET_RE = new RegExp(`\\b(${SECRET_LABELS})\\b\\s*[:=]\\s*\\S+`, "gi");
17841
- var CORRELATION_ID = "ERR-[0-9A-F]{4}(?:-[0-9A-F]{4}){3}";
17842
- var UPPER_SNAKE_DIAGNOSTIC = "[A-Z][A-Z0-9]*(?:_[A-Z0-9]+)+";
17843
- var NON_SECRET_TOKEN_RE = new RegExp(`^(?:${CORRELATION_ID}|delegated-tool-calls|${UPPER_SNAKE_DIAGNOSTIC})$`);
17844
- var RUNTIME_SECRET_LABELS = `${SERIALIZED_SECRET_LABELS}|(?<![?&])(?:key)`;
17845
- var MASK_AWARE_LABELED_SECRET_RE = new RegExp(`(?<![\\w-])(["']?)(${RUNTIME_SECRET_LABELS})\\1\\s*[:=]\\s*(?!Bearer\\s+\\S)(?!${GENERATED_MARKER}[;&])((?!&)\\S)`, "gi");
17846
- var CHAINED_LABEL_RE = new RegExp(`(?:${RUNTIME_SECRET_LABELS})\\b["']?\\s*[:=]\\s*(?=\\S)`, "iy");
17847
- var SHORT_BEARER_RE = new RegExp(`Bearer\\s+["']?(?!${GENERATED_MARKER}(?=$|[\\s"',;<>}]))(?=([^\\s"',;<>}]+))`, "gi");
17848
- var URL_SECRET_WORDS = "token|key|secret|signature|sig|code|password|passwd|pwd|auth|authorization|credential";
17849
- var URL_SECRET_PARAM_RE = new RegExp(`[?&#;]([\\w.-]{0,128}?(?:${URL_SECRET_WORDS})s?(?=[._=-])[\\w.-]{0,128})=[^&;\\s"'<>()]+`, "gi");
17850
- var LABELED_URL_PARAM_NAME_RE = new RegExp(`(?:^|[.-])(?:${SECRET_LABELS})$`, "i");
17851
- var MASKED_VALUE_RE = new RegExp(`^["']?${GENERATED_MARKER}["']?$`);
17852
- var PII_PATTERN_NAMES = ["email", "ipv4", "phone"];
17853
- var NON_PII_PATTERNS = PATTERNS.filter((pattern) => !PII_PATTERN_NAMES.includes(pattern.name));
17854
- var PII_PATTERNS = PATTERNS.filter((pattern) => PII_PATTERN_NAMES.includes(pattern.name));
17855
-
17856
- // ../core/dist/primitives/trim-chars.js
17857
- function trimCharsEnd({ text: text2, chars }) {
17858
- let end = text2.length;
17859
- while (end > 0 && chars.includes(text2.charAt(end - 1)))
17860
- end -= 1;
17861
- return text2.slice(0, end);
17862
- }
17863
-
17864
- // ../plugins/dist/host/provider-host.js
17865
- var PluginProviderStartupError = class extends Error {
17866
- reason;
17867
- action;
17868
- constructor({ reason, action, cause }, _optional = {}) {
17869
- super(reason, { cause });
17870
- this.name = "PluginProviderStartupError";
17871
- this.reason = reason;
17872
- this.action = action;
17873
- }
17874
- };
17875
-
17876
17294
  // ../core/dist/text/line-tail.js
17877
17295
  var LINE_TERMINATOR = /[\n\r\u2028\u2029]/;
17878
17296
  function captureLineTail({ rest }, { minWhitespace = 0 } = {}) {
@@ -17887,7 +17305,17 @@ function captureLineTail({ rest }, { minWhitespace = 0 } = {}) {
17887
17305
  return LINE_TERMINATOR.test(last) ? null : last;
17888
17306
  }
17889
17307
 
17890
- // ../plugins/dist/host/provider-setting-required.js
17308
+ // ../core/dist/contracts/plugin-sdk.js
17309
+ var PluginProviderStartupError = class extends Error {
17310
+ reason;
17311
+ action;
17312
+ constructor({ reason, action, cause }, _optional = {}) {
17313
+ super(reason, { cause });
17314
+ this.name = "PluginProviderStartupError";
17315
+ this.reason = reason;
17316
+ this.action = action;
17317
+ }
17318
+ };
17891
17319
  function hasProviderAuthHeader({ text: text2, names }, _optional = {}) {
17892
17320
  const pairs = text2.split(",").map((pair) => headerPair(pair.trim()));
17893
17321
  if (pairs.some((pair) => !pair))
@@ -17902,549 +17330,31 @@ function headerPair(pair) {
17902
17330
  return value === null ? null : [pair.slice(0, eq).trimEnd(), value];
17903
17331
  }
17904
17332
 
17905
- // ../diagnostics/dist/core/secrets-only.js
17906
- var import_js_tokens = __toESM(require_js_tokens(), 1);
17907
- function withGlobalFlag(flags) {
17908
- return flags.includes("g") ? flags : `${flags}g`;
17909
- }
17910
- var REUSED_CREDENTIAL_RULES = SECRET_SHAPE_PATTERNS.map((vendor) => ({
17911
- kind: "credential",
17912
- pattern: new RegExp(vendor.pattern.source, withGlobalFlag(vendor.pattern.flags)),
17913
- replacement: () => "[REDACTED:credential]"
17914
- }));
17915
- var LABELED_SECRET_LABELS = "password|passwd|pwd|secret|client_secret|api_key|apikey|access_token|refresh_token|id_token|auth_token|token|private_key|secret_access_key|signing_secret|webhook_secret";
17916
- var AUTH_HEADER_NAMES = "(?:proxy-)?authorization|x-api-key|api-key|x-goog-api-key|x-auth-token";
17917
- var AUTH_SCHEMES = "Bearer|Basic|Token|Digest|ApiKey";
17918
- var AUTH_VALUE = String.raw`(?!\[REDACTED)(?:(?!\x60(?=[\s"'.,);]|$))[^\s"'),;])+`;
17919
- var AUTH_HEADER_VALUE_RE = new RegExp(String.raw`(?<![a-z0-9-])(${AUTH_HEADER_NAMES})(\s*(?:["']\s*)?[:=]\s*["']?)` + String.raw`(?:((?:${AUTH_SCHEMES})\s+)${AUTH_VALUE}|(?!(?:${AUTH_SCHEMES})(?:\s|["'\x60),;]|$))${AUTH_VALUE})`, "gi");
17920
- var REDACTION_RULES = [
17921
- {
17922
- kind: "private_key",
17923
- // Matches a full PEM block, including a truncated one with no `-----END-----` line (the
17924
- // `$` alternative). `\1` backreferences the captured key type (e.g. "RSA ") so a
17925
- // "BEGIN RSA PRIVATE KEY" block cannot be closed by an unrelated "END EC PRIVATE KEY" line.
17926
- pattern: /-----BEGIN ([A-Z ]*)PRIVATE KEY-----[\s\S]*?(?:-----END \1PRIVATE KEY-----|$)/g,
17927
- replacement: () => "[REDACTED:private_key]"
17928
- },
17929
- {
17930
- kind: "auth_header",
17931
- // The value is ONE token after an optional known scheme, never the rest of the line — a
17932
- // rest-of-line value would eat a trailing IP/cause in a message like `request failed
17933
- // (Authorization: Bearer <tok>): connect ECONNREFUSED 10.0.4.7:443`.
17934
- //
17935
- // Split into two non-overlapping alternatives (scheme+value vs. no-scheme+value) rather than
17936
- // one optional scheme group, for idempotency: with a single optional group, a second pass over
17937
- // already-redacted text (`Authorization: Bearer [REDACTED:auth_header]`) would fail the
17938
- // `(?!\[REDACTED)` lookahead on the "with scheme" attempt, backtrack the optional group away,
17939
- // and then match the bare word "Bearer" itself as the "value" — corrupting already-redacted
17940
- // text. The second alternative explicitly refuses a scheme keyword followed by whitespace
17941
- // or a value terminator, so when the first alternative's lookahead fails there is no fallback left to
17942
- // backtrack into, and the whole rule correctly finds no match on a second pass.
17943
- // Scheme names without a following value (including Markdown's `Authorization: Bearer`)
17944
- // describe a header; they are not themselves credentials.
17945
- pattern: AUTH_HEADER_VALUE_RE,
17946
- replacement: ({ match: m }) => `${m[1]}${m[2]}${m[3] ?? ""}[REDACTED:auth_header]`
17947
- },
17948
- {
17949
- kind: "auth_header",
17950
- pattern: /(?<![a-z0-9-])((?:set-)?cookie)(\s*[:=]\s*)(?!\[REDACTED)[^\s"'),;]+(?:;\s*[^\s"'),;]+)*/gi,
17951
- replacement: ({ match: m }) => `${m[1]}${m[2]}[REDACTED:auth_header]`
17952
- },
17953
- {
17954
- kind: "url_credentials",
17955
- // Host, port, IP and path all stay — only the `user:pass@` half is replaced. The password class
17956
- // ADMITS `@` and backtracks to the LAST one before the authority ends (2026-09-16 security
17957
- // review): a password that was never percent-encoded — `postgres://u:p@ss4@host/db` — otherwise
17958
- // matched only up to its FIRST `@`, leaving the tail (`ss4`) of the password in the output.
17959
- // `?` is excluded so a query string's own `@` cannot drag the match past the authority.
17960
- // Find the delimiter before checking the original scheme grammar. Starting at each word
17961
- // boundary rescans long dashed runs quadratically; delimiter-first checks disjoint runs once.
17962
- // The scheme stays outside the replacement, including suffixes after malformed prefixes.
17963
- pattern: /:\/\/(?<=\b[a-z][a-z0-9+.-]*:\/\/)(?!\[REDACTED)[^\s/@:]+:[^\s/?]+@/gi,
17964
- replacement: () => "://[REDACTED:url_credentials]@"
17965
- },
17966
- ...REUSED_CREDENTIAL_RULES,
17967
- {
17968
- kind: "stripe_key",
17969
- pattern: /(?<!\w)(?:sk|rk)_(?:live|test)_[0-9A-Za-z]{16,}/g,
17970
- replacement: () => "[REDACTED:stripe_key]"
17971
- },
17972
- {
17973
- kind: "stripe_key",
17974
- pattern: /(?<!\w)whsec_[A-Za-z0-9]{24,}/g,
17975
- replacement: () => "[REDACTED:stripe_key]"
17976
- },
17977
- {
17978
- kind: "github_token",
17979
- // Covers `ghs_`/`ghu_`/`ghr_` and lengths the exact-length SECRET_SHAPE_PATTERNS entries miss.
17980
- pattern: /(?<!\w)gh[pousr]_[A-Za-z0-9]{30,}/g,
17981
- replacement: () => "[REDACTED:github_token]"
17982
- },
17983
- {
17984
- kind: "openai_key",
17985
- pattern: /(?<![A-Za-z0-9_-])sk-(?:proj|svcacct|admin)-[A-Za-z0-9_-]{20,}/g,
17986
- replacement: () => "[REDACTED:openai_key]"
17987
- },
17988
- {
17989
- kind: "anthropic_key",
17990
- // SECRET_SHAPE_PATTERNS' own `sk-ant-` entry needs 90+ trailing characters, which is right for the
17991
- // repo-wide static check (a committed key is whole) but wrong here (2026-09-16 security review):
17992
- // an upstream 401 often echoes a TRUNCATED key, and `sk-[A-Za-z0-9]{40,}` cannot cover it either
17993
- // because `sk-ant-api03-` carries hyphens. The prefix alone is specific enough at this length.
17994
- pattern: /(?<![A-Za-z0-9_-])sk-ant-[A-Za-z0-9_-]{20,}/g,
17995
- replacement: () => "[REDACTED:anthropic_key]"
17996
- },
17997
- {
17998
- kind: "google_api_key",
17999
- pattern: /(?<![A-Za-z0-9_.-])AQ\.[A-Za-z0-9_-]{20,}/g,
18000
- replacement: () => "[REDACTED:google_api_key]"
18001
- },
18002
- {
18003
- kind: "aws_access_key",
18004
- pattern: /(?<![0-9A-Z])ASIA[0-9A-Z]{16}(?![0-9A-Z])/g,
18005
- replacement: () => "[REDACTED:aws_access_key]"
18006
- },
18007
- {
18008
- kind: "jwt",
18009
- pattern: /(?<![A-Za-z0-9_-])eyJ[A-Za-z0-9_-]{8,}\.eyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,}/g,
18010
- replacement: () => "[REDACTED:jwt]"
18011
- },
18012
- {
18013
- kind: "bearer_token",
18014
- // Bare scheme outside a header line. The value must be at least 16 characters AND contain a
18015
- // digit, so ordinary prose ("Bearer token", "Basic authentication is not supported") is
18016
- // untouched.
18017
- pattern: /\b(Bearer|Basic|Token)\s+(?!\[REDACTED)(?=[A-Za-z0-9._~+/=:-]*\d)[A-Za-z0-9._~+/=:-]{16,}/g,
18018
- replacement: ({ match: m }) => `${m[1]} [REDACTED:bearer_token]`
18019
- },
18020
- {
18021
- kind: "labeled_secret",
18022
- // Assignment form only — never a bare prose colon (`password: must be...` is untouched).
18023
- pattern: new RegExp(`(?<![A-Za-z0-9])(${LABELED_SECRET_LABELS})(\\s*=\\s*)(?!\\[REDACTED)([^\\s"'&,;})]+)`, "gi"),
18024
- replacement: ({ match: m }) => `${m[1]}${m[2]}[REDACTED:labeled_secret]`
18025
- },
18026
- {
18027
- kind: "labeled_secret",
18028
- // JSON form: `"label":"value"`.
18029
- pattern: new RegExp(`"(${LABELED_SECRET_LABELS})"(\\s*:\\s*)"(?!\\[REDACTED)[^"]+"`, "gi"),
18030
- replacement: ({ match: m }) => `"${m[1]}"${m[2]}"[REDACTED:labeled_secret]"`
18031
- },
18032
- {
18033
- kind: "labeled_secret",
18034
- // Multi-word quoted keys can hold credentials too; translated phrases with spaces stay prose.
18035
- pattern: new RegExp(String.raw`(["'])((?:[A-Za-z0-9_-]{1,32}[ \t]+){1,6}(?:${LABELED_SECRET_LABELS}))\1(\s*:\s*)(["'])(?!\[REDACTED)[^\s"'\\]{12,}\4`, "gi"),
18036
- replacement: ({ match: m }) => `${m[1]}${m[2]}${m[1]}${m[3]}${m[4]}[REDACTED:labeled_secret]${m[4]}`
18037
- },
18038
- {
18039
- kind: "labeled_secret",
18040
- // Colon form: `api_key: <value>`, `{ api_key: 'value' }`, `\"api_key\":\"value\"` (2026-09-16
18041
- // security review). The `=` and double-quoted-JSON rules above miss every one of these, and they
18042
- // are the shapes a real failure arrives in most often — `util.inspect` of a request config, a
18043
- // YAML/pretty-printed body, or a JSON error body embedded inside ANOTHER JSON string, where the
18044
- // escaped `\"` defeats the plain JSON rule.
18045
- //
18046
- // Prose is kept out by the VALUE's own shape rather than by banning the colon: a quoted value is
18047
- // always taken, an unquoted one only when it is a single ≥12-character token. That is what keeps
18048
- // this file's Must NOT change list intact — `password: must be at least 8 characters` stops at
18049
- // the 4-character `must`, and `token expired at ...` has no colon at all.
18050
- // Match the whole key; multi-word labels above additionally require an opaque value.
18051
- pattern: new RegExp(`(?<![A-Za-z0-9])((?:\\\\?["'])?)((?:[A-Za-z0-9]{1,32}[_-]){0,6}(?:${LABELED_SECRET_LABELS}))\\1(\\s*:\\s*)(?:(\\\\?["'])(?!\\[REDACTED)[^"'\\\\\\r\\n]+\\4|(?!\\[REDACTED)[^\\s"',;}]{12,})`, "gi"),
18052
- replacement: ({ match: m }) => `${m[1]}${m[2]}${m[1]}${m[3]}${m[4] ?? ""}[REDACTED:labeled_secret]${m[4] ?? ""}`
18053
- },
18054
- {
18055
- kind: "labeled_secret",
18056
- // Query-string form: `?key=value` / `&token=value`.
18057
- pattern: /([?&](?:key|api_key|api-key|token|access_token|sig|signature)=)(?!\[REDACTED)[^&#\s"']+/gi,
18058
- replacement: ({ match: m }) => `${m[1]}[REDACTED:labeled_secret]`
18059
- }
18060
- ];
18061
- var CODE_VENDOR_RULES = [
18062
- { kind: "google_oauth", pattern: /ya29\.[\w-]{20,}/g, replacement: () => "[REDACTED:google_oauth]" },
18063
- { kind: "sendgrid_key", pattern: /SG\.[\w-]{16,}\.[\w-]{16,}/g, replacement: () => "[REDACTED:sendgrid_key]" }
18064
- ];
18065
- function applyRedactionRules({ text: text2, rules }, _options = {}) {
18066
- let redactions = 0;
18067
- let result = text2;
18068
- for (const rule of rules) {
18069
- result = result.replace(new RegExp(rule.pattern.source, withGlobalFlag(rule.pattern.flags)), (...args) => {
18070
- redactions += 1;
18071
- return rule.replacement({ match: args });
18072
- });
18073
- }
18074
- return { text: result, redactions };
18075
- }
18076
- function hasCredentialEntropy({ content }, _options = {}) {
18077
- const frequencies = /* @__PURE__ */ new Map();
18078
- for (const char of content)
18079
- frequencies.set(char, (frequencies.get(char) ?? 0) + 1);
18080
- let entropy = 0;
18081
- for (const count of frequencies.values()) {
18082
- const probability = count / content.length;
18083
- entropy -= probability * Math.log2(probability);
18084
- }
18085
- return entropy >= 3.5;
18086
- }
18087
- function isCredentialLiteral({ content }, _options = {}) {
18088
- if (content.length < 20 || /\s/.test(content) || !/[a-z]/i.test(content) || !/\d/.test(content))
18089
- return false;
18090
- if (!/^[A-Za-z0-9_\-+/=.]{20,}$/.test(content))
18091
- return false;
18092
- if (/^[a-f0-9]{20,40}$/i.test(content))
18093
- return false;
18094
- if (content.includes("/") || /^[\w$-]+(?:\.[\w$-]+)+$/.test(content))
18095
- return false;
18096
- return hasCredentialEntropy({ content });
18097
- }
18098
- function isFirstNamedCallArgument({ previous, separator, name }, _options = {}) {
18099
- if (separator !== "," || name.type !== "StringLiteral" || previous.at(-3)?.value !== "(")
18100
- return false;
18101
- const callee = previous.at(-4);
18102
- if (!callee)
18103
- return false;
18104
- return callee.type === "IdentifierName" && !/^(if|while|for|switch|catch|with|function)$/.test(callee.value) || callee.value === ")" || callee.value === "]";
18105
- }
18106
- function hasSecretLiteralContext({ previous }, _options = {}) {
18107
- const separator = previous.at(-1)?.value;
18108
- const name = previous.at(-2);
18109
- if (!name || name.type !== "IdentifierName" && name.type !== "StringLiteral")
18110
- return false;
18111
- const label = name.type === "StringLiteral" ? decodeStaticLiteral({ content: name.value.slice(1, -1) }) : name.value;
18112
- if (!SECRET_LABEL_SUFFIX.test(label))
18113
- return false;
18114
- if (separator === ":" || separator === "=")
18115
- return true;
18116
- return isFirstNamedCallArgument({ previous, separator, name });
18117
- }
18118
- function codeTokenSpan({ token }, _options = {}) {
18119
- switch (token.type) {
18120
- case "StringLiteral":
18121
- case "JSXString":
18122
- case "NoSubstitutionTemplate":
18123
- case "TemplateTail":
18124
- return { start: 1, end: token.value.length - (token.closed ? 1 : 0), literal: true };
18125
- case "TemplateHead":
18126
- case "TemplateMiddle":
18127
- return { start: 1, end: token.value.length - 2, literal: true };
18128
- }
18129
- if (/^(SingleLineComment|MultiLineComment|HashbangComment)$/.test(token.type)) {
18130
- return { start: 0, end: token.value.length, literal: false };
18131
- }
18132
- return void 0;
18133
- }
18134
- function redactUnclassifiedLiteral({ content, adjacentSecret }, _options = {}) {
18135
- const value = content.replace(/^(Bearer|Basic|Token) /i, "");
18136
- if (adjacentSecret && content.length >= 8 && !/\s/.test(value) && !/^[A-Za-z]+(?:[-_.][A-Za-z]+)+$/.test(value)) {
18137
- return { text: "[REDACTED:labeled_secret]", redactions: 1 };
18138
- }
18139
- if (isCredentialLiteral({ content }))
18140
- return { text: "[REDACTED:high_entropy]", redactions: 1 };
18141
- return { text: content, redactions: 0 };
18142
- }
18143
- var SECRET_LABEL_WORDS = [
18144
- "pass(word|wd)?",
18145
- "secret",
18146
- "token",
18147
- "api[-_]?key",
18148
- "access[-_]?key",
18149
- "private[-_]?key",
18150
- "client[-_]?secret",
18151
- "auth(orization)?",
18152
- "bearer",
18153
- "cookie",
18154
- "credential"
18155
- ];
18156
- var SECRET_LABEL_SUFFIX = new RegExp(`(${SECRET_LABEL_WORDS.join("|")})s?$`, "i");
18157
- function decodeStaticLiteral({ content }, _options = {}) {
18158
- const escapes = { n: "\n", r: "\r", t: " ", b: "\b", f: "\f", v: "\v" };
18159
- return content.replace(/\\(u\{[0-9a-fA-F]+\}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{2}|[0-7]{1,3}|\r\n|[\s\S])/g, (_match, sequence) => {
18160
- if (sequence.startsWith("u{")) {
18161
- const point = Number.parseInt(sequence.slice(2, -1), 16);
18162
- return point <= 1114111 ? String.fromCodePoint(point) : "";
18163
- }
18164
- if (/^[ux]/.test(sequence) && sequence.length > 1)
18165
- return String.fromCharCode(Number.parseInt(sequence.slice(1), 16));
18166
- if (/^[0-7]+$/.test(sequence))
18167
- return String.fromCharCode(Number.parseInt(sequence, 8));
18168
- if (/^[\r\n]/.test(sequence))
18169
- return "";
18170
- return escapes[sequence] ?? sequence;
18171
- });
18172
- }
18173
- function redactCodeTokenContent({ content, literal, adjacentSecret, policy }, _options = {}) {
18174
- const strict = redactSecretShapes({ text: content, policy: { ...policy, codeAware: false } });
18175
- const vendor = applyRedactionRules({ text: strict.text, rules: CODE_VENDOR_RULES });
18176
- if (literal && strict.redactions === 0 && vendor.text === content && !content.includes("[REDACTED:")) {
18177
- return redactUnclassifiedLiteral({ content, adjacentSecret });
18178
- }
18179
- return { text: vendor.text, redactions: strict.redactions + vendor.redactions };
18180
- }
18181
- function renderRedactedLiteral({ content, classified, result }, _options = {}) {
18182
- if (result.redactions === 0)
18183
- return content;
18184
- if (content === classified)
18185
- return result.text;
18186
- return result.text.match(/\[REDACTED:[^\]]+\]/)?.[0] ?? "[REDACTED:escaped_secret]";
18187
- }
18188
- function rememberSignificantCodeToken({ previous, token }, _options = {}) {
18189
- if (/^(WhiteSpace|LineTerminatorSequence|SingleLineComment|MultiLineComment|HashbangComment)$/.test(token.type))
18190
- return;
18191
- previous.push(token);
18192
- if (previous.length > 4)
18193
- previous.shift();
18194
- }
18195
- function redactCodeLiterals({ source, policy }, { jsx = true } = {}) {
18196
- const parts = [];
18197
- let redactions = 0;
18198
- const tokens = jsx ? (0, import_js_tokens.default)(source, { jsx: true }) : (0, import_js_tokens.default)(source);
18199
- const previous = [];
18200
- for (const token of tokens) {
18201
- const adjacentSecret = /^(StringLiteral|NoSubstitutionTemplate|TemplateHead)$/.test(token.type) && hasSecretLiteralContext({ previous });
18202
- rememberSignificantCodeToken({ previous, token });
18203
- const span = codeTokenSpan({ token });
18204
- if (!span) {
18205
- parts.push(token.value);
18206
- continue;
18207
- }
18208
- const { start, end, literal } = span;
18209
- const content = token.value.slice(start, end);
18210
- const classified = literal ? decodeStaticLiteral({ content }) : content;
18211
- const result = redactCodeTokenContent({ content: classified, literal, adjacentSecret, policy });
18212
- redactions += result.redactions;
18213
- parts.push(token.value.slice(0, start), renderRedactedLiteral({ content, classified, result }), token.value.slice(end));
18214
- }
18215
- return { text: parts.join(""), redactions };
18216
- }
18217
- var CONTEXT_RULE_KINDS = /* @__PURE__ */ new Set(["auth_header", "url_credentials", "bearer_token", "labeled_secret"]);
18218
- function redactSecretShapes({ text: text2, policy }) {
18219
- if (text2.length === 0)
18220
- return { text: text2, redactions: 0 };
18221
- if (policy.vendorOnly) {
18222
- const vendorRules = REDACTION_RULES.filter((rule) => !CONTEXT_RULE_KINDS.has(rule.kind));
18223
- return applyRedactionRules({ text: text2, rules: [...vendorRules, ...CODE_VENDOR_RULES, ...policy.additionalRules ?? []] });
18224
- }
18225
- if (policy.codeAware) {
18226
- const jsx = redactCodeLiterals({ source: text2, policy });
18227
- const plain = redactCodeLiterals({ source: jsx.text, policy }, { jsx: false });
18228
- return { text: plain.text, redactions: jsx.redactions + plain.redactions };
18229
- }
18230
- const applicationRuleSlot = REDACTION_RULES.findIndex((rule) => rule.kind === "bearer_token");
18231
- const rules = [
18232
- ...REDACTION_RULES.slice(0, applicationRuleSlot),
18233
- ...policy.additionalRules ?? [],
18234
- ...REDACTION_RULES.slice(applicationRuleSlot)
18235
- ];
18236
- return applyRedactionRules({ text: text2, rules });
18237
- }
18238
-
18239
- // ../diagnostics/dist/observability/otel.js
18240
- function fallbackErrorLabel(error) {
18241
- return error instanceof Error ? String(error.name) : typeof error;
18242
- }
18243
- function errorType(error) {
18244
- const code = error?.code;
18245
- const label = typeof code === "string" && /^[A-Z][A-Z0-9_]{1,63}$/.test(code) ? code : fallbackErrorLabel(error);
18246
- return redactLabel(label).slice(0, MAX_ERROR_TYPE) || "Error";
18247
- }
18248
- var MAX_ERROR_TYPE = 64;
18249
- var MAX_ATTRIBUTE_TEXT = 256;
18250
- var MAX_ATTRIBUTES = 64;
18251
- var ATTRIBUTE_KEY = /^[a-zA-Z][a-zA-Z0-9_.-]{0,63}$/;
18252
- function redactLabel(text2) {
18253
- return redactSecretShapes({ text: text2, policy: {} }).text;
18254
- }
18255
- function redactOperationAttributes({ attributes }) {
18256
- const safe = {};
18257
- const names = Object.keys(attributes).filter((name) => ATTRIBUTE_KEY.test(name) && redactLabel(name) === name);
18258
- for (const name of names.slice(0, MAX_ATTRIBUTES)) {
18259
- const value = attributes[name];
18260
- safe[name] = typeof value === "string" ? redactLabel(value).slice(0, MAX_ATTRIBUTE_TEXT) : value;
18261
- }
18262
- return safe;
18263
- }
18264
- function safePathSegment({ segment }, _options = {}) {
18265
- let decoded;
18266
- try {
18267
- decoded = decodeURIComponent(segment);
18268
- } catch {
18269
- return ":param";
18270
- }
18271
- if (decoded === "")
18272
- return "";
18273
- if (!/^[a-zA-Z-]{1,24}$/.test(decoded))
18274
- return ":param";
18275
- if (/^[a-fA-F]{8,}$/.test(decoded) || decoded.length >= 16)
18276
- return ":param";
18277
- return decoded;
18278
- }
18279
- function withoutQueryOrFragment(target) {
18280
- const cut = target.search(/[?#]/);
18281
- return cut === -1 ? target : target.slice(0, cut);
18282
- }
18283
- function redactRequestTarget({ path }, { routePattern } = {}) {
18284
- if (routePattern && routePattern !== "unmatched")
18285
- return withoutQueryOrFragment(routePattern).slice(0, 1024);
18286
- return withoutQueryOrFragment(path).split("/").map((segment) => safePathSegment({ segment })).join("/").slice(0, 1024);
18287
- }
18288
- function outboundTargetAttributes(url) {
18289
- let parsed;
18290
- try {
18291
- parsed = new URL(url);
18292
- } catch {
18293
- return { "server.address": "invalid-url" };
18294
- }
18295
- return {
18296
- "url.scheme": parsed.protocol.replace(/:$/, ""),
18297
- "server.address": parsed.hostname,
18298
- ...parsed.port ? { "server.port": Number(parsed.port) } : {}
18299
- };
18300
- }
18301
- var FAILED_RUN_STATUSES = /* @__PURE__ */ new Set(["failed", "interrupted"]);
18302
- function once(handler) {
18303
- let ended = false;
18304
- return (outcome) => {
18305
- if (ended)
18306
- return;
18307
- ended = true;
18308
- handler(outcome);
18309
- };
18310
- }
18311
- function createOtelObservabilityPort({ config, exporterFactory, tracerProviderFactory }, { scope } = {}) {
18312
- const exporter = exporterFactory.create({ endpoint: config.endpoint });
18313
- const provider = tracerProviderFactory.create({ serviceName: config.serviceName, exporter });
18314
- const tracer = provider.getTracer({ name: config.tracerName });
18315
- const reportedSpans = /* @__PURE__ */ new WeakSet();
18316
- function finish({ span, attributes }, { failure, error } = {}) {
18317
- for (const [name, value] of Object.entries(attributes))
18318
- span.setAttribute({ name, value });
18319
- if (failure !== void 0 && !reportedSpans.has(span)) {
18320
- span.setAttribute({ name: "error.type", value: failure });
18321
- span.setStatus({ code: "error", description: failure });
18322
- if (error !== void 0)
18323
- span.addEvent({ name: "exception", attributes: { "exception.type": failure } });
18324
- }
18325
- span.end({});
18326
- }
18327
- function start({ name, kind, attributes }, { root = false } = {}) {
18328
- const parent = root ? void 0 : scope?.active();
18329
- return tracer.startSpan({ name, kind, attributes }, parent ? { parent } : {});
18330
- }
18331
- function runIn(span) {
18332
- return (fn) => scope ? scope.run({ span, fn }) : fn();
18333
- }
18334
- return {
18335
- supportsMetric: false,
18336
- activeTraceIds: (_required = {}, _optional = {}) => scope?.active()?.ids?.(),
18337
- // This structural tracing adapter has no metrics exporter; the provider plugin supplies it.
18338
- metric() {
18339
- },
18340
- trackRequest(input, { requestId } = {}) {
18341
- const span = start({ name: input.method, kind: "server", attributes: {
18342
- "http.method": input.method,
18343
- "http.target": redactRequestTarget({ path: input.path }),
18344
- ...requestId ? { "http.request.id": requestId } : {}
18345
- } });
18346
- return { ...requestId ? { requestId } : {}, run: runIn(span), end: once((outcome) => {
18347
- span.updateName({ name: `${input.method} ${outcome.routePattern}` });
18348
- span.setAttribute({ name: "http.route", value: outcome.routePattern });
18349
- span.setAttribute({ name: "http.target", value: redactRequestTarget({ path: input.path }, { routePattern: outcome.routePattern }) });
18350
- span.setAttribute({ name: "http.status_code", value: outcome.statusCode });
18351
- if (outcome.statusCode >= 500 && !reportedSpans.has(span))
18352
- span.setStatus({ code: "error" });
18353
- span.end({});
18354
- }) };
18355
- },
18356
- trackDbQuery({ system }) {
18357
- const span = start({ name: "db", kind: "client", attributes: { "db.system.name": system } });
18358
- return { run: runIn(span), end: once(({ operation, table, error }) => {
18359
- const op = operation.toUpperCase();
18360
- span.updateName({ name: table ? `${op} ${table}` : op });
18361
- finish({ span, attributes: { "db.operation.name": op, ...table ? { "db.collection.name": table } : {} } }, error !== void 0 ? { failure: errorType(error), error } : {});
18362
- }) };
18363
- },
18364
- trackOutboundCall({ method, url }) {
18365
- const target = outboundTargetAttributes(url);
18366
- const span = start({ name: `${method} ${target["server.address"]}`, kind: "client", attributes: { "http.request.method": method, ...target } });
18367
- return { run: runIn(span), end: once(({ statusCode, error }) => {
18368
- const attributes = statusCode !== void 0 ? { "http.response.status_code": statusCode } : {};
18369
- if (error !== void 0) {
18370
- finish({ span, attributes }, { failure: errorType(error), error });
18371
- return;
18372
- }
18373
- finish({ span, attributes }, statusCode !== void 0 && statusCode >= 400 ? { failure: String(statusCode) } : {});
18374
- }) };
18375
- },
18376
- trackOperation({ name, attributes = {} }) {
18377
- const span = start({ name, kind: "internal", attributes: redactOperationAttributes({ attributes }) });
18378
- return { run: runIn(span), end: once(({ outcome, failed, attributes: settled = {} }) => {
18379
- finish({ span, attributes: redactOperationAttributes({ attributes: { ...settled, "operation.outcome": outcome } }) }, failed ? { failure: redactLabel(outcome) } : {});
18380
- }) };
18381
- },
18382
- reportError({ error, context }) {
18383
- try {
18384
- const active = scope?.active();
18385
- const span = active ?? start({ name: `error ${context.operation}`, kind: "internal", attributes: redactOperationAttributes({ attributes: context.attributes ?? {} }) }, { root: true });
18386
- const type = errorType(error);
18387
- span.addEvent({ name: "exception", attributes: { "exception.type": type, "operation.name": context.operation } });
18388
- span.setAttribute({ name: "error.type", value: type });
18389
- span.setStatus({ code: "error", description: type });
18390
- reportedSpans.add(span);
18391
- if (!active)
18392
- span.end({});
18393
- return true;
18394
- } catch {
18395
- return false;
18396
- }
18397
- },
18398
- trackAgentRun({ runId }, { conversationId, agentName } = {}) {
18399
- const span = start({ name: agentName ? `invoke_agent ${agentName}` : "invoke_agent", kind: "internal", attributes: {
18400
- "gen_ai.operation.name": "invoke_agent",
18401
- ...agentName ? { "gen_ai.agent.name": agentName } : {},
18402
- ...conversationId ? { "gen_ai.conversation.id": conversationId } : {},
18403
- "agent.run.id": runId
18404
- } }, { root: true });
18405
- return { run: runIn(span), end: once(({ status, error }) => {
18406
- const attributes = { "agent.run.status": status };
18407
- if (error !== void 0) {
18408
- finish({ span, attributes }, { failure: errorType(error), error });
18409
- return;
18410
- }
18411
- finish({ span, attributes }, FAILED_RUN_STATUSES.has(status) ? { failure: status } : {});
18412
- }) };
18413
- }
18414
- };
18415
- }
18416
-
18417
- // ../diagnostics/dist/observability/config.js
18418
- function resolveObservabilityConfig({ serviceName, tracerName }, { endpoint, tracesEndpoint } = {}) {
18419
- const traces = tracesEndpoint?.trim();
18420
- const base = endpoint?.trim();
18421
- if (!traces && !base)
18422
- return { enabled: false };
18423
- if (!serviceName.trim())
18424
- throw new TypeError("serviceName must be non-empty");
18425
- if (!tracerName.trim())
18426
- throw new TypeError("tracerName must be non-empty");
18427
- return { enabled: true, serviceName: serviceName.trim(), tracerName: tracerName.trim(), endpoint: traces || `${trimCharsEnd({ text: base, chars: "/" })}/v1/traces` };
18428
- }
18429
-
18430
- // ../diagnostics/dist/observability/delivery.js
18431
- var ERROR_CLASSES = /* @__PURE__ */ new Set(["Error", "TypeError", "RangeError", "TimeoutError", "AbortError", "OTLPExporterError", "PluginProviderError"]);
18432
- function httpStatus(value) {
18433
- if (typeof value !== "number" || !Number.isInteger(value))
18434
- return void 0;
18435
- return value >= 100 && value <= 599 ? value : void 0;
18436
- }
18437
- function describeTelemetryFailure({ error }, _options = {}) {
18438
- if (typeof error !== "object" || error === null)
18439
- return { errorClass: "Error" };
18440
- try {
18441
- const value = error;
18442
- const errorClass = typeof value.name === "string" && ERROR_CLASSES.has(value.name) ? value.name : "Error";
18443
- const statusCode = httpStatus(value.statusCode ?? value.status ?? value.code);
18444
- return { errorClass, ...statusCode === void 0 ? {} : { statusCode } };
18445
- } catch {
18446
- return { errorClass: "Error" };
17333
+ // src/observability-opentelemetry/configuration.ts
17334
+ var HELPERS = ["redactOperationAttributes", "errorType", "redactLabel", "describeReportedError", "describeTelemetryFailure", "resolveObservabilityConfig"];
17335
+ var OpenTelemetryProviderConfigError = class extends Error {
17336
+ code = "observability_opentelemetry_context_missing";
17337
+ details;
17338
+ constructor(required, _optional = {}) {
17339
+ super("The OpenTelemetry exporter was started without the redaction helpers it needs, so it will not send anything. Restart the app; if this keeps happening, copy the details into a bug report.");
17340
+ this.name = "OpenTelemetryProviderConfigError";
17341
+ this.details = required.details;
18447
17342
  }
17343
+ };
17344
+ function readOpenTelemetryHost({ context, scope }, _optional = {}) {
17345
+ const record = context !== null && typeof context === "object" ? context : {};
17346
+ const missing = HELPERS.filter((name) => typeof record[name] !== "function");
17347
+ const scopeRecord = scope !== null && typeof scope === "object" ? scope : {};
17348
+ if (typeof scopeRecord.active !== "function" || typeof scopeRecord.run !== "function") missing.push("scope");
17349
+ if (missing.length > 0) throw new OpenTelemetryProviderConfigError({ details: `optional.context / optional.scope is missing: ${missing.join(", ")}` });
17350
+ return { scope, context: {
17351
+ redactOperationAttributes: record.redactOperationAttributes,
17352
+ errorType: record.errorType,
17353
+ redactLabel: record.redactLabel,
17354
+ describeReportedError: record.describeReportedError,
17355
+ describeTelemetryFailure: record.describeTelemetryFailure,
17356
+ resolveObservabilityConfig: record.resolveObservabilityConfig
17357
+ } };
18448
17358
  }
18449
17359
 
18450
17360
  // ../../node_modules/.pnpm/@opentelemetry+api@1.10.0/node_modules/@opentelemetry/api/dist/version.mjs
@@ -19326,7 +18236,7 @@ function createBoundedQueueExportPromiseHandler(options) {
19326
18236
  }
19327
18237
 
19328
18238
  // ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.221.0_@opentelemetry+api@1.10.0/node_modules/@opentelemetry/otlp-exporter-base/build/esm/otlp-export-delegate.js
19329
- var import_core2 = __toESM(require_src());
18239
+ var import_core = __toESM(require_src());
19330
18240
 
19331
18241
  // ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.221.0_@opentelemetry+api@1.10.0/node_modules/@opentelemetry/otlp-exporter-base/build/esm/logging-response-handler.js
19332
18242
  function isPartialSuccessResponse(response) {
@@ -19367,7 +18277,7 @@ var OTLPExportDelegate = class {
19367
18277
  this._diagLogger.debug("items to be sent", internalRepresentation);
19368
18278
  if (this._promiseQueue.hasReachedLimit()) {
19369
18279
  resultCallback({
19370
- code: import_core2.ExportResultCode.FAILED,
18280
+ code: import_core.ExportResultCode.FAILED,
19371
18281
  error: new Error("Concurrent export limit reached")
19372
18282
  });
19373
18283
  return;
@@ -19375,7 +18285,7 @@ var OTLPExportDelegate = class {
19375
18285
  const serializedRequest = this._serializer.serializeRequest(internalRepresentation);
19376
18286
  if (serializedRequest == null) {
19377
18287
  resultCallback({
19378
- code: import_core2.ExportResultCode.FAILED,
18288
+ code: import_core.ExportResultCode.FAILED,
19379
18289
  error: new Error("Nothing to send")
19380
18290
  });
19381
18291
  return;
@@ -19392,33 +18302,33 @@ var OTLPExportDelegate = class {
19392
18302
  }
19393
18303
  }
19394
18304
  resultCallback({
19395
- code: import_core2.ExportResultCode.SUCCESS
18305
+ code: import_core.ExportResultCode.SUCCESS
19396
18306
  });
19397
18307
  return;
19398
18308
  } else if (response.status === "failure" && response.error) {
19399
18309
  finishExport(response.error);
19400
18310
  resultCallback({
19401
- code: import_core2.ExportResultCode.FAILED,
18311
+ code: import_core.ExportResultCode.FAILED,
19402
18312
  error: response.error
19403
18313
  });
19404
18314
  return;
19405
18315
  } else if (response.status === "retryable") {
19406
18316
  finishExport("export_max_retries");
19407
18317
  resultCallback({
19408
- code: import_core2.ExportResultCode.FAILED,
18318
+ code: import_core.ExportResultCode.FAILED,
19409
18319
  error: response.error ?? new OTLPExporterError("Export failed with retryable status")
19410
18320
  });
19411
18321
  } else {
19412
18322
  finishExport("export_failed");
19413
18323
  resultCallback({
19414
- code: import_core2.ExportResultCode.FAILED,
18324
+ code: import_core.ExportResultCode.FAILED,
19415
18325
  error: new OTLPExporterError("Export failed with unknown error")
19416
18326
  });
19417
18327
  }
19418
18328
  }, (reason) => {
19419
18329
  finishExport(reason);
19420
18330
  resultCallback({
19421
- code: import_core2.ExportResultCode.FAILED,
18331
+ code: import_core.ExportResultCode.FAILED,
19422
18332
  error: reason
19423
18333
  });
19424
18334
  }));
@@ -19440,7 +18350,7 @@ function createOtlpExportDelegate(components, settings) {
19440
18350
  }
19441
18351
 
19442
18352
  // ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.221.0_@opentelemetry+api@1.10.0/node_modules/@opentelemetry/otlp-exporter-base/build/esm/ExporterMetrics.js
19443
- var import_core3 = __toESM(require_src());
18353
+ var import_core2 = __toESM(require_src());
19444
18354
 
19445
18355
  // ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.221.0_@opentelemetry+api@1.10.0/node_modules/@opentelemetry/otlp-exporter-base/build/esm/semconv.js
19446
18356
  var ATTR_HTTP_RESPONSE_STATUS_CODE2 = "http.response.status_code";
@@ -19513,10 +18423,10 @@ var ExporterMetrics = class {
19513
18423
  }
19514
18424
  startExport(request) {
19515
18425
  const numItems = this.helper.countItems(request);
19516
- const startTime = (0, import_core3.hrTime)();
18426
+ const startTime = (0, import_core2.hrTime)();
19517
18427
  this.inflight.add(numItems, this.standardAttrs);
19518
18428
  return (error) => {
19519
- const endTime = (0, import_core3.hrTime)();
18429
+ const endTime = (0, import_core2.hrTime)();
19520
18430
  this.inflight.add(-numItems, this.standardAttrs);
19521
18431
  const exportedAttrs = error ? {
19522
18432
  ...this.standardAttrs,
@@ -19527,7 +18437,7 @@ var ExporterMetrics = class {
19527
18437
  ...exportedAttrs,
19528
18438
  ...this.responseAttributesFromError(error)
19529
18439
  };
19530
- const duration = (0, import_core3.hrTimeToMilliseconds)((0, import_core3.hrTimeDuration)(startTime, endTime)) / 1e3;
18440
+ const duration = (0, import_core2.hrTimeToMilliseconds)((0, import_core2.hrTimeDuration)(startTime, endTime)) / 1e3;
19531
18441
  this.duration.record(duration, durationAttrs);
19532
18442
  };
19533
18443
  }
@@ -19829,15 +18739,160 @@ var import_sdk_trace_base = __toESM(require_index_shim(), 1);
19829
18739
  var import_sdk_metrics = __toESM(require_src4(), 1);
19830
18740
  var import_sdk_trace_node = __toESM(require_src10(), 1);
19831
18741
 
19832
- // ../diagnostics/dist/observability/node.js
19833
- import { AsyncLocalStorage } from "node:async_hooks";
19834
- function createAsyncLocalSpanScope(_required) {
19835
- const storage = new AsyncLocalStorage();
19836
- return { active: () => storage.getStore(), run: ({ span, fn }) => storage.run(span, fn) };
18742
+ // src/observability-opentelemetry/otel-port.ts
18743
+ function safePathSegment({ segment }, _options = {}) {
18744
+ let decoded;
18745
+ try {
18746
+ decoded = decodeURIComponent(segment);
18747
+ } catch {
18748
+ return ":param";
18749
+ }
18750
+ if (decoded === "") return "";
18751
+ if (!/^[a-zA-Z-]{1,24}$/.test(decoded)) return ":param";
18752
+ if (/^[a-fA-F]{8,}$/.test(decoded) || decoded.length >= 16) return ":param";
18753
+ return decoded;
18754
+ }
18755
+ function withoutQueryOrFragment(target) {
18756
+ const cut = target.search(/[?#]/);
18757
+ return cut === -1 ? target : target.slice(0, cut);
18758
+ }
18759
+ function redactRequestTarget({ path }, { routePattern } = {}) {
18760
+ if (routePattern && routePattern !== "unmatched") return withoutQueryOrFragment(routePattern).slice(0, 1024);
18761
+ return withoutQueryOrFragment(path).split("/").map((segment) => safePathSegment({ segment })).join("/").slice(0, 1024);
18762
+ }
18763
+ function outboundTargetAttributes(url) {
18764
+ let parsed;
18765
+ try {
18766
+ parsed = new URL(url);
18767
+ } catch {
18768
+ return { "server.address": "invalid-url" };
18769
+ }
18770
+ return {
18771
+ "url.scheme": parsed.protocol.replace(/:$/, ""),
18772
+ "server.address": parsed.hostname,
18773
+ ...parsed.port ? { "server.port": Number(parsed.port) } : {}
18774
+ };
18775
+ }
18776
+ var FAILED_RUN_STATUSES = /* @__PURE__ */ new Set(["failed", "interrupted"]);
18777
+ function once(handler) {
18778
+ let ended = false;
18779
+ return (outcome) => {
18780
+ if (ended) return;
18781
+ ended = true;
18782
+ handler(outcome);
18783
+ };
18784
+ }
18785
+ function finish({ ctx, span, attributes }, { failure, error } = {}) {
18786
+ for (const [name, value] of Object.entries(attributes)) span.setAttribute({ name, value });
18787
+ if (failure !== void 0 && !ctx.reportedSpans.has(span)) {
18788
+ span.setAttribute({ name: "error.type", value: failure });
18789
+ span.setStatus({ code: "error", description: failure });
18790
+ if (error !== void 0) span.addEvent({ name: "exception", attributes: { "exception.type": failure } });
18791
+ }
18792
+ span.end({});
18793
+ }
18794
+ function finishWithOutcome({ ctx, span, attributes }, { error, softFailure } = {}) {
18795
+ if (error !== void 0) {
18796
+ finish({ ctx, span, attributes }, { failure: ctx.helpers.errorType({ error }), error });
18797
+ return;
18798
+ }
18799
+ finish({ ctx, span, attributes }, softFailure !== void 0 ? { failure: softFailure } : {});
18800
+ }
18801
+ function start({ ctx, name, kind, attributes }, { root = false } = {}) {
18802
+ const parent = root ? void 0 : ctx.scope?.active();
18803
+ return ctx.tracer.startSpan({ name, kind, attributes }, parent ? { parent } : {});
18804
+ }
18805
+ function runIn({ ctx, span }) {
18806
+ return (fn) => ctx.scope ? ctx.scope.run({ span, fn }) : fn();
18807
+ }
18808
+ function trackRequest({ ctx, input, requestId }) {
18809
+ const span = start({ ctx, name: input.method, kind: "server", attributes: {
18810
+ "http.method": input.method,
18811
+ "http.target": redactRequestTarget({ path: input.path }),
18812
+ ...requestId ? { "http.request.id": requestId } : {}
18813
+ } });
18814
+ return { ...requestId ? { requestId } : {}, run: runIn({ ctx, span }), end: once((outcome) => {
18815
+ span.updateName({ name: `${input.method} ${outcome.routePattern}` });
18816
+ span.setAttribute({ name: "http.route", value: outcome.routePattern });
18817
+ span.setAttribute({ name: "http.target", value: redactRequestTarget({ path: input.path }, { routePattern: outcome.routePattern }) });
18818
+ span.setAttribute({ name: "http.status_code", value: outcome.statusCode });
18819
+ if (outcome.statusCode >= 500 && !ctx.reportedSpans.has(span)) span.setStatus({ code: "error" });
18820
+ span.end({});
18821
+ }) };
18822
+ }
18823
+ function trackDbQuery({ ctx, system }) {
18824
+ const span = start({ ctx, name: "db", kind: "client", attributes: { "db.system.name": system } });
18825
+ return { run: runIn({ ctx, span }), end: once(({ operation, table, error }) => {
18826
+ const op = operation.toUpperCase();
18827
+ span.updateName({ name: table ? `${op} ${table}` : op });
18828
+ finishWithOutcome({ ctx, span, attributes: { "db.operation.name": op, ...table ? { "db.collection.name": table } : {} } }, { error });
18829
+ }) };
18830
+ }
18831
+ function trackOutboundCall({ ctx, method, url }) {
18832
+ const target = outboundTargetAttributes(url);
18833
+ const span = start({ ctx, name: `${method} ${target["server.address"]}`, kind: "client", attributes: { "http.request.method": method, ...target } });
18834
+ return { run: runIn({ ctx, span }), end: once(({ statusCode, error }) => {
18835
+ const attributes = statusCode !== void 0 ? { "http.response.status_code": statusCode } : {};
18836
+ finishWithOutcome({ ctx, span, attributes }, { error, ...statusCode !== void 0 && statusCode >= 400 ? { softFailure: String(statusCode) } : {} });
18837
+ }) };
18838
+ }
18839
+ function trackOperation({ ctx, name, attributes = {} }) {
18840
+ const { redactOperationAttributes, redactLabel } = ctx.helpers;
18841
+ const span = start({ ctx, name, kind: "internal", attributes: redactOperationAttributes({ attributes }) });
18842
+ return { run: runIn({ ctx, span }), end: once(({ outcome, failed, attributes: settled = {} }) => {
18843
+ finish({ ctx, span, attributes: redactOperationAttributes({ attributes: { ...settled, "operation.outcome": outcome } }) }, failed ? { failure: redactLabel({ text: outcome }) } : {});
18844
+ }) };
18845
+ }
18846
+ function reportError({ ctx, error, context }) {
18847
+ const { errorType, redactOperationAttributes } = ctx.helpers;
18848
+ try {
18849
+ const active = ctx.scope?.active();
18850
+ const span = active ?? start({ ctx, name: `error ${context.operation}`, kind: "internal", attributes: redactOperationAttributes({ attributes: context.attributes ?? {} }) }, { root: true });
18851
+ const type = errorType({ error });
18852
+ span.addEvent({ name: "exception", attributes: { "exception.type": type, "operation.name": context.operation } });
18853
+ span.setAttribute({ name: "error.type", value: type });
18854
+ span.setStatus({ code: "error", description: type });
18855
+ ctx.reportedSpans.add(span);
18856
+ if (!active) span.end({});
18857
+ return true;
18858
+ } catch {
18859
+ return false;
18860
+ }
18861
+ }
18862
+ function trackAgentRun({ ctx, runId, conversationId, agentName }) {
18863
+ const startedAt = ctx.metric ? performance.now() : 0;
18864
+ const span = start({ ctx, name: agentName ? `invoke_agent ${agentName}` : "invoke_agent", kind: "internal", attributes: {
18865
+ "gen_ai.operation.name": "invoke_agent",
18866
+ ...agentName ? { "gen_ai.agent.name": agentName } : {},
18867
+ ...conversationId ? { "gen_ai.conversation.id": conversationId } : {},
18868
+ "agent.run.id": runId
18869
+ } }, { root: true });
18870
+ return { run: runIn({ ctx, span }), end: once(({ status, error }) => {
18871
+ finishWithOutcome({ ctx, span, attributes: { "agent.run.status": status } }, { error, ...FAILED_RUN_STATUSES.has(status) ? { softFailure: status } : {} });
18872
+ ctx.metric?.({ name: "agent.run.duration", value: performance.now() - startedAt }, { kind: "histogram", unit: "ms" });
18873
+ }) };
18874
+ }
18875
+ function createOtelObservabilityPort({ config, exporterFactory, tracerProviderFactory }, { scope, helpers, metric }) {
18876
+ const exporter = exporterFactory.create({ endpoint: config.endpoint });
18877
+ const provider = tracerProviderFactory.create({ serviceName: config.serviceName, exporter });
18878
+ const ctx = { tracer: provider.getTracer({ name: config.tracerName }), scope, helpers, metric, reportedSpans: /* @__PURE__ */ new WeakSet() };
18879
+ return {
18880
+ supportsMetric: false,
18881
+ activeTraceIds: (_required = {}, _optional = {}) => scope?.active()?.ids?.(),
18882
+ // This structural tracing adapter has no metrics exporter; the provider plugin supplies it.
18883
+ metric() {
18884
+ },
18885
+ trackRequest: (input, { requestId } = {}) => trackRequest({ ctx, input, ...requestId ? { requestId } : {} }),
18886
+ trackDbQuery: ({ system }) => trackDbQuery({ ctx, system }),
18887
+ trackOutboundCall: ({ method, url }) => trackOutboundCall({ ctx, method, url }),
18888
+ trackOperation: ({ name, attributes }) => trackOperation({ ctx, name, ...attributes ? { attributes } : {} }),
18889
+ reportError: ({ error, context }) => reportError({ ctx, error, context }),
18890
+ trackAgentRun: ({ runId }, { conversationId, agentName } = {}) => trackAgentRun({ ctx, runId, ...conversationId ? { conversationId } : {}, ...agentName ? { agentName } : {} })
18891
+ };
19837
18892
  }
19838
18893
 
19839
18894
  // src/telemetry-reporter.ts
19840
- function createProviderTelemetryReporter({ endpoint }, optional = {}) {
18895
+ function createProviderTelemetryReporter({ endpoint, describeTelemetryFailure }, optional = {}) {
19841
18896
  const host = URL.canParse(endpoint) ? new URL(endpoint).hostname : "invalid-endpoint";
19842
18897
  return {
19843
18898
  initialized({ message }, _options = {}) {
@@ -19942,7 +18997,7 @@ function adaptTracer({ tracer }, _options = {}) {
19942
18997
  }
19943
18998
  };
19944
18999
  }
19945
- function createOtelFactories(_required, options = {}) {
19000
+ function createOtelFactories({ describeTelemetryFailure }, options = {}) {
19946
19001
  const providers = [];
19947
19002
  const exporterPipelines = /* @__PURE__ */ new WeakMap();
19948
19003
  return {
@@ -19955,7 +19010,7 @@ function createOtelFactories(_required, options = {}) {
19955
19010
  const exporter = createInjectedOtlpTraceExporter({ url: endpoint }, options);
19956
19011
  exporterPipelines.set(exporter, createReportingExporter({
19957
19012
  exporter,
19958
- reporter: createProviderTelemetryReporter({ endpoint }, options)
19013
+ reporter: createProviderTelemetryReporter({ endpoint, describeTelemetryFailure }, options)
19959
19014
  }, options));
19960
19015
  return exporter;
19961
19016
  }
@@ -19985,7 +19040,7 @@ function resolveMetricsEndpoint({ tracesEndpoint }, { endpoint } = {}) {
19985
19040
  if (/\/v1\/traces(?=[?#]|$)/.test(tracesEndpoint)) return tracesEndpoint.replace(/\/v1\/traces(?=[?#]|$)/, "/v1/metrics");
19986
19041
  return new URL("/v1/metrics", tracesEndpoint).href;
19987
19042
  }
19988
- function createMetricProvider({ config }, options = {}) {
19043
+ function createMetricProvider({ config, describeTelemetryFailure }, options = {}) {
19989
19044
  const endpoint = resolveMetricsEndpoint({ tracesEndpoint: config.endpoint }, options);
19990
19045
  const readers = options.exportEnabled !== true ? [] : options.metricReaders ?? [new import_sdk_metrics.PeriodicExportingMetricReader({
19991
19046
  exporter: createReportingExporter({
@@ -19995,7 +19050,7 @@ function createMetricProvider({ config }, options = {}) {
19995
19050
  component: "otlp_http_metric_exporter",
19996
19051
  helper: import_otlp_transformer.MetricsExporterMetricsHelper
19997
19052
  }, options),
19998
- reporter: createProviderTelemetryReporter({ endpoint }, options)
19053
+ reporter: createProviderTelemetryReporter({ endpoint, describeTelemetryFailure }, options)
19999
19054
  }, options),
20000
19055
  exportIntervalMillis: 6e4,
20001
19056
  exportTimeoutMillis: 3e4
@@ -20007,20 +19062,20 @@ var RECORD_METRIC = {
20007
19062
  gauge: ({ meter, name, value, settings, attributes }) => meter.createGauge(name, settings).record(value, attributes),
20008
19063
  histogram: ({ meter, name, value, settings, attributes }) => meter.createHistogram(name, settings).record(value, attributes)
20009
19064
  };
20010
- function createMetrics({ config }, options = {}) {
19065
+ function createMetrics({ config, context }, options = {}) {
20011
19066
  let provider;
20012
19067
  let closed = false;
20013
19068
  return {
20014
19069
  metric({ name, value }, { kind = "gauge", unit, attributes = {} } = {}) {
20015
19070
  if (closed || !Number.isFinite(value)) return;
20016
19071
  if (name.length > 255) return;
20017
- provider ??= createMetricProvider({ config }, options);
19072
+ provider ??= createMetricProvider({ config, describeTelemetryFailure: context.describeTelemetryFailure }, options);
20018
19073
  RECORD_METRIC[kind]({
20019
19074
  meter: provider.getMeter(config.tracerName),
20020
19075
  name,
20021
19076
  value,
20022
19077
  settings: unit === void 0 ? {} : { unit },
20023
- attributes: redactOperationAttributes({ attributes })
19078
+ attributes: context.redactOperationAttributes({ attributes })
20024
19079
  });
20025
19080
  },
20026
19081
  async shutdown() {
@@ -20029,11 +19084,11 @@ function createMetrics({ config }, options = {}) {
20029
19084
  }
20030
19085
  };
20031
19086
  }
20032
- function createOtelObservabilityAdapter({ config }, options = {}) {
20033
- const reporter = createProviderTelemetryReporter({ endpoint: config.endpoint }, options);
20034
- const { shutdown, ...factories } = createOtelFactories({}, options);
20035
- const metrics = createMetrics({ config }, options);
20036
- const port = { ...createOtelObservabilityPort({ config, ...factories }, { scope: createAsyncLocalSpanScope({}) }), metric: metrics.metric, supportsMetric: true };
19087
+ function createOtelObservabilityAdapter({ config, context, scope }, options = {}) {
19088
+ const reporter = createProviderTelemetryReporter({ endpoint: config.endpoint, describeTelemetryFailure: context.describeTelemetryFailure }, options);
19089
+ const { shutdown, ...factories } = createOtelFactories({ describeTelemetryFailure: context.describeTelemetryFailure }, options);
19090
+ const metrics = createMetrics({ config, context }, options);
19091
+ const port = { ...createOtelObservabilityPort({ config, ...factories }, { scope, helpers: { errorType: context.errorType, redactOperationAttributes: context.redactOperationAttributes, redactLabel: context.redactLabel }, ...options.exportEnabled === true ? { metric: metrics.metric } : {} }), metric: metrics.metric, supportsMetric: true };
20037
19092
  reporter.initialized({ message: options.exportEnabled === true ? "OpenTelemetry exporting" : "OpenTelemetry export disabled" });
20038
19093
  return { port, dispose: async () => {
20039
19094
  try {
@@ -20071,7 +19126,7 @@ var jini_plugin_default = {
20071
19126
  engine: 1,
20072
19127
  tier: "tier-3",
20073
19128
  extensions: {
20074
- tovu: {
19129
+ jini: {
20075
19130
  id: "jini/observability-opentelemetry"
20076
19131
  },
20077
19132
  "open-marketing": {
@@ -20208,7 +19263,8 @@ function createOpenTelemetryProvider(required, optional = {}) {
20208
19263
  const endpoint = text(required.endpoint, "endpoint");
20209
19264
  const tracesEndpoint = text(required.tracesEndpoint, "tracesEndpoint");
20210
19265
  const serviceName = text(required.serviceName, "serviceName");
20211
- const config = resolveObservabilityConfig({
19266
+ const { context, scope } = readOpenTelemetryHost({ context: optional.context, scope: optional.scope });
19267
+ const config = context.resolveObservabilityConfig({
20212
19268
  serviceName: serviceName ?? "",
20213
19269
  tracerName: text(required.tracerName, "tracerName") ?? serviceName ?? ""
20214
19270
  }, { ...endpoint === void 0 ? {} : { endpoint }, ...tracesEndpoint === void 0 ? {} : { tracesEndpoint } });
@@ -20228,7 +19284,7 @@ function createOpenTelemetryProvider(required, optional = {}) {
20228
19284
  reportTelemetry: optional.reportTelemetry,
20229
19285
  info: optional.info
20230
19286
  };
20231
- const { port, dispose } = startOpenTelemetryAdapter({ config }, options);
19287
+ const { port, dispose } = startOpenTelemetryAdapter({ config, context, scope }, options);
20232
19288
  return { port, dispose: (_required, _optional = {}) => dispose() };
20233
19289
  }
20234
19290
  var index_default = {