better-supabase 0.21.0 → 0.22.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (216) hide show
  1. package/dist/{adapter-DZJZTY6g.js → adapter-D4aNBxhm.js} +2 -2
  2. package/dist/api-3C0AWFeP.js +696 -0
  3. package/dist/{api-Cj4W_pqT.d.ts → api-CHObZL7m.d.ts} +1 -1
  4. package/dist/{app-tables-C5HjXs2k.d.ts → app-tables-BGzdnQm5.d.ts} +1 -1
  5. package/dist/astro/index.js +5 -5
  6. package/dist/blocks/access-requests/index.js +1 -1
  7. package/dist/blocks/activities/index.js +1 -1
  8. package/dist/blocks/agents/index.js +1 -1
  9. package/dist/blocks/ai-chat/index.js +1 -1
  10. package/dist/blocks/ai-keys/index.js +1 -1
  11. package/dist/blocks/announcements/index.js +1 -1
  12. package/dist/blocks/api-keys/index.js +1 -1
  13. package/dist/blocks/approvals/index.js +1 -1
  14. package/dist/blocks/assets/index.js +1 -1
  15. package/dist/blocks/assignment/index.js +1 -1
  16. package/dist/blocks/attachments/index.js +1 -1
  17. package/dist/blocks/audit/index.d.ts +1 -1
  18. package/dist/blocks/audit/index.js +1 -1
  19. package/dist/blocks/automations/index.js +1 -1
  20. package/dist/blocks/billable-time/index.js +1 -1
  21. package/dist/blocks/billing/index.js +2 -2
  22. package/dist/blocks/bookings/index.js +1 -1
  23. package/dist/blocks/bulk/index.js +1 -1
  24. package/dist/blocks/calendar/index.js +1 -1
  25. package/dist/blocks/catalog/index.js +1 -1
  26. package/dist/blocks/channels/index.js +1 -1
  27. package/dist/blocks/collections/index.js +1 -1
  28. package/dist/blocks/compliance/index.js +1 -1
  29. package/dist/blocks/connectors/index.js +1 -1
  30. package/dist/blocks/contacts/index.js +1 -1
  31. package/dist/blocks/content/index.js +1 -1
  32. package/dist/blocks/contracts/index.js +1 -1
  33. package/dist/blocks/courses/index.js +1 -1
  34. package/dist/blocks/custom-fields/index.js +1 -1
  35. package/dist/blocks/data-lifecycle/index.js +1 -1
  36. package/dist/blocks/deals/index.js +1 -1
  37. package/dist/blocks/dispatch/index.js +1 -1
  38. package/dist/blocks/documents/index.js +1 -1
  39. package/dist/blocks/domains/index.js +1 -1
  40. package/dist/blocks/donations/index.js +1 -1
  41. package/dist/blocks/drive/index.js +1 -1
  42. package/dist/blocks/employees/index.js +1 -1
  43. package/dist/blocks/enrichment/index.js +1 -1
  44. package/dist/blocks/enrollments/index.js +1 -1
  45. package/dist/blocks/expenses/index.js +1 -1
  46. package/dist/blocks/flags/index.js +1 -1
  47. package/dist/blocks/forecasts/index.js +1 -1
  48. package/dist/blocks/forms/index.js +1 -1
  49. package/dist/blocks/guests/index.js +1 -1
  50. package/dist/blocks/hiring/index.js +1 -1
  51. package/dist/blocks/imports/index.js +1 -1
  52. package/dist/blocks/inbox/index.js +1 -1
  53. package/dist/blocks/incidents/index.js +1 -1
  54. package/dist/blocks/index.js +2 -2
  55. package/dist/blocks/inventory/index.js +1 -1
  56. package/dist/blocks/invoices/index.js +1 -1
  57. package/dist/blocks/leases/index.js +1 -1
  58. package/dist/blocks/leave/index.js +1 -1
  59. package/dist/blocks/ledger/index.js +1 -1
  60. package/dist/blocks/mail-sync/index.js +1 -1
  61. package/dist/blocks/messaging/index.js +1 -1
  62. package/dist/blocks/metrics/index.js +1 -1
  63. package/dist/blocks/moderation/index.js +1 -1
  64. package/dist/blocks/notifications/index.js +3 -3
  65. package/dist/blocks/numbering/index.js +1 -1
  66. package/dist/blocks/oauth-server/index.js +1 -1
  67. package/dist/blocks/orders/index.js +1 -1
  68. package/dist/blocks/organizations/index.js +1 -1
  69. package/dist/blocks/outbox/index.js +1 -1
  70. package/dist/blocks/passes/index.js +1 -1
  71. package/dist/blocks/pipelines/index.js +1 -1
  72. package/dist/blocks/posts/index.js +1 -1
  73. package/dist/blocks/promotions/index.js +1 -1
  74. package/dist/blocks/push/index.js +1 -1
  75. package/dist/blocks/quotes/index.js +1 -1
  76. package/dist/blocks/reactions/index.js +1 -1
  77. package/dist/blocks/relations/index.js +1 -1
  78. package/dist/blocks/reminders/index.js +1 -1
  79. package/dist/blocks/reviews/index.js +1 -1
  80. package/dist/blocks/saved-views/index.js +1 -1
  81. package/dist/blocks/scores/index.js +1 -1
  82. package/dist/blocks/search/index.js +1 -1
  83. package/dist/blocks/security-events/index.js +1 -1
  84. package/dist/blocks/segments/index.js +1 -1
  85. package/dist/blocks/sequences/index.js +1 -1
  86. package/dist/blocks/service-accounts/index.js +1 -1
  87. package/dist/blocks/settings/index.js +1 -1
  88. package/dist/blocks/share-links/index.js +1 -1
  89. package/dist/blocks/shipments/index.js +1 -1
  90. package/dist/blocks/signatures/index.js +1 -1
  91. package/dist/blocks/signing-keys/index.js +1 -1
  92. package/dist/blocks/sla/index.js +1 -1
  93. package/dist/blocks/sso/index.js +1 -1
  94. package/dist/blocks/state-machine/index.js +1 -1
  95. package/dist/blocks/tags/index.js +1 -1
  96. package/dist/blocks/tasks/index.js +2 -2
  97. package/dist/blocks/teams/index.js +1 -1
  98. package/dist/blocks/templates/index.js +1 -1
  99. package/dist/blocks/time-tracking/index.js +1 -1
  100. package/dist/blocks/timeline/index.js +1 -1
  101. package/dist/blocks/trash/index.js +1 -1
  102. package/dist/blocks/vercel-marketplace/index.js +1 -1
  103. package/dist/blocks/versions/index.js +1 -1
  104. package/dist/blocks/waitlist/index.js +1 -1
  105. package/dist/blocks/webhooks/index.js +4 -4
  106. package/dist/blocks/workflow-editor/index.js +1 -1
  107. package/dist/blocks/workflows/index.js +1 -1
  108. package/dist/cli/{add-C0w-mVTQ.js → add-B6CQOt3A.js} +2 -2
  109. package/dist/cli/{add-BTDPjVGC.js → add-BXFzr0Wf.js} +9 -9
  110. package/dist/cli/add-w_HumDPX.js +1 -0
  111. package/dist/cli/{backfill-BDdBs6Ne.js → backfill-Dflp6JZk.js} +1 -1
  112. package/dist/cli/bin.js +1 -1
  113. package/dist/cli/{blocks-Bs-lA-U_.js → blocks-CBH3N7Fy.js} +1 -1
  114. package/dist/cli/{blocks-CQLME-HQ.js → blocks-FtOIcUbu.js} +1 -1
  115. package/dist/cli/{cache-DDKao2Va.js → cache-61VwYKEv.js} +1 -1
  116. package/dist/cli/{codemod-Bjl998Do.js → codemod-CqPRa25J.js} +1 -1
  117. package/dist/cli/{content-mapper-DgSTl-DL.js → content-mapper-DGQQY5IA.js} +2 -2
  118. package/dist/cli/{doctor-CMLWbt44.js → doctor-BxxSO193.js} +19 -17
  119. package/dist/cli/{gen-D3VX8WdV.js → gen-D2cqqqTH.js} +11 -11
  120. package/dist/cli/index.d.ts +1 -1
  121. package/dist/cli/index.js +6 -6
  122. package/dist/cli/{init-D6D6eWze.js → init-BnG1IE1y.js} +5 -5
  123. package/dist/cli/{live-C_xgTOfD.js → live-D26OWOAb.js} +2 -2
  124. package/dist/cli/{mcp-B0Irjbes.js → mcp-1l3C_GdB.js} +2 -2
  125. package/dist/cli/{metadata-cLXra-XB.js → metadata-DDfPBHwI.js} +3 -3
  126. package/dist/cli/{migration-safety-OUK-Afbb.js → migration-safety-CQbrfZIx.js} +1 -1
  127. package/dist/cli/{migrations-CHenMvl_.js → migrations-Ch5Uuvyj.js} +1 -1
  128. package/dist/cli/{module-migration-6V7vXWUK.js → module-migration-Dul1uTYX.js} +2 -2
  129. package/dist/cli/{powersync-D83yAFbl.js → powersync-CfT-tRx1.js} +2 -2
  130. package/dist/cli/powersync-Vmhw5c1N.js +1 -0
  131. package/dist/cli/{print-C0OmQyTu.js → print-CbPT4PTL.js} +2 -2
  132. package/dist/cli/{remove-BWlOngNT.js → remove-kDH1yxKZ.js} +5 -5
  133. package/dist/cli/{render-9m70qveo.js → render-0Vd7BaNA.js} +3 -3
  134. package/dist/cli/{run-gE4eAazR.js → run-Dafms0D2.js} +8 -8
  135. package/dist/cli/{run-He3M-ZRq.js → run-DxTd55Ug.js} +21 -21
  136. package/dist/cli/{shared-Cx2WFVWq.js → shared-BQAMXvwd.js} +1 -1
  137. package/dist/cli/{snapshot-CZb3uVKE.js → snapshot-B8K6gYjA.js} +2 -2
  138. package/dist/cli/{source-CrYSCdPZ.js → source-CXDyCWz5.js} +1 -1
  139. package/dist/cli/{spec-Cn5RhuQc.js → spec-BGsnTkIl.js} +2 -2
  140. package/dist/cli/{spec-D4b9ePuQ.js → spec-CaN7nOqI.js} +1 -1
  141. package/dist/cli/{sql-layout-CLJ67h3L.js → sql-layout-BGAlcp1U.js} +2 -2
  142. package/dist/cli/{sync-B8VGiaHk.js → sync-CT_5VG0E.js} +3 -3
  143. package/dist/cli/{upgrade-DMiYx1C8.js → upgrade-DA7aO88E.js} +2 -2
  144. package/dist/cli/{upgrade-BvBWK3Fo.js → upgrade-frUtPDDb.js} +4 -4
  145. package/dist/cli/{version-BVg2Z6yv.js → version-CUdPyV6J.js} +1 -1
  146. package/dist/{composite-Dw5ofSF_.js → composite-CBRbvn5j.js} +2 -2
  147. package/dist/config/index.d.ts +1 -1
  148. package/dist/config/index.js +4 -4
  149. package/dist/{config-CD2OGfCG.js → config-C9AOcQ9S.js} +1 -1
  150. package/dist/{config-BOt5T6Vs.js → config-CH-D2B-4.js} +3 -3
  151. package/dist/{context-sgrUjA3U.d.ts → context-DEisra3V.d.ts} +15 -3
  152. package/dist/create/index.d.ts +72 -451
  153. package/dist/create/index.js +15 -1687
  154. package/dist/create/lite/index.d.ts +250 -13
  155. package/dist/create/lite/index.js +1007 -24
  156. package/dist/credentials/index.js +1 -1
  157. package/dist/edge/index.js +7 -7
  158. package/dist/elysia/index.js +1 -1
  159. package/dist/events/index.js +1 -1
  160. package/dist/expo/index.js +3 -3
  161. package/dist/{framework-DXM1vNcV.js → framework-DYEUraqt.js} +1 -1
  162. package/dist/h3/index.js +1 -1
  163. package/dist/h3/v1/index.js +1 -1
  164. package/dist/hono/index.js +6 -6
  165. package/dist/{index-5JSxY1MG.d.ts → index-3p_oWttZ.d.ts} +77 -2
  166. package/dist/{index-Bt7_mxn0.d.ts → index-CM2aGNRo.d.ts} +1 -1
  167. package/dist/{app-tables-DyswUg6J.js → instances-CK0jR3Pc.js} +147 -3
  168. package/dist/{kit-DhlB-vv_.js → kit-Bcd9wYCV.js} +1 -1
  169. package/dist/mapper/bin.js +5 -5
  170. package/dist/mcp/index.js +6 -6
  171. package/dist/mcp/sdk/index.js +2 -2
  172. package/dist/nestjs/index.js +1 -1
  173. package/dist/next/index.js +7 -7
  174. package/dist/node/index.js +1 -1
  175. package/dist/orpc/index.d.ts +1 -1
  176. package/dist/orpc/index.js +5 -5
  177. package/dist/otel/index.js +4 -4
  178. package/dist/preset/index.d.ts +4 -4
  179. package/dist/preset/index.js +4 -4
  180. package/dist/{preset-B3CukUhu.js → preset-CS490mYJ.js} +179 -7
  181. package/dist/project-NmP1NdLi.js +1760 -0
  182. package/dist/react/index.js +2 -2
  183. package/dist/react/server.js +2 -2
  184. package/dist/{react-_D_CeZMk.js → react-CcrQQl0_.js} +2 -2
  185. package/dist/react-router/index.js +5 -5
  186. package/dist/realtime/index.js +1 -1
  187. package/dist/{refusal-D48CMqpQ.js → refusal-DDlInPff.js} +2 -2
  188. package/dist/{instances-DDt7NdVl.js → resolved-names-DdlJzoMK.js} +2 -146
  189. package/dist/{resource-R3KToNze.js → resource-BUJcZKiW.js} +2 -2
  190. package/dist/{resources-DqIwoQsP.js → resources-jb3R6rEa.js} +1 -1
  191. package/dist/server/index.js +7 -7
  192. package/dist/{sign-in-1FJiXXyG.js → sign-in-NO7LWlw4.js} +2 -2
  193. package/dist/solid/index.js +1 -1
  194. package/dist/solid-start/index.js +5 -5
  195. package/dist/spec/index.d.ts +2 -2
  196. package/dist/spec/index.js +2 -693
  197. package/dist/sql/index.d.ts +3 -3
  198. package/dist/sql/index.js +2 -2
  199. package/dist/{sql-BjjgwJKg.js → sql-BMXEHTvr.js} +17 -3
  200. package/dist/svelte/index.js +1 -1
  201. package/dist/sveltekit/index.js +5 -5
  202. package/dist/tanstack-start/index.js +5 -5
  203. package/dist/testing/index.d.ts +2 -2
  204. package/dist/testing/index.js +4 -4
  205. package/dist/types-BC1HLEVx.d.ts +461 -0
  206. package/dist/vue/index.js +1 -1
  207. package/dist/yjs/index.js +1 -1
  208. package/package.json +1 -1
  209. package/dist/cli/add-CspY9jKT.js +0 -1
  210. package/dist/cli/powersync-DwhCH0gs.js +0 -1
  211. package/dist/types-DGHfTW8_.d.ts +0 -9
  212. package/dist/{build-CM8PJqwW.js → build-CH2N3Yf0.js} +3 -3
  213. package/dist/{create-blocks-CUS28FfS.js → create-blocks-BfrDUSM6.js} +1 -1
  214. package/dist/{data-hooks-tgF1Ct0F.js → data-hooks-CdcZfVS1.js} +1 -1
  215. package/dist/{respond-3RKp6VgU.js → respond-CZMWbUs3.js} +1 -1
  216. package/dist/{topic-J9I3yu6f.js → topic-DClSoqY7.js} +1 -1
@@ -1,10 +1,10 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as slaSqlOptions } from "../../options-Dz9Yo52Z.js";
3
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
3
4
  import { A as recordsOf, C as optionalInstant, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
4
5
  import { i as wrapTransport, n as extendBlock, r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
5
6
  import { n as entitySchema } from "../../entity-schema-B1YmMtP8.js";
6
7
  import { t as defineRecordBinding } from "../../record-bindings-Z51mGfhB.js";
7
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
8
8
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
9
9
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
10
10
  import { i as subjectRefOf } from "../../block-subjects-DFSuFY1a.js";
@@ -1,8 +1,8 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { a as ok } from "../../result-ntFBW2p2.js";
3
3
  import { t as ssoSqlOptions } from "../../options-3OYOU56e.js";
4
- import { A as recordsOf, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, n as applyTemporal, o as blockCall, w as optionalText, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
5
4
  import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
5
+ import { A as recordsOf, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, n as applyTemporal, o as blockCall, w as optionalText, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
6
6
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
7
7
  import { n as createSsoAdmin, r as dohResolver, t as createSso } from "../../sso-DdDpJQzw.js";
8
8
  //#region src/blocks/sso/scim-filter.ts
@@ -1,7 +1,7 @@
1
1
  import { t as stateMachineSqlOptions } from "../../options-aT89JqlB.js";
2
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
2
3
  import { A as recordsOf, C as optionalInstant, I as stringsOf, L as textOf, O as recordOf, T as pageOf, j as requiredInstant, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
3
4
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
4
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
5
5
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
6
6
  import { i as subjectRefOf } from "../../block-subjects-DFSuFY1a.js";
7
7
  //#region src/blocks/state-machine/state-machine.ts
@@ -2,12 +2,12 @@ import { n as dbError } from "../../errors-BVFgt8BZ.js";
2
2
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
3
3
  import { a as ok, r as err, s as toDbError, t as AsyncResult } from "../../result-ntFBW2p2.js";
4
4
  import { t as tagsSqlOptions } from "../../options-fMxhtuVR.js";
5
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
5
6
  import { n as whileSignedIn, t as defineController } from "../../controller-BEliOBOv.js";
6
7
  import { L as textOf, O as recordOf, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
7
8
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
8
9
  import { n as entitySchema } from "../../entity-schema-B1YmMtP8.js";
9
10
  import { t as defineRecordBinding } from "../../record-bindings-Z51mGfhB.js";
10
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
11
11
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
12
12
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
13
13
  import { t as requireOrganization } from "../../block-tenant-DHp7subc.js";
@@ -3,12 +3,12 @@ import { n as isRecord } from "../../guards-6F2bCtQR.js";
3
3
  import { t as temporal } from "../../temporal-required-DcLhnDhQ.js";
4
4
  import { a as ok, r as err, t as AsyncResult } from "../../result-ntFBW2p2.js";
5
5
  import { t as tasksSqlOptions } from "../../options-D2s7fT1s.js";
6
+ import { a as stripTypePrefix } from "../../cloud-event-XsM53POL.js";
7
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
6
8
  import { A as recordsOf, C as optionalInstant, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
7
9
  import { i as wrapTransport, n as extendBlock, r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
8
- import { a as stripTypePrefix } from "../../cloud-event-XsM53POL.js";
9
10
  import { n as entitySchema } from "../../entity-schema-B1YmMtP8.js";
10
11
  import { t as defineRecordBinding } from "../../record-bindings-Z51mGfhB.js";
11
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
12
12
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
13
13
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
14
14
  import { t as defineConversionAction } from "../../conversion-Dq1S7xzE.js";
@@ -1,8 +1,8 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as teamsSqlOptions } from "../../options-BfFC4iFE.js";
3
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
3
4
  import { A as recordsOf, L as textOf, O as recordOf, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
4
5
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
5
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
6
6
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
7
7
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
8
8
  //#region src/blocks/teams/teams.ts
@@ -4,9 +4,9 @@ import { n as isRecord } from "../../guards-6F2bCtQR.js";
4
4
  import { a as ok, r as err, t as AsyncResult } from "../../result-ntFBW2p2.js";
5
5
  import { n as validate } from "../../standard-BA3mLh6w.js";
6
6
  import { t as templatesSqlOptions } from "../../options-BKDxrPvE.js";
7
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
7
8
  import { A as recordsOf, C as optionalInstant, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, k as recordOrEmpty, n as applyTemporal, o as blockCall, r as asDbError, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
8
9
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
9
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
10
10
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
11
11
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
12
12
  //#region src/blocks/templates/templates.ts
@@ -4,9 +4,9 @@ import { t as temporal } from "../../temporal-required-DcLhnDhQ.js";
4
4
  import { t as AsyncResult } from "../../result-ntFBW2p2.js";
5
5
  import { t as timeTrackingSqlOptions } from "../../options-DhdazgTZ.js";
6
6
  import { r as defineMetric } from "../../metric-definition-BjxVn4R5.js";
7
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
7
8
  import { A as recordsOf, C as optionalInstant, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
8
9
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
9
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
10
10
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
11
11
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
12
12
  import { n as optionalRecordRefOf } from "../../block-subjects-DFSuFY1a.js";
@@ -1,7 +1,7 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
+ import { a as stripTypePrefix } from "../../cloud-event-XsM53POL.js";
2
3
  import { A as recordsOf, L as textOf, O as recordOf, T as pageOf, U as rpcTransport, V as dbTransport, W as sqlTransport, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
3
4
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
4
- import { a as stripTypePrefix } from "../../cloud-event-XsM53POL.js";
5
5
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
6
6
  import { n as optionalRecordRefOf } from "../../block-subjects-DFSuFY1a.js";
7
7
  import { n as defineListQuery } from "../../list-query-BnpA2BDg.js";
@@ -1,8 +1,8 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as trashSqlOptions } from "../../options-B692WoK6.js";
3
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
3
4
  import { A as recordsOf, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, j as requiredInstant, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
4
5
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
5
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
6
6
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
7
7
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
8
8
  import { t as trashExtension } from "../../extension-DzCc0IOd.js";
@@ -3,9 +3,9 @@ import { n as isRecord } from "../../guards-6F2bCtQR.js";
3
3
  import { a as ok, r as err, t as AsyncResult } from "../../result-ntFBW2p2.js";
4
4
  import { a as methodNotAllowed, o as problemResponse } from "../../problem-Bf0cJ7tk.js";
5
5
  import { t as vercelMarketplaceSqlOptions } from "../../options-DZRpXKQE.js";
6
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
6
7
  import { A as recordsOf, L as textOf, O as recordOf, W as sqlTransport, f as errorText, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
7
8
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
8
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
9
9
  import { r as timingSafeEqual } from "../../hmac-B3CTTlfv.js";
10
10
  import { t as cronRoute } from "../../cron-route-FjKgRvTY.js";
11
11
  import { c as verifyCompact, t as JwsError } from "../../jws-DOgHJKHb.js";
@@ -1,10 +1,10 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as versionsSqlOptions } from "../../options-DZLkeqWn.js";
3
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
3
4
  import { A as recordsOf, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
4
5
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
5
6
  import { n as entitySchema } from "../../entity-schema-B1YmMtP8.js";
6
7
  import { i as recordRowInput, t as defineRecordBinding } from "../../record-bindings-Z51mGfhB.js";
7
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
8
8
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
9
9
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
10
10
  import { i as subjectRefOf } from "../../block-subjects-DFSuFY1a.js";
@@ -1,8 +1,8 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as waitlistSqlOptions } from "../../options-DKoQoRCy.js";
3
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
3
4
  import { A as recordsOf, C as optionalInstant, L as textOf, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
4
5
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
5
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
6
6
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
7
7
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
8
8
  import { r as hookError, t as authHook } from "../../verify-7EucfCnv.js";
@@ -7,12 +7,13 @@ import { i as toBase64, r as fromBase64 } from "../../base64-B9Wlsdj7.js";
7
7
  import { a as methodNotAllowed, o as problemResponse } from "../../problem-Bf0cJ7tk.js";
8
8
  import { t as MAX_BATCH } from "../../batch-limit-DKVQDz4o.js";
9
9
  import { n as webhooksOutSqlOptions, t as webhooksInSqlOptions } from "../../options-D96dScev.js";
10
- import { A as recordsOf, D as readBodyCapped, N as seconds, O as recordOf, R as toBlockError, U as rpcTransport, V as dbTransport, W as sqlTransport, c as chunksOf, f as errorText, h as instantOf, i as batchResultsOf, n as applyTemporal, o as blockCall, r as asDbError, s as budget, w as optionalText, y as nullableInstant, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
11
- import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
12
10
  import { a as stripTypePrefix } from "../../cloud-event-XsM53POL.js";
13
- import { n as credentialRefInTenant, r as foreignCredentialRef } from "../../provider-B6g7rBZX.js";
14
11
  import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
15
12
  import { r as blockEmitter } from "../../block-events-IWAyafO3.js";
13
+ import { toHttp } from "../../events/index.js";
14
+ import { A as recordsOf, D as readBodyCapped, N as seconds, O as recordOf, R as toBlockError, U as rpcTransport, V as dbTransport, W as sqlTransport, c as chunksOf, f as errorText, h as instantOf, i as batchResultsOf, n as applyTemporal, o as blockCall, r as asDbError, s as budget, w as optionalText, y as nullableInstant, z as toInstant } from "../../block-helpers-B0f0ZVb5.js";
15
+ import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
16
+ import { n as credentialRefInTenant, r as foreignCredentialRef } from "../../provider-B6g7rBZX.js";
16
17
  import { n as hmacHex, r as timingSafeEqual } from "../../hmac-B3CTTlfv.js";
17
18
  import { i as signWebhook, o as verifySharedSecret, s as verifyWebhook, t as PUBLIC_KEY_PREFIX } from "../../signatures-CX1b4WHa.js";
18
19
  import { t as cronRoute } from "../../cron-route-FjKgRvTY.js";
@@ -20,7 +21,6 @@ import { t as subjectReaders } from "../../subject-readers-CeeJJOQ4.js";
20
21
  import { n as hitRateLimit, o as receiveWebhook } from "../../rate-limit-fZ_d8gSE.js";
21
22
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
22
23
  import { a as signStripeWebhook, i as isDatabaseWebhook, n as databaseChange, o as stripeInboxVerify, r as hookError, s as verifyStripeWebhook, t as authHook } from "../../verify-7EucfCnv.js";
23
- import { toHttp } from "../../events/index.js";
24
24
  //#region src/blocks/webhooks/destinations.ts
25
25
  /**
26
26
  * Stores deliveries in the webhook inbox under `source` (the delivery's source
@@ -2,12 +2,12 @@ import { n as dbError } from "../../errors-BVFgt8BZ.js";
2
2
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
3
3
  import { a as ok, r as err, t as AsyncResult } from "../../result-ntFBW2p2.js";
4
4
  import { t as workflowEditorSqlOptions } from "../../options-DFpyP1bg.js";
5
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
5
6
  import { n as whileSignedIn, t as defineController } from "../../controller-BEliOBOv.js";
6
7
  import { A as recordsOf, C as optionalInstant, E as randomToken, I as stringsOf, L as textOf, N as seconds, O as recordOf, U as rpcTransport, V as dbTransport, W as sqlTransport, d as enumOrThrow, j as requiredInstant, k as recordOrEmpty, n as applyTemporal, o as blockCall, p as injectableOf, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
7
8
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
8
9
  import { n as LEGACY_PERMISSION_CAP_CLAIM, r as PERMISSION_CAP_CLAIM } from "../../delegation-DGOIiT8k.js";
9
10
  import { n as credentialRefInTenant, r as foreignCredentialRef } from "../../provider-B6g7rBZX.js";
10
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
11
11
  import { n as blockFields } from "../../block-fields-BjXgX_5c.js";
12
12
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
13
13
  import { n as watchRun, t as firstError } from "../../run-watch-B-LoK5m1.js";
@@ -1,10 +1,10 @@
1
1
  import { n as isRecord } from "../../guards-6F2bCtQR.js";
2
2
  import { t as temporal } from "../../temporal-required-DcLhnDhQ.js";
3
3
  import { a as ok, r as err } from "../../result-ntFBW2p2.js";
4
+ import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
4
5
  import { n as whileSignedIn, t as defineController } from "../../controller-BEliOBOv.js";
5
6
  import { A as recordsOf, C as optionalInstant, L as textOf, N as seconds, O as recordOf, T as pageOf, U as rpcTransport, V as dbTransport, W as sqlTransport, f as errorText, j as requiredInstant, m as instantArg, n as applyTemporal, o as blockCall, w as optionalText } from "../../block-helpers-B0f0ZVb5.js";
6
7
  import { r as withBlockHooks } from "../../block-hooks-DKtz0HRh.js";
7
- import { n as event, t as defineEvents } from "../../event-map-CtPFhcOp.js";
8
8
  import { n as nextCronRun, t as assertCron } from "../../cron-DdT4ti8a.js";
9
9
  import { n as defineBlock } from "../../define-block-BGqOO8B3.js";
10
10
  import { n as watchRun } from "../../run-watch-B-LoK5m1.js";
@@ -1,8 +1,8 @@
1
1
  import { n as CliError } from "./errors-BTe6A15O.js";
2
- import { c as layoutFor, g as providerLabel, l as providerOwnsMemberships, o as MEMBERSHIP_CLAIM_MODULES } from "./migrations-CHenMvl_.js";
2
+ import { c as layoutFor, g as providerLabel, l as providerOwnsMemberships, o as MEMBERSHIP_CLAIM_MODULES } from "./migrations-Ch5Uuvyj.js";
3
3
  import { r as applyPlan } from "./files-CX71yBm8.js";
4
4
  import { n as addBlocksToJson, s as keyText, t as addBlocksToConfig } from "./config-edit-CrWfk8s3.js";
5
- import { a as write, i as unlistedModuleFiles, r as nextStep } from "./sync-B8VGiaHk.js";
5
+ import { a as write, i as unlistedModuleFiles, r as nextStep } from "./sync-CT_5VG0E.js";
6
6
  import { basename, dirname } from "node:path";
7
7
  import { readFile } from "node:fs/promises";
8
8
  import { SQL_MODULES, resolveBlocks } from "better-supabase/sql";
@@ -1,21 +1,21 @@
1
1
  import { a as list, p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
2
  import { i as plain } from "./style-Bm2X5JrN.js";
3
- import { t as VERSION } from "./version-BVg2Z6yv.js";
3
+ import { t as VERSION } from "./version-CUdPyV6J.js";
4
4
  import { a as parseNames, n as CliError } from "./errors-BTe6A15O.js";
5
5
  import { r as readIfExists, t as display } from "./io-DH1kcmmP.js";
6
- import { t as loadSnapshot } from "./snapshot-CZb3uVKE.js";
6
+ import { t as loadSnapshot } from "./snapshot-B8K6gYjA.js";
7
7
  import { t as isRecord } from "./guards-CUlDNYZs.js";
8
- import { a as toCatalog } from "./source-CrYSCdPZ.js";
9
- import { n as dataMigration } from "./migrations-CHenMvl_.js";
8
+ import { a as toCatalog } from "./source-CXDyCWz5.js";
9
+ import { n as dataMigration } from "./migrations-Ch5Uuvyj.js";
10
10
  import { a as findConfig, f as INTEGRATIONS, s as loadConfig } from "./config-BH0goim0.js";
11
11
  import { i as changeLines, n as PLAN_ARGS, r as applyPlan, u as planResult } from "./files-CX71yBm8.js";
12
- import { a as wiringFiles, d as libEntry, f as needsLib, i as wiringChecklist, l as importFrom, n as latestMigrationVersion, o as wiringFor, p as resolveIntegrations, s as TEMPLATES, u as isIntegration } from "./migration-safety-OUK-Afbb.js";
12
+ import { a as wiringFiles, d as libEntry, f as needsLib, i as wiringChecklist, l as importFrom, n as latestMigrationVersion, o as wiringFor, p as resolveIntegrations, s as TEMPLATES, u as isIntegration } from "./migration-safety-CQbrfZIx.js";
13
13
  import { n as installCommand, t as detectProject } from "./detect-D9JaAX20.js";
14
14
  import { d as setBlockInJson, f as setPathInConfig, h as setPresetInJson, m as setPresetInConfig, n as addBlocksToJson, p as setPathInJson, r as addBlocksToWiring, t as addBlocksToConfig, u as setBlockInConfig } from "./config-edit-CrWfk8s3.js";
15
- import { t as syncModules } from "./sync-B8VGiaHk.js";
16
- import { t as addModules } from "./add-C0w-mVTQ.js";
17
- import { n as ident } from "./live-C_xgTOfD.js";
18
- import { t as blockNames } from "./blocks-Bs-lA-U_.js";
15
+ import { t as syncModules } from "./sync-CT_5VG0E.js";
16
+ import { t as addModules } from "./add-B6CQOt3A.js";
17
+ import { n as ident } from "./live-D26OWOAb.js";
18
+ import { t as blockNames } from "./blocks-CBH3N7Fy.js";
19
19
  import { i as sourceArgs, n as SOURCE_ARGS } from "./source-args-z-jkabmO.js";
20
20
  import { existsSync } from "node:fs";
21
21
  import { dirname, join, posix, resolve } from "node:path";
@@ -0,0 +1 @@
1
+ export { t as addCommand } from "./add-BXFzr0Wf.js";
@@ -3,7 +3,7 @@ import { n as CliError, r as errorText } from "./errors-BTe6A15O.js";
3
3
  import { i as isLocalDatabaseUrl, r as databaseHost } from "./agent-CbuPvI2x.js";
4
4
  import { l as stdinDatabaseUrl, n as databaseUrl } from "./config-BH0goim0.js";
5
5
  import { t as connect } from "./db-CQCLx7cx.js";
6
- import { n as ident } from "./live-C_xgTOfD.js";
6
+ import { n as ident } from "./live-D26OWOAb.js";
7
7
  import { r as STACK_ARG, t as DB_URL_STDIN_ARG } from "./source-args-z-jkabmO.js";
8
8
  //#region src/cli/commands/backfill.ts
9
9
  const DEFAULT_BATCH = 1e3;
package/dist/cli/bin.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { i as run } from "./run-He3M-ZRq.js";
2
+ import { i as run } from "./run-DxTd55Ug.js";
3
3
  import { t as colorEnabled } from "./style-Bm2X5JrN.js";
4
4
  import { existsSync } from "node:fs";
5
5
  import { basename } from "node:path";
@@ -1,7 +1,7 @@
1
1
  import { p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
2
  import { n as CliError } from "./errors-BTe6A15O.js";
3
3
  import { t as SQL_ARGS } from "./args-UEwg0l-N.js";
4
- import { n as listModules, t as printModule } from "./print-C0OmQyTu.js";
4
+ import { n as listModules, t as printModule } from "./print-CbPT4PTL.js";
5
5
  import { t as decodePresetInput } from "./preset-BwmIfFnh.js";
6
6
  import { BLOCK_CATEGORIES } from "better-supabase/blocks";
7
7
  import { PRESET_CATALOG, PRESET_NAMES, glueCommand } from "better-supabase/preset";
@@ -1 +1 @@
1
- export { n as blocksListCommand, r as blocksSearchCommand, i as blocksViewCommand } from "./blocks-Bs-lA-U_.js";
1
+ export { n as blocksListCommand, r as blocksSearchCommand, i as blocksViewCommand } from "./blocks-CBH3N7Fy.js";
@@ -1,4 +1,4 @@
1
- import { t as VERSION } from "./version-BVg2Z6yv.js";
1
+ import { t as VERSION } from "./version-CUdPyV6J.js";
2
2
  import { dirname, resolve } from "node:path";
3
3
  import { createHash } from "node:crypto";
4
4
  import { mkdir, readFile, rename, rm, writeFile } from "node:fs/promises";
@@ -4,7 +4,7 @@ import { n as CliError } from "./errors-BTe6A15O.js";
4
4
  import { t as migrateCliCall } from "./moved-DVwgE8lV.js";
5
5
  import { t as isRecord$1 } from "./guards-CUlDNYZs.js";
6
6
  import { a as changedFiles, i as changeLines, r as applyPlan, u as planResult } from "./files-CX71yBm8.js";
7
- import { i as schemasDirOf, n as migrationsDir, o as writtenByBlocks } from "./sql-layout-CLJ67h3L.js";
7
+ import { i as schemasDirOf, n as migrationsDir, o as writtenByBlocks } from "./sql-layout-BGAlcp1U.js";
8
8
  import { a as configObject, c as mask, f as setPathInConfig, g as skipSpace, h as setPresetInJson, i as closingIndex, l as properties, m as setPresetInConfig, o as indentAt, p as setPathInJson, t as addBlocksToConfig, v as codeRanges } from "./config-edit-CrWfk8s3.js";
9
9
  import { i as legacyPrefixNames, n as LEGACY_PREFIXES, t as LEGACY_CLAIMS } from "./legacy-prefix-R7UChFFl.js";
10
10
  import { a as REVIEW_0_15, c as renameSubpaths, r as PLUGIN_IMPORT_RENAMES, s as SUBPATH_RENAMES_0_15, t as BLOCK_EXPORT_RENAMES } from "./codemod-block-renames-BuSaTE_G.js";
@@ -1,6 +1,6 @@
1
1
  import { r as readIfExists } from "./io-DH1kcmmP.js";
2
- import { t as CACHE_DIR } from "./cache-DDKao2Va.js";
3
- import { x as installedVersion } from "./snapshot-CZb3uVKE.js";
2
+ import { t as CACHE_DIR } from "./cache-61VwYKEv.js";
3
+ import { x as installedVersion } from "./snapshot-B8K6gYjA.js";
4
4
  import { t as i } from "./jsonc-D5Fu67jw.js";
5
5
  import { resolve } from "node:path";
6
6
  import { createHash } from "node:crypto";
@@ -1,36 +1,36 @@
1
1
  import { a as list, p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
2
  import { i as plain } from "./style-Bm2X5JrN.js";
3
- import { t as VERSION } from "./version-BVg2Z6yv.js";
3
+ import { t as VERSION } from "./version-CUdPyV6J.js";
4
4
  import { n as CliError, r as errorText } from "./errors-BTe6A15O.js";
5
5
  import { i as isLocalDatabaseUrl, r as databaseHost } from "./agent-CbuPvI2x.js";
6
6
  import { a as sameText, t as display } from "./io-DH1kcmmP.js";
7
- import { t as CACHE_DIR } from "./cache-DDKao2Va.js";
7
+ import { t as CACHE_DIR } from "./cache-61VwYKEv.js";
8
8
  import { t as byCodePoint } from "./compare-BmIWVEui.js";
9
- import { C as satisfies, S as peerVersions, c as isSqliteLiteDriver, n as managementTarget, o as snapshotFile, r as openSource, s as liteDriverOf, t as loadSnapshot, u as MetadataRejectedError } from "./snapshot-CZb3uVKE.js";
10
- import { d as configFor, r as renderFiles, u as notNullTag } from "./render-9m70qveo.js";
9
+ import { C as satisfies, S as peerVersions, c as isSqliteLiteDriver, n as managementTarget, o as snapshotFile, r as openSource, s as liteDriverOf, t as loadSnapshot, u as MetadataRejectedError } from "./snapshot-B8K6gYjA.js";
10
+ import { d as configFor, r as renderFiles, u as notNullTag } from "./render-0Vd7BaNA.js";
11
11
  import { t as isRecord } from "./guards-CUlDNYZs.js";
12
- import { i as request } from "./source-CrYSCdPZ.js";
13
- import { g as providerLabel, u as compiledReadSets } from "./migrations-CHenMvl_.js";
12
+ import { i as request } from "./source-CXDyCWz5.js";
13
+ import { g as providerLabel, u as compiledReadSets } from "./migrations-Ch5Uuvyj.js";
14
14
  import { l as stdinDatabaseUrl, n as databaseUrl } from "./config-BH0goim0.js";
15
15
  import { a as findRepoRoot, c as httpHooks, d as readSupabaseToml, f as schemaPaths, h as tomlGet, i as diffEngine, l as migrationCommand, n as declarativeSchemasDir, p as sqlWorkflow, u as pgFunctionHooks } from "./supabase-toml-CncmQbO0.js";
16
16
  import { t as PROCESS_ENV } from "./env-DMgjB_4y.js";
17
17
  import { n as readStackStatus } from "./stack-status-B_Ipd_-z.js";
18
18
  import { t as connect } from "./db-CQCLx7cx.js";
19
- import { a as hasContentMapper, c as supportsContentMappers, i as contentMapperSetup$1, n as TSCONFIG_SNIPPET, o as needsRunExternalCode, t as RUN_EXTERNAL_CODE } from "./content-mapper-DgSTl-DL.js";
19
+ import { a as hasContentMapper, c as supportsContentMappers, i as contentMapperSetup$1, n as TSCONFIG_SNIPPET, o as needsRunExternalCode, t as RUN_EXTERNAL_CODE } from "./content-mapper-DGQQY5IA.js";
20
20
  import { c as insideRoot, i as changeLines, r as applyPlan } from "./files-CX71yBm8.js";
21
- import { C as splinterTables, S as advisorRule, _ as withoutStrings, a as METADATA_GAPS_TEXT, b as appTablesOf, c as accessModule, d as RLS_RULES, f as appliesTo, g as policyHelpers, h as functionObject, l as entitlementsModule, m as functionBody, p as escape$2, s as AUTHORIZATION_RULES, u as COMMANDS$2, v as BLOCK_PREFIX, x as appViewsOf, y as blockTargets } from "./run-gE4eAazR.js";
22
- import { n as migrationsDir, r as moduleLayoutFor, t as blockDeclaredTables } from "./sql-layout-CLJ67h3L.js";
23
- import { a as permissionCatalogKeys, i as lineOf, l as tableObject, n as exposed, o as policyObject, r as exposedSchemas, s as qualified, t as catalogOf, u as workflowOf } from "./shared-Cx2WFVWq.js";
24
- import { i as migrationHolds, o as migrationModules, r as latestMigration, t as MODULES_SUFFIX } from "./module-migration-6V7vXWUK.js";
25
- import { o as wiringFor, r as configInstances, t as MIGRATION_SAFETY_RULES } from "./migration-safety-OUK-Afbb.js";
21
+ import { C as splinterTables, S as advisorRule, _ as withoutStrings, a as METADATA_GAPS_TEXT, b as appTablesOf, c as accessModule, d as RLS_RULES, f as appliesTo, g as policyHelpers, h as functionObject, l as entitlementsModule, m as functionBody, p as escape$2, s as AUTHORIZATION_RULES, u as COMMANDS$2, v as BLOCK_PREFIX, x as appViewsOf, y as blockTargets } from "./run-Dafms0D2.js";
22
+ import { n as migrationsDir, r as moduleLayoutFor, t as blockDeclaredTables } from "./sql-layout-BGAlcp1U.js";
23
+ import { a as permissionCatalogKeys, i as lineOf, l as tableObject, n as exposed, o as policyObject, r as exposedSchemas, s as qualified, t as catalogOf, u as workflowOf } from "./shared-BQAMXvwd.js";
24
+ import { i as migrationHolds, o as migrationModules, r as latestMigration, t as MODULES_SUFFIX } from "./module-migration-Dul1uTYX.js";
25
+ import { o as wiringFor, r as configInstances, t as MIGRATION_SAFETY_RULES } from "./migration-safety-CQbrfZIx.js";
26
26
  import { t as orphanedBlockFiles } from "./orphans-BAboqyVM.js";
27
- import { i as reservedRoles, n as ident$1, r as literal$1, t as LIVE_RULES } from "./live-C_xgTOfD.js";
27
+ import { i as reservedRoles, n as ident$1, r as literal$1, t as LIVE_RULES } from "./live-D26OWOAb.js";
28
28
  import { a as sourceFlags, n as SOURCE_ARGS } from "./source-args-z-jkabmO.js";
29
29
  import { i as PLUGIN_SUBPATH_RENAMES, n as BLOCK_SUBPATH_RENAMES, o as SPEC_SUBPATH_RENAMES, t as BLOCK_EXPORT_RENAMES } from "./codemod-block-renames-BuSaTE_G.js";
30
30
  import { n as PLATFORM_SCHEMAS } from "./in-stack-diff-DQTW53Vf.js";
31
31
  import { i as staleVariables, r as stackEnvValues, t as PREFIX_NAMES } from "./stack-env-6hS-WEmh.js";
32
32
  import { a as readSharedMemory, n as listStacks, t as branchName } from "./stacks-BYlQ96WS.js";
33
- import { i as refuseWithMetadata, r as readMetadataSnapshot } from "./metadata-cLXra-XB.js";
33
+ import { i as refuseWithMetadata, r as readMetadataSnapshot } from "./metadata-DDfPBHwI.js";
34
34
  import { existsSync } from "node:fs";
35
35
  import { dirname, resolve } from "node:path";
36
36
  import { createHash } from "node:crypto";
@@ -1409,8 +1409,9 @@ function attachmentSubjects(context) {
1409
1409
  * Whether `expression` only checks that the caller is a member of the row's
1410
1410
  * tenant: `current_tenant_id()`, a `*_ids_with` or `*member_*ids` function in
1411
1411
  * any schema (the provider's own helpers included), `can('tenant', ...)` or
1412
- * `member_can`, joined by `and`, with a soft-delete `is null` allowed. A
1413
- * permission call passes only with one of `keys`.
1412
+ * `member_can`, joined by `and`, with a soft-delete `is null` and the
1413
+ * support-session `actor_may_write()` guard allowed. A permission call passes
1414
+ * only with one of `keys`.
1414
1415
  */
1415
1416
  function tenantOnly(expression, column, keys) {
1416
1417
  const col = `(?:"?\\w+"?\\.)?"?${escape$2(column)}"?(?:::\\w+)?`;
@@ -1421,7 +1422,8 @@ function tenantOnly(expression, column, keys) {
1421
1422
  `${col}\\s+in\\s+\\(\\s*select\\s+(?:\\w+\\.)?\\w*member_\\w*ids\\(\\s*\\)(?:\\s+as\\s+\\w+)?\\s*\\)`,
1422
1423
  `better_supabase\\.can\\(\\s*'tenant'(?:::text)?\\s*,\\s*${col}\\s*,\\s*${key}\\s*\\)`,
1423
1424
  `better_supabase\\.member_can\\(\\s*${col}\\s*,\\s*${key}\\s*\\)`,
1424
- `(?:"?\\w+"?\\.)?"?\\w+"?\\s+is\\s+null`
1425
+ `(?:"?\\w+"?\\.)?"?\\w+"?\\s+is\\s+null`,
1426
+ `\\(?\\s*(?:select\\s+)?better_supabase\\.actor_may_write\\(\\)(?:\\s+as\\s+\\w+)?\\s*\\)?`
1425
1427
  ];
1426
1428
  const used = [];
1427
1429
  let rest = expression;
@@ -1,22 +1,22 @@
1
1
  import { a as list, p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
2
  import { i as plain } from "./style-Bm2X5JrN.js";
3
3
  import { a as parseNames, i as failedResult, n as CliError } from "./errors-BTe6A15O.js";
4
- import { u as catalogFingerprint } from "./cache-DDKao2Va.js";
5
- import { a as serializeSnapshot, g as serializeGenerator, h as restrictSchemas, o as snapshotFile, r as openSource, t as loadSnapshot } from "./snapshot-CZb3uVKE.js";
6
- import { n as dataMigration } from "./migrations-CHenMvl_.js";
4
+ import { u as catalogFingerprint } from "./cache-61VwYKEv.js";
5
+ import { a as serializeSnapshot, g as serializeGenerator, h as restrictSchemas, o as snapshotFile, r as openSource, t as loadSnapshot } from "./snapshot-B8K6gYjA.js";
6
+ import { n as dataMigration } from "./migrations-Ch5Uuvyj.js";
7
7
  import { d as GEN_TASKS, p as isGenTask } from "./config-BH0goim0.js";
8
8
  import { c as insideRoot, r as applyPlan, u as planResult } from "./files-CX71yBm8.js";
9
- import { n as runGen } from "./run-gE4eAazR.js";
10
- import { t as syncModules } from "./sync-B8VGiaHk.js";
11
- import { t as addModules } from "./add-C0w-mVTQ.js";
12
- import { n as listModules, t as printModule } from "./print-C0OmQyTu.js";
9
+ import { n as runGen } from "./run-Dafms0D2.js";
10
+ import { t as syncModules } from "./sync-CT_5VG0E.js";
11
+ import { t as addModules } from "./add-B6CQOt3A.js";
12
+ import { n as listModules, t as printModule } from "./print-CbPT4PTL.js";
13
13
  import { a as sourceFlags, i as sourceArgs, n as SOURCE_ARGS } from "./source-args-z-jkabmO.js";
14
- import { a as runMetadataGen, n as checkMetadataFlags, t as EMITS } from "./metadata-cLXra-XB.js";
14
+ import { a as runMetadataGen, n as checkMetadataFlags, t as EMITS } from "./metadata-DDfPBHwI.js";
15
15
  import { a as runEnv } from "./env-BCgVZkcb.js";
16
- import { c as watchLoop, o as parseInterval, r as specOptionsFromConfig, s as stampFiles, t as runSpec } from "./spec-Cn5RhuQc.js";
17
- import { n as runPowerSync } from "./powersync-D83yAFbl.js";
16
+ import { c as watchLoop, o as parseInterval, r as specOptionsFromConfig, s as stampFiles, t as runSpec } from "./spec-BGsnTkIl.js";
17
+ import { n as runPowerSync } from "./powersync-CfT-tRx1.js";
18
18
  import { t as runSeed } from "./seed-CdSxunFT.js";
19
- import { t as upgrade } from "./upgrade-BvBWK3Fo.js";
19
+ import { t as upgrade } from "./upgrade-frUtPDDb.js";
20
20
  import { existsSync } from "node:fs";
21
21
  import { resolve } from "node:path";
22
22
  //#region src/cli/commands/sql.ts
@@ -798,6 +798,6 @@ export declare function emitModule(model: Model, options: EmitOptions): string;
798
798
  export declare function loadConfig(cwd: string, explicit?: string, environment?: string, path?: string | undefined): Promise<ResolvedConfig>;
799
799
  //#endregion
800
800
  //#region src/cli/version.d.ts
801
- export declare const VERSION = "0.21.0";
801
+ export declare const VERSION = "0.22.0";
802
802
  //#endregion
803
803
  export type { Catalog, CatalogCheck, CatalogColumn, CatalogColumnGrant, CatalogEnum, CatalogForeignKey, CatalogFunction, CatalogFunctionArg, CatalogGrant, CatalogIndex, CatalogPolicy, CatalogTable, CatalogTrigger, CatalogUnique, Choice, Cli, CliArgs, CliCommand, CliCommandDef, CliContext, CliEnv, CliErrorCode, CliErrorOptions, CliIo, CliLog, CliProblem, CliProblemExtensions, CommandResult, CreateCliOptions, ExitCode, ExtrasFunction, ExtrasHook, ExtrasHookFunction, ExtrasTable, ForeignKeyAction, Format, GeneratorMetadata, IntrospectionSource, ManagementSourceOptions, NextStep, Paint, Prompter, Queryable, RunOptions, RunResult, Snapshot, SnapshotBucket, SnapshotExtras };
package/dist/cli/index.js CHANGED
@@ -1,12 +1,12 @@
1
1
  import { a as list, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
- import { i as run, n as createCli, r as help, t as commandNames } from "./run-He3M-ZRq.js";
3
- import { t as VERSION } from "./version-BVg2Z6yv.js";
2
+ import { i as run, n as createCli, r as help, t as commandNames } from "./run-DxTd55Ug.js";
3
+ import { t as VERSION } from "./version-CUdPyV6J.js";
4
4
  import { n as CliError, t as CLI_ERRORS_URL } from "./errors-BTe6A15O.js";
5
- import { a as serializeSnapshot, i as parseSnapshot, l as introspect, t as loadSnapshot } from "./snapshot-CZb3uVKE.js";
6
- import { a as emitBlockConfig, l as buildModel, o as GENERATED_HEADER, r as renderFiles, s as emitModule } from "./render-9m70qveo.js";
7
- import { a as toCatalog, n as managementSource, r as pgSource } from "./source-CrYSCdPZ.js";
5
+ import { a as serializeSnapshot, i as parseSnapshot, l as introspect, t as loadSnapshot } from "./snapshot-B8K6gYjA.js";
6
+ import { a as emitBlockConfig, l as buildModel, o as GENERATED_HEADER, r as renderFiles, s as emitModule } from "./render-0Vd7BaNA.js";
7
+ import { a as toCatalog, n as managementSource, r as pgSource } from "./source-CXDyCWz5.js";
8
8
  import { s as loadConfig } from "./config-BH0goim0.js";
9
- import { n as runGen } from "./run-gE4eAazR.js";
9
+ import { n as runGen } from "./run-Dafms0D2.js";
10
10
  //#region src/cli/introspect/from-catalog.ts
11
11
  /**
12
12
  * Builds a snapshot from catalog records: the inverse of `toCatalog`. Tests and
@@ -2,14 +2,14 @@ import { a as list, p as commandMeta, r as defineCliCommand } from "./command-BW
2
2
  import { i as plain } from "./style-Bm2X5JrN.js";
3
3
  import { n as CliError } from "./errors-BTe6A15O.js";
4
4
  import { r as readIfExists } from "./io-DH1kcmmP.js";
5
- import { l as TYPEGEN_VERSION } from "./cache-DDKao2Va.js";
5
+ import { l as TYPEGEN_VERSION } from "./cache-61VwYKEv.js";
6
6
  import { a as findConfig, s as loadConfig } from "./config-BH0goim0.js";
7
- import { r as contentMapperFiles } from "./content-mapper-DgSTl-DL.js";
7
+ import { r as contentMapperFiles } from "./content-mapper-DGQQY5IA.js";
8
8
  import { i as changeLines, n as PLAN_ARGS, r as applyPlan, u as planResult } from "./files-CX71yBm8.js";
9
- import { C as promptConventions, S as hasConventionFlags, _ as templatePlan, b as conventionFlags, c as AUTHZ_NOTE, d as chooseIntegrations, f as integrationFiles, g as templateContextFor, h as parseIntegrations, i as blocksWiringPath, l as createUrlParam, m as packagesFor, o as writeDesign, p as overwrite, r as blockConfigImport, s as readPresetInput, u as CANCELLED, v as CONVENTION_ARGS, w as withConventions, x as defaultConventions, y as CONVENTION_COMPLETIONS } from "./add-BTDPjVGC.js";
10
- import { a as wiringFiles, c as baseFiles, f as needsLib, i as wiringChecklist, m as suggestedIntegrations, n as latestMigrationVersion, o as wiringFor, p as resolveIntegrations, r as configInstances, s as TEMPLATES } from "./migration-safety-OUK-Afbb.js";
9
+ import { C as promptConventions, S as hasConventionFlags, _ as templatePlan, b as conventionFlags, c as AUTHZ_NOTE, d as chooseIntegrations, f as integrationFiles, g as templateContextFor, h as parseIntegrations, i as blocksWiringPath, l as createUrlParam, m as packagesFor, o as writeDesign, p as overwrite, r as blockConfigImport, s as readPresetInput, u as CANCELLED, v as CONVENTION_ARGS, w as withConventions, x as defaultConventions, y as CONVENTION_COMPLETIONS } from "./add-BXFzr0Wf.js";
10
+ import { a as wiringFiles, c as baseFiles, f as needsLib, i as wiringChecklist, m as suggestedIntegrations, n as latestMigrationVersion, o as wiringFor, p as resolveIntegrations, r as configInstances, s as TEMPLATES } from "./migration-safety-CQbrfZIx.js";
11
11
  import { n as installCommand, t as detectProject } from "./detect-D9JaAX20.js";
12
- import { s as enablePgDelta, t as syncModules } from "./sync-B8VGiaHk.js";
12
+ import { s as enablePgDelta, t as syncModules } from "./sync-CT_5VG0E.js";
13
13
  import { existsSync } from "node:fs";
14
14
  import { join, posix, resolve } from "node:path";
15
15
  import { glob, readFile } from "node:fs/promises";
@@ -1,6 +1,6 @@
1
1
  import { r as errorText } from "./errors-BTe6A15O.js";
2
- import "./source-CrYSCdPZ.js";
3
- import { l as tableObject, n as exposed, s as qualified, t as catalogOf } from "./shared-Cx2WFVWq.js";
2
+ import "./source-CXDyCWz5.js";
3
+ import { l as tableObject, n as exposed, s as qualified, t as catalogOf } from "./shared-BQAMXvwd.js";
4
4
  //#region src/cli/doctor/reserved-roles.ts
5
5
  /**
6
6
  * Supautils' `reserved_roles` on Supabase. Nobody but a superuser may alter,
@@ -1,6 +1,6 @@
1
1
  import { p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
- import { a as envelope, i as run } from "./run-He3M-ZRq.js";
3
- import { t as VERSION } from "./version-BVg2Z6yv.js";
2
+ import { a as envelope, i as run } from "./run-DxTd55Ug.js";
3
+ import { t as VERSION } from "./version-CUdPyV6J.js";
4
4
  import { n as CliError } from "./errors-BTe6A15O.js";
5
5
  import { n as consentToken } from "./agent-CbuPvI2x.js";
6
6
  import { C as optional, D as record, N as unknown, a as array, d as is, j as string$1, k as safeParse, o as boolean, t as PROCESS_ENV, x as object } from "./env-DMgjB_4y.js";
@@ -1,8 +1,8 @@
1
1
  import { n as CliError, r as errorText } from "./errors-BTe6A15O.js";
2
2
  import { i as readStdin } from "./io-DH1kcmmP.js";
3
- import { m as parseMetadataDocument, u as MetadataRejectedError } from "./snapshot-CZb3uVKE.js";
4
- import { c as metaPaths, n as render } from "./render-9m70qveo.js";
5
- import { i as generationNotices, n as runGen, o as fromMetadata, r as UNFORMATTED, t as refuseRowConditionedBuckets } from "./run-gE4eAazR.js";
3
+ import { m as parseMetadataDocument, u as MetadataRejectedError } from "./snapshot-B8K6gYjA.js";
4
+ import { c as metaPaths, n as render } from "./render-0Vd7BaNA.js";
5
+ import { i as generationNotices, n as runGen, o as fromMetadata, r as UNFORMATTED, t as refuseRowConditionedBuckets } from "./run-Dafms0D2.js";
6
6
  import { basename, join, relative, resolve, sep } from "node:path";
7
7
  import { readFile } from "node:fs/promises";
8
8
  import { jsonSchema, standardSchema, valibot, zod } from "better-supabase/config";
@@ -1,5 +1,5 @@
1
1
  import { f as INTEGRATIONS } from "./config-BH0goim0.js";
2
- import { c as splitStatements } from "./shared-Cx2WFVWq.js";
2
+ import { c as splitStatements } from "./shared-BQAMXvwd.js";
3
3
  import { dirname, join, posix } from "node:path";
4
4
  import { readdir } from "node:fs/promises";
5
5
  import { INTEGRATION_INFO, groupEntries } from "better-supabase/config";
@@ -2,7 +2,7 @@ import { n as CliError } from "./errors-BTe6A15O.js";
2
2
  import { d as readSupabaseToml, p as sqlWorkflow } from "./supabase-toml-CncmQbO0.js";
3
3
  import { t as importFresh } from "./fresh-import-DzgsGHkX.js";
4
4
  import { i as changeLines, r as applyPlan } from "./files-CX71yBm8.js";
5
- import { a as sqlPlan, i as schemasDirOf, n as migrationsDir, r as moduleLayoutFor } from "./sql-layout-CLJ67h3L.js";
5
+ import { a as sqlPlan, i as schemasDirOf, n as migrationsDir, r as moduleLayoutFor } from "./sql-layout-BGAlcp1U.js";
6
6
  import { resolve } from "node:path";
7
7
  import { readFile, readdir } from "node:fs/promises";
8
8
  import { MODULE_ID_TYPES, compileReadSets, moduleIdType, moduleLayout, modulePermissionKeys, moduleSchemaExtensions, renderBlocks, resolveBlocks, scopeProblems, templateFunctions } from "better-supabase/sql";
@@ -1,7 +1,7 @@
1
- import { i as stampAfter } from "./migrations-CHenMvl_.js";
1
+ import { i as stampAfter } from "./migrations-Ch5Uuvyj.js";
2
2
  import { d as readSupabaseToml, p as sqlWorkflow } from "./supabase-toml-CncmQbO0.js";
3
3
  import { i as changeLines, r as applyPlan } from "./files-CX71yBm8.js";
4
- import { a as sqlPlan, n as migrationsDir } from "./sql-layout-CLJ67h3L.js";
4
+ import { a as sqlPlan, n as migrationsDir } from "./sql-layout-BGAlcp1U.js";
5
5
  import { resolve } from "node:path";
6
6
  import { readFile, readdir } from "node:fs/promises";
7
7
  import { moduleSchemaExtensions } from "better-supabase/sql";
@@ -1,7 +1,7 @@
1
1
  import { p as commandMeta, r as defineCliCommand } from "./command-BWEEXmtz.js";
2
- import { c as layoutFor, i as stampAfter } from "./migrations-CHenMvl_.js";
2
+ import { c as layoutFor, i as stampAfter } from "./migrations-Ch5Uuvyj.js";
3
3
  import { n as PLAN_ARGS, r as applyPlan, u as planResult } from "./files-CX71yBm8.js";
4
- import { n as migrationsDir } from "./sql-layout-CLJ67h3L.js";
4
+ import { n as migrationsDir } from "./sql-layout-BGAlcp1U.js";
5
5
  import { existsSync } from "node:fs";
6
6
  import { join, resolve } from "node:path";
7
7
  import { readFile, readdir } from "node:fs/promises";
@@ -0,0 +1 @@
1
+ export { t as powersyncStreamsCommand } from "./powersync-CfT-tRx1.js";
@@ -1,6 +1,6 @@
1
1
  import { n as CliError } from "./errors-BTe6A15O.js";
2
- import { s as layout } from "./migrations-CHenMvl_.js";
3
- import { o as migrationModules, r as latestMigration, u as writesMigrations } from "./module-migration-6V7vXWUK.js";
2
+ import { s as layout } from "./migrations-Ch5Uuvyj.js";
3
+ import { o as migrationModules, r as latestMigration, u as writesMigrations } from "./module-migration-Dul1uTYX.js";
4
4
  import { existsSync } from "node:fs";
5
5
  import { resolve } from "node:path";
6
6
  import { SQL_MODULES, contractSignature, customContracts, moduleBody, moduleFilePaths } from "better-supabase/sql";