@eventmodelers/node-kit 0.0.2

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 (546) hide show
  1. package/README.md +66 -0
  2. package/package.json +36 -0
  3. package/src/cli.js +176 -0
  4. package/templates/.claude/skills/connect/SKILL.md +169 -0
  5. package/templates/.claude/skills/load-slice/SKILL.md +86 -0
  6. package/templates/realtime-agent/node_modules/.package-lock.json +107 -0
  7. package/templates/realtime-agent/node_modules/@supabase/auth-js/LICENSE +21 -0
  8. package/templates/realtime-agent/node_modules/@supabase/auth-js/README.md +190 -0
  9. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthAdminApi.d.ts +4 -0
  10. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthAdminApi.d.ts.map +1 -0
  11. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthAdminApi.js +7 -0
  12. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthAdminApi.js.map +1 -0
  13. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthClient.d.ts +4 -0
  14. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthClient.d.ts.map +1 -0
  15. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthClient.js +7 -0
  16. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/AuthClient.js.map +1 -0
  17. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueAdminApi.d.ts +716 -0
  18. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueAdminApi.d.ts.map +1 -0
  19. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueAdminApi.js +1108 -0
  20. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueAdminApi.js.map +1 -0
  21. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueClient.d.ts +2473 -0
  22. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueClient.d.ts.map +1 -0
  23. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueClient.js +5217 -0
  24. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/GoTrueClient.js.map +1 -0
  25. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/index.d.ts +9 -0
  26. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/index.d.ts.map +1 -0
  27. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/index.js +20 -0
  28. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/index.js.map +1 -0
  29. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/base64url.d.ts +76 -0
  30. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/base64url.d.ts.map +1 -0
  31. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/base64url.js +269 -0
  32. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/base64url.js.map +1 -0
  33. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/constants.d.ts +26 -0
  34. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/constants.d.ts.map +1 -0
  35. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/constants.js +31 -0
  36. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/constants.js.map +1 -0
  37. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/error-codes.d.ts +7 -0
  38. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/error-codes.d.ts.map +1 -0
  39. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/error-codes.js +3 -0
  40. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/error-codes.js.map +1 -0
  41. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/errors.d.ts +258 -0
  42. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/errors.d.ts.map +1 -0
  43. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/errors.js +290 -0
  44. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/errors.js.map +1 -0
  45. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/fetch.d.ts +54 -0
  46. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/fetch.d.ts.map +1 -0
  47. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/fetch.js +200 -0
  48. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/fetch.js.map +1 -0
  49. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/helpers.d.ts +94 -0
  50. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/helpers.d.ts.map +1 -0
  51. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/helpers.js +406 -0
  52. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/helpers.js.map +1 -0
  53. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/local-storage.d.ts +9 -0
  54. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/local-storage.d.ts.map +1 -0
  55. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/local-storage.js +21 -0
  56. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/local-storage.js.map +1 -0
  57. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/locks.d.ts +107 -0
  58. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/locks.d.ts.map +1 -0
  59. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/locks.js +349 -0
  60. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/locks.js.map +1 -0
  61. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/polyfills.d.ts +5 -0
  62. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/polyfills.d.ts.map +1 -0
  63. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/polyfills.js +29 -0
  64. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/polyfills.js.map +1 -0
  65. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/types.d.ts +2498 -0
  66. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/types.d.ts.map +1 -0
  67. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/types.js +23 -0
  68. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/types.js.map +1 -0
  69. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/version.d.ts +2 -0
  70. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/version.d.ts.map +1 -0
  71. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/version.js +11 -0
  72. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/version.js.map +1 -0
  73. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/ethereum.d.ts +96 -0
  74. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/ethereum.d.ts.map +1 -0
  75. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/ethereum.js +66 -0
  76. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/ethereum.js.map +1 -0
  77. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/solana.d.ts +160 -0
  78. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/solana.d.ts.map +1 -0
  79. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/solana.js +4 -0
  80. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/web3/solana.js.map +1 -0
  81. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.d.ts +284 -0
  82. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.d.ts.map +1 -0
  83. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.dom.d.ts +583 -0
  84. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.dom.d.ts.map +1 -0
  85. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.dom.js +4 -0
  86. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.dom.js.map +1 -0
  87. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.errors.d.ts +85 -0
  88. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.errors.d.ts.map +1 -0
  89. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.errors.js +272 -0
  90. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.errors.js.map +1 -0
  91. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.js +707 -0
  92. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/main/lib/webauthn.js.map +1 -0
  93. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthAdminApi.d.ts +4 -0
  94. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthAdminApi.d.ts.map +1 -0
  95. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthAdminApi.js +4 -0
  96. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthAdminApi.js.map +1 -0
  97. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthClient.d.ts +4 -0
  98. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthClient.d.ts.map +1 -0
  99. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthClient.js +4 -0
  100. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/AuthClient.js.map +1 -0
  101. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueAdminApi.d.ts +716 -0
  102. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueAdminApi.d.ts.map +1 -0
  103. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueAdminApi.js +1105 -0
  104. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueAdminApi.js.map +1 -0
  105. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueClient.d.ts +2473 -0
  106. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueClient.d.ts.map +1 -0
  107. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueClient.js +5214 -0
  108. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/GoTrueClient.js.map +1 -0
  109. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/index.d.ts +9 -0
  110. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/index.d.ts.map +1 -0
  111. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/index.js +9 -0
  112. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/index.js.map +1 -0
  113. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/base64url.d.ts +76 -0
  114. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/base64url.d.ts.map +1 -0
  115. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/base64url.js +257 -0
  116. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/base64url.js.map +1 -0
  117. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/constants.d.ts +26 -0
  118. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/constants.d.ts.map +1 -0
  119. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/constants.js +28 -0
  120. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/constants.js.map +1 -0
  121. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/error-codes.d.ts +7 -0
  122. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/error-codes.d.ts.map +1 -0
  123. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/error-codes.js +2 -0
  124. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/error-codes.js.map +1 -0
  125. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/errors.d.ts +258 -0
  126. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/errors.d.ts.map +1 -0
  127. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/errors.js +267 -0
  128. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/errors.js.map +1 -0
  129. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/fetch.d.ts +54 -0
  130. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/fetch.d.ts.map +1 -0
  131. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/fetch.js +190 -0
  132. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/fetch.js.map +1 -0
  133. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/helpers.d.ts +94 -0
  134. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/helpers.d.ts.map +1 -0
  135. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/helpers.js +378 -0
  136. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/helpers.js.map +1 -0
  137. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/local-storage.d.ts +9 -0
  138. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/local-storage.d.ts.map +1 -0
  139. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/local-storage.js +18 -0
  140. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/local-storage.js.map +1 -0
  141. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/locks.d.ts +107 -0
  142. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/locks.d.ts.map +1 -0
  143. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/locks.js +341 -0
  144. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/locks.js.map +1 -0
  145. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/polyfills.d.ts +5 -0
  146. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/polyfills.d.ts.map +1 -0
  147. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/polyfills.js +26 -0
  148. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/polyfills.js.map +1 -0
  149. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/types.d.ts +2498 -0
  150. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/types.d.ts.map +1 -0
  151. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/types.js +20 -0
  152. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/types.js.map +1 -0
  153. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/version.d.ts +2 -0
  154. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/version.d.ts.map +1 -0
  155. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/version.js +8 -0
  156. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/version.js.map +1 -0
  157. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/ethereum.d.ts +96 -0
  158. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/ethereum.d.ts.map +1 -0
  159. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/ethereum.js +60 -0
  160. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/ethereum.js.map +1 -0
  161. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/solana.d.ts +160 -0
  162. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/solana.d.ts.map +1 -0
  163. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/solana.js +3 -0
  164. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/web3/solana.js.map +1 -0
  165. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.d.ts +284 -0
  166. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.d.ts.map +1 -0
  167. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.dom.d.ts +583 -0
  168. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.dom.d.ts.map +1 -0
  169. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.dom.js +3 -0
  170. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.dom.js.map +1 -0
  171. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.errors.d.ts +85 -0
  172. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.errors.d.ts.map +1 -0
  173. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.errors.js +264 -0
  174. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.errors.js.map +1 -0
  175. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.js +689 -0
  176. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/module/lib/webauthn.js.map +1 -0
  177. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/tsconfig.module.tsbuildinfo +1 -0
  178. package/templates/realtime-agent/node_modules/@supabase/auth-js/dist/tsconfig.tsbuildinfo +1 -0
  179. package/templates/realtime-agent/node_modules/@supabase/auth-js/package.json +44 -0
  180. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/AuthAdminApi.ts +5 -0
  181. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/AuthClient.ts +5 -0
  182. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/GoTrueAdminApi.ts +1267 -0
  183. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/GoTrueClient.ts +6360 -0
  184. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/index.ts +13 -0
  185. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/base64url.ts +308 -0
  186. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/constants.ts +34 -0
  187. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/error-codes.ts +90 -0
  188. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/errors.ts +359 -0
  189. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/fetch.ts +320 -0
  190. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/helpers.ts +476 -0
  191. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/local-storage.ts +21 -0
  192. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/locks.ts +420 -0
  193. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/polyfills.ts +23 -0
  194. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/types.ts +2917 -0
  195. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/version.ts +7 -0
  196. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/web3/ethereum.ts +184 -0
  197. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/web3/solana.ts +186 -0
  198. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/webauthn.dom.ts +636 -0
  199. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/webauthn.errors.ts +329 -0
  200. package/templates/realtime-agent/node_modules/@supabase/auth-js/src/lib/webauthn.ts +946 -0
  201. package/templates/realtime-agent/node_modules/@supabase/functions-js/README.md +134 -0
  202. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/FunctionsClient.d.ts +177 -0
  203. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/FunctionsClient.d.ts.map +1 -0
  204. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/FunctionsClient.js +309 -0
  205. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/FunctionsClient.js.map +1 -0
  206. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/helper.d.ts +3 -0
  207. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/helper.d.ts.map +1 -0
  208. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/helper.js +11 -0
  209. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/helper.js.map +1 -0
  210. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/index.d.ts +3 -0
  211. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/index.d.ts.map +1 -0
  212. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/index.js +12 -0
  213. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/index.js.map +1 -0
  214. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/types.d.ts +122 -0
  215. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/types.d.ts.map +1 -0
  216. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/types.js +98 -0
  217. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/types.js.map +1 -0
  218. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/version.d.ts +2 -0
  219. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/version.d.ts.map +1 -0
  220. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/version.js +11 -0
  221. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/main/version.js.map +1 -0
  222. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/FunctionsClient.d.ts +177 -0
  223. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/FunctionsClient.d.ts.map +1 -0
  224. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/FunctionsClient.js +305 -0
  225. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/FunctionsClient.js.map +1 -0
  226. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/helper.d.ts +3 -0
  227. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/helper.d.ts.map +1 -0
  228. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/helper.js +7 -0
  229. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/helper.js.map +1 -0
  230. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/index.d.ts +3 -0
  231. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/index.d.ts.map +1 -0
  232. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/index.js +3 -0
  233. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/index.js.map +1 -0
  234. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/types.d.ts +122 -0
  235. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/types.d.ts.map +1 -0
  236. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/types.js +91 -0
  237. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/types.js.map +1 -0
  238. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/version.d.ts +2 -0
  239. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/version.d.ts.map +1 -0
  240. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/version.js +8 -0
  241. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/module/version.js.map +1 -0
  242. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/tsconfig.module.tsbuildinfo +1 -0
  243. package/templates/realtime-agent/node_modules/@supabase/functions-js/dist/tsconfig.tsbuildinfo +1 -0
  244. package/templates/realtime-agent/node_modules/@supabase/functions-js/package.json +52 -0
  245. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/FunctionsClient.ts +335 -0
  246. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/edge-runtime.d.ts +214 -0
  247. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/helper.ts +8 -0
  248. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/index.ts +10 -0
  249. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/types.ts +146 -0
  250. package/templates/realtime-agent/node_modules/@supabase/functions-js/src/version.ts +7 -0
  251. package/templates/realtime-agent/node_modules/@supabase/phoenix/LICENSE.md +22 -0
  252. package/templates/realtime-agent/node_modules/@supabase/phoenix/README.md +121 -0
  253. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/ajax.js +116 -0
  254. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/channel.js +331 -0
  255. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/constants.js +35 -0
  256. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/index.js +212 -0
  257. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/longpoll.js +192 -0
  258. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/presence.js +208 -0
  259. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/push.js +134 -0
  260. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/serializer.js +133 -0
  261. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/socket.js +756 -0
  262. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/timer.js +48 -0
  263. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/types.js +184 -0
  264. package/templates/realtime-agent/node_modules/@supabase/phoenix/assets/js/phoenix/utils.js +16 -0
  265. package/templates/realtime-agent/node_modules/@supabase/phoenix/package.json +58 -0
  266. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/favicon.ico +0 -0
  267. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix-orange.png +0 -0
  268. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.cjs.js +1825 -0
  269. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.cjs.js.map +7 -0
  270. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.js +1847 -0
  271. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.min.js +2 -0
  272. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.mjs +1802 -0
  273. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.mjs.map +7 -0
  274. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/phoenix.png +0 -0
  275. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/ajax.d.ts +10 -0
  276. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/ajax.d.ts.map +1 -0
  277. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/channel.d.ts +167 -0
  278. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/channel.d.ts.map +1 -0
  279. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/constants.d.ts +36 -0
  280. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/constants.d.ts.map +1 -0
  281. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/index.d.ts +10 -0
  282. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/index.d.ts.map +1 -0
  283. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/longpoll.d.ts +29 -0
  284. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/longpoll.d.ts.map +1 -0
  285. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/presence.d.ts +107 -0
  286. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/presence.d.ts.map +1 -0
  287. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/push.d.ts +70 -0
  288. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/push.d.ts.map +1 -0
  289. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/serializer.d.ts +74 -0
  290. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/serializer.d.ts.map +1 -0
  291. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/socket.d.ts +291 -0
  292. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/socket.d.ts.map +1 -0
  293. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/timer.d.ts +36 -0
  294. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/timer.d.ts.map +1 -0
  295. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/types.d.ts +280 -0
  296. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/types.d.ts.map +1 -0
  297. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/utils.d.ts +2 -0
  298. package/templates/realtime-agent/node_modules/@supabase/phoenix/priv/static/types/utils.d.ts.map +1 -0
  299. package/templates/realtime-agent/node_modules/@supabase/phoenix/tsconfig.json +20 -0
  300. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/README.md +213 -0
  301. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.cjs +5025 -0
  302. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.cjs.map +1 -0
  303. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.d.cts +3828 -0
  304. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.d.cts.map +1 -0
  305. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.d.mts +3828 -0
  306. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.d.mts.map +1 -0
  307. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.mjs +5017 -0
  308. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/dist/index.mjs.map +1 -0
  309. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/package.json +69 -0
  310. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestBuilder.ts +688 -0
  311. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestClient.ts +447 -0
  312. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestError.ts +41 -0
  313. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestFilterBuilder.ts +2137 -0
  314. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestQueryBuilder.ts +1703 -0
  315. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/PostgrestTransformBuilder.ts +981 -0
  316. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/constants.ts +2 -0
  317. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/index.ts +34 -0
  318. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/select-query-parser/parser.ts +476 -0
  319. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/select-query-parser/result.ts +550 -0
  320. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/select-query-parser/types.ts +129 -0
  321. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/select-query-parser/utils.ts +704 -0
  322. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/types/common/common.ts +83 -0
  323. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/types/common/rpc.ts +148 -0
  324. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/types/feature-flags.ts +17 -0
  325. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/types/types.ts +161 -0
  326. package/templates/realtime-agent/node_modules/@supabase/postgrest-js/src/version.ts +7 -0
  327. package/templates/realtime-agent/node_modules/@supabase/realtime-js/README.md +326 -0
  328. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeChannel.d.ts +442 -0
  329. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeChannel.d.ts.map +1 -0
  330. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeChannel.js +719 -0
  331. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeChannel.js.map +1 -0
  332. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeClient.d.ts +275 -0
  333. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeClient.d.ts.map +1 -0
  334. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeClient.js +697 -0
  335. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimeClient.js.map +1 -0
  336. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimePresence.d.ts +62 -0
  337. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimePresence.d.ts.map +1 -0
  338. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimePresence.js +43 -0
  339. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/RealtimePresence.js.map +1 -0
  340. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/index.d.ts +6 -0
  341. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/index.d.ts.map +1 -0
  342. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/index.js +18 -0
  343. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/index.js.map +1 -0
  344. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/constants.d.ts +43 -0
  345. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/constants.d.ts.map +1 -0
  346. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/constants.js +43 -0
  347. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/constants.js.map +1 -0
  348. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/normalizeChannelError.d.ts +10 -0
  349. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/normalizeChannelError.d.ts.map +1 -0
  350. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/normalizeChannelError.js +29 -0
  351. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/normalizeChannelError.js.map +1 -0
  352. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/serializer.d.ts +33 -0
  353. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/serializer.d.ts.map +1 -0
  354. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/serializer.js +155 -0
  355. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/serializer.js.map +1 -0
  356. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/transformers.d.ts +109 -0
  357. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/transformers.d.ts.map +1 -0
  358. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/transformers.js +241 -0
  359. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/transformers.js.map +1 -0
  360. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/version.d.ts +2 -0
  361. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/version.d.ts.map +1 -0
  362. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/version.js +11 -0
  363. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/version.js.map +1 -0
  364. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/websocket-factory.d.ts +82 -0
  365. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/websocket-factory.d.ts.map +1 -0
  366. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/websocket-factory.js +130 -0
  367. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/lib/websocket-factory.js.map +1 -0
  368. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/channelAdapter.d.ts +32 -0
  369. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/channelAdapter.d.ts.map +1 -0
  370. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/channelAdapter.js +103 -0
  371. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/channelAdapter.js.map +1 -0
  372. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/presenceAdapter.d.ts +53 -0
  373. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/presenceAdapter.d.ts.map +1 -0
  374. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/presenceAdapter.js +93 -0
  375. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/presenceAdapter.js.map +1 -0
  376. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/socketAdapter.d.ts +38 -0
  377. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/socketAdapter.d.ts.map +1 -0
  378. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/socketAdapter.js +114 -0
  379. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/socketAdapter.js.map +1 -0
  380. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/types.d.ts +5 -0
  381. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/types.d.ts.map +1 -0
  382. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/types.js +3 -0
  383. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/main/phoenix/types.js.map +1 -0
  384. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeChannel.d.ts +442 -0
  385. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeChannel.d.ts.map +1 -0
  386. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeChannel.js +714 -0
  387. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeChannel.js.map +1 -0
  388. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeClient.d.ts +275 -0
  389. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeClient.d.ts.map +1 -0
  390. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeClient.js +693 -0
  391. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimeClient.js.map +1 -0
  392. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimePresence.d.ts +62 -0
  393. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimePresence.d.ts.map +1 -0
  394. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimePresence.js +38 -0
  395. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/RealtimePresence.js.map +1 -0
  396. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/index.d.ts +6 -0
  397. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/index.d.ts.map +1 -0
  398. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/index.js +6 -0
  399. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/index.js.map +1 -0
  400. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/constants.d.ts +43 -0
  401. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/constants.d.ts.map +1 -0
  402. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/constants.js +40 -0
  403. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/constants.js.map +1 -0
  404. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/normalizeChannelError.d.ts +10 -0
  405. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/normalizeChannelError.d.ts.map +1 -0
  406. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/normalizeChannelError.js +26 -0
  407. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/normalizeChannelError.js.map +1 -0
  408. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/serializer.d.ts +33 -0
  409. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/serializer.d.ts.map +1 -0
  410. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/serializer.js +152 -0
  411. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/serializer.js.map +1 -0
  412. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/transformers.d.ts +109 -0
  413. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/transformers.d.ts.map +1 -0
  414. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/transformers.js +229 -0
  415. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/transformers.js.map +1 -0
  416. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/version.d.ts +2 -0
  417. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/version.d.ts.map +1 -0
  418. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/version.js +8 -0
  419. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/version.js.map +1 -0
  420. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/websocket-factory.d.ts +82 -0
  421. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/websocket-factory.d.ts.map +1 -0
  422. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/websocket-factory.js +126 -0
  423. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/lib/websocket-factory.js.map +1 -0
  424. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/channelAdapter.d.ts +32 -0
  425. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/channelAdapter.d.ts.map +1 -0
  426. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/channelAdapter.js +100 -0
  427. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/channelAdapter.js.map +1 -0
  428. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/presenceAdapter.d.ts +53 -0
  429. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/presenceAdapter.d.ts.map +1 -0
  430. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/presenceAdapter.js +90 -0
  431. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/presenceAdapter.js.map +1 -0
  432. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/socketAdapter.d.ts +38 -0
  433. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/socketAdapter.d.ts.map +1 -0
  434. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/socketAdapter.js +111 -0
  435. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/socketAdapter.js.map +1 -0
  436. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/types.d.ts +5 -0
  437. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/types.d.ts.map +1 -0
  438. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/types.js +2 -0
  439. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/module/phoenix/types.js.map +1 -0
  440. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/tsconfig.module.tsbuildinfo +1 -0
  441. package/templates/realtime-agent/node_modules/@supabase/realtime-js/dist/tsconfig.tsbuildinfo +1 -0
  442. package/templates/realtime-agent/node_modules/@supabase/realtime-js/package.json +58 -0
  443. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/RealtimeChannel.ts +1118 -0
  444. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/RealtimeClient.ts +868 -0
  445. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/RealtimePresence.ts +71 -0
  446. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/index.ts +53 -0
  447. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/constants.ts +62 -0
  448. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/normalizeChannelError.ts +30 -0
  449. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/serializer.ts +203 -0
  450. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/transformers.ts +270 -0
  451. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/version.ts +7 -0
  452. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/lib/websocket-factory.ts +204 -0
  453. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/phoenix/channelAdapter.ts +149 -0
  454. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/phoenix/presenceAdapter.ts +116 -0
  455. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/phoenix/socketAdapter.ts +168 -0
  456. package/templates/realtime-agent/node_modules/@supabase/realtime-js/src/phoenix/types.ts +32 -0
  457. package/templates/realtime-agent/node_modules/@supabase/storage-js/README.md +1262 -0
  458. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.cjs +2995 -0
  459. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.cjs.map +1 -0
  460. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.d.cts +2956 -0
  461. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.d.cts.map +1 -0
  462. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.d.mts +2956 -0
  463. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.d.mts.map +1 -0
  464. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.mjs +2979 -0
  465. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/index.mjs.map +1 -0
  466. package/templates/realtime-agent/node_modules/@supabase/storage-js/dist/umd/supabase.js +1 -0
  467. package/templates/realtime-agent/node_modules/@supabase/storage-js/package.json +62 -0
  468. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/StorageClient.ts +98 -0
  469. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/index.ts +19 -0
  470. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/common/BaseApiClient.ts +104 -0
  471. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/common/errors.ts +160 -0
  472. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/common/fetch.ts +303 -0
  473. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/common/headers.ts +43 -0
  474. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/common/helpers.ts +146 -0
  475. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/constants.ts +4 -0
  476. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/types.ts +654 -0
  477. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/lib/version.ts +7 -0
  478. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/BlobDownloadBuilder.ts +62 -0
  479. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/StorageAnalyticsClient.ts +420 -0
  480. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/StorageBucketApi.ts +414 -0
  481. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/StorageFileApi.ts +1423 -0
  482. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/StorageVectorsClient.ts +644 -0
  483. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/StreamDownloadBuilder.ts +39 -0
  484. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/VectorBucketApi.ts +73 -0
  485. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/VectorDataApi.ts +98 -0
  486. package/templates/realtime-agent/node_modules/@supabase/storage-js/src/packages/VectorIndexApi.ts +90 -0
  487. package/templates/realtime-agent/node_modules/@supabase/supabase-js/README.md +238 -0
  488. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.cjs +89 -0
  489. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.cjs.map +1 -0
  490. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.d.cts +58 -0
  491. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.d.cts.map +1 -0
  492. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.d.mts +58 -0
  493. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.d.mts.map +1 -0
  494. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.mjs +88 -0
  495. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/cors.mjs.map +1 -0
  496. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.cjs +660 -0
  497. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.cjs.map +1 -0
  498. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.d.cts +616 -0
  499. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.d.cts.map +1 -0
  500. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.d.mts +616 -0
  501. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.d.mts.map +1 -0
  502. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.mjs +607 -0
  503. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/index.mjs.map +1 -0
  504. package/templates/realtime-agent/node_modules/@supabase/supabase-js/dist/umd/supabase.js +24 -0
  505. package/templates/realtime-agent/node_modules/@supabase/supabase-js/package.json +122 -0
  506. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/SupabaseClient.ts +625 -0
  507. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/cors.ts +84 -0
  508. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/index.ts +106 -0
  509. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/SupabaseAuthClient.ts +8 -0
  510. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/constants.ts +35 -0
  511. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/fetch.ts +36 -0
  512. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/helpers.ts +98 -0
  513. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/rest/types/common/common.ts +93 -0
  514. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/rest/types/common/rpc.ts +158 -0
  515. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/types.ts +196 -0
  516. package/templates/realtime-agent/node_modules/@supabase/supabase-js/src/lib/version.ts +7 -0
  517. package/templates/realtime-agent/node_modules/iceberg-js/LICENSE +21 -0
  518. package/templates/realtime-agent/node_modules/iceberg-js/README.md +439 -0
  519. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.cjs +596 -0
  520. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.cjs.map +1 -0
  521. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.d.cts +547 -0
  522. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.d.ts +547 -0
  523. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.mjs +587 -0
  524. package/templates/realtime-agent/node_modules/iceberg-js/dist/index.mjs.map +1 -0
  525. package/templates/realtime-agent/node_modules/iceberg-js/package.json +77 -0
  526. package/templates/realtime-agent/node_modules/tslib/CopyrightNotice.txt +15 -0
  527. package/templates/realtime-agent/node_modules/tslib/LICENSE.txt +12 -0
  528. package/templates/realtime-agent/node_modules/tslib/README.md +164 -0
  529. package/templates/realtime-agent/node_modules/tslib/SECURITY.md +41 -0
  530. package/templates/realtime-agent/node_modules/tslib/modules/index.d.ts +38 -0
  531. package/templates/realtime-agent/node_modules/tslib/modules/index.js +70 -0
  532. package/templates/realtime-agent/node_modules/tslib/modules/package.json +3 -0
  533. package/templates/realtime-agent/node_modules/tslib/package.json +47 -0
  534. package/templates/realtime-agent/node_modules/tslib/tslib.d.ts +460 -0
  535. package/templates/realtime-agent/node_modules/tslib/tslib.es6.html +1 -0
  536. package/templates/realtime-agent/node_modules/tslib/tslib.es6.js +402 -0
  537. package/templates/realtime-agent/node_modules/tslib/tslib.es6.mjs +401 -0
  538. package/templates/realtime-agent/node_modules/tslib/tslib.html +1 -0
  539. package/templates/realtime-agent/node_modules/tslib/tslib.js +484 -0
  540. package/templates/realtime-agent/package-lock.json +114 -0
  541. package/templates/realtime-agent/package.json +11 -0
  542. package/templates/realtime-agent/src/index.js +152 -0
  543. package/templates/root/AGENT.md +37 -0
  544. package/templates/root/model.md +1 -0
  545. package/templates/root/prompt.md +91 -0
  546. package/templates/root/ralph.sh +47 -0
@@ -0,0 +1,2956 @@
1
+ import { IcebergError, IcebergRestCatalog } from "iceberg-js";
2
+
3
+ //#region src/lib/common/errors.d.ts
4
+
5
+ /**
6
+ * Namespace type for error classes
7
+ * Determines the error class names and type guards
8
+ */
9
+ type ErrorNamespace = 'storage' | 'vectors';
10
+ /**
11
+ * Base error class for all Storage errors
12
+ * Supports both 'storage' and 'vectors' namespaces
13
+ */
14
+ declare class StorageError extends Error {
15
+ protected __isStorageError: boolean;
16
+ protected namespace: ErrorNamespace;
17
+ status: number | undefined;
18
+ statusCode: string | undefined;
19
+ constructor(message: string, namespace?: ErrorNamespace, status?: number, statusCode?: string);
20
+ toJSON(): {
21
+ name: string;
22
+ message: string;
23
+ status: number | undefined;
24
+ statusCode: string | undefined;
25
+ };
26
+ }
27
+ /**
28
+ * Type guard to check if an error is a StorageError
29
+ * @param error - The error to check
30
+ * @returns True if the error is a StorageError
31
+ */
32
+ declare function isStorageError(error: unknown): error is StorageError;
33
+ /**
34
+ * API error returned from Storage service
35
+ * Includes HTTP status code and service-specific error code
36
+ */
37
+ declare class StorageApiError extends StorageError {
38
+ status: number;
39
+ statusCode: string;
40
+ constructor(message: string, status: number, statusCode: string, namespace?: ErrorNamespace);
41
+ toJSON(): {
42
+ name: string;
43
+ message: string;
44
+ status: number | undefined;
45
+ statusCode: string | undefined;
46
+ };
47
+ }
48
+ /**
49
+ * Unknown error that doesn't match expected error patterns
50
+ * Wraps the original error for debugging
51
+ */
52
+ declare class StorageUnknownError extends StorageError {
53
+ originalError: unknown;
54
+ constructor(message: string, originalError: unknown, namespace?: ErrorNamespace);
55
+ }
56
+ /**
57
+ * @deprecated Use StorageError with namespace='vectors' instead
58
+ * Alias for backward compatibility with existing vector storage code
59
+ */
60
+ declare class StorageVectorsError extends StorageError {
61
+ constructor(message: string);
62
+ }
63
+ /**
64
+ * Type guard to check if an error is a StorageVectorsError
65
+ * @param error - The error to check
66
+ * @returns True if the error is a StorageVectorsError
67
+ */
68
+ declare function isStorageVectorsError(error: unknown): error is StorageVectorsError;
69
+ /**
70
+ * @deprecated Use StorageApiError with namespace='vectors' instead
71
+ * Alias for backward compatibility with existing vector storage code
72
+ */
73
+ declare class StorageVectorsApiError extends StorageApiError {
74
+ constructor(message: string, status: number, statusCode: string);
75
+ }
76
+ /**
77
+ * @deprecated Use StorageUnknownError with namespace='vectors' instead
78
+ * Alias for backward compatibility with existing vector storage code
79
+ */
80
+ declare class StorageVectorsUnknownError extends StorageUnknownError {
81
+ constructor(message: string, originalError: unknown);
82
+ }
83
+ /**
84
+ * Error codes specific to S3 Vectors API
85
+ * Maps AWS service errors to application-friendly error codes
86
+ */
87
+ declare enum StorageVectorsErrorCode {
88
+ /** Internal server fault (HTTP 500) */
89
+ InternalError = "InternalError",
90
+ /** Resource already exists / conflict (HTTP 409) */
91
+ S3VectorConflictException = "S3VectorConflictException",
92
+ /** Resource not found (HTTP 404) */
93
+ S3VectorNotFoundException = "S3VectorNotFoundException",
94
+ /** Delete bucket while not empty (HTTP 400) */
95
+ S3VectorBucketNotEmpty = "S3VectorBucketNotEmpty",
96
+ /** Exceeds bucket quota/limit (HTTP 400) */
97
+ S3VectorMaxBucketsExceeded = "S3VectorMaxBucketsExceeded",
98
+ /** Exceeds index quota/limit (HTTP 400) */
99
+ S3VectorMaxIndexesExceeded = "S3VectorMaxIndexesExceeded",
100
+ }
101
+ //#endregion
102
+ //#region src/lib/types.d.ts
103
+ /**
104
+ * Type of storage bucket
105
+ * - STANDARD: Regular file storage buckets
106
+ * - ANALYTICS: Iceberg table-based buckets for analytical workloads
107
+ */
108
+ type BucketType = 'STANDARD' | 'ANALYTICS' | (string & {});
109
+ interface Bucket {
110
+ id: string;
111
+ type?: BucketType;
112
+ name: string;
113
+ owner: string;
114
+ file_size_limit?: number;
115
+ allowed_mime_types?: string[];
116
+ created_at: string;
117
+ updated_at: string;
118
+ public: boolean;
119
+ }
120
+ interface ListBucketOptions {
121
+ limit?: number;
122
+ offset?: number;
123
+ sortColumn?: 'id' | 'name' | 'created_at' | 'updated_at';
124
+ sortOrder?: 'asc' | 'desc';
125
+ search?: string;
126
+ }
127
+ /**
128
+ * Represents an Analytics Bucket using Apache Iceberg table format.
129
+ * Analytics buckets are optimized for analytical queries and data processing.
130
+ */
131
+ interface AnalyticBucket {
132
+ /** Unique identifier for the bucket */
133
+ name: string;
134
+ /** Bucket type - always 'ANALYTICS' for analytics buckets */
135
+ type: 'ANALYTICS';
136
+ /** Storage format used (e.g., 'iceberg') */
137
+ format: string;
138
+ /** ISO 8601 timestamp of bucket creation */
139
+ created_at: string;
140
+ /** ISO 8601 timestamp of last update */
141
+ updated_at: string;
142
+ }
143
+ /**
144
+ * Metadata object returned by the Storage API for files
145
+ * Contains information about file size, type, caching, and HTTP response details
146
+ */
147
+ interface FileMetadata {
148
+ /** Entity tag for caching and conditional requests */
149
+ eTag: string;
150
+ /** File size in bytes */
151
+ size: number;
152
+ /** MIME type of the file */
153
+ mimetype: string;
154
+ /** Cache control directive (e.g., "max-age=3600") */
155
+ cacheControl: string;
156
+ /** Last modification timestamp (ISO 8601) */
157
+ lastModified: string;
158
+ /** Content length in bytes (usually same as size) */
159
+ contentLength: number;
160
+ /** HTTP status code from the storage backend */
161
+ httpStatusCode: number;
162
+ /** Any additional custom metadata stored with the file */
163
+ [key: string]: any;
164
+ }
165
+ /**
166
+ * File object returned by the List V1 API (list() method)
167
+ * Note: Folder entries will have null values for most fields except name
168
+ *
169
+ * Warning: Some fields may not be present in all API responses. Fields like
170
+ * bucket_id, owner, and buckets are not returned by list() operations.
171
+ */
172
+ interface FileObject {
173
+ /** File or folder name (relative to the prefix) - always present */
174
+ name: string;
175
+ /** Unique identifier for the file (null for folders) */
176
+ id: string | null;
177
+ /** Last update timestamp (null for folders) */
178
+ updated_at: string | null;
179
+ /** Creation timestamp (null for folders) */
180
+ created_at: string | null;
181
+ /** @deprecated Last access timestamp (null for folders) */
182
+ last_accessed_at: string | null;
183
+ /** File metadata including size, mimetype, etc. (null for folders) */
184
+ metadata: FileMetadata | null;
185
+ /**
186
+ * @deprecated Bucket identifier - NOT returned by list() operations.
187
+ * May be present in remove() responses. Do not rely on this field.
188
+ */
189
+ bucket_id?: string;
190
+ /**
191
+ * @deprecated Owner identifier - NOT returned by list() or remove() operations.
192
+ * This field should not be relied upon.
193
+ */
194
+ owner?: string;
195
+ /**
196
+ * @deprecated Bucket object - NOT returned by list() or remove() operations.
197
+ * This field should not be relied upon.
198
+ */
199
+ buckets?: Bucket;
200
+ }
201
+ /**
202
+ * File object returned by the Info endpoint (info() method)
203
+ * Contains detailed metadata for a specific file
204
+ */
205
+ interface FileObjectV2 {
206
+ /** Unique identifier for the file */
207
+ id: string;
208
+ /** File version identifier */
209
+ version: string;
210
+ /** File name */
211
+ name: string;
212
+ /** Bucket identifier */
213
+ bucket_id: string;
214
+ /** Creation timestamp */
215
+ created_at: string;
216
+ /** File size in bytes */
217
+ size?: number;
218
+ /** Cache control header value */
219
+ cache_control?: string;
220
+ /** MIME content type */
221
+ content_type?: string;
222
+ /** Entity tag for caching */
223
+ etag?: string;
224
+ /** Last modification timestamp (replaces updated_at) */
225
+ last_modified?: string;
226
+ /** Custom file metadata */
227
+ metadata?: FileMetadata;
228
+ /**
229
+ * @deprecated The API returns last_modified instead.
230
+ * This field may not be present in responses.
231
+ */
232
+ updated_at?: string;
233
+ }
234
+ interface SortBy {
235
+ column?: string;
236
+ order?: string;
237
+ }
238
+ interface FileOptions {
239
+ /**
240
+ * The number of seconds the asset is cached in the browser and in the Supabase CDN. This is set in the `Cache-Control: max-age=<seconds>` header. Defaults to 3600 seconds.
241
+ */
242
+ cacheControl?: string;
243
+ /**
244
+ * the `Content-Type` header value. Should be specified if using a `fileBody` that is neither `Blob` nor `File` nor `FormData`, otherwise will default to `text/plain;charset=UTF-8`.
245
+ */
246
+ contentType?: string;
247
+ /**
248
+ * When upsert is set to true, the file is overwritten if it exists. When set to false, an error is thrown if the object already exists. Defaults to false.
249
+ */
250
+ upsert?: boolean;
251
+ /**
252
+ * The duplex option is a string parameter that enables or disables duplex streaming, allowing for both reading and writing data in the same stream. It can be passed as an option to the fetch() method.
253
+ */
254
+ duplex?: string;
255
+ /**
256
+ * The metadata option is an object that allows you to store additional information about the file. This information can be used to filter and search for files. The metadata object can contain any key-value pairs you want to store.
257
+ */
258
+ metadata?: Record<string, any>;
259
+ /**
260
+ * Optionally add extra headers
261
+ */
262
+ headers?: Record<string, string>;
263
+ }
264
+ interface DestinationOptions {
265
+ destinationBucket?: string;
266
+ }
267
+ interface SearchOptions {
268
+ /**
269
+ * The number of files you want to be returned.
270
+ * @default 100
271
+ */
272
+ limit?: number;
273
+ /**
274
+ * The starting position.
275
+ */
276
+ offset?: number;
277
+ /**
278
+ * The column to sort by. Can be any column inside a FileObject.
279
+ */
280
+ sortBy?: SortBy;
281
+ /**
282
+ * The search string to filter files by.
283
+ */
284
+ search?: string;
285
+ }
286
+ interface SortByV2 {
287
+ column: 'name' | 'updated_at' | 'created_at';
288
+ order?: 'asc' | 'desc';
289
+ }
290
+ interface SearchV2Options {
291
+ /**
292
+ * The number of files you want to be returned.
293
+ * @default 1000
294
+ */
295
+ limit?: number;
296
+ /**
297
+ * The prefix search string to filter files by.
298
+ */
299
+ prefix?: string;
300
+ /**
301
+ * The cursor used for pagination. Pass the value received from nextCursor of the previous request.
302
+ */
303
+ cursor?: string;
304
+ /**
305
+ * Whether to emulate a hierarchical listing of objects using delimiters.
306
+ *
307
+ * - When `false` (default), all objects are listed as flat key/value pairs.
308
+ * - When `true`, the response groups objects by delimiter, making it appear
309
+ * like a file/folder hierarchy.
310
+ *
311
+ * @default false
312
+ */
313
+ with_delimiter?: boolean;
314
+ /**
315
+ * The column and order to sort by
316
+ * @default 'name asc'
317
+ */
318
+ sortBy?: SortByV2;
319
+ }
320
+ /**
321
+ * File object returned by the List V2 API (listV2() method)
322
+ * Objects and folders are returned in separate arrays - this type represents
323
+ * actual files only. Use SearchV2Folder for folder entries.
324
+ */
325
+ interface SearchV2Object {
326
+ /** File name */
327
+ name: string;
328
+ /** Full object key/path */
329
+ key?: string;
330
+ /** Unique identifier for the file */
331
+ id: string;
332
+ /** Last update timestamp */
333
+ updated_at: string;
334
+ /** Creation timestamp */
335
+ created_at: string;
336
+ /** File metadata including size, mimetype, etc. (null if not yet set) */
337
+ metadata: FileMetadata | null;
338
+ /** @deprecated Last access timestamp */
339
+ last_accessed_at: string;
340
+ }
341
+ /**
342
+ * Folder entry returned by the List V2 API (listV2() method) when using with_delimiter: true
343
+ */
344
+ interface SearchV2Folder {
345
+ /** Folder name/prefix */
346
+ name: string;
347
+ /** Full folder key/path */
348
+ key?: string;
349
+ }
350
+ interface SearchV2Result {
351
+ hasNext: boolean;
352
+ folders: SearchV2Folder[];
353
+ objects: SearchV2Object[];
354
+ nextCursor?: string;
355
+ }
356
+ interface FetchParameters {
357
+ /**
358
+ * Pass in an AbortController's signal to cancel the request.
359
+ */
360
+ signal?: AbortSignal;
361
+ /**
362
+ * Controls how the request interacts with the browser's HTTP cache.
363
+ * - 'default': Use standard cache behavior
364
+ * - 'no-store': Bypass cache entirely (useful in Edge Functions)
365
+ * - 'reload': Bypass cache but update it with response
366
+ * - 'no-cache': Validate with server before using cached response
367
+ * - 'force-cache': Use cache even if stale
368
+ * - 'only-if-cached': Only use cache, fail if not cached
369
+ */
370
+ cache?: 'default' | 'no-store' | 'reload' | 'no-cache' | 'force-cache' | 'only-if-cached';
371
+ }
372
+ interface Metadata {
373
+ name: string;
374
+ }
375
+ interface TransformOptions {
376
+ /**
377
+ * The width of the image in pixels.
378
+ */
379
+ width?: number;
380
+ /**
381
+ * The height of the image in pixels.
382
+ */
383
+ height?: number;
384
+ /**
385
+ * The resize mode can be cover, contain or fill. Defaults to cover.
386
+ * Cover resizes the image to maintain it's aspect ratio while filling the entire width and height.
387
+ * Contain resizes the image to maintain it's aspect ratio while fitting the entire image within the width and height.
388
+ * Fill resizes the image to fill the entire width and height. If the object's aspect ratio does not match the width and height, the image will be stretched to fit.
389
+ */
390
+ resize?: 'cover' | 'contain' | 'fill';
391
+ /**
392
+ * Set the quality of the returned image.
393
+ * A number from 20 to 100, with 100 being the highest quality.
394
+ * Defaults to 80
395
+ */
396
+ quality?: number;
397
+ /**
398
+ * Specify the format of the image requested.
399
+ *
400
+ * When using 'origin' we force the format to be the same as the original image.
401
+ * When this option is not passed in, images are optimized to modern image formats like Webp.
402
+ */
403
+ format?: 'origin';
404
+ }
405
+ type CamelCase<S extends string> = S extends `${infer P1}_${infer P2}${infer P3}` ? `${Lowercase<P1>}${Uppercase<P2>}${CamelCase<P3>}` : S;
406
+ type Camelize<T> = { [K in keyof T as CamelCase<Extract<K, string>>]: T[K] };
407
+ type DownloadResult<T> = {
408
+ data: T;
409
+ error: null;
410
+ } | {
411
+ data: null;
412
+ error: StorageError;
413
+ };
414
+ /**
415
+ * Configuration for encryption at rest
416
+ * @property kmsKeyArn - ARN of the KMS key used for encryption
417
+ * @property sseType - Server-side encryption type (e.g., 'KMS')
418
+ */
419
+ interface EncryptionConfiguration {
420
+ kmsKeyArn?: string;
421
+ sseType?: string;
422
+ }
423
+ /**
424
+ * Vector bucket metadata
425
+ * @property vectorBucketName - Unique name of the vector bucket
426
+ * @property creationTime - Unix timestamp of when the bucket was created
427
+ * @property encryptionConfiguration - Optional encryption settings
428
+ */
429
+ interface VectorBucket {
430
+ vectorBucketName: string;
431
+ creationTime?: number;
432
+ encryptionConfiguration?: EncryptionConfiguration;
433
+ }
434
+ /**
435
+ * Metadata configuration for vector index
436
+ * Defines which metadata keys should not be indexed for filtering
437
+ * @property nonFilterableMetadataKeys - Array of metadata keys that cannot be used in filters
438
+ */
439
+ interface MetadataConfiguration {
440
+ nonFilterableMetadataKeys?: string[];
441
+ }
442
+ /**
443
+ * Supported data types for vectors
444
+ * Currently only float32 is supported
445
+ */
446
+ type VectorDataType = 'float32' | (string & {});
447
+ /**
448
+ * Distance metrics for vector similarity search
449
+ */
450
+ type DistanceMetric = 'cosine' | 'euclidean' | 'dotproduct' | (string & {});
451
+ /**
452
+ * Vector index configuration and metadata
453
+ * @property indexName - Unique name of the index within the bucket
454
+ * @property vectorBucketName - Name of the parent vector bucket
455
+ * @property dataType - Data type of vector components (currently only 'float32')
456
+ * @property dimension - Dimensionality of vectors (e.g., 384, 768, 1536)
457
+ * @property distanceMetric - Similarity metric used for queries
458
+ * @property metadataConfiguration - Configuration for metadata filtering
459
+ * @property creationTime - Unix timestamp of when the index was created
460
+ */
461
+ interface VectorIndex {
462
+ indexName: string;
463
+ vectorBucketName: string;
464
+ dataType: VectorDataType;
465
+ dimension: number;
466
+ distanceMetric: DistanceMetric;
467
+ metadataConfiguration?: MetadataConfiguration;
468
+ creationTime?: number;
469
+ }
470
+ /**
471
+ * Vector data representation
472
+ * Vectors must be float32 arrays with dimensions matching the index
473
+ * @property float32 - Array of 32-bit floating point numbers
474
+ */
475
+ interface VectorData {
476
+ float32: number[];
477
+ }
478
+ /**
479
+ * Arbitrary JSON metadata attached to vectors
480
+ * Keys configured as non-filterable in the index can be stored but not queried
481
+ */
482
+ type VectorMetadata = Record<string, any>;
483
+ /**
484
+ * Single vector object for insertion/update
485
+ * @property key - Unique identifier for the vector
486
+ * @property data - Vector embedding data
487
+ * @property metadata - Optional arbitrary metadata
488
+ */
489
+ interface VectorObject {
490
+ key: string;
491
+ data: VectorData;
492
+ metadata?: VectorMetadata;
493
+ }
494
+ /**
495
+ * Vector object returned from queries with optional distance
496
+ * @property key - Unique identifier for the vector
497
+ * @property data - Vector embedding data (if requested)
498
+ * @property metadata - Arbitrary metadata (if requested)
499
+ * @property distance - Similarity distance from query vector (if requested)
500
+ */
501
+ interface VectorMatch {
502
+ key: string;
503
+ data?: VectorData;
504
+ metadata?: VectorMetadata;
505
+ distance?: number;
506
+ }
507
+ /**
508
+ * Options for fetching vector buckets
509
+ * @property prefix - Filter buckets by name prefix
510
+ * @property maxResults - Maximum number of results to return (default: 100)
511
+ * @property nextToken - Token for pagination from previous response
512
+ */
513
+ interface ListVectorBucketsOptions {
514
+ prefix?: string;
515
+ maxResults?: number;
516
+ nextToken?: string;
517
+ }
518
+ /**
519
+ * Response from listing vector buckets
520
+ * @property vectorBuckets - Array of bucket names
521
+ * @property nextToken - Token for fetching next page (if more results exist)
522
+ */
523
+ interface ListVectorBucketsResponse {
524
+ vectorBuckets: {
525
+ vectorBucketName: string;
526
+ }[];
527
+ nextToken?: string;
528
+ }
529
+ /**
530
+ * Options for listing indexes within a bucket
531
+ * @property vectorBucketName - Name of the parent vector bucket
532
+ * @property prefix - Filter indexes by name prefix
533
+ * @property maxResults - Maximum number of results to return (default: 100)
534
+ * @property nextToken - Token for pagination from previous response
535
+ */
536
+ interface ListIndexesOptions {
537
+ vectorBucketName: string;
538
+ prefix?: string;
539
+ maxResults?: number;
540
+ nextToken?: string;
541
+ }
542
+ /**
543
+ * Response from listing indexes
544
+ * @property indexes - Array of index names
545
+ * @property nextToken - Token for fetching next page (if more results exist)
546
+ */
547
+ interface ListIndexesResponse {
548
+ indexes: {
549
+ indexName: string;
550
+ }[];
551
+ nextToken?: string;
552
+ }
553
+ /**
554
+ * Options for batch reading vectors
555
+ * @property vectorBucketName - Name of the vector bucket
556
+ * @property indexName - Name of the index
557
+ * @property keys - Array of vector keys to retrieve
558
+ * @property returnData - Whether to include vector data in response
559
+ * @property returnMetadata - Whether to include metadata in response
560
+ */
561
+ interface GetVectorsOptions {
562
+ vectorBucketName: string;
563
+ indexName: string;
564
+ keys: string[];
565
+ returnData?: boolean;
566
+ returnMetadata?: boolean;
567
+ }
568
+ /**
569
+ * Response from getting vectors
570
+ * @property vectors - Array of retrieved vector objects
571
+ */
572
+ interface GetVectorsResponse {
573
+ vectors: VectorMatch[];
574
+ }
575
+ /**
576
+ * Options for batch inserting/updating vectors
577
+ * @property vectorBucketName - Name of the vector bucket
578
+ * @property indexName - Name of the index
579
+ * @property vectors - Array of vectors to insert/upsert (1-500 items)
580
+ */
581
+ interface PutVectorsOptions {
582
+ vectorBucketName: string;
583
+ indexName: string;
584
+ vectors: VectorObject[];
585
+ }
586
+ /**
587
+ * Options for batch deleting vectors
588
+ * @property vectorBucketName - Name of the vector bucket
589
+ * @property indexName - Name of the index
590
+ * @property keys - Array of vector keys to delete (1-500 items)
591
+ */
592
+ interface DeleteVectorsOptions {
593
+ vectorBucketName: string;
594
+ indexName: string;
595
+ keys: string[];
596
+ }
597
+ /**
598
+ * Options for listing/scanning vectors in an index
599
+ * Supports parallel scanning via segment configuration
600
+ * @property vectorBucketName - Name of the vector bucket
601
+ * @property indexName - Name of the index
602
+ * @property maxResults - Maximum number of results to return (default: 500, max: 1000)
603
+ * @property nextToken - Token for pagination from previous response
604
+ * @property returnData - Whether to include vector data in response
605
+ * @property returnMetadata - Whether to include metadata in response
606
+ * @property segmentCount - Total number of parallel segments (1-16)
607
+ * @property segmentIndex - Zero-based index of this segment (0 to segmentCount-1)
608
+ */
609
+ interface ListVectorsOptions {
610
+ vectorBucketName: string;
611
+ indexName: string;
612
+ maxResults?: number;
613
+ nextToken?: string;
614
+ returnData?: boolean;
615
+ returnMetadata?: boolean;
616
+ segmentCount?: number;
617
+ segmentIndex?: number;
618
+ }
619
+ /**
620
+ * Response from listing vectors
621
+ * @property vectors - Array of vector objects
622
+ * @property nextToken - Token for fetching next page (if more results exist)
623
+ */
624
+ interface ListVectorsResponse {
625
+ vectors: VectorMatch[];
626
+ nextToken?: string;
627
+ }
628
+ /**
629
+ * JSON filter expression for metadata filtering
630
+ * Format and syntax depend on the S3 Vectors service implementation
631
+ */
632
+ type VectorFilter = Record<string, any>;
633
+ /**
634
+ * Options for querying similar vectors (ANN search)
635
+ * @property vectorBucketName - Name of the vector bucket
636
+ * @property indexName - Name of the index
637
+ * @property queryVector - Query vector to find similar vectors
638
+ * @property topK - Number of nearest neighbors to return (default: 10)
639
+ * @property filter - Optional JSON filter for metadata
640
+ * @property returnDistance - Whether to include distance scores
641
+ * @property returnMetadata - Whether to include metadata in results
642
+ */
643
+ interface QueryVectorsOptions {
644
+ vectorBucketName: string;
645
+ indexName: string;
646
+ queryVector: VectorData;
647
+ topK?: number;
648
+ filter?: VectorFilter;
649
+ returnDistance?: boolean;
650
+ returnMetadata?: boolean;
651
+ }
652
+ /**
653
+ * Response from vector similarity query
654
+ * @property vectors - Array of similar vectors ordered by distance
655
+ * @property distanceMetric - The distance metric used for the similarity search
656
+ */
657
+ interface QueryVectorsResponse {
658
+ vectors: VectorMatch[];
659
+ distanceMetric?: DistanceMetric;
660
+ }
661
+ /**
662
+ * Fetch-specific parameters like abort signals
663
+ * @property signal - AbortSignal for cancelling requests
664
+ */
665
+ interface VectorFetchParameters {
666
+ signal?: AbortSignal;
667
+ }
668
+ /**
669
+ * Standard response wrapper for successful operations
670
+ * @property data - Response data of type T
671
+ * @property error - Null on success
672
+ */
673
+ interface SuccessResponse<T> {
674
+ data: T;
675
+ error: null;
676
+ }
677
+ /**
678
+ * Standard response wrapper for failed operations
679
+ * @property data - Null on error
680
+ * @property error - StorageError with details (named StorageVectorsError for vector operations)
681
+ */
682
+ interface ErrorResponse {
683
+ data: null;
684
+ error: StorageError;
685
+ }
686
+ /**
687
+ * Union type for all API responses
688
+ * Follows the pattern: { data: T, error: null } | { data: null, error: Error }
689
+ */
690
+ type ApiResponse<T> = SuccessResponse<T> | ErrorResponse;
691
+ //#endregion
692
+ //#region src/lib/common/fetch.d.ts
693
+ type Fetch = typeof fetch;
694
+ //#endregion
695
+ //#region src/lib/common/BaseApiClient.d.ts
696
+ /**
697
+ * @ignore
698
+ * Base API client class for all Storage API classes
699
+ * Provides common infrastructure for error handling and configuration
700
+ *
701
+ * @typeParam TError - The error type (StorageError or subclass)
702
+ */
703
+ declare abstract class BaseApiClient<TError extends StorageError = StorageError> {
704
+ protected url: string;
705
+ protected headers: {
706
+ [key: string]: string;
707
+ };
708
+ protected fetch: Fetch;
709
+ protected shouldThrowOnError: boolean;
710
+ protected namespace: ErrorNamespace;
711
+ /**
712
+ * Creates a new BaseApiClient instance
713
+ * @param url - Base URL for API requests
714
+ * @param headers - Default headers for API requests
715
+ * @param fetch - Optional custom fetch implementation
716
+ * @param namespace - Error namespace ('storage' or 'vectors')
717
+ */
718
+ constructor(url: string, headers?: {
719
+ [key: string]: string;
720
+ }, fetch?: Fetch, namespace?: ErrorNamespace);
721
+ /**
722
+ * Enable throwing errors instead of returning them.
723
+ * When enabled, errors are thrown instead of returned in { data, error } format.
724
+ *
725
+ * @returns this - For method chaining
726
+ */
727
+ throwOnError(): this;
728
+ /**
729
+ * Set an HTTP header for the request.
730
+ * Creates a shallow copy of headers to avoid mutating shared state.
731
+ *
732
+ * @param name - Header name
733
+ * @param value - Header value
734
+ * @returns this - For method chaining
735
+ */
736
+ setHeader(name: string, value: string): this;
737
+ /**
738
+ * Handles API operation with standardized error handling
739
+ * Eliminates repetitive try-catch blocks across all API methods
740
+ *
741
+ * This wrapper:
742
+ * 1. Executes the operation
743
+ * 2. Returns { data, error: null } on success
744
+ * 3. Returns { data: null, error } on failure (if shouldThrowOnError is false)
745
+ * 4. Throws error on failure (if shouldThrowOnError is true)
746
+ *
747
+ * @typeParam T - The expected data type from the operation
748
+ * @param operation - Async function that performs the API call
749
+ * @returns Promise with { data, error } tuple
750
+ *
751
+ * @example Handling an operation
752
+ * ```typescript
753
+ * async listBuckets() {
754
+ * return this.handleOperation(async () => {
755
+ * return await get(this.fetch, `${this.url}/bucket`, {
756
+ * headers: this.headers,
757
+ * })
758
+ * })
759
+ * }
760
+ * ```
761
+ */
762
+ protected handleOperation<T>(operation: () => Promise<T>): Promise<{
763
+ data: T;
764
+ error: null;
765
+ } | {
766
+ data: null;
767
+ error: TError;
768
+ }>;
769
+ }
770
+ //#endregion
771
+ //#region src/packages/StreamDownloadBuilder.d.ts
772
+ declare class StreamDownloadBuilder implements PromiseLike<DownloadResult<ReadableStream>> {
773
+ private downloadFn;
774
+ private shouldThrowOnError;
775
+ constructor(downloadFn: () => Promise<Response>, shouldThrowOnError: boolean);
776
+ then<TResult1 = DownloadResult<ReadableStream>, TResult2 = never>(onfulfilled?: ((value: DownloadResult<ReadableStream>) => TResult1 | PromiseLike<TResult1>) | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null): Promise<TResult1 | TResult2>;
777
+ private execute;
778
+ }
779
+ //#endregion
780
+ //#region src/packages/BlobDownloadBuilder.d.ts
781
+ declare class BlobDownloadBuilder implements Promise<DownloadResult<Blob>> {
782
+ private downloadFn;
783
+ private shouldThrowOnError;
784
+ readonly [Symbol.toStringTag]: string;
785
+ private promise;
786
+ constructor(downloadFn: () => Promise<Response>, shouldThrowOnError: boolean);
787
+ asStream(): StreamDownloadBuilder;
788
+ then<TResult1 = DownloadResult<Blob>, TResult2 = never>(onfulfilled?: ((value: DownloadResult<Blob>) => TResult1 | PromiseLike<TResult1>) | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null): Promise<TResult1 | TResult2>;
789
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null): Promise<DownloadResult<Blob> | TResult>;
790
+ finally(onfinally?: (() => void) | null): Promise<DownloadResult<Blob>>;
791
+ private getPromise;
792
+ private execute;
793
+ }
794
+ //#endregion
795
+ //#region src/packages/StorageFileApi.d.ts
796
+ type FileBody = ArrayBuffer | ArrayBufferView | Blob | Buffer | File | FormData | NodeJS.ReadableStream | ReadableStream<Uint8Array> | URLSearchParams | string;
797
+ declare class StorageFileApi extends BaseApiClient<StorageError> {
798
+ protected bucketId: string | undefined;
799
+ constructor(url: string, headers?: {
800
+ [key: string]: string;
801
+ }, bucketId?: string, fetch?: Fetch);
802
+ /**
803
+ * Uploads a file to an existing bucket or replaces an existing file at the specified path with a new one.
804
+ *
805
+ * @param method HTTP method.
806
+ * @param path The relative file path. Should be of the format `folder/subfolder/filename.png`. The bucket must already exist before attempting to upload.
807
+ * @param fileBody The body of the file to be stored in the bucket.
808
+ */
809
+ private uploadOrUpdate;
810
+ /**
811
+ * Uploads a file to an existing bucket.
812
+ *
813
+ * @category Storage
814
+ * @subcategory File Buckets
815
+ * @param path The file path, including the file name. Should be of the format `folder/subfolder/filename.png`. The bucket must already exist before attempting to upload.
816
+ * @param fileBody The body of the file to be stored in the bucket.
817
+ * @param fileOptions Optional file upload options including cacheControl, contentType, upsert, and metadata.
818
+ * @returns Promise with response containing file path, id, and fullPath or error
819
+ *
820
+ * @example Upload file
821
+ * ```js
822
+ * const avatarFile = event.target.files[0]
823
+ * const { data, error } = await supabase
824
+ * .storage
825
+ * .from('avatars')
826
+ * .upload('public/avatar1.png', avatarFile, {
827
+ * cacheControl: '3600',
828
+ * upsert: false
829
+ * })
830
+ * ```
831
+ *
832
+ * Response:
833
+ * ```json
834
+ * {
835
+ * "data": {
836
+ * "path": "public/avatar1.png",
837
+ * "fullPath": "avatars/public/avatar1.png"
838
+ * },
839
+ * "error": null
840
+ * }
841
+ * ```
842
+ *
843
+ * @example Upload file using `ArrayBuffer` from base64 file data
844
+ * ```js
845
+ * import { decode } from 'base64-arraybuffer'
846
+ *
847
+ * const { data, error } = await supabase
848
+ * .storage
849
+ * .from('avatars')
850
+ * .upload('public/avatar1.png', decode('base64FileData'), {
851
+ * contentType: 'image/png'
852
+ * })
853
+ * ```
854
+ *
855
+ * @remarks
856
+ * - RLS policy permissions required:
857
+ * - `buckets` table permissions: none
858
+ * - `objects` table permissions: only `insert` when you are uploading new files and `select`, `insert` and `update` when you are upserting files
859
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
860
+ * - For React Native, using either `Blob`, `File` or `FormData` does not work as intended. Upload file using `ArrayBuffer` from base64 file data instead, see example below.
861
+ */
862
+ upload(path: string, fileBody: FileBody, fileOptions?: FileOptions): Promise<{
863
+ data: {
864
+ id: string;
865
+ path: string;
866
+ fullPath: string;
867
+ };
868
+ error: null;
869
+ } | {
870
+ data: null;
871
+ error: StorageError;
872
+ }>;
873
+ /**
874
+ * Upload a file with a token generated from `createSignedUploadUrl`.
875
+ *
876
+ * @category Storage
877
+ * @subcategory File Buckets
878
+ * @param path The file path, including the file name. Should be of the format `folder/subfolder/filename.png`. The bucket must already exist before attempting to upload.
879
+ * @param token The token generated from `createSignedUploadUrl`
880
+ * @param fileBody The body of the file to be stored in the bucket.
881
+ * @param fileOptions HTTP headers (cacheControl, contentType, etc.).
882
+ * **Note:** The `upsert` option has no effect here. To enable upsert behavior,
883
+ * pass `{ upsert: true }` when calling `createSignedUploadUrl()` instead.
884
+ * @returns Promise with response containing file path and fullPath or error
885
+ *
886
+ * @example Upload to a signed URL
887
+ * ```js
888
+ * const { data, error } = await supabase
889
+ * .storage
890
+ * .from('avatars')
891
+ * .uploadToSignedUrl('folder/cat.jpg', 'token-from-createSignedUploadUrl', file)
892
+ * ```
893
+ *
894
+ * Response:
895
+ * ```json
896
+ * {
897
+ * "data": {
898
+ * "path": "folder/cat.jpg",
899
+ * "fullPath": "avatars/folder/cat.jpg"
900
+ * },
901
+ * "error": null
902
+ * }
903
+ * ```
904
+ *
905
+ * @remarks
906
+ * - RLS policy permissions required:
907
+ * - `buckets` table permissions: none
908
+ * - `objects` table permissions: none
909
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
910
+ */
911
+ uploadToSignedUrl(path: string, token: string, fileBody: FileBody, fileOptions?: FileOptions): Promise<{
912
+ data: null;
913
+ error: StorageError;
914
+ } | {
915
+ data: {
916
+ path: string;
917
+ fullPath: any;
918
+ };
919
+ error: null;
920
+ }>;
921
+ /**
922
+ * Creates a signed upload URL.
923
+ * Signed upload URLs can be used to upload files to the bucket without further authentication.
924
+ * They are valid for 2 hours.
925
+ *
926
+ * @category Storage
927
+ * @subcategory File Buckets
928
+ * @param path The file path, including the current file name. For example `folder/image.png`.
929
+ * @param options.upsert If set to true, allows the file to be overwritten if it already exists.
930
+ * @returns Promise with response containing signed upload URL, token, and path or error
931
+ *
932
+ * @example Create Signed Upload URL
933
+ * ```js
934
+ * const { data, error } = await supabase
935
+ * .storage
936
+ * .from('avatars')
937
+ * .createSignedUploadUrl('folder/cat.jpg')
938
+ * ```
939
+ *
940
+ * Response:
941
+ * ```json
942
+ * {
943
+ * "data": {
944
+ * "signedUrl": "https://example.supabase.co/storage/v1/object/upload/sign/avatars/folder/cat.jpg?token=<TOKEN>",
945
+ * "path": "folder/cat.jpg",
946
+ * "token": "<TOKEN>"
947
+ * },
948
+ * "error": null
949
+ * }
950
+ * ```
951
+ *
952
+ * @remarks
953
+ * - RLS policy permissions required:
954
+ * - `buckets` table permissions: none
955
+ * - `objects` table permissions: `insert`
956
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
957
+ */
958
+ createSignedUploadUrl(path: string, options?: {
959
+ upsert: boolean;
960
+ }): Promise<{
961
+ data: {
962
+ signedUrl: string;
963
+ token: string;
964
+ path: string;
965
+ };
966
+ error: null;
967
+ } | {
968
+ data: null;
969
+ error: StorageError;
970
+ }>;
971
+ /**
972
+ * Replaces an existing file at the specified path with a new one.
973
+ *
974
+ * @category Storage
975
+ * @subcategory File Buckets
976
+ * @param path The relative file path. Should be of the format `folder/subfolder/filename.png`. The bucket must already exist before attempting to update.
977
+ * @param fileBody The body of the file to be stored in the bucket.
978
+ * @param fileOptions Optional file upload options including cacheControl, contentType, and metadata.
979
+ * **Note:** The `upsert` option has no effect here. `update()` always replaces the
980
+ * file at the given path, so the `x-upsert` header is not sent. To control upsert
981
+ * behavior, use `upload()` instead.
982
+ * @returns Promise with response containing file path, id, and fullPath or error
983
+ *
984
+ * @example Update file
985
+ * ```js
986
+ * const avatarFile = event.target.files[0]
987
+ * const { data, error } = await supabase
988
+ * .storage
989
+ * .from('avatars')
990
+ * .update('public/avatar1.png', avatarFile, {
991
+ * cacheControl: '3600'
992
+ * })
993
+ * ```
994
+ *
995
+ * Response:
996
+ * ```json
997
+ * {
998
+ * "data": {
999
+ * "path": "public/avatar1.png",
1000
+ * "fullPath": "avatars/public/avatar1.png"
1001
+ * },
1002
+ * "error": null
1003
+ * }
1004
+ * ```
1005
+ *
1006
+ * @example Update file using `ArrayBuffer` from base64 file data
1007
+ * ```js
1008
+ * import {decode} from 'base64-arraybuffer'
1009
+ *
1010
+ * const { data, error } = await supabase
1011
+ * .storage
1012
+ * .from('avatars')
1013
+ * .update('public/avatar1.png', decode('base64FileData'), {
1014
+ * contentType: 'image/png'
1015
+ * })
1016
+ * ```
1017
+ *
1018
+ * @remarks
1019
+ * - RLS policy permissions required:
1020
+ * - `buckets` table permissions: none
1021
+ * - `objects` table permissions: `update` and `select`
1022
+ * - `update()` always replaces the file at the given path regardless of the `upsert` option.
1023
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1024
+ * - For React Native, using either `Blob`, `File` or `FormData` does not work as intended. Update file using `ArrayBuffer` from base64 file data instead, see example below.
1025
+ */
1026
+ update(path: string, fileBody: ArrayBuffer | ArrayBufferView | Blob | Buffer | File | FormData | NodeJS.ReadableStream | ReadableStream<Uint8Array> | URLSearchParams | string, fileOptions?: FileOptions): Promise<{
1027
+ data: {
1028
+ id: string;
1029
+ path: string;
1030
+ fullPath: string;
1031
+ };
1032
+ error: null;
1033
+ } | {
1034
+ data: null;
1035
+ error: StorageError;
1036
+ }>;
1037
+ /**
1038
+ * Moves an existing file to a new path in the same bucket.
1039
+ *
1040
+ * @category Storage
1041
+ * @subcategory File Buckets
1042
+ * @param fromPath The original file path, including the current file name. For example `folder/image.png`.
1043
+ * @param toPath The new file path, including the new file name. For example `folder/image-new.png`.
1044
+ * @param options The destination options.
1045
+ * @returns Promise with response containing success message or error
1046
+ *
1047
+ * @example Move file
1048
+ * ```js
1049
+ * const { data, error } = await supabase
1050
+ * .storage
1051
+ * .from('avatars')
1052
+ * .move('public/avatar1.png', 'private/avatar2.png')
1053
+ * ```
1054
+ *
1055
+ * Response:
1056
+ * ```json
1057
+ * {
1058
+ * "data": {
1059
+ * "message": "Successfully moved"
1060
+ * },
1061
+ * "error": null
1062
+ * }
1063
+ * ```
1064
+ *
1065
+ * @remarks
1066
+ * - RLS policy permissions required:
1067
+ * - `buckets` table permissions: none
1068
+ * - `objects` table permissions: `update` and `select`
1069
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1070
+ */
1071
+ move(fromPath: string, toPath: string, options?: DestinationOptions): Promise<{
1072
+ data: {
1073
+ message: string;
1074
+ };
1075
+ error: null;
1076
+ } | {
1077
+ data: null;
1078
+ error: StorageError;
1079
+ }>;
1080
+ /**
1081
+ * Copies an existing file to a new path in the same bucket.
1082
+ *
1083
+ * @category Storage
1084
+ * @subcategory File Buckets
1085
+ * @param fromPath The original file path, including the current file name. For example `folder/image.png`.
1086
+ * @param toPath The new file path, including the new file name. For example `folder/image-copy.png`.
1087
+ * @param options The destination options.
1088
+ * @returns Promise with response containing copied file path or error
1089
+ *
1090
+ * @example Copy file
1091
+ * ```js
1092
+ * const { data, error } = await supabase
1093
+ * .storage
1094
+ * .from('avatars')
1095
+ * .copy('public/avatar1.png', 'private/avatar2.png')
1096
+ * ```
1097
+ *
1098
+ * Response:
1099
+ * ```json
1100
+ * {
1101
+ * "data": {
1102
+ * "path": "avatars/private/avatar2.png"
1103
+ * },
1104
+ * "error": null
1105
+ * }
1106
+ * ```
1107
+ *
1108
+ * @remarks
1109
+ * - RLS policy permissions required:
1110
+ * - `buckets` table permissions: none
1111
+ * - `objects` table permissions: `insert` and `select`
1112
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1113
+ */
1114
+ copy(fromPath: string, toPath: string, options?: DestinationOptions): Promise<{
1115
+ data: {
1116
+ path: string;
1117
+ };
1118
+ error: null;
1119
+ } | {
1120
+ data: null;
1121
+ error: StorageError;
1122
+ }>;
1123
+ /**
1124
+ * Creates a signed URL. Use a signed URL to share a file for a fixed amount of time.
1125
+ *
1126
+ * @category Storage
1127
+ * @subcategory File Buckets
1128
+ * @param path The file path, including the current file name. For example `folder/image.png`.
1129
+ * @param expiresIn The number of seconds until the signed URL expires. For example, `60` for a URL which is valid for one minute.
1130
+ * @param options.download triggers the file as a download if set to true. Set this parameter as the name of the file if you want to trigger the download with a different filename.
1131
+ * @param options.transform Transform the asset before serving it to the client.
1132
+ * @param options.cacheNonce Append a cache nonce parameter to the URL to invalidate the cache.
1133
+ * @returns Promise with response containing signed URL or error
1134
+ *
1135
+ * @example Create Signed URL
1136
+ * ```js
1137
+ * const { data, error } = await supabase
1138
+ * .storage
1139
+ * .from('avatars')
1140
+ * .createSignedUrl('folder/avatar1.png', 60)
1141
+ * ```
1142
+ *
1143
+ * Response:
1144
+ * ```json
1145
+ * {
1146
+ * "data": {
1147
+ * "signedUrl": "https://example.supabase.co/storage/v1/object/sign/avatars/folder/avatar1.png?token=<TOKEN>"
1148
+ * },
1149
+ * "error": null
1150
+ * }
1151
+ * ```
1152
+ *
1153
+ * @example Create a signed URL for an asset with transformations
1154
+ * ```js
1155
+ * const { data } = await supabase
1156
+ * .storage
1157
+ * .from('avatars')
1158
+ * .createSignedUrl('folder/avatar1.png', 60, {
1159
+ * transform: {
1160
+ * width: 100,
1161
+ * height: 100,
1162
+ * }
1163
+ * })
1164
+ * ```
1165
+ *
1166
+ * @example Create a signed URL which triggers the download of the asset
1167
+ * ```js
1168
+ * const { data } = await supabase
1169
+ * .storage
1170
+ * .from('avatars')
1171
+ * .createSignedUrl('folder/avatar1.png', 60, {
1172
+ * download: true,
1173
+ * })
1174
+ * ```
1175
+ *
1176
+ * @remarks
1177
+ * - RLS policy permissions required:
1178
+ * - `buckets` table permissions: none
1179
+ * - `objects` table permissions: `select`
1180
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1181
+ */
1182
+ createSignedUrl(path: string, expiresIn: number, options?: {
1183
+ download?: string | boolean;
1184
+ transform?: TransformOptions;
1185
+ cacheNonce?: string;
1186
+ }): Promise<{
1187
+ data: {
1188
+ signedUrl: string;
1189
+ };
1190
+ error: null;
1191
+ } | {
1192
+ data: null;
1193
+ error: StorageError;
1194
+ }>;
1195
+ /**
1196
+ * Creates multiple signed URLs. Use a signed URL to share a file for a fixed amount of time.
1197
+ *
1198
+ * @category Storage
1199
+ * @subcategory File Buckets
1200
+ * @param paths The file paths to be downloaded, including the current file names. For example `['folder/image.png', 'folder2/image2.png']`.
1201
+ * @param expiresIn The number of seconds until the signed URLs expire. For example, `60` for URLs which are valid for one minute.
1202
+ * @param options.download triggers the file as a download if set to true. Set this parameter as the name of the file if you want to trigger the download with a different filename.
1203
+ * @param options.cacheNonce Append a cache nonce parameter to the URL to invalidate the cache.
1204
+ * @returns Promise with response containing array of objects with signedUrl, path, and error or error
1205
+ *
1206
+ * @example Create Signed URLs
1207
+ * ```js
1208
+ * const { data, error } = await supabase
1209
+ * .storage
1210
+ * .from('avatars')
1211
+ * .createSignedUrls(['folder/avatar1.png', 'folder/avatar2.png'], 60)
1212
+ * ```
1213
+ *
1214
+ * Response:
1215
+ * ```json
1216
+ * {
1217
+ * "data": [
1218
+ * {
1219
+ * "error": null,
1220
+ * "path": "folder/avatar1.png",
1221
+ * "signedURL": "/object/sign/avatars/folder/avatar1.png?token=<TOKEN>",
1222
+ * "signedUrl": "https://example.supabase.co/storage/v1/object/sign/avatars/folder/avatar1.png?token=<TOKEN>"
1223
+ * },
1224
+ * {
1225
+ * "error": null,
1226
+ * "path": "folder/avatar2.png",
1227
+ * "signedURL": "/object/sign/avatars/folder/avatar2.png?token=<TOKEN>",
1228
+ * "signedUrl": "https://example.supabase.co/storage/v1/object/sign/avatars/folder/avatar2.png?token=<TOKEN>"
1229
+ * }
1230
+ * ],
1231
+ * "error": null
1232
+ * }
1233
+ * ```
1234
+ *
1235
+ * @remarks
1236
+ * - RLS policy permissions required:
1237
+ * - `buckets` table permissions: none
1238
+ * - `objects` table permissions: `select`
1239
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1240
+ */
1241
+ createSignedUrls(paths: string[], expiresIn: number, options?: {
1242
+ download?: string | boolean;
1243
+ cacheNonce?: string;
1244
+ }): Promise<{
1245
+ data: {
1246
+ error: string | null;
1247
+ path: string | null;
1248
+ signedUrl: string | null;
1249
+ }[];
1250
+ error: null;
1251
+ } | {
1252
+ data: null;
1253
+ error: StorageError;
1254
+ }>;
1255
+ /**
1256
+ * Downloads a file from a private bucket. For public buckets, make a request to the URL returned from `getPublicUrl` instead.
1257
+ *
1258
+ * @category Storage
1259
+ * @subcategory File Buckets
1260
+ * @param path The full path and file name of the file to be downloaded. For example `folder/image.png`.
1261
+ * @param options.transform Transform the asset before serving it to the client.
1262
+ * @param options.cacheNonce Append a cache nonce parameter to the URL to invalidate the cache.
1263
+ * @param parameters Additional fetch parameters like signal for cancellation. Supports standard fetch options including cache control.
1264
+ * @returns BlobDownloadBuilder instance for downloading the file
1265
+ *
1266
+ * @example Download file
1267
+ * ```js
1268
+ * const { data, error } = await supabase
1269
+ * .storage
1270
+ * .from('avatars')
1271
+ * .download('folder/avatar1.png')
1272
+ * ```
1273
+ *
1274
+ * Response:
1275
+ * ```json
1276
+ * {
1277
+ * "data": <BLOB>,
1278
+ * "error": null
1279
+ * }
1280
+ * ```
1281
+ *
1282
+ * @example Download file with transformations
1283
+ * ```js
1284
+ * const { data, error } = await supabase
1285
+ * .storage
1286
+ * .from('avatars')
1287
+ * .download('folder/avatar1.png', {
1288
+ * transform: {
1289
+ * width: 100,
1290
+ * height: 100,
1291
+ * quality: 80
1292
+ * }
1293
+ * })
1294
+ * ```
1295
+ *
1296
+ * @example Download with cache control (useful in Edge Functions)
1297
+ * ```js
1298
+ * const { data, error } = await supabase
1299
+ * .storage
1300
+ * .from('avatars')
1301
+ * .download('folder/avatar1.png', {}, { cache: 'no-store' })
1302
+ * ```
1303
+ *
1304
+ * @example Download with abort signal
1305
+ * ```js
1306
+ * const controller = new AbortController()
1307
+ * setTimeout(() => controller.abort(), 5000)
1308
+ *
1309
+ * const { data, error } = await supabase
1310
+ * .storage
1311
+ * .from('avatars')
1312
+ * .download('folder/avatar1.png', {}, { signal: controller.signal })
1313
+ * ```
1314
+ *
1315
+ * @remarks
1316
+ * - RLS policy permissions required:
1317
+ * - `buckets` table permissions: none
1318
+ * - `objects` table permissions: `select`
1319
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1320
+ */
1321
+ download<Options extends {
1322
+ transform?: TransformOptions;
1323
+ cacheNonce?: string;
1324
+ }>(path: string, options?: Options, parameters?: FetchParameters): BlobDownloadBuilder;
1325
+ /**
1326
+ * Retrieves the details of an existing file.
1327
+ *
1328
+ * Returns detailed file metadata including size, content type, and timestamps.
1329
+ * Note: The API returns `last_modified` field, not `updated_at`.
1330
+ *
1331
+ * @category Storage
1332
+ * @subcategory File Buckets
1333
+ * @param path The file path, including the file name. For example `folder/image.png`.
1334
+ * @returns Promise with response containing file metadata or error
1335
+ *
1336
+ * @example Get file info
1337
+ * ```js
1338
+ * const { data, error } = await supabase
1339
+ * .storage
1340
+ * .from('avatars')
1341
+ * .info('folder/avatar1.png')
1342
+ *
1343
+ * if (data) {
1344
+ * console.log('Last modified:', data.lastModified)
1345
+ * console.log('Size:', data.size)
1346
+ * }
1347
+ * ```
1348
+ */
1349
+ info(path: string): Promise<{
1350
+ data: Camelize<FileObjectV2>;
1351
+ error: null;
1352
+ } | {
1353
+ data: null;
1354
+ error: StorageError;
1355
+ }>;
1356
+ /**
1357
+ * Checks the existence of a file.
1358
+ *
1359
+ * @category Storage
1360
+ * @subcategory File Buckets
1361
+ * @param path The file path, including the file name. For example `folder/image.png`.
1362
+ * @returns Promise with response containing boolean indicating file existence or error
1363
+ *
1364
+ * @example Check file existence
1365
+ * ```js
1366
+ * const { data, error } = await supabase
1367
+ * .storage
1368
+ * .from('avatars')
1369
+ * .exists('folder/avatar1.png')
1370
+ * ```
1371
+ */
1372
+ exists(path: string): Promise<{
1373
+ data: boolean;
1374
+ error: null;
1375
+ } | {
1376
+ data: boolean;
1377
+ error: StorageError;
1378
+ }>;
1379
+ /**
1380
+ * A simple convenience function to get the URL for an asset in a public bucket. If you do not want to use this function, you can construct the public URL by concatenating the bucket URL with the path to the asset.
1381
+ * This function does not verify if the bucket is public. If a public URL is created for a bucket which is not public, you will not be able to download the asset.
1382
+ *
1383
+ * @category Storage
1384
+ * @subcategory File Buckets
1385
+ * @param path The path and name of the file to generate the public URL for. For example `folder/image.png`.
1386
+ * @param options.download Triggers the file as a download if set to true. Set this parameter as the name of the file if you want to trigger the download with a different filename.
1387
+ * @param options.transform Transform the asset before serving it to the client.
1388
+ * @param options.cacheNonce Append a cache nonce parameter to the URL to invalidate the cache.
1389
+ * @returns Object with public URL
1390
+ *
1391
+ * @example Returns the URL for an asset in a public bucket
1392
+ * ```js
1393
+ * const { data } = supabase
1394
+ * .storage
1395
+ * .from('public-bucket')
1396
+ * .getPublicUrl('folder/avatar1.png')
1397
+ * ```
1398
+ *
1399
+ * Response:
1400
+ * ```json
1401
+ * {
1402
+ * "data": {
1403
+ * "publicUrl": "https://example.supabase.co/storage/v1/object/public/public-bucket/folder/avatar1.png"
1404
+ * }
1405
+ * }
1406
+ * ```
1407
+ *
1408
+ * @example Returns the URL for an asset in a public bucket with transformations
1409
+ * ```js
1410
+ * const { data } = supabase
1411
+ * .storage
1412
+ * .from('public-bucket')
1413
+ * .getPublicUrl('folder/avatar1.png', {
1414
+ * transform: {
1415
+ * width: 100,
1416
+ * height: 100,
1417
+ * }
1418
+ * })
1419
+ * ```
1420
+ *
1421
+ * @example Returns the URL which triggers the download of an asset in a public bucket
1422
+ * ```js
1423
+ * const { data } = supabase
1424
+ * .storage
1425
+ * .from('public-bucket')
1426
+ * .getPublicUrl('folder/avatar1.png', {
1427
+ * download: true,
1428
+ * })
1429
+ * ```
1430
+ *
1431
+ * @remarks
1432
+ * - The bucket needs to be set to public, either via [updateBucket()](/docs/reference/javascript/storage-updatebucket) or by going to Storage on [supabase.com/dashboard](https://supabase.com/dashboard), clicking the overflow menu on a bucket and choosing "Make public"
1433
+ * - RLS policy permissions required:
1434
+ * - `buckets` table permissions: none
1435
+ * - `objects` table permissions: none
1436
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1437
+ */
1438
+ getPublicUrl(path: string, options?: {
1439
+ download?: string | boolean;
1440
+ transform?: TransformOptions;
1441
+ cacheNonce?: string;
1442
+ }): {
1443
+ data: {
1444
+ publicUrl: string;
1445
+ };
1446
+ };
1447
+ /**
1448
+ * Deletes files within the same bucket
1449
+ *
1450
+ * Returns an array of FileObject entries for the deleted files. Note that deprecated
1451
+ * fields like `bucket_id` may or may not be present in the response - do not rely on them.
1452
+ *
1453
+ * @category Storage
1454
+ * @subcategory File Buckets
1455
+ * @param paths An array of files to delete, including the path and file name. For example [`'folder/image.png'`].
1456
+ * @returns Promise with response containing array of deleted file objects or error
1457
+ *
1458
+ * @example Delete file
1459
+ * ```js
1460
+ * const { data, error } = await supabase
1461
+ * .storage
1462
+ * .from('avatars')
1463
+ * .remove(['folder/avatar1.png'])
1464
+ * ```
1465
+ *
1466
+ * Response:
1467
+ * ```json
1468
+ * {
1469
+ * "data": [],
1470
+ * "error": null
1471
+ * }
1472
+ * ```
1473
+ *
1474
+ * @remarks
1475
+ * - RLS policy permissions required:
1476
+ * - `buckets` table permissions: none
1477
+ * - `objects` table permissions: `delete` and `select`
1478
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1479
+ */
1480
+ remove(paths: string[]): Promise<{
1481
+ data: FileObject[];
1482
+ error: null;
1483
+ } | {
1484
+ data: null;
1485
+ error: StorageError;
1486
+ }>;
1487
+ /**
1488
+ * Get file metadata
1489
+ * @param id the file id to retrieve metadata
1490
+ */
1491
+ /**
1492
+ * Update file metadata
1493
+ * @param id the file id to update metadata
1494
+ * @param meta the new file metadata
1495
+ */
1496
+ /**
1497
+ * Lists all the files and folders within a path of the bucket.
1498
+ *
1499
+ * **Important:** For folder entries, fields like `id`, `updated_at`, `created_at`,
1500
+ * `last_accessed_at`, and `metadata` will be `null`. Only files have these fields populated.
1501
+ * Additionally, deprecated fields like `bucket_id`, `owner`, and `buckets` are NOT returned
1502
+ * by this method.
1503
+ *
1504
+ * @category Storage
1505
+ * @subcategory File Buckets
1506
+ * @param path The folder path.
1507
+ * @param options Search options including limit (defaults to 100), offset, sortBy, and search
1508
+ * @param parameters Optional fetch parameters including signal for cancellation
1509
+ * @returns Promise with response containing array of files/folders or error
1510
+ *
1511
+ * @example List files in a bucket
1512
+ * ```js
1513
+ * const { data, error } = await supabase
1514
+ * .storage
1515
+ * .from('avatars')
1516
+ * .list('folder', {
1517
+ * limit: 100,
1518
+ * offset: 0,
1519
+ * sortBy: { column: 'name', order: 'asc' },
1520
+ * })
1521
+ *
1522
+ * // Handle files vs folders
1523
+ * data?.forEach(item => {
1524
+ * if (item.id !== null) {
1525
+ * // It's a file
1526
+ * console.log('File:', item.name, 'Size:', item.metadata?.size)
1527
+ * } else {
1528
+ * // It's a folder
1529
+ * console.log('Folder:', item.name)
1530
+ * }
1531
+ * })
1532
+ * ```
1533
+ *
1534
+ * Response:
1535
+ * ```json
1536
+ * {
1537
+ * "data": [
1538
+ * {
1539
+ * "name": "avatar1.png",
1540
+ * "id": "e668cf7f-821b-4a2f-9dce-7dfa5dd1cfd2",
1541
+ * "updated_at": "2024-05-22T23:06:05.580Z",
1542
+ * "created_at": "2024-05-22T23:04:34.443Z",
1543
+ * "last_accessed_at": "2024-05-22T23:04:34.443Z",
1544
+ * "metadata": {
1545
+ * "eTag": "\"c5e8c553235d9af30ef4f6e280790b92\"",
1546
+ * "size": 32175,
1547
+ * "mimetype": "image/png",
1548
+ * "cacheControl": "max-age=3600",
1549
+ * "lastModified": "2024-05-22T23:06:05.574Z",
1550
+ * "contentLength": 32175,
1551
+ * "httpStatusCode": 200
1552
+ * }
1553
+ * }
1554
+ * ],
1555
+ * "error": null
1556
+ * }
1557
+ * ```
1558
+ *
1559
+ * @example Search files in a bucket
1560
+ * ```js
1561
+ * const { data, error } = await supabase
1562
+ * .storage
1563
+ * .from('avatars')
1564
+ * .list('folder', {
1565
+ * limit: 100,
1566
+ * offset: 0,
1567
+ * sortBy: { column: 'name', order: 'asc' },
1568
+ * search: 'jon'
1569
+ * })
1570
+ * ```
1571
+ *
1572
+ * @remarks
1573
+ * - RLS policy permissions required:
1574
+ * - `buckets` table permissions: none
1575
+ * - `objects` table permissions: `select`
1576
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1577
+ */
1578
+ list(path?: string, options?: SearchOptions, parameters?: FetchParameters): Promise<{
1579
+ data: FileObject[];
1580
+ error: null;
1581
+ } | {
1582
+ data: null;
1583
+ error: StorageError;
1584
+ }>;
1585
+ /**
1586
+ * Lists all the files and folders within a bucket using the V2 API with pagination support.
1587
+ *
1588
+ * **Important:** Folder entries in the `folders` array only contain `name` and optionally `key` —
1589
+ * they have no `id`, timestamps, or `metadata` fields. Full file metadata is only available
1590
+ * on entries in the `objects` array.
1591
+ *
1592
+ * @experimental this method signature might change in the future
1593
+ *
1594
+ * @category Storage
1595
+ * @subcategory File Buckets
1596
+ * @param options Search options including prefix, cursor for pagination, limit, with_delimiter
1597
+ * @param parameters Optional fetch parameters including signal for cancellation
1598
+ * @returns Promise with response containing folders/objects arrays with pagination info or error
1599
+ *
1600
+ * @example List files with pagination
1601
+ * ```js
1602
+ * const { data, error } = await supabase
1603
+ * .storage
1604
+ * .from('avatars')
1605
+ * .listV2({
1606
+ * prefix: 'folder/',
1607
+ * limit: 100,
1608
+ * })
1609
+ *
1610
+ * // Handle pagination
1611
+ * if (data?.hasNext) {
1612
+ * const nextPage = await supabase
1613
+ * .storage
1614
+ * .from('avatars')
1615
+ * .listV2({
1616
+ * prefix: 'folder/',
1617
+ * cursor: data.nextCursor,
1618
+ * })
1619
+ * }
1620
+ *
1621
+ * // Handle files vs folders
1622
+ * data?.objects.forEach(file => {
1623
+ * if (file.id !== null) {
1624
+ * console.log('File:', file.name, 'Size:', file.metadata?.size)
1625
+ * }
1626
+ * })
1627
+ * data?.folders.forEach(folder => {
1628
+ * console.log('Folder:', folder.name)
1629
+ * })
1630
+ * ```
1631
+ */
1632
+ listV2(options?: SearchV2Options, parameters?: FetchParameters): Promise<{
1633
+ data: SearchV2Result;
1634
+ error: null;
1635
+ } | {
1636
+ data: null;
1637
+ error: StorageError;
1638
+ }>;
1639
+ protected encodeMetadata(metadata: Record<string, any>): string;
1640
+ toBase64(data: string): string;
1641
+ private _getFinalPath;
1642
+ private _removeEmptyFolders;
1643
+ /** Modifies the `query`, appending values the from `transform` */
1644
+ private applyTransformOptsToQuery;
1645
+ }
1646
+ //#endregion
1647
+ //#region src/packages/StorageBucketApi.d.ts
1648
+ declare class StorageBucketApi extends BaseApiClient<StorageError> {
1649
+ constructor(url: string, headers?: {
1650
+ [key: string]: string;
1651
+ }, fetch?: Fetch, opts?: StorageClientOptions);
1652
+ /**
1653
+ * Retrieves the details of all Storage buckets within an existing project.
1654
+ *
1655
+ * @category Storage
1656
+ * @subcategory File Buckets
1657
+ * @param options Query parameters for listing buckets
1658
+ * @param options.limit Maximum number of buckets to return
1659
+ * @param options.offset Number of buckets to skip
1660
+ * @param options.sortColumn Column to sort by ('id', 'name', 'created_at', 'updated_at')
1661
+ * @param options.sortOrder Sort order ('asc' or 'desc')
1662
+ * @param options.search Search term to filter bucket names
1663
+ * @returns Promise with response containing array of buckets or error
1664
+ *
1665
+ * @example List buckets
1666
+ * ```js
1667
+ * const { data, error } = await supabase
1668
+ * .storage
1669
+ * .listBuckets()
1670
+ * ```
1671
+ *
1672
+ * @example List buckets with options
1673
+ * ```js
1674
+ * const { data, error } = await supabase
1675
+ * .storage
1676
+ * .listBuckets({
1677
+ * limit: 10,
1678
+ * offset: 0,
1679
+ * sortColumn: 'created_at',
1680
+ * sortOrder: 'desc',
1681
+ * search: 'prod'
1682
+ * })
1683
+ * ```
1684
+ *
1685
+ * @remarks
1686
+ * - RLS policy permissions required:
1687
+ * - `buckets` table permissions: `select`
1688
+ * - `objects` table permissions: none
1689
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1690
+ */
1691
+ listBuckets(options?: ListBucketOptions): Promise<{
1692
+ data: Bucket[];
1693
+ error: null;
1694
+ } | {
1695
+ data: null;
1696
+ error: StorageError;
1697
+ }>;
1698
+ /**
1699
+ * Retrieves the details of an existing Storage bucket.
1700
+ *
1701
+ * @category Storage
1702
+ * @subcategory File Buckets
1703
+ * @param id The unique identifier of the bucket you would like to retrieve.
1704
+ * @returns Promise with response containing bucket details or error
1705
+ *
1706
+ * @example Get bucket
1707
+ * ```js
1708
+ * const { data, error } = await supabase
1709
+ * .storage
1710
+ * .getBucket('avatars')
1711
+ * ```
1712
+ *
1713
+ * Response:
1714
+ * ```json
1715
+ * {
1716
+ * "data": {
1717
+ * "id": "avatars",
1718
+ * "name": "avatars",
1719
+ * "owner": "",
1720
+ * "public": false,
1721
+ * "file_size_limit": 1024,
1722
+ * "allowed_mime_types": [
1723
+ * "image/png"
1724
+ * ],
1725
+ * "created_at": "2024-05-22T22:26:05.100Z",
1726
+ * "updated_at": "2024-05-22T22:26:05.100Z"
1727
+ * },
1728
+ * "error": null
1729
+ * }
1730
+ * ```
1731
+ *
1732
+ * @remarks
1733
+ * - RLS policy permissions required:
1734
+ * - `buckets` table permissions: `select`
1735
+ * - `objects` table permissions: none
1736
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1737
+ */
1738
+ getBucket(id: string): Promise<{
1739
+ data: Bucket;
1740
+ error: null;
1741
+ } | {
1742
+ data: null;
1743
+ error: StorageError;
1744
+ }>;
1745
+ /**
1746
+ * Creates a new Storage bucket
1747
+ *
1748
+ * @category Storage
1749
+ * @subcategory File Buckets
1750
+ * @param id A unique identifier for the bucket you are creating.
1751
+ * @param options.public The visibility of the bucket. Public buckets don't require an authorization token to download objects, but still require a valid token for all other operations. By default, buckets are private.
1752
+ * @param options.fileSizeLimit specifies the max file size in bytes that can be uploaded to this bucket.
1753
+ * The global file size limit takes precedence over this value.
1754
+ * The default value is null, which doesn't set a per bucket file size limit.
1755
+ * @param options.allowedMimeTypes specifies the allowed mime types that this bucket can accept during upload.
1756
+ * The default value is null, which allows files with all mime types to be uploaded.
1757
+ * Each mime type specified can be a wildcard, e.g. image/*, or a specific mime type, e.g. image/png.
1758
+ * @param options.type (private-beta) specifies the bucket type. see `BucketType` for more details.
1759
+ * - default bucket type is `STANDARD`
1760
+ * @returns Promise with response containing newly created bucket name or error
1761
+ *
1762
+ * @example Create bucket
1763
+ * ```js
1764
+ * const { data, error } = await supabase
1765
+ * .storage
1766
+ * .createBucket('avatars', {
1767
+ * public: false,
1768
+ * allowedMimeTypes: ['image/png'],
1769
+ * fileSizeLimit: 1024
1770
+ * })
1771
+ * ```
1772
+ *
1773
+ * Response:
1774
+ * ```json
1775
+ * {
1776
+ * "data": {
1777
+ * "name": "avatars"
1778
+ * },
1779
+ * "error": null
1780
+ * }
1781
+ * ```
1782
+ *
1783
+ * @remarks
1784
+ * - RLS policy permissions required:
1785
+ * - `buckets` table permissions: `insert`
1786
+ * - `objects` table permissions: none
1787
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1788
+ */
1789
+ createBucket(id: string, options?: {
1790
+ public: boolean;
1791
+ fileSizeLimit?: number | string | null;
1792
+ allowedMimeTypes?: string[] | null;
1793
+ type?: BucketType;
1794
+ }): Promise<{
1795
+ data: Pick<Bucket, 'name'>;
1796
+ error: null;
1797
+ } | {
1798
+ data: null;
1799
+ error: StorageError;
1800
+ }>;
1801
+ /**
1802
+ * Updates a Storage bucket
1803
+ *
1804
+ * @category Storage
1805
+ * @subcategory File Buckets
1806
+ * @param id A unique identifier for the bucket you are updating.
1807
+ * @param options.public The visibility of the bucket. Public buckets don't require an authorization token to download objects, but still require a valid token for all other operations.
1808
+ * @param options.fileSizeLimit specifies the max file size in bytes that can be uploaded to this bucket.
1809
+ * The global file size limit takes precedence over this value.
1810
+ * The default value is null, which doesn't set a per bucket file size limit.
1811
+ * @param options.allowedMimeTypes specifies the allowed mime types that this bucket can accept during upload.
1812
+ * The default value is null, which allows files with all mime types to be uploaded.
1813
+ * Each mime type specified can be a wildcard, e.g. image/*, or a specific mime type, e.g. image/png.
1814
+ * @returns Promise with response containing success message or error
1815
+ *
1816
+ * @example Update bucket
1817
+ * ```js
1818
+ * const { data, error } = await supabase
1819
+ * .storage
1820
+ * .updateBucket('avatars', {
1821
+ * public: false,
1822
+ * allowedMimeTypes: ['image/png'],
1823
+ * fileSizeLimit: 1024
1824
+ * })
1825
+ * ```
1826
+ *
1827
+ * Response:
1828
+ * ```json
1829
+ * {
1830
+ * "data": {
1831
+ * "message": "Successfully updated"
1832
+ * },
1833
+ * "error": null
1834
+ * }
1835
+ * ```
1836
+ *
1837
+ * @remarks
1838
+ * - RLS policy permissions required:
1839
+ * - `buckets` table permissions: `select` and `update`
1840
+ * - `objects` table permissions: none
1841
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1842
+ */
1843
+ updateBucket(id: string, options: {
1844
+ public: boolean;
1845
+ fileSizeLimit?: number | string | null;
1846
+ allowedMimeTypes?: string[] | null;
1847
+ }): Promise<{
1848
+ data: {
1849
+ message: string;
1850
+ };
1851
+ error: null;
1852
+ } | {
1853
+ data: null;
1854
+ error: StorageError;
1855
+ }>;
1856
+ /**
1857
+ * Removes all objects inside a single bucket.
1858
+ *
1859
+ * @category Storage
1860
+ * @subcategory File Buckets
1861
+ * @param id The unique identifier of the bucket you would like to empty.
1862
+ * @returns Promise with success message or error
1863
+ *
1864
+ * @example Empty bucket
1865
+ * ```js
1866
+ * const { data, error } = await supabase
1867
+ * .storage
1868
+ * .emptyBucket('avatars')
1869
+ * ```
1870
+ *
1871
+ * Response:
1872
+ * ```json
1873
+ * {
1874
+ * "data": {
1875
+ * "message": "Successfully emptied"
1876
+ * },
1877
+ * "error": null
1878
+ * }
1879
+ * ```
1880
+ *
1881
+ * @remarks
1882
+ * - RLS policy permissions required:
1883
+ * - `buckets` table permissions: `select`
1884
+ * - `objects` table permissions: `select` and `delete`
1885
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1886
+ */
1887
+ emptyBucket(id: string): Promise<{
1888
+ data: {
1889
+ message: string;
1890
+ };
1891
+ error: null;
1892
+ } | {
1893
+ data: null;
1894
+ error: StorageError;
1895
+ }>;
1896
+ /**
1897
+ * Deletes an existing bucket. A bucket can't be deleted with existing objects inside it.
1898
+ * You must first `empty()` the bucket.
1899
+ *
1900
+ * @category Storage
1901
+ * @subcategory File Buckets
1902
+ * @param id The unique identifier of the bucket you would like to delete.
1903
+ * @returns Promise with success message or error
1904
+ *
1905
+ * @example Delete bucket
1906
+ * ```js
1907
+ * const { data, error } = await supabase
1908
+ * .storage
1909
+ * .deleteBucket('avatars')
1910
+ * ```
1911
+ *
1912
+ * Response:
1913
+ * ```json
1914
+ * {
1915
+ * "data": {
1916
+ * "message": "Successfully deleted"
1917
+ * },
1918
+ * "error": null
1919
+ * }
1920
+ * ```
1921
+ *
1922
+ * @remarks
1923
+ * - RLS policy permissions required:
1924
+ * - `buckets` table permissions: `select` and `delete`
1925
+ * - `objects` table permissions: none
1926
+ * - Refer to the [Storage guide](/docs/guides/storage/security/access-control) on how access control works
1927
+ */
1928
+ deleteBucket(id: string): Promise<{
1929
+ data: {
1930
+ message: string;
1931
+ };
1932
+ error: null;
1933
+ } | {
1934
+ data: null;
1935
+ error: StorageError;
1936
+ }>;
1937
+ private listBucketOptionsToQueryString;
1938
+ }
1939
+ //#endregion
1940
+ //#region src/packages/StorageAnalyticsClient.d.ts
1941
+ type WrapAsyncMethod<T> = T extends ((...args: infer A) => Promise<infer R>) ? (...args: A) => Promise<{
1942
+ data: R;
1943
+ error: null;
1944
+ } | {
1945
+ data: null;
1946
+ error: IcebergError;
1947
+ }> : T;
1948
+ type WrappedIcebergRestCatalog = { [K in keyof IcebergRestCatalog]: WrapAsyncMethod<IcebergRestCatalog[K]> };
1949
+ /**
1950
+ * Client class for managing Analytics Buckets using Iceberg tables
1951
+ * Provides methods for creating, listing, and deleting analytics buckets
1952
+ */
1953
+ declare class StorageAnalyticsClient extends BaseApiClient<StorageError> {
1954
+ /**
1955
+ * @alpha
1956
+ *
1957
+ * Creates a new StorageAnalyticsClient instance
1958
+ *
1959
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
1960
+ *
1961
+ * @category Storage
1962
+ * @subcategory Analytics Buckets
1963
+ * @param url - The base URL for the storage API
1964
+ * @param headers - HTTP headers to include in requests
1965
+ * @param fetch - Optional custom fetch implementation
1966
+ *
1967
+ * @example Using supabase-js (recommended)
1968
+ * ```typescript
1969
+ * import { createClient } from '@supabase/supabase-js'
1970
+ *
1971
+ * const supabase = createClient('https://xyzcompany.supabase.co', 'your-publishable-key')
1972
+ * const { data, error } = await supabase.storage.analytics.listBuckets()
1973
+ * ```
1974
+ *
1975
+ * @example Standalone import for bundle-sensitive environments
1976
+ * ```typescript
1977
+ * import { StorageAnalyticsClient } from '@supabase/storage-js'
1978
+ *
1979
+ * const client = new StorageAnalyticsClient(url, headers)
1980
+ * ```
1981
+ */
1982
+ constructor(url: string, headers?: {
1983
+ [key: string]: string;
1984
+ }, fetch?: Fetch);
1985
+ /**
1986
+ * @alpha
1987
+ *
1988
+ * Creates a new analytics bucket using Iceberg tables
1989
+ * Analytics buckets are optimized for analytical queries and data processing
1990
+ *
1991
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
1992
+ *
1993
+ * @category Storage
1994
+ * @subcategory Analytics Buckets
1995
+ * @param name A unique name for the bucket you are creating
1996
+ * @returns Promise with response containing newly created analytics bucket or error
1997
+ *
1998
+ * @example Create analytics bucket
1999
+ * ```js
2000
+ * const { data, error } = await supabase
2001
+ * .storage
2002
+ * .analytics
2003
+ * .createBucket('analytics-data')
2004
+ * ```
2005
+ *
2006
+ * Response:
2007
+ * ```json
2008
+ * {
2009
+ * "data": {
2010
+ * "name": "analytics-data",
2011
+ * "type": "ANALYTICS",
2012
+ * "format": "iceberg",
2013
+ * "created_at": "2024-05-22T22:26:05.100Z",
2014
+ * "updated_at": "2024-05-22T22:26:05.100Z"
2015
+ * },
2016
+ * "error": null
2017
+ * }
2018
+ * ```
2019
+ *
2020
+ * @remarks
2021
+ * - Creates a new analytics bucket using Iceberg tables
2022
+ * - Analytics buckets are optimized for analytical queries and data processing
2023
+ */
2024
+ createBucket(name: string): Promise<{
2025
+ data: AnalyticBucket;
2026
+ error: null;
2027
+ } | {
2028
+ data: null;
2029
+ error: StorageError;
2030
+ }>;
2031
+ /**
2032
+ * @alpha
2033
+ *
2034
+ * Retrieves the details of all Analytics Storage buckets within an existing project
2035
+ * Only returns buckets of type 'ANALYTICS'
2036
+ *
2037
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2038
+ *
2039
+ * @category Storage
2040
+ * @subcategory Analytics Buckets
2041
+ * @param options Query parameters for listing buckets
2042
+ * @param options.limit Maximum number of buckets to return
2043
+ * @param options.offset Number of buckets to skip
2044
+ * @param options.sortColumn Column to sort by ('name', 'created_at', 'updated_at')
2045
+ * @param options.sortOrder Sort order ('asc' or 'desc')
2046
+ * @param options.search Search term to filter bucket names
2047
+ * @returns Promise with response containing array of analytics buckets or error
2048
+ *
2049
+ * @example List analytics buckets
2050
+ * ```js
2051
+ * const { data, error } = await supabase
2052
+ * .storage
2053
+ * .analytics
2054
+ * .listBuckets({
2055
+ * limit: 10,
2056
+ * offset: 0,
2057
+ * sortColumn: 'created_at',
2058
+ * sortOrder: 'desc'
2059
+ * })
2060
+ * ```
2061
+ *
2062
+ * Response:
2063
+ * ```json
2064
+ * {
2065
+ * "data": [
2066
+ * {
2067
+ * "name": "analytics-data",
2068
+ * "type": "ANALYTICS",
2069
+ * "format": "iceberg",
2070
+ * "created_at": "2024-05-22T22:26:05.100Z",
2071
+ * "updated_at": "2024-05-22T22:26:05.100Z"
2072
+ * }
2073
+ * ],
2074
+ * "error": null
2075
+ * }
2076
+ * ```
2077
+ *
2078
+ * @remarks
2079
+ * - Retrieves the details of all Analytics Storage buckets within an existing project
2080
+ * - Only returns buckets of type 'ANALYTICS'
2081
+ */
2082
+ listBuckets(options?: {
2083
+ limit?: number;
2084
+ offset?: number;
2085
+ sortColumn?: 'name' | 'created_at' | 'updated_at';
2086
+ sortOrder?: 'asc' | 'desc';
2087
+ search?: string;
2088
+ }): Promise<{
2089
+ data: AnalyticBucket[];
2090
+ error: null;
2091
+ } | {
2092
+ data: null;
2093
+ error: StorageError;
2094
+ }>;
2095
+ /**
2096
+ * @alpha
2097
+ *
2098
+ * Deletes an existing analytics bucket
2099
+ * A bucket can't be deleted with existing objects inside it
2100
+ * You must first empty the bucket before deletion
2101
+ *
2102
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2103
+ *
2104
+ * @category Storage
2105
+ * @subcategory Analytics Buckets
2106
+ * @param bucketName The unique identifier of the bucket you would like to delete
2107
+ * @returns Promise with response containing success message or error
2108
+ *
2109
+ * @example Delete analytics bucket
2110
+ * ```js
2111
+ * const { data, error } = await supabase
2112
+ * .storage
2113
+ * .analytics
2114
+ * .deleteBucket('analytics-data')
2115
+ * ```
2116
+ *
2117
+ * Response:
2118
+ * ```json
2119
+ * {
2120
+ * "data": {
2121
+ * "message": "Successfully deleted"
2122
+ * },
2123
+ * "error": null
2124
+ * }
2125
+ * ```
2126
+ *
2127
+ * @remarks
2128
+ * - Deletes an analytics bucket
2129
+ */
2130
+ deleteBucket(bucketName: string): Promise<{
2131
+ data: {
2132
+ message: string;
2133
+ };
2134
+ error: null;
2135
+ } | {
2136
+ data: null;
2137
+ error: StorageError;
2138
+ }>;
2139
+ /**
2140
+ * @alpha
2141
+ *
2142
+ * Get an Iceberg REST Catalog client configured for a specific analytics bucket
2143
+ * Use this to perform advanced table and namespace operations within the bucket
2144
+ * The returned client provides full access to the Apache Iceberg REST Catalog API
2145
+ * with the Supabase `{ data, error }` pattern for consistent error handling on all operations.
2146
+ *
2147
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2148
+ *
2149
+ * @category Storage
2150
+ * @subcategory Analytics Buckets
2151
+ * @param bucketName - The name of the analytics bucket (warehouse) to connect to
2152
+ * @returns The wrapped Iceberg catalog client
2153
+ * @throws {StorageError} If the bucket name is invalid
2154
+ *
2155
+ * @example Get catalog and create table
2156
+ * ```js
2157
+ * // First, create an analytics bucket
2158
+ * const { data: bucket, error: bucketError } = await supabase
2159
+ * .storage
2160
+ * .analytics
2161
+ * .createBucket('analytics-data')
2162
+ *
2163
+ * // Get the Iceberg catalog for that bucket
2164
+ * const catalog = supabase.storage.analytics.from('analytics-data')
2165
+ *
2166
+ * // Create a namespace
2167
+ * const { error: nsError } = await catalog.createNamespace({ namespace: ['default'] })
2168
+ *
2169
+ * // Create a table with schema
2170
+ * const { data: tableMetadata, error: tableError } = await catalog.createTable(
2171
+ * { namespace: ['default'] },
2172
+ * {
2173
+ * name: 'events',
2174
+ * schema: {
2175
+ * type: 'struct',
2176
+ * fields: [
2177
+ * { id: 1, name: 'id', type: 'long', required: true },
2178
+ * { id: 2, name: 'timestamp', type: 'timestamp', required: true },
2179
+ * { id: 3, name: 'user_id', type: 'string', required: false }
2180
+ * ],
2181
+ * 'schema-id': 0,
2182
+ * 'identifier-field-ids': [1]
2183
+ * },
2184
+ * 'partition-spec': {
2185
+ * 'spec-id': 0,
2186
+ * fields: []
2187
+ * },
2188
+ * 'write-order': {
2189
+ * 'order-id': 0,
2190
+ * fields: []
2191
+ * },
2192
+ * properties: {
2193
+ * 'write.format.default': 'parquet'
2194
+ * }
2195
+ * }
2196
+ * )
2197
+ * ```
2198
+ *
2199
+ * @example List tables in namespace
2200
+ * ```js
2201
+ * const catalog = supabase.storage.analytics.from('analytics-data')
2202
+ *
2203
+ * // List all tables in the default namespace
2204
+ * const { data: tables, error: listError } = await catalog.listTables({ namespace: ['default'] })
2205
+ * if (listError) {
2206
+ * if (listError.isNotFound()) {
2207
+ * console.log('Namespace not found')
2208
+ * }
2209
+ * return
2210
+ * }
2211
+ * console.log(tables) // [{ namespace: ['default'], name: 'events' }]
2212
+ * ```
2213
+ *
2214
+ * @example Working with namespaces
2215
+ * ```js
2216
+ * const catalog = supabase.storage.analytics.from('analytics-data')
2217
+ *
2218
+ * // List all namespaces
2219
+ * const { data: namespaces } = await catalog.listNamespaces()
2220
+ *
2221
+ * // Create namespace with properties
2222
+ * await catalog.createNamespace(
2223
+ * { namespace: ['production'] },
2224
+ * { properties: { owner: 'data-team', env: 'prod' } }
2225
+ * )
2226
+ * ```
2227
+ *
2228
+ * @example Cleanup operations
2229
+ * ```js
2230
+ * const catalog = supabase.storage.analytics.from('analytics-data')
2231
+ *
2232
+ * // Drop table with purge option (removes all data)
2233
+ * const { error: dropError } = await catalog.dropTable(
2234
+ * { namespace: ['default'], name: 'events' },
2235
+ * { purge: true }
2236
+ * )
2237
+ *
2238
+ * if (dropError?.isNotFound()) {
2239
+ * console.log('Table does not exist')
2240
+ * }
2241
+ *
2242
+ * // Drop namespace (must be empty)
2243
+ * await catalog.dropNamespace({ namespace: ['default'] })
2244
+ * ```
2245
+ *
2246
+ * @remarks
2247
+ * This method provides a bridge between Supabase's bucket management and the standard
2248
+ * Apache Iceberg REST Catalog API. The bucket name maps to the Iceberg warehouse parameter.
2249
+ * All authentication and configuration is handled automatically using your Supabase credentials.
2250
+ *
2251
+ * **Error Handling**: Invalid bucket names throw immediately. All catalog
2252
+ * operations return `{ data, error }` where errors are `IcebergError` instances from iceberg-js.
2253
+ * Use helper methods like `error.isNotFound()` or check `error.status` for specific error handling.
2254
+ * Use `.throwOnError()` on the analytics client if you prefer exceptions for catalog operations.
2255
+ *
2256
+ * **Cleanup Operations**: When using `dropTable`, the `purge: true` option permanently
2257
+ * deletes all table data. Without it, the table is marked as deleted but data remains.
2258
+ *
2259
+ * **Library Dependency**: The returned catalog wraps `IcebergRestCatalog` from iceberg-js.
2260
+ * For complete API documentation and advanced usage, refer to the
2261
+ * [iceberg-js documentation](https://supabase.github.io/iceberg-js/).
2262
+ */
2263
+ from(bucketName: string): WrappedIcebergRestCatalog;
2264
+ }
2265
+ //#endregion
2266
+ //#region src/packages/VectorIndexApi.d.ts
2267
+ /**
2268
+ * @alpha
2269
+ *
2270
+ * Options for creating a vector index
2271
+ *
2272
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2273
+ */
2274
+ interface CreateIndexOptions {
2275
+ vectorBucketName: string;
2276
+ indexName: string;
2277
+ dataType: VectorDataType;
2278
+ dimension: number;
2279
+ distanceMetric: DistanceMetric;
2280
+ metadataConfiguration?: MetadataConfiguration;
2281
+ }
2282
+ /**
2283
+ * @hidden
2284
+ * Base implementation for vector index operations.
2285
+ * Use {@link VectorBucketScope} via `supabase.storage.vectors.from('bucket')` instead.
2286
+ */
2287
+ declare class VectorIndexApi extends BaseApiClient<StorageError> {
2288
+ /** Creates a new VectorIndexApi instance */
2289
+ constructor(url: string, headers?: {
2290
+ [key: string]: string;
2291
+ }, fetch?: Fetch);
2292
+ /** Creates a new vector index within a bucket */
2293
+ createIndex(options: CreateIndexOptions): Promise<ApiResponse<undefined>>;
2294
+ /** Retrieves metadata for a specific vector index */
2295
+ getIndex(vectorBucketName: string, indexName: string): Promise<ApiResponse<{
2296
+ index: VectorIndex;
2297
+ }>>;
2298
+ /** Lists vector indexes within a bucket with optional filtering and pagination */
2299
+ listIndexes(options: ListIndexesOptions): Promise<ApiResponse<ListIndexesResponse>>;
2300
+ /** Deletes a vector index and all its data */
2301
+ deleteIndex(vectorBucketName: string, indexName: string): Promise<ApiResponse<undefined>>;
2302
+ }
2303
+ //#endregion
2304
+ //#region src/packages/VectorDataApi.d.ts
2305
+ /**
2306
+ * @hidden
2307
+ * Base implementation for vector data operations.
2308
+ * Use {@link VectorIndexScope} via `supabase.storage.vectors.from('bucket').index('idx')` instead.
2309
+ */
2310
+ declare class VectorDataApi extends BaseApiClient<StorageError> {
2311
+ /** Creates a new VectorDataApi instance */
2312
+ constructor(url: string, headers?: {
2313
+ [key: string]: string;
2314
+ }, fetch?: Fetch);
2315
+ /** Inserts or updates vectors in batch (1-500 per request) */
2316
+ putVectors(options: PutVectorsOptions): Promise<ApiResponse<undefined>>;
2317
+ /** Retrieves vectors by their keys in batch */
2318
+ getVectors(options: GetVectorsOptions): Promise<ApiResponse<GetVectorsResponse>>;
2319
+ /** Lists vectors in an index with pagination */
2320
+ listVectors(options: ListVectorsOptions): Promise<ApiResponse<ListVectorsResponse>>;
2321
+ /** Queries for similar vectors using approximate nearest neighbor search */
2322
+ queryVectors(options: QueryVectorsOptions): Promise<ApiResponse<QueryVectorsResponse>>;
2323
+ /** Deletes vectors by their keys in batch (1-500 per request) */
2324
+ deleteVectors(options: DeleteVectorsOptions): Promise<ApiResponse<undefined>>;
2325
+ }
2326
+ //#endregion
2327
+ //#region src/packages/VectorBucketApi.d.ts
2328
+ /**
2329
+ * @hidden
2330
+ * Base implementation for vector bucket operations.
2331
+ * Use {@link StorageVectorsClient} via `supabase.storage.vectors` instead.
2332
+ */
2333
+ declare class VectorBucketApi extends BaseApiClient<StorageError> {
2334
+ /** Creates a new VectorBucketApi instance */
2335
+ constructor(url: string, headers?: {
2336
+ [key: string]: string;
2337
+ }, fetch?: Fetch);
2338
+ /** Creates a new vector bucket */
2339
+ createBucket(vectorBucketName: string): Promise<ApiResponse<undefined>>;
2340
+ /** Retrieves metadata for a specific vector bucket */
2341
+ getBucket(vectorBucketName: string): Promise<ApiResponse<{
2342
+ vectorBucket: VectorBucket;
2343
+ }>>;
2344
+ /** Lists vector buckets with optional filtering and pagination */
2345
+ listBuckets(options?: ListVectorBucketsOptions): Promise<ApiResponse<ListVectorBucketsResponse>>;
2346
+ /** Deletes a vector bucket (must be empty first) */
2347
+ deleteBucket(vectorBucketName: string): Promise<ApiResponse<undefined>>;
2348
+ }
2349
+ //#endregion
2350
+ //#region src/packages/StorageVectorsClient.d.ts
2351
+ /**
2352
+ *
2353
+ * @alpha
2354
+ *
2355
+ * Configuration options for the Storage Vectors client
2356
+ *
2357
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2358
+ */
2359
+ interface StorageVectorsClientOptions {
2360
+ /**
2361
+ * Custom headers to include in all requests
2362
+ */
2363
+ headers?: {
2364
+ [key: string]: string;
2365
+ };
2366
+ /**
2367
+ * Custom fetch implementation (optional)
2368
+ * Useful for testing or custom request handling
2369
+ */
2370
+ fetch?: Fetch;
2371
+ }
2372
+ /**
2373
+ *
2374
+ * @alpha
2375
+ *
2376
+ * Main client for interacting with S3 Vectors API
2377
+ * Provides access to bucket, index, and vector data operations
2378
+ *
2379
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2380
+ *
2381
+ * **Usage Patterns:**
2382
+ *
2383
+ * ```typescript
2384
+ * const { data, error } = await supabase
2385
+ * .storage
2386
+ * .vectors
2387
+ * .createBucket('embeddings-prod')
2388
+ *
2389
+ * // Access index operations via buckets
2390
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2391
+ * await bucket.createIndex({
2392
+ * indexName: 'documents',
2393
+ * dataType: 'float32',
2394
+ * dimension: 1536,
2395
+ * distanceMetric: 'cosine'
2396
+ * })
2397
+ *
2398
+ * // Access vector operations via index
2399
+ * const index = bucket.index('documents')
2400
+ * await index.putVectors({
2401
+ * vectors: [
2402
+ * { key: 'doc-1', data: { float32: [...] }, metadata: { title: 'Intro' } }
2403
+ * ]
2404
+ * })
2405
+ *
2406
+ * // Query similar vectors
2407
+ * const { data } = await index.queryVectors({
2408
+ * queryVector: { float32: [...] },
2409
+ * topK: 5,
2410
+ * returnDistance: true
2411
+ * })
2412
+ * ```
2413
+ */
2414
+ declare class StorageVectorsClient extends VectorBucketApi {
2415
+ /**
2416
+ * @alpha
2417
+ *
2418
+ * Creates a StorageVectorsClient that can manage buckets, indexes, and vectors.
2419
+ *
2420
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2421
+ *
2422
+ * @category Storage
2423
+ * @subcategory Vector Buckets
2424
+ * @param url - Base URL of the Storage Vectors REST API.
2425
+ * @param options.headers - Optional headers (for example `Authorization`) applied to every request.
2426
+ * @param options.fetch - Optional custom `fetch` implementation for non-browser runtimes.
2427
+ *
2428
+ * @example Using supabase-js (recommended)
2429
+ * ```typescript
2430
+ * import { createClient } from '@supabase/supabase-js'
2431
+ *
2432
+ * const supabase = createClient('https://xyzcompany.supabase.co', 'your-publishable-key')
2433
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2434
+ * ```
2435
+ *
2436
+ * @example Standalone import for bundle-sensitive environments
2437
+ * ```typescript
2438
+ * import { StorageVectorsClient } from '@supabase/storage-js'
2439
+ *
2440
+ * const client = new StorageVectorsClient(url, options)
2441
+ * ```
2442
+ */
2443
+ constructor(url: string, options?: StorageVectorsClientOptions);
2444
+ /**
2445
+ *
2446
+ * @alpha
2447
+ *
2448
+ * Access operations for a specific vector bucket
2449
+ * Returns a scoped client for index and vector operations within the bucket
2450
+ *
2451
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2452
+ *
2453
+ * @category Storage
2454
+ * @subcategory Vector Buckets
2455
+ * @param vectorBucketName - Name of the vector bucket
2456
+ * @returns Bucket-scoped client with index and vector operations
2457
+ *
2458
+ * @example Accessing a vector bucket
2459
+ * ```typescript
2460
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2461
+ * ```
2462
+ */
2463
+ from(vectorBucketName: string): VectorBucketScope;
2464
+ /**
2465
+ *
2466
+ * @alpha
2467
+ *
2468
+ * Creates a new vector bucket
2469
+ * Vector buckets are containers for vector indexes and their data
2470
+ *
2471
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2472
+ *
2473
+ * @category Storage
2474
+ * @subcategory Vector Buckets
2475
+ * @param vectorBucketName - Unique name for the vector bucket
2476
+ * @returns Promise with empty response on success or error
2477
+ *
2478
+ * @example Creating a vector bucket
2479
+ * ```typescript
2480
+ * const { data, error } = await supabase
2481
+ * .storage
2482
+ * .vectors
2483
+ * .createBucket('embeddings-prod')
2484
+ * ```
2485
+ */
2486
+ createBucket(vectorBucketName: string): Promise<ApiResponse<undefined>>;
2487
+ /**
2488
+ *
2489
+ * @alpha
2490
+ *
2491
+ * Retrieves metadata for a specific vector bucket
2492
+ *
2493
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2494
+ *
2495
+ * @category Storage
2496
+ * @subcategory Vector Buckets
2497
+ * @param vectorBucketName - Name of the vector bucket
2498
+ * @returns Promise with bucket metadata or error
2499
+ *
2500
+ * @example Get bucket metadata
2501
+ * ```typescript
2502
+ * const { data, error } = await supabase
2503
+ * .storage
2504
+ * .vectors
2505
+ * .getBucket('embeddings-prod')
2506
+ *
2507
+ * console.log('Bucket created:', data?.vectorBucket.creationTime)
2508
+ * ```
2509
+ */
2510
+ getBucket(vectorBucketName: string): Promise<ApiResponse<{
2511
+ vectorBucket: VectorBucket;
2512
+ }>>;
2513
+ /**
2514
+ *
2515
+ * @alpha
2516
+ *
2517
+ * Lists all vector buckets with optional filtering and pagination
2518
+ *
2519
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2520
+ *
2521
+ * @category Storage
2522
+ * @subcategory Vector Buckets
2523
+ * @param options - Optional filters (prefix, maxResults, nextToken)
2524
+ * @returns Promise with list of buckets or error
2525
+ *
2526
+ * @example List vector buckets
2527
+ * ```typescript
2528
+ * const { data, error } = await supabase
2529
+ * .storage
2530
+ * .vectors
2531
+ * .listBuckets({ prefix: 'embeddings-' })
2532
+ *
2533
+ * data?.vectorBuckets.forEach(bucket => {
2534
+ * console.log(bucket.vectorBucketName)
2535
+ * })
2536
+ * ```
2537
+ */
2538
+ listBuckets(options?: ListVectorBucketsOptions): Promise<ApiResponse<ListVectorBucketsResponse>>;
2539
+ /**
2540
+ *
2541
+ * @alpha
2542
+ *
2543
+ * Deletes a vector bucket (bucket must be empty)
2544
+ * All indexes must be deleted before deleting the bucket
2545
+ *
2546
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2547
+ *
2548
+ * @category Storage
2549
+ * @subcategory Vector Buckets
2550
+ * @param vectorBucketName - Name of the vector bucket to delete
2551
+ * @returns Promise with empty response on success or error
2552
+ *
2553
+ * @example Delete a vector bucket
2554
+ * ```typescript
2555
+ * const { data, error } = await supabase
2556
+ * .storage
2557
+ * .vectors
2558
+ * .deleteBucket('embeddings-old')
2559
+ * ```
2560
+ */
2561
+ deleteBucket(vectorBucketName: string): Promise<ApiResponse<undefined>>;
2562
+ }
2563
+ /**
2564
+ *
2565
+ * @alpha
2566
+ *
2567
+ * Scoped client for operations within a specific vector bucket
2568
+ * Provides index management and access to vector operations
2569
+ *
2570
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2571
+ */
2572
+ declare class VectorBucketScope extends VectorIndexApi {
2573
+ private vectorBucketName;
2574
+ /**
2575
+ * @alpha
2576
+ *
2577
+ * Creates a helper that automatically scopes all index operations to the provided bucket.
2578
+ *
2579
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2580
+ *
2581
+ * @category Storage
2582
+ * @subcategory Vector Buckets
2583
+ * @example Creating a vector bucket scope
2584
+ * ```typescript
2585
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2586
+ * ```
2587
+ */
2588
+ constructor(url: string, headers: {
2589
+ [key: string]: string;
2590
+ }, vectorBucketName: string, fetch?: Fetch);
2591
+ /**
2592
+ *
2593
+ * @alpha
2594
+ *
2595
+ * Creates a new vector index in this bucket
2596
+ * Convenience method that automatically includes the bucket name
2597
+ *
2598
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2599
+ *
2600
+ * @category Storage
2601
+ * @subcategory Vector Buckets
2602
+ * @param options - Index configuration (vectorBucketName is automatically set)
2603
+ * @returns Promise with empty response on success or error
2604
+ *
2605
+ * @example Creating a vector index
2606
+ * ```typescript
2607
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2608
+ * await bucket.createIndex({
2609
+ * indexName: 'documents-openai',
2610
+ * dataType: 'float32',
2611
+ * dimension: 1536,
2612
+ * distanceMetric: 'cosine',
2613
+ * metadataConfiguration: {
2614
+ * nonFilterableMetadataKeys: ['raw_text']
2615
+ * }
2616
+ * })
2617
+ * ```
2618
+ */
2619
+ createIndex(options: Omit<CreateIndexOptions, 'vectorBucketName'>): Promise<ApiResponse<undefined>>;
2620
+ /**
2621
+ *
2622
+ * @alpha
2623
+ *
2624
+ * Lists indexes in this bucket
2625
+ * Convenience method that automatically includes the bucket name
2626
+ *
2627
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2628
+ *
2629
+ * @category Storage
2630
+ * @subcategory Vector Buckets
2631
+ * @param options - Listing options (vectorBucketName is automatically set)
2632
+ * @returns Promise with response containing indexes array and pagination token or error
2633
+ *
2634
+ * @example List indexes
2635
+ * ```typescript
2636
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2637
+ * const { data } = await bucket.listIndexes({ prefix: 'documents-' })
2638
+ * ```
2639
+ */
2640
+ listIndexes(options?: Omit<ListIndexesOptions, 'vectorBucketName'>): Promise<ApiResponse<ListIndexesResponse>>;
2641
+ /**
2642
+ *
2643
+ * @alpha
2644
+ *
2645
+ * Retrieves metadata for a specific index in this bucket
2646
+ * Convenience method that automatically includes the bucket name
2647
+ *
2648
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2649
+ *
2650
+ * @category Storage
2651
+ * @subcategory Vector Buckets
2652
+ * @param indexName - Name of the index to retrieve
2653
+ * @returns Promise with index metadata or error
2654
+ *
2655
+ * @example Get index metadata
2656
+ * ```typescript
2657
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2658
+ * const { data } = await bucket.getIndex('documents-openai')
2659
+ * console.log('Dimension:', data?.index.dimension)
2660
+ * ```
2661
+ */
2662
+ getIndex(indexName: string): Promise<ApiResponse<{
2663
+ index: VectorIndex;
2664
+ }>>;
2665
+ /**
2666
+ *
2667
+ * @alpha
2668
+ *
2669
+ * Deletes an index from this bucket
2670
+ * Convenience method that automatically includes the bucket name
2671
+ *
2672
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2673
+ *
2674
+ * @category Storage
2675
+ * @subcategory Vector Buckets
2676
+ * @param indexName - Name of the index to delete
2677
+ * @returns Promise with empty response on success or error
2678
+ *
2679
+ * @example Delete an index
2680
+ * ```typescript
2681
+ * const bucket = supabase.storage.vectors.from('embeddings-prod')
2682
+ * await bucket.deleteIndex('old-index')
2683
+ * ```
2684
+ */
2685
+ deleteIndex(indexName: string): Promise<ApiResponse<undefined>>;
2686
+ /**
2687
+ *
2688
+ * @alpha
2689
+ *
2690
+ * Access operations for a specific index within this bucket
2691
+ * Returns a scoped client for vector data operations
2692
+ *
2693
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2694
+ *
2695
+ * @category Storage
2696
+ * @subcategory Vector Buckets
2697
+ * @param indexName - Name of the index
2698
+ * @returns Index-scoped client with vector data operations
2699
+ *
2700
+ * @example Accessing an index
2701
+ * ```typescript
2702
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2703
+ *
2704
+ * // Insert vectors
2705
+ * await index.putVectors({
2706
+ * vectors: [
2707
+ * { key: 'doc-1', data: { float32: [...] }, metadata: { title: 'Intro' } }
2708
+ * ]
2709
+ * })
2710
+ *
2711
+ * // Query similar vectors
2712
+ * const { data } = await index.queryVectors({
2713
+ * queryVector: { float32: [...] },
2714
+ * topK: 5
2715
+ * })
2716
+ * ```
2717
+ */
2718
+ index(indexName: string): VectorIndexScope;
2719
+ }
2720
+ /**
2721
+ *
2722
+ * @alpha
2723
+ *
2724
+ * Scoped client for operations within a specific vector index
2725
+ * Provides vector data operations (put, get, list, query, delete)
2726
+ *
2727
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2728
+ */
2729
+ declare class VectorIndexScope extends VectorDataApi {
2730
+ private vectorBucketName;
2731
+ private indexName;
2732
+ /**
2733
+ *
2734
+ * @alpha
2735
+ *
2736
+ * Creates a helper that automatically scopes all vector operations to the provided bucket/index names.
2737
+ *
2738
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2739
+ *
2740
+ * @category Storage
2741
+ * @subcategory Vector Buckets
2742
+ * @example Creating a vector index scope
2743
+ * ```typescript
2744
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2745
+ * ```
2746
+ */
2747
+ constructor(url: string, headers: {
2748
+ [key: string]: string;
2749
+ }, vectorBucketName: string, indexName: string, fetch?: Fetch);
2750
+ /**
2751
+ *
2752
+ * @alpha
2753
+ *
2754
+ * Inserts or updates vectors in this index
2755
+ * Convenience method that automatically includes bucket and index names
2756
+ *
2757
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2758
+ *
2759
+ * @category Storage
2760
+ * @subcategory Vector Buckets
2761
+ * @param options - Vector insertion options (bucket and index names automatically set)
2762
+ * @returns Promise with empty response on success or error
2763
+ *
2764
+ * @example Insert vectors into an index
2765
+ * ```typescript
2766
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2767
+ * await index.putVectors({
2768
+ * vectors: [
2769
+ * {
2770
+ * key: 'doc-1',
2771
+ * data: { float32: [0.1, 0.2, ...] },
2772
+ * metadata: { title: 'Introduction', page: 1 }
2773
+ * }
2774
+ * ]
2775
+ * })
2776
+ * ```
2777
+ */
2778
+ putVectors(options: Omit<PutVectorsOptions, 'vectorBucketName' | 'indexName'>): Promise<ApiResponse<undefined>>;
2779
+ /**
2780
+ *
2781
+ * @alpha
2782
+ *
2783
+ * Retrieves vectors by keys from this index
2784
+ * Convenience method that automatically includes bucket and index names
2785
+ *
2786
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2787
+ *
2788
+ * @category Storage
2789
+ * @subcategory Vector Buckets
2790
+ * @param options - Vector retrieval options (bucket and index names automatically set)
2791
+ * @returns Promise with response containing vectors array or error
2792
+ *
2793
+ * @example Get vectors by keys
2794
+ * ```typescript
2795
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2796
+ * const { data } = await index.getVectors({
2797
+ * keys: ['doc-1', 'doc-2'],
2798
+ * returnMetadata: true
2799
+ * })
2800
+ * ```
2801
+ */
2802
+ getVectors(options: Omit<GetVectorsOptions, 'vectorBucketName' | 'indexName'>): Promise<ApiResponse<GetVectorsResponse>>;
2803
+ /**
2804
+ *
2805
+ * @alpha
2806
+ *
2807
+ * Lists vectors in this index with pagination
2808
+ * Convenience method that automatically includes bucket and index names
2809
+ *
2810
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2811
+ *
2812
+ * @category Storage
2813
+ * @subcategory Vector Buckets
2814
+ * @param options - Listing options (bucket and index names automatically set)
2815
+ * @returns Promise with response containing vectors array and pagination token or error
2816
+ *
2817
+ * @example List vectors with pagination
2818
+ * ```typescript
2819
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2820
+ * const { data } = await index.listVectors({
2821
+ * maxResults: 500,
2822
+ * returnMetadata: true
2823
+ * })
2824
+ * ```
2825
+ */
2826
+ listVectors(options?: Omit<ListVectorsOptions, 'vectorBucketName' | 'indexName'>): Promise<ApiResponse<ListVectorsResponse>>;
2827
+ /**
2828
+ *
2829
+ * @alpha
2830
+ *
2831
+ * Queries for similar vectors in this index
2832
+ * Convenience method that automatically includes bucket and index names
2833
+ *
2834
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2835
+ *
2836
+ * @category Storage
2837
+ * @subcategory Vector Buckets
2838
+ * @param options - Query options (bucket and index names automatically set)
2839
+ * @returns Promise with response containing matches array of similar vectors ordered by distance or error
2840
+ *
2841
+ * @example Query similar vectors
2842
+ * ```typescript
2843
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2844
+ * const { data } = await index.queryVectors({
2845
+ * queryVector: { float32: [0.1, 0.2, ...] },
2846
+ * topK: 5,
2847
+ * filter: { category: 'technical' },
2848
+ * returnDistance: true,
2849
+ * returnMetadata: true
2850
+ * })
2851
+ * ```
2852
+ */
2853
+ queryVectors(options: Omit<QueryVectorsOptions, 'vectorBucketName' | 'indexName'>): Promise<ApiResponse<QueryVectorsResponse>>;
2854
+ /**
2855
+ *
2856
+ * @alpha
2857
+ *
2858
+ * Deletes vectors by keys from this index
2859
+ * Convenience method that automatically includes bucket and index names
2860
+ *
2861
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2862
+ *
2863
+ * @category Storage
2864
+ * @subcategory Vector Buckets
2865
+ * @param options - Deletion options (bucket and index names automatically set)
2866
+ * @returns Promise with empty response on success or error
2867
+ *
2868
+ * @example Delete vectors by keys
2869
+ * ```typescript
2870
+ * const index = supabase.storage.vectors.from('embeddings-prod').index('documents-openai')
2871
+ * await index.deleteVectors({
2872
+ * keys: ['doc-1', 'doc-2', 'doc-3']
2873
+ * })
2874
+ * ```
2875
+ */
2876
+ deleteVectors(options: Omit<DeleteVectorsOptions, 'vectorBucketName' | 'indexName'>): Promise<ApiResponse<undefined>>;
2877
+ }
2878
+ //#endregion
2879
+ //#region src/StorageClient.d.ts
2880
+ interface StorageClientOptions {
2881
+ useNewHostname?: boolean;
2882
+ }
2883
+ declare class StorageClient extends StorageBucketApi {
2884
+ /**
2885
+ * Creates a client for Storage buckets, files, analytics, and vectors.
2886
+ *
2887
+ * @category Storage
2888
+ * @subcategory File Buckets
2889
+ *
2890
+ * @example Using supabase-js (recommended)
2891
+ * ```ts
2892
+ * import { createClient } from '@supabase/supabase-js'
2893
+ *
2894
+ * const supabase = createClient('https://xyzcompany.supabase.co', 'your-publishable-key')
2895
+ * const avatars = supabase.storage.from('avatars')
2896
+ * ```
2897
+ *
2898
+ * @example Standalone import for bundle-sensitive environments
2899
+ * ```ts
2900
+ * import { StorageClient } from '@supabase/storage-js'
2901
+ *
2902
+ * const storage = new StorageClient('https://xyzcompany.supabase.co/storage/v1', {
2903
+ * apikey: 'your-publishable-key',
2904
+ * })
2905
+ * const avatars = storage.from('avatars')
2906
+ * ```
2907
+ */
2908
+ constructor(url: string, headers?: {
2909
+ [key: string]: string;
2910
+ }, fetch?: Fetch, opts?: StorageClientOptions);
2911
+ /**
2912
+ * Perform file operation in a bucket.
2913
+ *
2914
+ * @category Storage
2915
+ * @subcategory File Buckets
2916
+ *
2917
+ * @param id The bucket id to operate on.
2918
+ *
2919
+ * @example Accessing a bucket
2920
+ * ```typescript
2921
+ * const avatars = supabase.storage.from('avatars')
2922
+ * ```
2923
+ */
2924
+ from(id: string): StorageFileApi;
2925
+ /**
2926
+ *
2927
+ * @alpha
2928
+ *
2929
+ * Access vector storage operations.
2930
+ *
2931
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2932
+ *
2933
+ * @category Storage
2934
+ * @subcategory Vector Buckets
2935
+ *
2936
+ * @returns A StorageVectorsClient instance configured with the current storage settings.
2937
+ */
2938
+ get vectors(): StorageVectorsClient;
2939
+ /**
2940
+ *
2941
+ * @alpha
2942
+ *
2943
+ * Access analytics storage operations using Iceberg tables.
2944
+ *
2945
+ * **Public alpha:** This API is part of a public alpha release and may not be available to your account type.
2946
+ *
2947
+ * @category Storage
2948
+ * @subcategory Analytics Buckets
2949
+ *
2950
+ * @returns A StorageAnalyticsClient instance configured with the current storage settings.
2951
+ */
2952
+ get analytics(): StorageAnalyticsClient;
2953
+ }
2954
+ //#endregion
2955
+ export { AnalyticBucket, ApiResponse, Bucket, BucketType, Camelize, type CreateIndexOptions, DeleteVectorsOptions, DestinationOptions, DistanceMetric, DownloadResult, EncryptionConfiguration, ErrorNamespace, ErrorResponse, FetchParameters, FileMetadata, FileObject, FileObjectV2, FileOptions, GetVectorsOptions, GetVectorsResponse, ListBucketOptions, ListIndexesOptions, ListIndexesResponse, ListVectorBucketsOptions, ListVectorBucketsResponse, ListVectorsOptions, ListVectorsResponse, Metadata, MetadataConfiguration, PutVectorsOptions, QueryVectorsOptions, QueryVectorsResponse, SearchOptions, SearchV2Folder, SearchV2Object, SearchV2Options, SearchV2Result, SortBy, SortByV2, StorageAnalyticsClient, StorageApiError, StorageClient, type StorageClientOptions, StorageError, StorageUnknownError, StorageVectorsApiError, StorageVectorsClient, type StorageVectorsClientOptions, StorageVectorsError, StorageVectorsErrorCode, StorageVectorsUnknownError, SuccessResponse, TransformOptions, VectorBucket, VectorBucketApi, VectorBucketScope, VectorData, VectorDataApi, VectorDataType, VectorFetchParameters, VectorFilter, VectorIndex, VectorIndexApi, VectorIndexScope, VectorMatch, VectorMetadata, VectorObject, isStorageError, isStorageVectorsError };
2956
+ //# sourceMappingURL=index.d.cts.map