@openclaw/googlechat 2026.7.2-beta.7 → 2026.7.33

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 (264) hide show
  1. package/README.md +1 -1
  2. package/dist/.setup/actions-DeT_GgtP.mjs +167 -0
  3. package/dist/.setup/approval-auth-CQP5ZS_f.mjs +27 -0
  4. package/dist/{approval-handler.runtime-CBeHrXtL.js → .setup/approval-handler.runtime-DWNRBf9B.mjs} +5 -6
  5. package/dist/{channel-kouqKs2x.js → .setup/channel-BPjomke4.mjs} +87 -67
  6. package/dist/{channel-base-hw9ErEr5.js → .setup/channel-base-DJICAvKH.mjs} +91 -182
  7. package/dist/{channel.adapters-DaipaeYt.js → .setup/channel.adapters-T6wPzrpo.mjs} +170 -383
  8. package/dist/{channel.runtime-BbwE9vOC.js → .setup/channel.runtime-CpT-qT67.mjs} +241 -440
  9. package/dist/.setup/doctor-contract-BcEqUZ4j.mjs +151 -0
  10. package/dist/{runtime-api-Dh0CNVS4.js → .setup/runtime-api-BbVoWRxq.mjs} +7 -3
  11. package/dist/.setup/secret-contract-api-BGDBptmu.mjs +3 -0
  12. package/dist/.setup/secret-contract-lCMHqumt.mjs +99 -0
  13. package/dist/.setup/setup-plugin-api-BgwvQMls.mjs +5 -0
  14. package/dist/.setup/setup-plugin-api-Ce08GSFO.mjs +2 -0
  15. package/dist/api.js +2 -2
  16. package/dist/channel-config-api.js +2 -1
  17. package/dist/channel-plugin-api.js +1 -1
  18. package/dist/directory-contract-api.js +1 -1
  19. package/dist/doctor-contract-api.js +1 -1
  20. package/dist/runtime-api.js +2 -3
  21. package/dist/secret-contract-api.js +1 -1
  22. package/dist/setup-entry.js +3 -2
  23. package/dist/setup-plugin-api.js +1 -4
  24. package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/gaxios.js +1 -1
  25. package/node_modules/gaxios/build/cjs/src/gaxios.js.map +1 -0
  26. package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.getch.js +0 -66
  27. package/node_modules/gaxios/build/cjs/test/test.getch.js.map +1 -0
  28. package/node_modules/gaxios/build/cjs/tsconfig.cjs.tsbuildinfo +1 -0
  29. package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/gaxios.js +1 -1
  30. package/node_modules/gaxios/build/esm/src/gaxios.js.map +1 -0
  31. package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.getch.js +0 -66
  32. package/node_modules/gaxios/build/esm/test/test.getch.js.map +1 -0
  33. package/node_modules/gaxios/build/esm/tsconfig.tsbuildinfo +1 -0
  34. package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/package.json +4 -4
  35. package/node_modules/google-auth-library/build/src/auth/googleauth.js +19 -24
  36. package/node_modules/google-auth-library/package.json +1 -1
  37. package/openclaw.plugin.json +488 -416
  38. package/package.json +25 -82
  39. package/dist/actions-D81dCtkC.js +0 -68
  40. package/dist/approval-auth-ykO6i_ub.js +0 -30
  41. package/dist/config-api-CsD0IFxF.js +0 -3
  42. package/dist/doctor-contract-BpuSvJro.js +0 -115
  43. package/dist/secret-contract-BFYyuE0F.js +0 -88
  44. package/node_modules/google-auth-library/node_modules/gaxios/build/cjs/src/gaxios.js.map +0 -1
  45. package/node_modules/google-auth-library/node_modules/gaxios/build/cjs/test/test.getch.js.map +0 -1
  46. package/node_modules/google-auth-library/node_modules/gaxios/build/cjs/tsconfig.cjs.tsbuildinfo +0 -1
  47. package/node_modules/google-auth-library/node_modules/gaxios/build/esm/src/gaxios.js.map +0 -1
  48. package/node_modules/google-auth-library/node_modules/gaxios/build/esm/test/test.getch.js.map +0 -1
  49. package/node_modules/google-auth-library/node_modules/gaxios/build/esm/tsconfig.tsbuildinfo +0 -1
  50. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/LICENSE +0 -202
  51. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/README.md +0 -73
  52. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/colours.d.ts +0 -1
  53. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/colours.js +0 -81
  54. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/colours.js.map +0 -1
  55. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/index.d.ts +0 -2
  56. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/index.js +0 -31
  57. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/index.js.map +0 -1
  58. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/logging-utils.d.ts +0 -89
  59. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/logging-utils.js +0 -414
  60. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/logging-utils.js.map +0 -1
  61. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/temporal.d.ts +0 -45
  62. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/temporal.js +0 -68
  63. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/temporal.js.map +0 -1
  64. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/types.d.ts +0 -78
  65. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/types.js +0 -16
  66. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/build/src/types.js.map +0 -1
  67. package/node_modules/google-auth-library/node_modules/gcp-metadata/node_modules/google-logging-utils/package.json +0 -47
  68. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/LICENSE +0 -0
  69. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/README.md +0 -0
  70. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/browser-test-runner.d.ts +0 -0
  71. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/browser-test-runner.js +0 -0
  72. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/browser-test-runner.js.map +0 -0
  73. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/test.browser.d.ts +0 -0
  74. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/test.browser.js +0 -0
  75. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/browser-test/test.browser.js.map +0 -0
  76. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/common.d.ts +0 -0
  77. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/common.js +0 -0
  78. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/common.js.map +0 -0
  79. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/gaxios.d.ts +0 -0
  80. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/index.d.ts +0 -0
  81. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/index.js +0 -0
  82. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/index.js.map +0 -0
  83. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/interceptor.d.ts +0 -0
  84. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/interceptor.js +0 -0
  85. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/interceptor.js.map +0 -0
  86. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/retry.d.ts +0 -0
  87. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/retry.js +0 -0
  88. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/retry.js.map +0 -0
  89. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/util.cjs +0 -0
  90. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/util.cjs.map +0 -0
  91. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/src/util.d.cts +0 -0
  92. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/system-test/test.install.d.ts +0 -0
  93. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/system-test/test.install.js +0 -0
  94. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/system-test/test.install.js.map +0 -0
  95. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.getch.d.ts +0 -0
  96. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.index.d.ts +0 -0
  97. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.index.js +0 -0
  98. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.index.js.map +0 -0
  99. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.retry.d.ts +0 -0
  100. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.retry.js +0 -0
  101. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/cjs/test/test.retry.js.map +0 -0
  102. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/browser-test-runner.d.ts +0 -0
  103. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/browser-test-runner.js +0 -0
  104. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/browser-test-runner.js.map +0 -0
  105. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/test.browser.d.ts +0 -0
  106. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/test.browser.js +0 -0
  107. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/browser-test/test.browser.js.map +0 -0
  108. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/package.json +0 -0
  109. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/common.d.ts +0 -0
  110. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/common.js +0 -0
  111. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/common.js.map +0 -0
  112. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/gaxios.d.ts +0 -0
  113. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/index.d.ts +0 -0
  114. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/index.js +0 -0
  115. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/index.js.map +0 -0
  116. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/interceptor.d.ts +0 -0
  117. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/interceptor.js +0 -0
  118. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/interceptor.js.map +0 -0
  119. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/retry.d.ts +0 -0
  120. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/retry.js +0 -0
  121. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/retry.js.map +0 -0
  122. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/util.cjs +0 -0
  123. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/util.cjs.map +0 -0
  124. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/src/util.d.cts +0 -0
  125. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/system-test/test.install.d.ts +0 -0
  126. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/system-test/test.install.js +0 -0
  127. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/system-test/test.install.js.map +0 -0
  128. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.getch.d.ts +0 -0
  129. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.index.d.ts +0 -0
  130. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.index.js +0 -0
  131. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.index.js.map +0 -0
  132. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.retry.d.ts +0 -0
  133. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.retry.js +0 -0
  134. /package/node_modules/{google-auth-library/node_modules/gaxios → gaxios}/build/esm/test/test.retry.js.map +0 -0
  135. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/LICENSE +0 -0
  136. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/README.md +0 -0
  137. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/helpers.d.ts +0 -0
  138. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/helpers.d.ts.map +0 -0
  139. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/helpers.js +0 -0
  140. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/helpers.js.map +0 -0
  141. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/index.d.ts +0 -0
  142. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/index.d.ts.map +0 -0
  143. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/index.js +0 -0
  144. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/dist/index.js.map +0 -0
  145. /package/node_modules/{google-auth-library → gaxios}/node_modules/agent-base/package.json +0 -0
  146. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/README.md +0 -0
  147. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/dist/index.d.ts +0 -0
  148. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/dist/index.js +0 -0
  149. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/dist/index.js.map +0 -0
  150. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/package.json +0 -0
  151. /package/node_modules/{google-auth-library → gaxios}/node_modules/data-uri-to-buffer/src/index.ts +0 -0
  152. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/LICENSE +0 -0
  153. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/README.md +0 -0
  154. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/package.json +0 -0
  155. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/src/browser.js +0 -0
  156. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/src/common.js +0 -0
  157. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/src/index.js +0 -0
  158. /package/node_modules/{google-auth-library → gaxios}/node_modules/debug/src/node.js +0 -0
  159. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/.editorconfig +0 -0
  160. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/.eslintrc +0 -0
  161. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/.jscs.json +0 -0
  162. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/.travis.yml +0 -0
  163. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/CHANGELOG.md +0 -0
  164. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/LICENSE +0 -0
  165. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/README.md +0 -0
  166. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/component.json +0 -0
  167. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/index.js +0 -0
  168. /package/node_modules/{google-auth-library → gaxios}/node_modules/extend/package.json +0 -0
  169. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/LICENSE +0 -0
  170. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/README.md +0 -0
  171. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/file.d.ts +0 -0
  172. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/file.js +0 -0
  173. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/from.d.ts +0 -0
  174. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/from.js +0 -0
  175. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/index.d.ts +0 -0
  176. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/index.js +0 -0
  177. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/package.json +0 -0
  178. /package/node_modules/{google-auth-library → gaxios}/node_modules/fetch-blob/streams.cjs +0 -0
  179. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/FormData.js +0 -0
  180. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/LICENSE +0 -0
  181. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/README.md +0 -0
  182. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/esm.min.d.ts +0 -0
  183. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/esm.min.js +0 -0
  184. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/formdata-to-blob.js +0 -0
  185. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/formdata.min.js +0 -0
  186. /package/node_modules/{google-auth-library → gaxios}/node_modules/formdata-polyfill/package.json +0 -0
  187. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/LICENSE +0 -0
  188. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/README.md +0 -0
  189. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/index.d.ts +0 -0
  190. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/index.d.ts.map +0 -0
  191. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/index.js +0 -0
  192. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/index.js.map +0 -0
  193. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/parse-proxy-response.d.ts +0 -0
  194. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/parse-proxy-response.d.ts.map +0 -0
  195. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/parse-proxy-response.js +0 -0
  196. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/dist/parse-proxy-response.js.map +0 -0
  197. /package/node_modules/{google-auth-library → gaxios}/node_modules/https-proxy-agent/package.json +0 -0
  198. /package/node_modules/{google-auth-library → gaxios}/node_modules/ms/index.js +0 -0
  199. /package/node_modules/{google-auth-library → gaxios}/node_modules/ms/license.md +0 -0
  200. /package/node_modules/{google-auth-library → gaxios}/node_modules/ms/package.json +0 -0
  201. /package/node_modules/{google-auth-library → gaxios}/node_modules/ms/readme.md +0 -0
  202. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-domexception/LICENSE +0 -0
  203. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-domexception/index.js +0 -0
  204. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-domexception/package.json +0 -0
  205. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/@types/index.d.ts +0 -0
  206. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/LICENSE.md +0 -0
  207. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/README.md +0 -0
  208. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/package.json +0 -0
  209. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/body.js +0 -0
  210. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/errors/abort-error.js +0 -0
  211. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/errors/base.js +0 -0
  212. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/errors/fetch-error.js +0 -0
  213. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/headers.js +0 -0
  214. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/index.js +0 -0
  215. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/request.js +0 -0
  216. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/response.js +0 -0
  217. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/utils/get-search.js +0 -0
  218. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/utils/is-redirect.js +0 -0
  219. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/utils/is.js +0 -0
  220. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/utils/multipart-parser.js +0 -0
  221. /package/node_modules/{google-auth-library → gaxios}/node_modules/node-fetch/src/utils/referrer.js +0 -0
  222. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/LICENSE +0 -0
  223. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/README.md +0 -0
  224. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.js +0 -0
  225. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.js.map +0 -0
  226. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.min.js +0 -0
  227. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.min.js.map +0 -0
  228. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.mjs +0 -0
  229. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es2018.mjs.map +0 -0
  230. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.js +0 -0
  231. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.js.map +0 -0
  232. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.min.js +0 -0
  233. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.min.js.map +0 -0
  234. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.mjs +0 -0
  235. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.es6.mjs.map +0 -0
  236. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.js +0 -0
  237. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.js.map +0 -0
  238. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.min.js +0 -0
  239. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.min.js.map +0 -0
  240. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.mjs +0 -0
  241. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/polyfill.mjs.map +0 -0
  242. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es2018.js +0 -0
  243. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es2018.js.map +0 -0
  244. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es2018.mjs +0 -0
  245. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es2018.mjs.map +0 -0
  246. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es6.js +0 -0
  247. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es6.js.map +0 -0
  248. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es6.mjs +0 -0
  249. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.es6.mjs.map +0 -0
  250. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.js +0 -0
  251. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.js.map +0 -0
  252. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.mjs +0 -0
  253. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/ponyfill.mjs.map +0 -0
  254. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/types/polyfill.d.ts +0 -0
  255. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/types/ponyfill.d.ts +0 -0
  256. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/types/ts3.6/polyfill.d.ts +0 -0
  257. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/types/ts3.6/ponyfill.d.ts +0 -0
  258. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/dist/types/tsdoc-metadata.json +0 -0
  259. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/es2018/package.json +0 -0
  260. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/es6/package.json +0 -0
  261. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/package.json +0 -0
  262. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/ponyfill/es2018/package.json +0 -0
  263. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/ponyfill/es6/package.json +0 -0
  264. /package/node_modules/{google-auth-library → gaxios}/node_modules/web-streams-polyfill/ponyfill/package.json +0 -0
@@ -0,0 +1,151 @@
1
+ import { asObjectRecord } from "openclaw/plugin-sdk/runtime-doctor";
2
+ //#region extensions/googlechat/src/doctor-contract.ts
3
+ function hasLegacyGoogleChatStreamMode(value) {
4
+ return asObjectRecord(value)?.streamMode !== void 0;
5
+ }
6
+ function hasLegacyGoogleChatGroupAllowAlias(value) {
7
+ const groups = asObjectRecord(asObjectRecord(value)?.groups);
8
+ if (!groups) return false;
9
+ return Object.values(groups).some((group) => Object.hasOwn(asObjectRecord(group) ?? {}, "allow"));
10
+ }
11
+ function hasLegacyAccountAliases(value, match) {
12
+ const accounts = asObjectRecord(value);
13
+ if (!accounts) return false;
14
+ return Object.values(accounts).some((account) => match(account));
15
+ }
16
+ function normalizeGoogleChatGroups(params) {
17
+ let changed = false;
18
+ const nextGroups = { ...params.groups };
19
+ for (const [groupId, groupValue] of Object.entries(params.groups)) {
20
+ const group = asObjectRecord(groupValue);
21
+ if (!group || !Object.hasOwn(group, "allow")) continue;
22
+ const nextGroup = { ...group };
23
+ if (nextGroup.enabled === void 0) {
24
+ nextGroup.enabled = group.allow;
25
+ params.changes.push(`Moved ${params.pathPrefix}.${groupId}.allow → ${params.pathPrefix}.${groupId}.enabled.`);
26
+ } else params.changes.push(`Removed ${params.pathPrefix}.${groupId}.allow (${params.pathPrefix}.${groupId}.enabled already set).`);
27
+ delete nextGroup.allow;
28
+ nextGroups[groupId] = nextGroup;
29
+ changed = true;
30
+ }
31
+ return {
32
+ groups: nextGroups,
33
+ changed
34
+ };
35
+ }
36
+ function normalizeGoogleChatEntry(params) {
37
+ let updated = params.entry;
38
+ let changed = false;
39
+ if (updated.streamMode !== void 0) {
40
+ updated = { ...updated };
41
+ delete updated.streamMode;
42
+ params.changes.push(`Removed ${params.pathPrefix}.streamMode (legacy key no longer used).`);
43
+ changed = true;
44
+ }
45
+ const groups = asObjectRecord(updated.groups);
46
+ if (groups) {
47
+ const normalized = normalizeGoogleChatGroups({
48
+ groups,
49
+ pathPrefix: `${params.pathPrefix}.groups`,
50
+ changes: params.changes
51
+ });
52
+ if (normalized.changed) {
53
+ updated = {
54
+ ...updated,
55
+ groups: normalized.groups
56
+ };
57
+ changed = true;
58
+ }
59
+ }
60
+ return {
61
+ entry: updated,
62
+ changed
63
+ };
64
+ }
65
+ const legacyConfigRules = [
66
+ {
67
+ path: ["channels", "googlechat"],
68
+ message: "channels.googlechat.streamMode is legacy and no longer used; it is removed on load.",
69
+ match: hasLegacyGoogleChatStreamMode
70
+ },
71
+ {
72
+ path: [
73
+ "channels",
74
+ "googlechat",
75
+ "accounts"
76
+ ],
77
+ message: "channels.googlechat.accounts.<id>.streamMode is legacy and no longer used; it is removed on load.",
78
+ match: (value) => hasLegacyAccountAliases(value, hasLegacyGoogleChatStreamMode)
79
+ },
80
+ {
81
+ path: ["channels", "googlechat"],
82
+ message: "channels.googlechat.groups.<id>.allow is legacy; use channels.googlechat.groups.<id>.enabled instead. Run \"openclaw doctor --fix\".",
83
+ match: hasLegacyGoogleChatGroupAllowAlias
84
+ },
85
+ {
86
+ path: [
87
+ "channels",
88
+ "googlechat",
89
+ "accounts"
90
+ ],
91
+ message: "channels.googlechat.accounts.<id>.groups.<id>.allow is legacy; use channels.googlechat.accounts.<id>.groups.<id>.enabled instead. Run \"openclaw doctor --fix\".",
92
+ match: (value) => hasLegacyAccountAliases(value, hasLegacyGoogleChatGroupAllowAlias)
93
+ }
94
+ ];
95
+ function normalizeCompatibilityConfig({ cfg }) {
96
+ const rawEntry = asObjectRecord(cfg.channels?.googlechat);
97
+ if (!rawEntry) return {
98
+ config: cfg,
99
+ changes: []
100
+ };
101
+ const changes = [];
102
+ let updated = rawEntry;
103
+ let changed;
104
+ const root = normalizeGoogleChatEntry({
105
+ entry: updated,
106
+ pathPrefix: "channels.googlechat",
107
+ changes
108
+ });
109
+ updated = root.entry;
110
+ changed = root.changed;
111
+ const accounts = asObjectRecord(updated.accounts);
112
+ if (accounts) {
113
+ let accountsChanged = false;
114
+ const nextAccounts = { ...accounts };
115
+ for (const [accountId, accountValue] of Object.entries(accounts)) {
116
+ const account = asObjectRecord(accountValue);
117
+ if (!account) continue;
118
+ const normalized = normalizeGoogleChatEntry({
119
+ entry: account,
120
+ pathPrefix: `channels.googlechat.accounts.${accountId}`,
121
+ changes
122
+ });
123
+ if (!normalized.changed) continue;
124
+ nextAccounts[accountId] = normalized.entry;
125
+ accountsChanged = true;
126
+ }
127
+ if (accountsChanged) {
128
+ updated = {
129
+ ...updated,
130
+ accounts: nextAccounts
131
+ };
132
+ changed = true;
133
+ }
134
+ }
135
+ if (!changed) return {
136
+ config: cfg,
137
+ changes: []
138
+ };
139
+ return {
140
+ config: {
141
+ ...cfg,
142
+ channels: {
143
+ ...cfg.channels,
144
+ googlechat: updated
145
+ }
146
+ },
147
+ changes
148
+ };
149
+ }
150
+ //#endregion
151
+ export { normalizeCompatibilityConfig as n, legacyConfigRules as t };
@@ -1,16 +1,20 @@
1
- import "./config-api-CsD0IFxF.js";
2
1
  import { extractToolSend as extractToolSend$1 } from "openclaw/plugin-sdk/tool-send";
2
+ import { readRemoteMediaBuffer, resolveChannelMediaMaxBytes } from "openclaw/plugin-sdk/media-runtime";
3
3
  import { fetchWithSsrFGuard as fetchWithSsrFGuard$1 } from "openclaw/plugin-sdk/ssrf-runtime";
4
4
  import { DEFAULT_ACCOUNT_ID } from "openclaw/plugin-sdk/account-id";
5
- import { createActionGate, jsonResult as jsonResult$1, readNumberParam, readReactionParams, readStringParam as readStringParam$1 } from "openclaw/plugin-sdk/channel-actions";
5
+ import { createActionGate as createActionGate$1, jsonResult as jsonResult$1, readNumberParam, readReactionParams as readReactionParams$1, readStringParam as readStringParam$1 } from "openclaw/plugin-sdk/channel-actions";
6
+ import { buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-primitives";
6
7
  import { missingTargetError } from "openclaw/plugin-sdk/channel-feedback";
7
8
  import { createAccountStatusSink as createAccountStatusSink$1, createChannelMessageReplyPipeline, runPassiveAccountLifecycle as runPassiveAccountLifecycle$1 } from "openclaw/plugin-sdk/channel-outbound";
8
9
  import { createChannelPairingController } from "openclaw/plugin-sdk/channel-pairing";
9
10
  import { PAIRING_APPROVED_MESSAGE } from "openclaw/plugin-sdk/channel-status";
10
11
  import { chunkTextForOutbound } from "openclaw/plugin-sdk/text-chunking";
12
+ import { GoogleChatConfigSchema } from "openclaw/plugin-sdk/bundled-channel-config-schema";
11
13
  import { GROUP_POLICY_BLOCKED_LABEL, resolveAllowlistProviderRuntimeGroupPolicy, resolveDefaultGroupPolicy, warnMissingProviderGroupPolicyFallbackOnce } from "openclaw/plugin-sdk/runtime-group-policy";
12
14
  import { isDangerousNameMatchingEnabled } from "openclaw/plugin-sdk/dangerous-name-runtime";
15
+ import { loadOutboundMediaFromUrl as loadOutboundMediaFromUrl$1 } from "openclaw/plugin-sdk/outbound-media";
13
16
  import { resolveInboundMentionDecision } from "openclaw/plugin-sdk/channel-inbound";
17
+ import { resolveInboundRouteEnvelopeBuilderWithRuntime } from "openclaw/plugin-sdk/inbound-envelope";
14
18
  import { resolveWebhookPath } from "openclaw/plugin-sdk/webhook-ingress";
15
19
  import { registerWebhookTargetWithPluginRoute as registerWebhookTargetWithPluginRoute$1, resolveWebhookTargetWithAuthOrReject as resolveWebhookTargetWithAuthOrReject$1, withResolvedWebhookRequestPipeline as withResolvedWebhookRequestPipeline$1 } from "openclaw/plugin-sdk/webhook-targets";
16
20
  import { createWebhookInFlightLimiter as createWebhookInFlightLimiter$1, readJsonWebhookBodyOrReject as readJsonWebhookBodyOrReject$1 } from "openclaw/plugin-sdk/webhook-request-guards";
@@ -21,4 +25,4 @@ const { setRuntime: setGoogleChatRuntime, getRuntime: getGoogleChatRuntime } = c
21
25
  errorMessage: "Google Chat runtime not initialized"
22
26
  });
23
27
  //#endregion
24
- export { resolveWebhookPath as C, withResolvedWebhookRequestPipeline$1 as D, warnMissingProviderGroupPolicyFallbackOnce as E, getGoogleChatRuntime as O, resolveInboundMentionDecision as S, runPassiveAccountLifecycle$1 as T, readReactionParams as _, createAccountStatusSink$1 as a, resolveAllowlistProviderRuntimeGroupPolicy as b, createChannelPairingController as c, fetchWithSsrFGuard$1 as d, isDangerousNameMatchingEnabled as f, readNumberParam as g, readJsonWebhookBodyOrReject$1 as h, chunkTextForOutbound as i, setGoogleChatRuntime as k, createWebhookInFlightLimiter$1 as l, missingTargetError as m, GROUP_POLICY_BLOCKED_LABEL as n, createActionGate as o, jsonResult$1 as p, PAIRING_APPROVED_MESSAGE as r, createChannelMessageReplyPipeline as s, DEFAULT_ACCOUNT_ID as t, extractToolSend$1 as u, readStringParam$1 as v, resolveWebhookTargetWithAuthOrReject$1 as w, resolveDefaultGroupPolicy as x, registerWebhookTargetWithPluginRoute$1 as y };
28
+ export { resolveWebhookTargetWithAuthOrReject$1 as A, registerWebhookTargetWithPluginRoute$1 as C, resolveInboundMentionDecision as D, resolveDefaultGroupPolicy as E, setGoogleChatRuntime as F, warnMissingProviderGroupPolicyFallbackOnce as M, withResolvedWebhookRequestPipeline$1 as N, resolveInboundRouteEnvelopeBuilderWithRuntime as O, getGoogleChatRuntime as P, readStringParam$1 as S, resolveChannelMediaMaxBytes as T, missingTargetError as _, buildChannelConfigSchema as a, readReactionParams$1 as b, createActionGate$1 as c, createWebhookInFlightLimiter$1 as d, extractToolSend$1 as f, loadOutboundMediaFromUrl$1 as g, jsonResult$1 as h, PAIRING_APPROVED_MESSAGE as i, runPassiveAccountLifecycle$1 as j, resolveWebhookPath as k, createChannelMessageReplyPipeline as l, isDangerousNameMatchingEnabled as m, GROUP_POLICY_BLOCKED_LABEL as n, chunkTextForOutbound as o, fetchWithSsrFGuard$1 as p, GoogleChatConfigSchema as r, createAccountStatusSink$1 as s, DEFAULT_ACCOUNT_ID as t, createChannelPairingController as u, readJsonWebhookBodyOrReject$1 as v, resolveAllowlistProviderRuntimeGroupPolicy as w, readRemoteMediaBuffer as x, readNumberParam as y };
@@ -0,0 +1,3 @@
1
+ import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "./secret-contract-lCMHqumt.mjs";
2
+ import "../secret-contract-api.js";
3
+ export { channelSecrets, collectRuntimeConfigAssignments, secretTargetRegistryEntries };
@@ -0,0 +1,99 @@
1
+ import { getChannelSurface, hasOwnProperty, pushAssignment, pushInactiveSurfaceWarning, pushWarning, resolveChannelAccountSurface } from "openclaw/plugin-sdk/channel-secret-basic-runtime";
2
+ import { coerceSecretRef } from "openclaw/plugin-sdk/secret-ref-runtime";
3
+ //#region extensions/googlechat/src/secret-contract.ts
4
+ const secretTargetRegistryEntries = [{
5
+ id: "channels.googlechat.accounts.*.serviceAccount",
6
+ targetType: "channels.googlechat.serviceAccount",
7
+ targetTypeAliases: ["channels.googlechat.accounts.*.serviceAccount"],
8
+ configFile: "openclaw.json",
9
+ pathPattern: "channels.googlechat.accounts.*.serviceAccount",
10
+ refPathPattern: "channels.googlechat.accounts.*.serviceAccountRef",
11
+ secretShape: "sibling_ref",
12
+ expectedResolvedValue: "string-or-object",
13
+ includeInPlan: true,
14
+ includeInConfigure: true,
15
+ includeInAudit: true,
16
+ accountIdPathSegmentIndex: 3
17
+ }, {
18
+ id: "channels.googlechat.serviceAccount",
19
+ targetType: "channels.googlechat.serviceAccount",
20
+ configFile: "openclaw.json",
21
+ pathPattern: "channels.googlechat.serviceAccount",
22
+ refPathPattern: "channels.googlechat.serviceAccountRef",
23
+ secretShape: "sibling_ref",
24
+ expectedResolvedValue: "string-or-object",
25
+ includeInPlan: true,
26
+ includeInConfigure: true,
27
+ includeInAudit: true
28
+ }];
29
+ function resolveSecretInputRef(params) {
30
+ const explicitRef = coerceSecretRef(params.refValue, params.defaults);
31
+ const inlineRef = explicitRef ? null : coerceSecretRef(params.value, params.defaults);
32
+ return {
33
+ explicitRef,
34
+ inlineRef,
35
+ ref: explicitRef ?? inlineRef
36
+ };
37
+ }
38
+ function collectGoogleChatAccountAssignment(params) {
39
+ const { explicitRef, ref } = resolveSecretInputRef({
40
+ value: params.target.serviceAccount,
41
+ refValue: params.target.serviceAccountRef,
42
+ defaults: params.defaults
43
+ });
44
+ if (!ref) return;
45
+ if (params.active === false) {
46
+ pushInactiveSurfaceWarning({
47
+ context: params.context,
48
+ path: `${params.path}.serviceAccount`,
49
+ details: params.inactiveReason
50
+ });
51
+ return;
52
+ }
53
+ if (explicitRef && params.target.serviceAccount !== void 0 && !coerceSecretRef(params.target.serviceAccount, params.defaults)) pushWarning(params.context, {
54
+ code: "SECRETS_REF_OVERRIDES_PLAINTEXT",
55
+ path: params.path,
56
+ message: `${params.path}: serviceAccountRef is set; runtime will ignore plaintext serviceAccount.`
57
+ });
58
+ pushAssignment(params.context, {
59
+ ref,
60
+ path: `${params.path}.serviceAccount`,
61
+ expected: "string-or-object",
62
+ apply: (value) => {
63
+ params.target.serviceAccount = value;
64
+ }
65
+ });
66
+ }
67
+ function collectRuntimeConfigAssignments(params) {
68
+ const resolved = getChannelSurface(params.config, "googlechat");
69
+ if (!resolved) return;
70
+ const googleChat = resolved.channel;
71
+ const surface = resolveChannelAccountSurface(googleChat);
72
+ const topLevelServiceAccountActive = !surface.channelEnabled ? false : !surface.hasExplicitAccounts ? true : surface.accounts.some(({ account, enabled }) => enabled && !hasOwnProperty(account, "serviceAccount") && !hasOwnProperty(account, "serviceAccountRef"));
73
+ collectGoogleChatAccountAssignment({
74
+ target: googleChat,
75
+ path: "channels.googlechat",
76
+ defaults: params.defaults,
77
+ context: params.context,
78
+ active: topLevelServiceAccountActive,
79
+ inactiveReason: "no enabled account inherits this top-level Google Chat serviceAccount."
80
+ });
81
+ if (!surface.hasExplicitAccounts) return;
82
+ for (const { accountId, account, enabled } of surface.accounts) {
83
+ if (!hasOwnProperty(account, "serviceAccount") && !hasOwnProperty(account, "serviceAccountRef")) continue;
84
+ collectGoogleChatAccountAssignment({
85
+ target: account,
86
+ path: `channels.googlechat.accounts.${accountId}`,
87
+ defaults: params.defaults,
88
+ context: params.context,
89
+ active: enabled,
90
+ inactiveReason: "Google Chat account is disabled."
91
+ });
92
+ }
93
+ }
94
+ const channelSecrets = {
95
+ secretTargetRegistryEntries,
96
+ collectRuntimeConfigAssignments
97
+ };
98
+ //#endregion
99
+ export { collectRuntimeConfigAssignments as n, secretTargetRegistryEntries as r, channelSecrets as t };
@@ -0,0 +1,5 @@
1
+ import { n as createGoogleChatPluginBase } from "./channel-base-DJICAvKH.mjs";
2
+ //#region extensions/googlechat/src/channel.setup.ts
3
+ const googlechatSetupPlugin = createGoogleChatPluginBase();
4
+ //#endregion
5
+ export { googlechatSetupPlugin as t };
@@ -0,0 +1,2 @@
1
+ import { t as googlechatSetupPlugin } from "./setup-plugin-api-BgwvQMls.mjs";
2
+ export { googlechatSetupPlugin };
package/dist/api.js CHANGED
@@ -1,3 +1,3 @@
1
- import { a as googlechatSetupAdapter, i as googlechatSetupWizard } from "./channel-base-hw9ErEr5.js";
2
- import { t as googlechatPlugin } from "./channel-kouqKs2x.js";
1
+ import { a as googlechatSetupAdapter, i as googlechatSetupWizard } from "./.setup/channel-base-DJICAvKH.mjs";
2
+ import { t as googlechatPlugin } from "./.setup/channel-BPjomke4.mjs";
3
3
  export { googlechatPlugin, googlechatSetupAdapter, googlechatSetupWizard };
@@ -1,4 +1,5 @@
1
- import { n as buildChannelConfigSchema, t as GoogleChatConfigSchema } from "./config-api-CsD0IFxF.js";
1
+ import { buildChannelConfigSchema } from "openclaw/plugin-sdk/channel-config-primitives";
2
+ import { GoogleChatConfigSchema } from "openclaw/plugin-sdk/bundled-channel-config-schema";
2
3
  //#region extensions/googlechat/src/config-schema.ts
3
4
  const GoogleChatChannelConfigSchema = buildChannelConfigSchema(GoogleChatConfigSchema);
4
5
  //#endregion
@@ -1,2 +1,2 @@
1
- import { t as googlechatPlugin } from "./channel-kouqKs2x.js";
1
+ import { t as googlechatPlugin } from "./.setup/channel-BPjomke4.mjs";
2
2
  export { googlechatPlugin };
@@ -1,4 +1,4 @@
1
- import { t as googlechatDirectoryAdapter } from "./channel.adapters-DaipaeYt.js";
1
+ import { t as googlechatDirectoryAdapter } from "./.setup/channel.adapters-T6wPzrpo.mjs";
2
2
  //#region extensions/googlechat/directory-contract-api.ts
3
3
  const googlechatDirectoryContractPlugin = {
4
4
  id: "googlechat",
@@ -1,2 +1,2 @@
1
- import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./doctor-contract-BpuSvJro.js";
1
+ import { n as normalizeCompatibilityConfig, t as legacyConfigRules } from "./.setup/doctor-contract-BcEqUZ4j.mjs";
2
2
  export { legacyConfigRules, normalizeCompatibilityConfig };
@@ -1,3 +1,2 @@
1
- import { n as buildChannelConfigSchema, t as GoogleChatConfigSchema } from "./config-api-CsD0IFxF.js";
2
- import { C as resolveWebhookPath, D as withResolvedWebhookRequestPipeline, E as warnMissingProviderGroupPolicyFallbackOnce, S as resolveInboundMentionDecision, T as runPassiveAccountLifecycle, _ as readReactionParams, a as createAccountStatusSink, b as resolveAllowlistProviderRuntimeGroupPolicy, c as createChannelPairingController, d as fetchWithSsrFGuard, f as isDangerousNameMatchingEnabled, g as readNumberParam, h as readJsonWebhookBodyOrReject, i as chunkTextForOutbound, k as setGoogleChatRuntime, l as createWebhookInFlightLimiter, m as missingTargetError, n as GROUP_POLICY_BLOCKED_LABEL, o as createActionGate, p as jsonResult, r as PAIRING_APPROVED_MESSAGE, s as createChannelMessageReplyPipeline, t as DEFAULT_ACCOUNT_ID, u as extractToolSend, v as readStringParam, w as resolveWebhookTargetWithAuthOrReject, x as resolveDefaultGroupPolicy, y as registerWebhookTargetWithPluginRoute } from "./runtime-api-Dh0CNVS4.js";
3
- export { DEFAULT_ACCOUNT_ID, GROUP_POLICY_BLOCKED_LABEL, GoogleChatConfigSchema, PAIRING_APPROVED_MESSAGE, buildChannelConfigSchema, chunkTextForOutbound, createAccountStatusSink, createActionGate, createChannelMessageReplyPipeline, createChannelPairingController, createWebhookInFlightLimiter, extractToolSend, fetchWithSsrFGuard, isDangerousNameMatchingEnabled, jsonResult, missingTargetError, readJsonWebhookBodyOrReject, readNumberParam, readReactionParams, readStringParam, registerWebhookTargetWithPluginRoute, resolveAllowlistProviderRuntimeGroupPolicy, resolveDefaultGroupPolicy, resolveInboundMentionDecision, resolveWebhookPath, resolveWebhookTargetWithAuthOrReject, runPassiveAccountLifecycle, setGoogleChatRuntime, warnMissingProviderGroupPolicyFallbackOnce, withResolvedWebhookRequestPipeline };
1
+ import { A as resolveWebhookTargetWithAuthOrReject, C as registerWebhookTargetWithPluginRoute, D as resolveInboundMentionDecision, E as resolveDefaultGroupPolicy, F as setGoogleChatRuntime, M as warnMissingProviderGroupPolicyFallbackOnce, N as withResolvedWebhookRequestPipeline, O as resolveInboundRouteEnvelopeBuilderWithRuntime, S as readStringParam, T as resolveChannelMediaMaxBytes, _ as missingTargetError, a as buildChannelConfigSchema, b as readReactionParams, c as createActionGate, d as createWebhookInFlightLimiter, f as extractToolSend, g as loadOutboundMediaFromUrl, h as jsonResult, i as PAIRING_APPROVED_MESSAGE, j as runPassiveAccountLifecycle, k as resolveWebhookPath, l as createChannelMessageReplyPipeline, m as isDangerousNameMatchingEnabled, n as GROUP_POLICY_BLOCKED_LABEL, o as chunkTextForOutbound, p as fetchWithSsrFGuard, r as GoogleChatConfigSchema, s as createAccountStatusSink, t as DEFAULT_ACCOUNT_ID, u as createChannelPairingController, v as readJsonWebhookBodyOrReject, w as resolveAllowlistProviderRuntimeGroupPolicy, x as readRemoteMediaBuffer, y as readNumberParam } from "./.setup/runtime-api-BbVoWRxq.mjs";
2
+ export { DEFAULT_ACCOUNT_ID, GROUP_POLICY_BLOCKED_LABEL, GoogleChatConfigSchema, PAIRING_APPROVED_MESSAGE, buildChannelConfigSchema, chunkTextForOutbound, createAccountStatusSink, createActionGate, createChannelMessageReplyPipeline, createChannelPairingController, createWebhookInFlightLimiter, extractToolSend, fetchWithSsrFGuard, isDangerousNameMatchingEnabled, jsonResult, loadOutboundMediaFromUrl, missingTargetError, readJsonWebhookBodyOrReject, readNumberParam, readReactionParams, readRemoteMediaBuffer, readStringParam, registerWebhookTargetWithPluginRoute, resolveAllowlistProviderRuntimeGroupPolicy, resolveChannelMediaMaxBytes, resolveDefaultGroupPolicy, resolveInboundMentionDecision, resolveInboundRouteEnvelopeBuilderWithRuntime, resolveWebhookPath, resolveWebhookTargetWithAuthOrReject, runPassiveAccountLifecycle, setGoogleChatRuntime, warnMissingProviderGroupPolicyFallbackOnce, withResolvedWebhookRequestPipeline };
@@ -1,2 +1,2 @@
1
- import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "./secret-contract-BFYyuE0F.js";
1
+ import { n as collectRuntimeConfigAssignments, r as secretTargetRegistryEntries, t as channelSecrets } from "./.setup/secret-contract-lCMHqumt.mjs";
2
2
  export { channelSecrets, collectRuntimeConfigAssignments, secretTargetRegistryEntries };
@@ -1,13 +1,14 @@
1
1
  import { defineBundledChannelSetupEntry } from "openclaw/plugin-sdk/channel-entry-contract";
2
+ import { fileURLToPath } from "node:url";
2
3
  //#region extensions/googlechat/setup-entry.ts
3
4
  var setup_entry_default = defineBundledChannelSetupEntry({
4
5
  importMetaUrl: import.meta.url,
5
6
  plugin: {
6
- specifier: "./setup-plugin-api.js",
7
+ specifier: fileURLToPath(new URL(".setup/setup-plugin-api-Ce08GSFO.mjs", import.meta.url).href),
7
8
  exportName: "googlechatSetupPlugin"
8
9
  },
9
10
  secrets: {
10
- specifier: "./secret-contract-api.js",
11
+ specifier: fileURLToPath(new URL(".setup/secret-contract-api-BGDBptmu.mjs", import.meta.url).href),
11
12
  exportName: "channelSecrets"
12
13
  }
13
14
  });
@@ -1,5 +1,2 @@
1
- import { n as createGoogleChatPluginBase } from "./channel-base-hw9ErEr5.js";
2
- //#region extensions/googlechat/src/channel.setup.ts
3
- const googlechatSetupPlugin = createGoogleChatPluginBase();
4
- //#endregion
1
+ import { t as googlechatSetupPlugin } from "./.setup/setup-plugin-api-BgwvQMls.mjs";
5
2
  export { googlechatSetupPlugin };
@@ -149,7 +149,7 @@ class Gaxios {
149
149
  for await (const chunk of translatedResponse.data) {
150
150
  response.push(chunk);
151
151
  }
152
- translatedResponse.data = Buffer.concat(response.map(c => (typeof c === 'string' ? Buffer.from(c) : c))).toString('utf8');
152
+ translatedResponse.data = response.toString();
153
153
  }
154
154
  const errorInfo = common_js_1.GaxiosError.extractAPIErrorFromResponse(translatedResponse, `Request failed with status code ${translatedResponse.status}`);
155
155
  throw new common_js_1.GaxiosError(errorInfo?.message, opts, translatedResponse, errorInfo);
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gaxios.js","sourceRoot":"","sources":["../../../src/gaxios.ts"],"names":[],"mappings":";AAAA,4BAA4B;AAC5B,kEAAkE;AAClE,mEAAmE;AACnE,0CAA0C;AAC1C,EAAE;AACF,gDAAgD;AAChD,EAAE;AACF,sEAAsE;AACtE,oEAAoE;AACpE,2EAA2E;AAC3E,sEAAsE;AACtE,iCAAiC;;;;;;;AAEjC,oDAA4B;AAE5B,iCAA0C;AAG1C,2CAQqB;AACrB,yCAA0C;AAC1C,mCAAgC;AAChC,qDAA0D;AAE1D,MAAM,UAAU,GAAG,KAAK,IAAI,EAAE,CAC5B,UAAU,CAAC,MAAM,EAAE,UAAU,EAAE,IAAI,CAAC,MAAM,MAAM,CAAC,QAAQ,CAAC,CAAC,CAAC,UAAU,EAAE,CAAC;AAc3E,MAAM,sBAAsB,GAAG,GAAG,CAAC;AAEnC,MAAa,MAAM;IACP,UAAU,GAAG,IAAI,GAAG,EAG3B,CAAC;IAEJ;;OAEG;IACH,QAAQ,CAAgB;IAExB;;OAEG;IACH,YAAY,CAGV;IAEF;;;OAGG;IACH,YAAY,QAAwB;QAClC,IAAI,CAAC,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AG,EAAE,EAAE;gBACzB,mDAAmD;gBACnD,6FAA6F;gBAC7F,GAAG,KAAK,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC;YACxE,CAAC,CAAC,CAAC;QACL,CAAC;QAED,OAAO,IAAI,CAAC;IACd,CAAC;CACF;AAtpBD,wBAspBC"}
@@ -139,72 +139,6 @@ function setEnv(obj) {
139
139
  apiError.error.details.length === 0);
140
140
  });
141
141
  });
142
- (0, mocha_1.describe)('should handle stream error responses', () => {
143
- (0, mocha_1.it)('split across multiple string chunks', async () => {
144
- const chunks = [
145
- '{"error": {"code": 400, ',
146
- '"message": "Invalid ',
147
- 'argument", "status": "INVALID_ARGUMENT"}}',
148
- ];
149
- const readableStream = stream_1.Readable.from(chunks);
150
- const scope = (0, nock_1.default)(url).get('/').reply(400, readableStream);
151
- await assert_1.default.rejects((0, index_js_1.request)({ url, responseType: 'stream' }), (err) => {
152
- scope.done();
153
- const apiError = JSON.parse(err.message);
154
- return (apiError.error.code === 400 &&
155
- apiError.error.message === 'Invalid argument' &&
156
- apiError.error.status === 'INVALID_ARGUMENT');
157
- });
158
- });
159
- (0, mocha_1.it)('split across multiple Buffer chunks', async () => {
160
- const chunks = [
161
- Buffer.from('{"error": {"code": 400, '),
162
- Buffer.from('"message": "Invalid '),
163
- Buffer.from('argument", "status": "INVALID_ARGUMENT"}}'),
164
- ];
165
- const readableStream = stream_1.Readable.from(chunks);
166
- const scope = (0, nock_1.default)(url).get('/').reply(400, readableStream);
167
- await assert_1.default.rejects((0, index_js_1.request)({ url, responseType: 'stream' }), (err) => {
168
- scope.done();
169
- const apiError = JSON.parse(err.message);
170
- return (apiError.error.code === 400 &&
171
- apiError.error.message === 'Invalid argument' &&
172
- apiError.error.status === 'INVALID_ARGUMENT');
173
- });
174
- });
175
- (0, mocha_1.it)('split across multiple Uint8Array chunks', async () => {
176
- const chunks = [
177
- new Uint8Array(Buffer.from('{"error": {"code": 400, ')),
178
- new Uint8Array(Buffer.from('"message": "Invalid ')),
179
- new Uint8Array(Buffer.from('argument", "status": "INVALID_ARGUMENT"}}')),
180
- ];
181
- const readableStream = stream_1.Readable.from(chunks);
182
- const scope = (0, nock_1.default)(url).get('/').reply(400, readableStream);
183
- await assert_1.default.rejects((0, index_js_1.request)({ url, responseType: 'stream' }), (err) => {
184
- scope.done();
185
- const apiError = JSON.parse(err.message);
186
- return (apiError.error.code === 400 &&
187
- apiError.error.message === 'Invalid argument' &&
188
- apiError.error.status === 'INVALID_ARGUMENT');
189
- });
190
- });
191
- (0, mocha_1.it)('split across mixed type chunks (string, Buffer, Uint8Array)', async () => {
192
- const chunks = [
193
- '{"error": {"code": 400, ',
194
- Buffer.from('"message": "Invalid '),
195
- new Uint8Array(Buffer.from('argument", "status": "INVALID_ARGUMENT"}}')),
196
- ];
197
- const readableStream = stream_1.Readable.from(chunks);
198
- const scope = (0, nock_1.default)(url).get('/').reply(400, readableStream);
199
- await assert_1.default.rejects((0, index_js_1.request)({ url, responseType: 'stream' }), (err) => {
200
- scope.done();
201
- const apiError = JSON.parse(err.message);
202
- return (apiError.error.code === 400 &&
203
- apiError.error.message === 'Invalid argument' &&
204
- apiError.error.status === 'INVALID_ARGUMENT');
205
- });
206
- });
207
- });
208
142
  (0, mocha_1.it)('should not throw an error during a translation error', () => {
209
143
  const notJSON = '.';
210
144
  const response = {