permdock 0.5.0 → 0.7.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.
- package/README.md +1 -0
- package/dist/{2020-C9VN-x8c.js → 2020-CJbO8Bvz.js} +1 -3
- package/dist/a2a/index.d.ts +5 -5
- package/dist/a2a/index.js +4 -4
- package/dist/{adoption-scan-B4R5fnMU.js → adoption-scan-D-feE7BE.js} +1 -1
- package/dist/agent/index.d.ts +3 -3
- package/dist/agent/index.js +1 -1
- package/dist/ai-sdk/index.d.ts +21 -6
- package/dist/ai-sdk/index.js +19 -9
- package/dist/{approval-prompt-Djo_PyZc.d.ts → approval-prompt-K0faOLFp.d.ts} +2 -2
- package/dist/approvals/index.d.ts +4 -4
- package/dist/approvals/index.js +4 -4
- package/dist/{approvals-DJ6Yd5z1.js → approvals-CMRfsbBh.js} +74 -48
- package/dist/{arazzo-B6lebmiQ.js → arazzo-ClrF3PVb.js} +2 -2
- package/dist/{arazzo-BWhNF-k0.js → arazzo-rdeJ8n1J.js} +4 -4
- package/dist/{args-IIolxxKA.js → args-CC3OwyHW.js} +112 -2
- package/dist/astro/index.d.ts +6 -6
- package/dist/astro/index.js +2 -2
- package/dist/{audience-Dg8XsRaO.js → audience-BrMs8c4o.js} +1 -1
- package/dist/{auth-DRLEizbL.js → auth-CscUX8Sy.js} +3 -4
- package/dist/authzen/index.d.ts +162 -22
- package/dist/authzen/index.js +315 -146
- package/dist/{automation-BMZPIVUM.d.ts → automation-DOtAFWdy.d.ts} +3 -3
- package/dist/{automation-DVjOckjV.js → automation-ySsxp_Yp.js} +1 -1
- package/dist/base-url-BQbddZO5.js +9 -0
- package/dist/better-auth/index.d.ts +2 -2
- package/dist/better-auth/index.js +2 -2
- package/dist/better-supabase/index.d.ts +50 -8
- package/dist/better-supabase/index.js +94 -32
- package/dist/{bind-CZzhx-Vj.js → bind-D1nO6fiC.js} +5 -5
- package/dist/{bind--9EFVYWF.d.ts → bind-JDuvxjuW.d.ts} +7 -7
- package/dist/{build-instance-BMnAudHn.js → build-instance-DxE7czo9.js} +1 -1
- package/dist/{canonical-json-BC8_nMTw.js → canonical-json-DwilZ1iB.js} +6 -3
- package/dist/{capability-BSslw1QV.d.ts → capability-D4UC9TTW.d.ts} +2 -2
- package/dist/{capability-N1K9IpqS.js → capability-L7NnfhiE.js} +1 -1
- package/dist/{casbin-Cr7RLtA3.js → casbin-BHijLuHY.js} +2 -2
- package/dist/{casbin-Dyu2gnUD.js → casbin-BW9pS47J.js} +1 -1
- package/dist/{casl-64gpT-8x.js → casl-CmJlgziS.js} +2 -2
- package/dist/{casl-DjEDhTCP.js → casl-UbI8v-Wq.js} +1 -1
- package/dist/catalog/index.d.ts +70 -10
- package/dist/catalog/index.js +112 -6
- package/dist/catalog-BCCjSAdH.js +1 -0
- package/dist/{catalog-R_A__RsH.js → catalog-BaMQfQ6Y.js} +3 -3
- package/dist/{catalog-BECMPrwc.js → catalog-D69WhFii.js} +43 -13
- package/dist/{catalog-doc-C9wjsfNY.js → catalog-doc-CV9s6B1S.js} +28 -5
- package/dist/{catalog-fingerprint-CCP0-yQS.js → catalog-fingerprint-C144oW4M.js} +1 -1
- package/dist/{create-BWRSXgOF.js → challenge-nGWma08S.js} +122 -25
- package/dist/chat/index.d.ts +1 -1
- package/dist/chat/index.js +2 -2
- package/dist/chat-sdk/index.d.ts +3 -3
- package/dist/checks-BC_0mPIq.js +37 -0
- package/dist/claude-agent/index.d.ts +3 -3
- package/dist/claude-agent/index.js +2 -2
- package/dist/clerk/index.d.ts +3 -3
- package/dist/clerk/index.js +1 -1
- package/dist/cli/bin.js +2 -2
- package/dist/cli/index.d.ts +3 -3
- package/dist/cli/index.js +3 -3
- package/dist/cloud/index.d.ts +127 -11
- package/dist/cloud/index.js +251 -3
- package/dist/{cloud-CIoHNevm.js → cloud-CO8pYtwr.js} +5 -5
- package/dist/{codemod-Cxvvc70T.js → codemod-BP6n8N9L.js} +3 -3
- package/dist/{codemod-Bmj9dWMH.js → codemod-i4N2BhDc.js} +3 -3
- package/dist/{collect-CrZJJnEF.js → collect-BaWeMjwV.js} +17 -8
- package/dist/{collect-DloHbDVa.js → collect-DNm3oKOk.js} +6 -5
- package/dist/collect-k_Dulxr5.js +1 -0
- package/dist/compile/index.d.ts +1 -1
- package/dist/compile/index.js +1 -1
- package/dist/{compile-CMqMx_IN.js → compile-BAEO5bOk.js} +2 -2
- package/dist/{compile-Ckm2HqBZ.d.ts → compile-COM2VKuN.d.ts} +3 -3
- package/dist/{completion-BqhRBJD8.js → completion-BNdVf7X2.js} +3 -3
- package/dist/{config-bs_kZeYq.js → config-CoQHDrDi.js} +7 -3
- package/dist/{config-B46rm9sc.js → config-DGZzMV1B.js} +2 -2
- package/dist/{config-report-DUgj62Ai.js → config-report-Cm7UITNA.js} +3 -3
- package/dist/connector-schema-_VCSsdtD.js +433 -0
- package/dist/{context-bbFHR-0D.js → context--uM9V3Ui.js} +2 -2
- package/dist/convex/index.d.ts +5 -5
- package/dist/convex/index.js +2 -2
- package/dist/core-B5-w6Kw9.js +335 -0
- package/dist/core-CQkE8Esr.d.ts +179 -0
- package/dist/{create-0VZ7Pdiu.d.ts → create-B2-CQqCI.d.ts} +5 -5
- package/dist/{create-C3b4B5eF.js → create-Cb86Z8Im.js} +9 -8
- package/dist/{create-DnrmLnLW.js → create-DJrlhEp9.js} +5 -5
- package/dist/{create-BFfm17UA.d.ts → create-QHuuPw3q.d.ts} +7 -7
- package/dist/{create-BDS7wc3y.d.ts → create-UTnUVETj.d.ts} +30 -10
- package/dist/{credential-DM2um3ha.js → credential-CIM7wHwA.js} +4 -4
- package/dist/{credentials-DPyHmYz5.js → credentials-BpuTwd7a.js} +1 -1
- package/dist/{deciding-columns-Sq12mEA6.js → deciding-columns-DRo2QM6E.js} +13 -2
- package/dist/{delegation-DaXVdDhM.js → delegation-C5rOdTp5.js} +5 -5
- package/dist/delivery/index.d.ts +5 -5
- package/dist/delivery/index.js +4 -3
- package/dist/{delivery-DCAgNyCn.js → delivery-rwOKLWRm.js} +51 -2
- package/dist/{denied-text-D8jDHgsl.d.ts → denied-text-D4qkEtFz.d.ts} +2 -2
- package/dist/{describe-BybMRY7A.js → describe-DZlnEtLy.js} +1 -0
- package/dist/{describe-BZUsixiL.d.ts → describe-O0SwYIK8.d.ts} +2 -2
- package/dist/{diff-CxZo9pTq.js → diff-Btr1c1Ow.js} +2 -2
- package/dist/{diff-DCePiN6M.js → diff-DzT-xD13.js} +10 -10
- package/dist/{doctor-DFjUxf2f.js → doctor-BU1szn63.js} +241 -49
- package/dist/{doctor-CxiwSfqH.js → doctor-BoK_y0KO.js} +4 -4
- package/dist/drizzle/index.d.ts +3 -3
- package/dist/drizzle/index.js +1 -1
- package/dist/elysia/index.d.ts +5 -5
- package/dist/elysia/index.js +3 -3
- package/dist/{errors-C2PXIv4c.d.ts → errors-B_Qg9D3e.d.ts} +2 -2
- package/dist/{errors-CWTY6uih.js → errors-DpP_U6Bf.js} +1 -0
- package/dist/{evaluate-_R8QkWaf.js → evaluate-B_oqFbWC.js} +130 -34
- package/dist/{evaluations-16UqqQ6W.d.ts → evaluations-BCddEOfO.d.ts} +4 -4
- package/dist/{evaluations-DZ2CbV5k.js → evaluations-DReoiVBw.js} +4 -4
- package/dist/eve/index.d.ts +5 -5
- package/dist/eve/index.js +3 -3
- package/dist/express/index.d.ts +5 -5
- package/dist/express/index.js +3 -3
- package/dist/fastify/index.d.ts +5 -5
- package/dist/fastify/index.js +3 -3
- package/dist/{fetch-adapter-qKJBuRqy.d.ts → fetch-adapter-CuhyYwC1.d.ts} +4 -4
- package/dist/{fetch-adapter-g0ypLkID.js → fetch-adapter-De-u6vhJ.js} +3 -3
- package/dist/{fields-D9tPVUUS.js → fields-ClcQLrVc.js} +48 -13
- package/dist/{files-C5ZI27eV.js → files-acUbNwWt.js} +15 -2
- package/dist/{fixtures-B7XrLeY7.js → fixtures-BTMW6zgU.js} +2 -2
- package/dist/{flags-C3DktBDY.js → flags-aaeRAdiD.js} +2 -2
- package/dist/{from-snapshot-D2lZt4Dd.js → from-snapshot-Bz469dIh.js} +17 -10
- package/dist/generate-3FNO5P5Q.js +159 -0
- package/dist/{grantee-Cn1HyUsI.js → grantee-BrRANrpT.js} +14 -4
- package/dist/{grantee-conditions-CcXf8hMM.js → grantee-conditions-C6P1Tvol.js} +1 -1
- package/dist/{grantee-match-DHArqY82.js → grantee-match-0RtHWQDx.js} +3 -3
- package/dist/h3/index.d.ts +4 -4
- package/dist/h3/index.js +3 -3
- package/dist/{helpers-DTcZOzhF.js → helpers-DY3vXuGs.js} +3 -3
- package/dist/hono/index.d.ts +5 -5
- package/dist/hono/index.js +3 -3
- package/dist/{hosted-DBDX0M-P.d.ts → hosted-BmjzxQhp.d.ts} +14 -2
- package/dist/{hosted-BZIAYvon.js → hosted-XBgU6RGT.js} +34 -12
- package/dist/{http-DXJ37RDA.js → http-Ca3Sr5x1.js} +1 -1
- package/dist/{import-DMmOG27O.js → import-Bz0GefWg.js} +5 -5
- package/dist/{import-CNV7I2Dw.js → import-DB2EG_iy.js} +3 -3
- package/dist/{index-CxGUswIC.d.ts → index-BE8y3moU.d.ts} +50 -8
- package/dist/{index-Chrs5fQ-.d.ts → index-BSfRl0hZ.d.ts} +6 -6
- package/dist/{index-DOVf7RJv.d.ts → index-BTkwrK7v.d.ts} +155 -17
- package/dist/index-CMiPH2Tv.d.ts +206 -0
- package/dist/{index-SGdIQyzc.d.ts → index-DH9DUDEM.d.ts} +18 -3
- package/dist/{index-BcHcPyIo.d.ts → index-DLwcuCN_.d.ts} +86 -7
- package/dist/index.d.ts +18 -17
- package/dist/index.js +27 -25
- package/dist/{init-GG6Jh8HD.js → init-5TXNji88.js} +5 -5
- package/dist/{init-DeMYsnYJ.js → init-B-4t1NzC.js} +4 -4
- package/dist/{instance-options-Omfd793B.d.ts → instance-options-CU0YQCLH.d.ts} +1 -1
- package/dist/{instance-snapshot-Cxq4ygFc.js → instance-snapshot-CjcwnEiV.js} +20 -14
- package/dist/jwt/index.d.ts +83 -5
- package/dist/jwt/index.js +143 -5
- package/dist/{kernel-5JatXyND.js → kernel-DVExUwkp.js} +138 -12
- package/dist/kysely/index.d.ts +3 -3
- package/dist/kysely/index.js +1 -1
- package/dist/load-DrMHXzgN.js +1 -0
- package/dist/{load-DFS_ry0W.js → load-DxroEzH1.js} +2 -2
- package/dist/{login-Dfe5RlYk.js → login-ClSJh5t5.js} +4 -4
- package/dist/{login-imhuwvn3.js → login-WC9HPJpU.js} +6 -10
- package/dist/{manifest-C8IzW3Do.js → manifest-B79YuF2T.js} +6 -2
- package/dist/{manifest-mx5ghSFM.d.ts → manifest-BVhExYhw.d.ts} +23 -2
- package/dist/{manifest-CtKR3GXL.js → manifest-Dv6q4i5s.js} +54 -35
- package/dist/{manifest-schema-C0kK_8V0.js → manifest-schema-Cv492Qev.js} +37 -7
- package/dist/{map-claims-D3oRmTk0.js → map-claims-etGIS_Dv.js} +14 -11
- package/dist/{map-error-TCAdw-eW.js → map-error-BQGyDm_M.js} +1 -1
- package/dist/mcp/index.d.ts +64 -10
- package/dist/mcp/index.js +151 -22
- package/dist/{migrate-BShP7Vf4.js → migrate-Dodel0IJ.js} +77 -24
- package/dist/nest/index.d.ts +5 -5
- package/dist/nest/index.js +3 -3
- package/dist/next/index.d.ts +9 -9
- package/dist/next/index.js +5 -5
- package/dist/next/plugin.d.ts +1 -1
- package/dist/next/plugin.js +2 -2
- package/dist/node/index.d.ts +5 -5
- package/dist/node/index.js +2 -2
- package/dist/openai/index.d.ts +5 -5
- package/dist/openai/index.js +3 -3
- package/dist/openapi/index.d.ts +14 -4
- package/dist/openapi/index.js +1 -1
- package/dist/{openapi-ahr8rHu3.js → openapi-DMocl1bh.js} +4 -4
- package/dist/{openapi-B7HZ0f-r.js → openapi-Ddb4628T.js} +2 -7
- package/dist/{openapi-DTaEmTSW.js → openapi-ztVaux6j.js} +8 -8
- package/dist/{operation-findings-DgATDpvh.js → operation-findings-kRcEp8lE.js} +1 -1
- package/dist/{operations-CxybZErY.d.ts → operations-BNLes61x.d.ts} +1 -1
- package/dist/orpc/index.d.ts +6 -6
- package/dist/orpc/index.js +4 -4
- package/dist/otel/index.d.ts +3 -3
- package/dist/otel/index.js +1 -1
- package/dist/{output-Dyw8fyPF.js → output-DgSDLrta.js} +7 -3
- package/dist/{output-files-DhRBBE4n.js → output-files-CCMdcFWb.js} +2 -2
- package/dist/output-files-DPAY7-GX.js +1 -0
- package/dist/{ownership-BatFgAA4.js → ownership-Z2LpxsGa.js} +1349 -883
- package/dist/parse-Ddhz2xf4.js +148 -0
- package/dist/{parse-local-manifest-CVSs6J9I.js → parse-local-manifest-T1Q8X3A2.js} +24 -1
- package/dist/{parse-local-manifest-DgqtruPn.d.ts → parse-local-manifest-e4mdwAKd.d.ts} +1 -1
- package/dist/pdp/index.d.ts +3 -3
- package/dist/pdp/index.js +7 -3
- package/dist/peer-12Q5I_RH.js +976 -0
- package/dist/{peer-CRvC7Hg1.js → peer-DOzzMfZL.js} +1 -1
- package/dist/{permdock-B9JxkBwC.js → permdock-BfWEeMqk.js} +177 -49
- package/dist/{permdock-D7eeLJER.d.ts → permdock-Dco6dyCK.d.ts} +34 -5
- package/dist/{permission-registry-Br4jSNVi.js → permission-registry-DpPtSKNZ.js} +1 -1
- package/dist/{vocabulary-D6lPdb4Z.d.ts → permission-types-DhNEmoRG.d.ts} +4 -62
- package/dist/{permissions-oEWfl-kl.d.ts → permissions-CoqCOfJ3.d.ts} +2 -1
- package/dist/{permissions-B-wCP5ZC.js → permissions-CyH2MV_B.js} +1 -1
- package/dist/{permissions-CZKiUfFM.js → permissions-DArULThq.js} +4 -4
- package/dist/pkce-5h8NgMQJ.js +21 -0
- package/dist/{policies-CO1oOymN.js → policies-B2lZIurj.js} +3 -3
- package/dist/{policy-Czo4n3Hs.d.ts → policy-B7dg_yzu.d.ts} +2 -2
- package/dist/{policy-DLZJ5gAp.js → policy-DaJy4nK4.js} +17 -8
- package/dist/{policy-from-catalog-DzhEc3Y9.js → policy-from-catalog-DFWYkNdu.js} +9 -9
- package/dist/{policy-types-DzwivBgR.d.ts → policy-types-B-F-qAZk.d.ts} +109 -5
- package/dist/postgres-store-BL9M_CA1.js +1001 -0
- package/dist/{postgrest-NUqZT-RB.d.ts → postgrest-CYacM_u7.d.ts} +12 -1
- package/dist/{postgrest-CW0IqC-U.js → postgrest-r5faDIzD.js} +47 -5
- package/dist/{powersync-BHfuehf3.js → powersync-13odBwiM.js} +3 -3
- package/dist/powersync-53ryOZip.js +1059 -0
- package/dist/powersync-CExtTLyA.js +1 -0
- package/dist/preset/index.js +1 -1
- package/dist/{preset-DZdU0tne.js → preset-CHTbd-DQ.js} +2 -2
- package/dist/prisma/index.d.ts +2 -2
- package/dist/prisma/index.js +1 -1
- package/dist/{problem-details-DXlt-vks.d.ts → problem-details-Tcfmj3bV.d.ts} +1 -1
- package/dist/prompt-DwtVemER.js +935 -0
- package/dist/{protected-DEPHc2xV.d.ts → protected-BwZYL1X_.d.ts} +6 -5
- package/dist/{protected-DfjY5mLA.js → protected-DXE3cQYg.js} +2 -2
- package/dist/{provider-CC-u3bYP.js → provider-BQsTYYy0.js} +2 -2
- package/dist/{provider-DMVt6yYn.d.ts → provider-Csk-THAn.d.ts} +1 -1
- package/dist/{provider-store-B5Yrkhzr.js → provider-store-IgqQipCO.js} +2 -2
- package/dist/{pull-BgIfno6w.js → pull-CN5OLxrF.js} +7 -7
- package/dist/pull-Cty6Ovyu.js +1 -0
- package/dist/{push-CmFVBOeI.js → push-tVdG8dUL.js} +54 -14
- package/dist/{pushed-policy-BImMTTIM.d.ts → pushed-policy-BbcY9r_4.d.ts} +1 -1
- package/dist/{pushed-policy-DobP7AHI.js → pushed-policy-CmYeSQqq.js} +1 -1
- package/dist/react/index.d.ts +6 -6
- package/dist/react/index.js +3 -3
- package/dist/react/provider-client.d.ts +1 -1
- package/dist/react/provider-client.js +1 -1
- package/dist/react-native/index.d.ts +25 -11
- package/dist/react-native/index.js +214 -24
- package/dist/{refs-K6eWUJ0H.js → refs-CNJBiTFo.js} +15 -1
- package/dist/{replay-D7iKcLFe.d.ts → replay-DCDD_ZfL.d.ts} +1 -1
- package/dist/{request-context-BTRTG7OT.js → request-context-BykKLmyE.js} +2 -2
- package/dist/resend/index.d.ts +4 -4
- package/dist/{retire-CALjIQ7e.js → retire-Wj6dkyDE.js} +2 -2
- package/dist/{rls-BA8an5Ap.js → rls-Ck_PocSp.js} +32 -8
- package/dist/{rls-j6t43t7n.js → rls-CxBZb4rZ.js} +478 -534
- package/dist/{role-builder-CXbis5-X.js → role-builder-C1VJzvcr.js} +3 -3
- package/dist/rolldown-runtime-C3I60J0A.js +4 -0
- package/dist/{rpc-aPyNi6tA.js → rpc-Bk1bE-ch.js} +1 -1
- package/dist/run-Bz7DXGEv.js +1 -0
- package/dist/{run-ticket-sxFI6LAk.js → run-ticket-B5d_63Ma.js} +22 -1
- package/dist/{run-ticket-BjhTOi6u.d.ts → run-ticket-BpNi7BCi.d.ts} +8 -3
- package/dist/{run-DOfMtc9V.js → run-uLD2aWuO.js} +7 -7
- package/dist/{runtime-D3VTAiCA.js → runtime-Vif3_-zf.js} +1 -1
- package/dist/{saas-FO-Q8oj0.js → saas-Az_Kz-4D.js} +7 -7
- package/dist/{scan-BOI5tJ-6.js → scan-DSljDE1Y.js} +1 -1
- package/dist/{schema-yLuBWWsh.js → schema-gIcCx7zM.js} +1 -1
- package/dist/scim/index.d.ts +3 -2
- package/dist/scim/index.js +3 -1
- package/dist/scim-C7JYhySg.js +44 -0
- package/dist/{scim-ClHtpyV3.js → scim-YNieBO1U.js} +3 -537
- package/dist/{scopes-CUPSjo9q.js → scopes-BHsc-wp-.js} +1 -1
- package/dist/server/index.d.ts +11 -11
- package/dist/server/index.js +7 -7
- package/dist/{server-DqCT4CgZ.js → server-Bnga6I50.js} +3 -3
- package/dist/{server-types-BLd4MnBX.d.ts → server-types-C4gZUEZy.d.ts} +9 -9
- package/dist/{shared-DvvFzYXe.js → shared-C8LjUdVU.js} +1 -1
- package/dist/{shared-CD11nBbC.js → shared-fMKOv8hP.js} +46 -39
- package/dist/{sink-Bj_lDUDq.d.ts → sink-Cp_Eot9W.d.ts} +4 -4
- package/dist/{skills-B6lVdD_W.js → skills-Dcjw9_1C.js} +5 -5
- package/dist/{skills-CTYwkl44.js → skills-g_3BS9NC.js} +3 -3
- package/dist/{snapshot-CXUWfsNy.js → snapshot-CbGmYiJx.js} +4 -4
- package/dist/{snapshot-cache-DZHQ0KF6.js → snapshot-cache-DT2Kx1F8.js} +1 -1
- package/dist/{snapshot-cache-DqK9eDmM.d.ts → snapshot-cache-Pahd3IYJ.d.ts} +1 -1
- package/dist/solid/index.d.ts +6 -5
- package/dist/solid/index.js +4 -4
- package/dist/solid-start/index.d.ts +6 -6
- package/dist/solid-start/index.js +3 -3
- package/dist/{sources-vs5dGOsS.js → sources-B-zYB4GS.js} +111 -25
- package/dist/{sources-BV9j0DeZ.d.ts → sources-DEEuGb8S.d.ts} +63 -14
- package/dist/sources-qoIJQrJv.js +11 -0
- package/dist/{sql-B5T1IL83.js → sql-B96movIM.js} +5 -1
- package/dist/sql-CDEPCA0g.d.ts +10 -0
- package/dist/{src-DLfUWFAI.js → src-DLFrtrrC.js} +154 -53
- package/dist/ssf/index.d.ts +4 -4
- package/dist/ssf/index.js +640 -211
- package/dist/{standard-webhooks-6lg8v_is.d.ts → standard-webhooks-B_qRg0ws.d.ts} +2 -2
- package/dist/{store-4u_hxjWa.js → store-DSP9oGvh.js} +15 -7
- package/dist/{store-options-BqEakYRa.js → store-options-B_poyYvg.js} +6 -6
- package/dist/{stores-ClZUgeoP.d.ts → stores-BAZwSYZA.d.ts} +6 -5
- package/dist/{stores-BbsD4fAR.js → stores-BqEuHC05.js} +2 -2
- package/dist/{stream-7-xmnf3U.d.ts → stream-2Vwhl7Er.d.ts} +2 -2
- package/dist/{style-Uao76wO7.js → style-Cqo7-73x.js} +1 -0
- package/dist/{style-DiKWnAvn.js → style-Ds1gNm77.js} +1 -1
- package/dist/supabase/index.d.ts +8 -7
- package/dist/supabase/index.js +5 -5
- package/dist/supabase/middleware.d.ts +6 -6
- package/dist/supabase/middleware.js +6 -6
- package/dist/{supabase-Dxlp8A94.js → supabase--0aJdLEd.js} +9 -7
- package/dist/{supabase-9pqI57pW.js → supabase-Bqp7iIY2.js} +3 -3
- package/dist/supabase-hook-DJxC4PoP.js +1 -0
- package/dist/{supabase-hook-DdDQhMlw.js → supabase-hook-Dg0SrQWR.js} +1069 -123
- package/dist/supautils-MESd81bF.js +689 -0
- package/dist/{support-session-C6xJQYut.js → support-session-Cna49-3f.js} +2 -2
- package/dist/svelte/index.d.ts +5 -5
- package/dist/svelte/index.js +5 -5
- package/dist/svelte/runtime.d.ts +3 -3
- package/dist/svelte/runtime.js +3 -3
- package/dist/svelte/source.d.ts +5 -5
- package/dist/svelte/source.js +2 -2
- package/dist/sveltekit/index.d.ts +6 -6
- package/dist/sveltekit/index.js +2 -2
- package/dist/tanstack-start/index.d.ts +6 -6
- package/dist/tanstack-start/index.js +2 -2
- package/dist/{tenancy-DN2QAx9z.js → tenancy-CmeBQ6Nv.js} +12 -3
- package/dist/terminal/index.d.ts +6 -6
- package/dist/terminal/index.js +3 -3
- package/dist/testing/core.d.ts +2 -0
- package/dist/testing/core.js +1 -0
- package/dist/testing/fixtures/index.d.ts +12 -0
- package/dist/testing/fixtures/index.js +770 -0
- package/dist/testing/index.d.ts +41 -174
- package/dist/testing/index.js +241 -731
- package/dist/testing/saas/index.d.ts +5 -5
- package/dist/testing/saas/index.js +2 -2
- package/dist/testing/saas/permissions.d.ts +1 -1
- package/dist/testing/saas/permissions.js +1 -1
- package/dist/text-diff-DhITNCnD.js +444 -0
- package/dist/{token-BLZcjQgt.js → token-2qYDvXz2.js} +1 -1
- package/dist/{tool-refusal-CMLN5xhn.js → tool-refusal-reAhIzdl.js} +1 -1
- package/dist/trpc/index.d.ts +6 -6
- package/dist/trpc/index.js +3 -3
- package/dist/{types-5Ut_pbKy.d.ts → types-BWZybqs9.d.ts} +112 -8
- package/dist/{types-CZTnPFzM.d.ts → types-BXMYB7BY.d.ts} +2 -2
- package/dist/{types-CdlxsYQh.d.ts → types-BfVmNJO5.d.ts} +14 -3
- package/dist/{types-BqAKcRNW.d.ts → types-CIeZcG8v.d.ts} +2 -2
- package/dist/{types-BNORmDM8.d.ts → types-CKV71kKh.d.ts} +4 -4
- package/dist/{types-tIgIeIKJ.d.ts → types-CQVEQawv.d.ts} +4 -4
- package/dist/{types-BjV-fqcA.d.ts → types-CeIscIKp.d.ts} +4 -4
- package/dist/{types-_sHy8BQf.d.ts → types-CfiKC5aN.d.ts} +1 -1
- package/dist/{types-ClZaWzfb.d.ts → types-D3A19w4A.d.ts} +8 -4
- package/dist/{types-C8-KNsFf.d.ts → types-DBHftjgS.d.ts} +15 -8
- package/dist/{types-CCpc2Dcv.d.ts → types-DC44-hqb.d.ts} +2 -2
- package/dist/{types-fbZ7JEXr.d.ts → types-DXmwu78Z.d.ts} +4 -4
- package/dist/{types-DiQjupG2.d.ts → types-cTos-H7p.d.ts} +2 -2
- package/dist/{types-DX0LaKTb.d.ts → types-g7Oy6Zg4.d.ts} +3 -3
- package/dist/unplugin/index.d.ts +1 -1
- package/dist/unplugin/index.js +2 -2
- package/dist/{usage-T5mXq98v.js → usage-Bybmck7f.js} +7 -7
- package/dist/{usage-DHtE8j4E.js → usage-CDaLXCfL.js} +2 -2
- package/dist/usage-y-kBNdqs.js +1 -0
- package/dist/{validation-error-Bg5Tpluk.d.ts → validation-error-CQpoquwj.d.ts} +1 -1
- package/dist/{verify-DbCL9bnB.js → verify-pe8rL_Qw.js} +350 -83
- package/dist/{views-DTIIO-oQ.js → views-BB8E9dTP.js} +1 -1
- package/dist/vocabulary-Bg3eeT2H.d.ts +67 -0
- package/dist/vue/index.d.ts +6 -5
- package/dist/vue/index.js +4 -4
- package/dist/{waiter-CKy4MQSY.d.ts → waiter-DwEyouan.d.ts} +2 -2
- package/dist/watch-Bd9mx3rd.js +1 -0
- package/dist/{watch-CszoTJMq.js → watch-C-4VmFlL.js} +3 -3
- package/dist/webmcp/index.d.ts +2 -2
- package/dist/webmcp/index.js +2 -2
- package/dist/{where-scope-Dv-WTP-w.js → where-scope-wq2coopv.js} +41 -21
- package/dist/{who-can-D0QoYbEb.js → who-can-BwNsI_Js.js} +6 -6
- package/dist/workflow/index.d.ts +3 -3
- package/dist/workflow/index.js +5 -5
- package/dist/workflow-sdk/index.d.ts +5 -5
- package/dist/{wrap-Bd1Tejur.d.ts → wrap-B6R0cMRL.d.ts} +2 -2
- package/dist/{wrap-gX61EtpB.js → wrap-CiSc_KCq.js} +8 -2
- package/package.json +22 -11
- package/schemas/cli-result-v1.json +1 -0
- package/schemas/cloud-api-v1.json +152 -7
- package/schemas/connector-v1.json +8 -0
- package/schemas/supabase-claims-v1.json +5 -0
- package/schemas/supabase-manifest-v1.json +276 -75
- package/skills/permdock/SKILL.md +1 -0
- package/skills/permdock-agents/references/runtimes.md +3 -1
- package/skills/permdock-approvals/references/stores-and-resume.md +2 -1
- package/skills/permdock-data/references/queries-and-rls.md +5 -2
- package/skills/permdock-tenancy/SKILL.md +1 -1
- package/skills/permdock-tenancy/references/ownership-and-custom-roles.md +2 -0
- package/skills/permdock-wire/references/adapters.md +14 -0
- package/skills/permdock-wire/references/policy-options.md +1 -0
- package/dist/catalog-DjhMYYCq.js +0 -1
- package/dist/collect-FlXJlhus.js +0 -1
- package/dist/index-D8EovfsP.d.ts +0 -91
- package/dist/load-BxEtwlBS.js +0 -1
- package/dist/output-files-B3IZJksC.js +0 -1
- package/dist/parse-Cxq0WxrA.js +0 -53
- package/dist/peer-C8swJ2GH.js +0 -50
- package/dist/powersync-CbzkqL_M.js +0 -1
- package/dist/powersync-bYUDLOAO.js +0 -538
- package/dist/prompt-DfZLJLIn.js +0 -32
- package/dist/pull-ByOks_Tg.js +0 -1
- package/dist/run-CNsApDpd.js +0 -1
- package/dist/supabase-hook-CXcGpHqq.js +0 -1
- package/dist/supautils-B6HYL9eL.js +0 -91
- package/dist/text-diff-BQcUapOb.js +0 -15
- package/dist/usage-CHOtwL19.js +0 -1
- package/dist/watch-Cb-NcaUw.js +0 -1
|
@@ -0,0 +1,770 @@
|
|
|
1
|
+
import { n as parseSupabaseManifest } from "../../manifest-B79YuF2T.js";
|
|
2
|
+
import { t as parseCatalog } from "../../parse-Ddhz2xf4.js";
|
|
3
|
+
//#region src/testing/fixtures/better-supabase.catalog.json
|
|
4
|
+
var better_supabase_catalog_default = {
|
|
5
|
+
$schema: "https://permdock.com/schemas/catalog-v1.json",
|
|
6
|
+
version: 1,
|
|
7
|
+
generatedAt: "2026-10-21T08:41:54.277Z",
|
|
8
|
+
generator: "permdock@0.6.0",
|
|
9
|
+
fingerprint: "sha-256:xLa3QGuqXtLe6WtPEyf2NaV_qr0vBW2qg2jRN5rBJdA",
|
|
10
|
+
resources: {
|
|
11
|
+
"staff": {
|
|
12
|
+
"id": "id",
|
|
13
|
+
"schema": {
|
|
14
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
15
|
+
"type": "object",
|
|
16
|
+
"properties": {
|
|
17
|
+
"id": {
|
|
18
|
+
"type": "string",
|
|
19
|
+
"format": "uuid",
|
|
20
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
21
|
+
},
|
|
22
|
+
"organization_id": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"format": "uuid",
|
|
25
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
26
|
+
},
|
|
27
|
+
"user_id": {
|
|
28
|
+
"type": "string",
|
|
29
|
+
"format": "uuid",
|
|
30
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
31
|
+
},
|
|
32
|
+
"name": { "type": "string" },
|
|
33
|
+
"title": { "type": "string" }
|
|
34
|
+
},
|
|
35
|
+
"required": [
|
|
36
|
+
"id",
|
|
37
|
+
"organization_id",
|
|
38
|
+
"user_id",
|
|
39
|
+
"name",
|
|
40
|
+
"title"
|
|
41
|
+
],
|
|
42
|
+
"additionalProperties": false
|
|
43
|
+
},
|
|
44
|
+
"definedIn": "src/permissions.ts",
|
|
45
|
+
"relations": { "organization": {
|
|
46
|
+
"field": "organization_id",
|
|
47
|
+
"memberOf": "organization"
|
|
48
|
+
} }
|
|
49
|
+
},
|
|
50
|
+
"quotes": {
|
|
51
|
+
"id": "id",
|
|
52
|
+
"schema": {
|
|
53
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
54
|
+
"type": "object",
|
|
55
|
+
"properties": {
|
|
56
|
+
"id": {
|
|
57
|
+
"type": "string",
|
|
58
|
+
"format": "uuid",
|
|
59
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
60
|
+
},
|
|
61
|
+
"organization_id": {
|
|
62
|
+
"type": "string",
|
|
63
|
+
"format": "uuid",
|
|
64
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
65
|
+
},
|
|
66
|
+
"customer_id": {
|
|
67
|
+
"type": "string",
|
|
68
|
+
"format": "uuid",
|
|
69
|
+
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
|
|
70
|
+
},
|
|
71
|
+
"title": { "type": "string" },
|
|
72
|
+
"amount_minor": {
|
|
73
|
+
"type": "integer",
|
|
74
|
+
"minimum": -9007199254740991,
|
|
75
|
+
"maximum": 9007199254740991
|
|
76
|
+
},
|
|
77
|
+
"currency": {
|
|
78
|
+
"type": "string",
|
|
79
|
+
"minLength": 3,
|
|
80
|
+
"maxLength": 3
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
"required": [
|
|
84
|
+
"id",
|
|
85
|
+
"organization_id",
|
|
86
|
+
"customer_id",
|
|
87
|
+
"title",
|
|
88
|
+
"amount_minor",
|
|
89
|
+
"currency"
|
|
90
|
+
],
|
|
91
|
+
"additionalProperties": false
|
|
92
|
+
},
|
|
93
|
+
"definedIn": "src/permissions.ts",
|
|
94
|
+
"relations": {
|
|
95
|
+
"organization": {
|
|
96
|
+
"field": "organization_id",
|
|
97
|
+
"memberOf": "organization"
|
|
98
|
+
},
|
|
99
|
+
"customer": {
|
|
100
|
+
"field": "customer_id",
|
|
101
|
+
"memberOf": "customer"
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"audit": {
|
|
106
|
+
"id": "id",
|
|
107
|
+
"schema": null,
|
|
108
|
+
"definedIn": "src/permissions.ts"
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
permissions: [
|
|
112
|
+
{
|
|
113
|
+
"key": "audit.revert",
|
|
114
|
+
"scope": "audit:revert",
|
|
115
|
+
"resource": "audit",
|
|
116
|
+
"action": "revert",
|
|
117
|
+
"arity": "collection",
|
|
118
|
+
"meta": {},
|
|
119
|
+
"usages": [{
|
|
120
|
+
"file": "src/policy.ts",
|
|
121
|
+
"line": 29,
|
|
122
|
+
"call": "reference"
|
|
123
|
+
}],
|
|
124
|
+
"rowConditions": false
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
"key": "audit.view",
|
|
128
|
+
"scope": "audit:view",
|
|
129
|
+
"resource": "audit",
|
|
130
|
+
"action": "view",
|
|
131
|
+
"arity": "collection",
|
|
132
|
+
"meta": {},
|
|
133
|
+
"usages": [{
|
|
134
|
+
"file": "src/policy.ts",
|
|
135
|
+
"line": 28,
|
|
136
|
+
"call": "reference"
|
|
137
|
+
}],
|
|
138
|
+
"rowConditions": false
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
"key": "quotes.list",
|
|
142
|
+
"scope": "quotes:list",
|
|
143
|
+
"resource": "quotes",
|
|
144
|
+
"action": "list",
|
|
145
|
+
"arity": "collection",
|
|
146
|
+
"meta": {},
|
|
147
|
+
"usages": [
|
|
148
|
+
{
|
|
149
|
+
"file": "src/agent/tools.ts",
|
|
150
|
+
"line": 80,
|
|
151
|
+
"call": "tools"
|
|
152
|
+
},
|
|
153
|
+
{
|
|
154
|
+
"file": "src/app/[locale]/(app)/[orgSlug]/nav.tsx",
|
|
155
|
+
"line": 29,
|
|
156
|
+
"call": "tools"
|
|
157
|
+
},
|
|
158
|
+
{
|
|
159
|
+
"file": "src/app/[locale]/(app)/[orgSlug]/quotes/page.tsx",
|
|
160
|
+
"line": 16,
|
|
161
|
+
"call": "reference"
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
"file": "src/app/[locale]/(portal)/portal/[orgSlug]/quotes/page.tsx",
|
|
165
|
+
"line": 16,
|
|
166
|
+
"call": "reference"
|
|
167
|
+
},
|
|
168
|
+
{
|
|
169
|
+
"file": "src/policy.ts",
|
|
170
|
+
"line": 26,
|
|
171
|
+
"call": "reference"
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"file": "src/policy.ts",
|
|
175
|
+
"line": 41,
|
|
176
|
+
"call": "reference"
|
|
177
|
+
}
|
|
178
|
+
],
|
|
179
|
+
"rowConditions": false
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
"key": "quotes.read",
|
|
183
|
+
"scope": "quotes:read",
|
|
184
|
+
"resource": "quotes",
|
|
185
|
+
"action": "read",
|
|
186
|
+
"arity": "instance",
|
|
187
|
+
"meta": {},
|
|
188
|
+
"usages": [
|
|
189
|
+
{
|
|
190
|
+
"file": "src/lib/share.ts",
|
|
191
|
+
"line": 51,
|
|
192
|
+
"call": "can"
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
"file": "src/policy.ts",
|
|
196
|
+
"line": 25,
|
|
197
|
+
"call": "reference"
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
"file": "src/policy.ts",
|
|
201
|
+
"line": 41,
|
|
202
|
+
"call": "reference"
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
"file": "src/policy.ts",
|
|
206
|
+
"line": 45,
|
|
207
|
+
"call": "allow"
|
|
208
|
+
}
|
|
209
|
+
],
|
|
210
|
+
"rowConditions": false
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
"key": "quotes.update",
|
|
214
|
+
"scope": "quotes:update",
|
|
215
|
+
"resource": "quotes",
|
|
216
|
+
"action": "update",
|
|
217
|
+
"arity": "instance",
|
|
218
|
+
"meta": {},
|
|
219
|
+
"usages": [{
|
|
220
|
+
"file": "src/agent/tools.ts",
|
|
221
|
+
"line": 82,
|
|
222
|
+
"call": "tools"
|
|
223
|
+
}, {
|
|
224
|
+
"file": "src/policy.ts",
|
|
225
|
+
"line": 27,
|
|
226
|
+
"call": "reference"
|
|
227
|
+
}],
|
|
228
|
+
"rowConditions": false
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
"key": "staff.list",
|
|
232
|
+
"scope": "staff:list",
|
|
233
|
+
"resource": "staff",
|
|
234
|
+
"action": "list",
|
|
235
|
+
"arity": "collection",
|
|
236
|
+
"meta": {},
|
|
237
|
+
"usages": [
|
|
238
|
+
{
|
|
239
|
+
"file": "src/app/[locale]/(app)/[orgSlug]/nav.tsx",
|
|
240
|
+
"line": 23,
|
|
241
|
+
"call": "tools"
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
"file": "src/app/[locale]/(app)/[orgSlug]/staff/page.tsx",
|
|
245
|
+
"line": 50,
|
|
246
|
+
"call": "reference"
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
"file": "src/app/api/staff/route.ts",
|
|
250
|
+
"line": 12,
|
|
251
|
+
"call": "tools"
|
|
252
|
+
},
|
|
253
|
+
{
|
|
254
|
+
"file": "src/policy.ts",
|
|
255
|
+
"line": 24,
|
|
256
|
+
"call": "reference"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"file": "src/policy.ts",
|
|
260
|
+
"line": 36,
|
|
261
|
+
"call": "reference"
|
|
262
|
+
}
|
|
263
|
+
],
|
|
264
|
+
"rowConditions": false
|
|
265
|
+
},
|
|
266
|
+
{
|
|
267
|
+
"key": "staff.read",
|
|
268
|
+
"scope": "staff:read",
|
|
269
|
+
"resource": "staff",
|
|
270
|
+
"action": "read",
|
|
271
|
+
"arity": "instance",
|
|
272
|
+
"meta": {},
|
|
273
|
+
"usages": [{
|
|
274
|
+
"file": "src/policy.ts",
|
|
275
|
+
"line": 23,
|
|
276
|
+
"call": "reference"
|
|
277
|
+
}, {
|
|
278
|
+
"file": "src/policy.ts",
|
|
279
|
+
"line": 36,
|
|
280
|
+
"call": "reference"
|
|
281
|
+
}],
|
|
282
|
+
"rowConditions": false
|
|
283
|
+
}
|
|
284
|
+
],
|
|
285
|
+
scopes: [{
|
|
286
|
+
"name": "organization",
|
|
287
|
+
"key": "organization_id"
|
|
288
|
+
}, {
|
|
289
|
+
"name": "customer",
|
|
290
|
+
"key": "customer_id",
|
|
291
|
+
"within": "organization"
|
|
292
|
+
}],
|
|
293
|
+
roles: [
|
|
294
|
+
{
|
|
295
|
+
"key": "contact",
|
|
296
|
+
"on": "customer",
|
|
297
|
+
"assignable": false
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"key": "guest",
|
|
301
|
+
"on": "resource",
|
|
302
|
+
"assignable": true
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
"key": "member",
|
|
306
|
+
"on": "organization",
|
|
307
|
+
"assignable": true
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
"key": "owner",
|
|
311
|
+
"on": "organization",
|
|
312
|
+
"assignable": true,
|
|
313
|
+
"min": 1
|
|
314
|
+
}
|
|
315
|
+
],
|
|
316
|
+
grants: [
|
|
317
|
+
{
|
|
318
|
+
"permission": "audit.revert",
|
|
319
|
+
"effect": "allow",
|
|
320
|
+
"role": "owner",
|
|
321
|
+
"to": {
|
|
322
|
+
"kind": "role",
|
|
323
|
+
"role": "owner",
|
|
324
|
+
"scope": "organization"
|
|
325
|
+
},
|
|
326
|
+
"scope": "organization"
|
|
327
|
+
},
|
|
328
|
+
{
|
|
329
|
+
"permission": "audit.view",
|
|
330
|
+
"effect": "allow",
|
|
331
|
+
"role": "owner",
|
|
332
|
+
"to": {
|
|
333
|
+
"kind": "role",
|
|
334
|
+
"role": "owner",
|
|
335
|
+
"scope": "organization"
|
|
336
|
+
},
|
|
337
|
+
"scope": "organization"
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
"permission": "quotes.list",
|
|
341
|
+
"effect": "allow",
|
|
342
|
+
"role": "contact",
|
|
343
|
+
"to": {
|
|
344
|
+
"kind": "role",
|
|
345
|
+
"role": "contact",
|
|
346
|
+
"scope": "customer"
|
|
347
|
+
},
|
|
348
|
+
"scope": "customer"
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
"permission": "quotes.list",
|
|
352
|
+
"effect": "allow",
|
|
353
|
+
"role": "owner",
|
|
354
|
+
"to": {
|
|
355
|
+
"kind": "role",
|
|
356
|
+
"role": "owner",
|
|
357
|
+
"scope": "organization"
|
|
358
|
+
},
|
|
359
|
+
"scope": "organization"
|
|
360
|
+
},
|
|
361
|
+
{
|
|
362
|
+
"permission": "quotes.read",
|
|
363
|
+
"effect": "allow",
|
|
364
|
+
"role": "contact",
|
|
365
|
+
"to": {
|
|
366
|
+
"kind": "role",
|
|
367
|
+
"role": "contact",
|
|
368
|
+
"scope": "customer"
|
|
369
|
+
},
|
|
370
|
+
"scope": "customer"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
"permission": "quotes.read",
|
|
374
|
+
"effect": "allow",
|
|
375
|
+
"role": "guest",
|
|
376
|
+
"to": {
|
|
377
|
+
"kind": "role",
|
|
378
|
+
"role": "guest",
|
|
379
|
+
"scope": { "resource": "quotes" }
|
|
380
|
+
},
|
|
381
|
+
"scope": { "resource": "quotes" }
|
|
382
|
+
},
|
|
383
|
+
{
|
|
384
|
+
"permission": "quotes.read",
|
|
385
|
+
"effect": "allow",
|
|
386
|
+
"role": "owner",
|
|
387
|
+
"to": {
|
|
388
|
+
"kind": "role",
|
|
389
|
+
"role": "owner",
|
|
390
|
+
"scope": "organization"
|
|
391
|
+
},
|
|
392
|
+
"scope": "organization"
|
|
393
|
+
},
|
|
394
|
+
{
|
|
395
|
+
"permission": "quotes.update",
|
|
396
|
+
"effect": "allow",
|
|
397
|
+
"role": "owner",
|
|
398
|
+
"to": {
|
|
399
|
+
"kind": "role",
|
|
400
|
+
"role": "owner",
|
|
401
|
+
"scope": "organization"
|
|
402
|
+
},
|
|
403
|
+
"scope": "organization"
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
"permission": "staff.list",
|
|
407
|
+
"effect": "allow",
|
|
408
|
+
"role": "member",
|
|
409
|
+
"to": {
|
|
410
|
+
"kind": "role",
|
|
411
|
+
"role": "member",
|
|
412
|
+
"scope": "organization"
|
|
413
|
+
},
|
|
414
|
+
"scope": "organization"
|
|
415
|
+
},
|
|
416
|
+
{
|
|
417
|
+
"permission": "staff.list",
|
|
418
|
+
"effect": "allow",
|
|
419
|
+
"role": "owner",
|
|
420
|
+
"to": {
|
|
421
|
+
"kind": "role",
|
|
422
|
+
"role": "owner",
|
|
423
|
+
"scope": "organization"
|
|
424
|
+
},
|
|
425
|
+
"scope": "organization"
|
|
426
|
+
},
|
|
427
|
+
{
|
|
428
|
+
"permission": "staff.read",
|
|
429
|
+
"effect": "allow",
|
|
430
|
+
"role": "member",
|
|
431
|
+
"to": {
|
|
432
|
+
"kind": "role",
|
|
433
|
+
"role": "member",
|
|
434
|
+
"scope": "organization"
|
|
435
|
+
},
|
|
436
|
+
"scope": "organization"
|
|
437
|
+
},
|
|
438
|
+
{
|
|
439
|
+
"permission": "staff.read",
|
|
440
|
+
"effect": "allow",
|
|
441
|
+
"role": "owner",
|
|
442
|
+
"to": {
|
|
443
|
+
"kind": "role",
|
|
444
|
+
"role": "owner",
|
|
445
|
+
"scope": "organization"
|
|
446
|
+
},
|
|
447
|
+
"scope": "organization"
|
|
448
|
+
}
|
|
449
|
+
],
|
|
450
|
+
delegations: [{
|
|
451
|
+
"from": {
|
|
452
|
+
"kind": "role",
|
|
453
|
+
"role": "owner",
|
|
454
|
+
"scope": "organization"
|
|
455
|
+
},
|
|
456
|
+
"to": { "kind": "agent" },
|
|
457
|
+
"permissions": [
|
|
458
|
+
"quotes.list",
|
|
459
|
+
"quotes.read",
|
|
460
|
+
"quotes.update"
|
|
461
|
+
]
|
|
462
|
+
}, {
|
|
463
|
+
"from": {
|
|
464
|
+
"kind": "role",
|
|
465
|
+
"role": "owner",
|
|
466
|
+
"scope": "organization"
|
|
467
|
+
},
|
|
468
|
+
"to": { "kind": "support" },
|
|
469
|
+
"permissions": [
|
|
470
|
+
"quotes.list",
|
|
471
|
+
"quotes.read",
|
|
472
|
+
"quotes.update"
|
|
473
|
+
]
|
|
474
|
+
}]
|
|
475
|
+
};
|
|
476
|
+
//#endregion
|
|
477
|
+
//#region src/testing/fixtures/better-supabase.manifest.json
|
|
478
|
+
var better_supabase_manifest_default = {
|
|
479
|
+
$schema: "https://permdock.com/schemas/supabase-manifest-v1.json",
|
|
480
|
+
version: 1,
|
|
481
|
+
hook: {
|
|
482
|
+
"schema": "permdock",
|
|
483
|
+
"function": "custom_access_token_hook",
|
|
484
|
+
"out": "supabase/schemas/permdock/functions/custom_access_token_hook.sql",
|
|
485
|
+
"schemas": "pg-delta"
|
|
486
|
+
},
|
|
487
|
+
helpers: {
|
|
488
|
+
"schema": "permdock",
|
|
489
|
+
"functions": [
|
|
490
|
+
"permdock_has",
|
|
491
|
+
"permitted_organization_ids",
|
|
492
|
+
"member_organization_ids",
|
|
493
|
+
"member_organization_ids_for",
|
|
494
|
+
"permitted_customer_ids",
|
|
495
|
+
"member_customer_ids",
|
|
496
|
+
"member_customer_ids_for"
|
|
497
|
+
]
|
|
498
|
+
},
|
|
499
|
+
tenantClaim: "tenant_id",
|
|
500
|
+
budget: {
|
|
501
|
+
"bytes": 1024,
|
|
502
|
+
"measure": "octet_length(memberships::text) + octet_length(attrs::text)"
|
|
503
|
+
},
|
|
504
|
+
claims: [
|
|
505
|
+
{
|
|
506
|
+
"name": "user_role",
|
|
507
|
+
"source": "permdock",
|
|
508
|
+
"budget": false
|
|
509
|
+
},
|
|
510
|
+
{
|
|
511
|
+
"name": "roles",
|
|
512
|
+
"source": "permdock",
|
|
513
|
+
"budget": false
|
|
514
|
+
},
|
|
515
|
+
{
|
|
516
|
+
"name": "memberships",
|
|
517
|
+
"source": "permdock",
|
|
518
|
+
"budget": true
|
|
519
|
+
},
|
|
520
|
+
{
|
|
521
|
+
"name": "memberships_truncated",
|
|
522
|
+
"source": "permdock",
|
|
523
|
+
"budget": false
|
|
524
|
+
},
|
|
525
|
+
{
|
|
526
|
+
"name": "tenant_id",
|
|
527
|
+
"source": "permdock",
|
|
528
|
+
"budget": false
|
|
529
|
+
},
|
|
530
|
+
{
|
|
531
|
+
"name": "authz_ver",
|
|
532
|
+
"source": "permdock",
|
|
533
|
+
"budget": false
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
"name": "datetime_preferences",
|
|
537
|
+
"source": "public.datetime_preference_claims",
|
|
538
|
+
"budget": false
|
|
539
|
+
},
|
|
540
|
+
{
|
|
541
|
+
"name": "features",
|
|
542
|
+
"source": "public.feature_claims",
|
|
543
|
+
"budget": false
|
|
544
|
+
}
|
|
545
|
+
],
|
|
546
|
+
authzVersion: true,
|
|
547
|
+
authzVersionBump: {
|
|
548
|
+
"schema": "permdock",
|
|
549
|
+
"function": "permdock_bump_authz_version_for",
|
|
550
|
+
"args": "p_users uuid[]"
|
|
551
|
+
},
|
|
552
|
+
memberships: [{
|
|
553
|
+
"table": "public.memberships",
|
|
554
|
+
"user": { "column": "user_id" },
|
|
555
|
+
"scope": { "column": "scope" },
|
|
556
|
+
"id": { "column": "scope_id" },
|
|
557
|
+
"role": { "column": "role" },
|
|
558
|
+
"columns": [
|
|
559
|
+
"user_id",
|
|
560
|
+
"scope",
|
|
561
|
+
"scope_id",
|
|
562
|
+
"role"
|
|
563
|
+
]
|
|
564
|
+
}, {
|
|
565
|
+
"table": "public.contacts",
|
|
566
|
+
"user": { "column": "user_id" },
|
|
567
|
+
"scope": { "value": "customer" },
|
|
568
|
+
"id": { "column": "customer_id" },
|
|
569
|
+
"role": { "value": ["contact"] },
|
|
570
|
+
"within": { "columns": { "organization": "organization_id" } },
|
|
571
|
+
"via": { "value": "contact" },
|
|
572
|
+
"columns": [
|
|
573
|
+
"user_id",
|
|
574
|
+
"customer_id",
|
|
575
|
+
"organization_id"
|
|
576
|
+
]
|
|
577
|
+
}],
|
|
578
|
+
rls: {
|
|
579
|
+
"schema": "permdock",
|
|
580
|
+
"mode": "database",
|
|
581
|
+
"tenantClaim": "tenant_id",
|
|
582
|
+
"scopes": [{
|
|
583
|
+
"name": "organization",
|
|
584
|
+
"type": "uuid"
|
|
585
|
+
}, {
|
|
586
|
+
"name": "customer",
|
|
587
|
+
"type": "uuid",
|
|
588
|
+
"within": "organization"
|
|
589
|
+
}],
|
|
590
|
+
"helpers": [
|
|
591
|
+
{
|
|
592
|
+
"name": "permdock_has",
|
|
593
|
+
"args": "p_grant text",
|
|
594
|
+
"returns": "boolean",
|
|
595
|
+
"execute": ["authenticated"]
|
|
596
|
+
},
|
|
597
|
+
{
|
|
598
|
+
"name": "permitted_organization_ids",
|
|
599
|
+
"args": "p_grant text",
|
|
600
|
+
"returns": "setof uuid",
|
|
601
|
+
"execute": ["authenticated"]
|
|
602
|
+
},
|
|
603
|
+
{
|
|
604
|
+
"name": "member_organization_ids",
|
|
605
|
+
"args": "",
|
|
606
|
+
"returns": "setof uuid",
|
|
607
|
+
"execute": ["authenticated"]
|
|
608
|
+
},
|
|
609
|
+
{
|
|
610
|
+
"name": "member_organization_ids_for",
|
|
611
|
+
"args": "p_user uuid",
|
|
612
|
+
"returns": "setof uuid",
|
|
613
|
+
"execute": ["supabase_auth_admin"]
|
|
614
|
+
},
|
|
615
|
+
{
|
|
616
|
+
"name": "permitted_customer_ids",
|
|
617
|
+
"args": "p_grant text",
|
|
618
|
+
"returns": "setof uuid",
|
|
619
|
+
"execute": ["authenticated"]
|
|
620
|
+
},
|
|
621
|
+
{
|
|
622
|
+
"name": "member_customer_ids",
|
|
623
|
+
"args": "",
|
|
624
|
+
"returns": "setof uuid",
|
|
625
|
+
"execute": ["authenticated"]
|
|
626
|
+
},
|
|
627
|
+
{
|
|
628
|
+
"name": "member_customer_ids_for",
|
|
629
|
+
"args": "p_user uuid",
|
|
630
|
+
"returns": "setof uuid",
|
|
631
|
+
"execute": ["supabase_auth_admin"]
|
|
632
|
+
},
|
|
633
|
+
{
|
|
634
|
+
"name": "permdock_user_id",
|
|
635
|
+
"args": "",
|
|
636
|
+
"returns": "uuid",
|
|
637
|
+
"execute": ["authenticated"]
|
|
638
|
+
},
|
|
639
|
+
{
|
|
640
|
+
"name": "permdock_actor_may_write",
|
|
641
|
+
"args": "",
|
|
642
|
+
"returns": "boolean",
|
|
643
|
+
"execute": ["authenticated"]
|
|
644
|
+
},
|
|
645
|
+
{
|
|
646
|
+
"name": "permdock_is_approver",
|
|
647
|
+
"args": "p_approvers jsonb, p_tenant text, p_requester text, p_resource text",
|
|
648
|
+
"returns": "boolean",
|
|
649
|
+
"execute": ["authenticated"]
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
"name": "permdock_has_for",
|
|
653
|
+
"args": "p_user uuid, p_grant text",
|
|
654
|
+
"returns": "boolean",
|
|
655
|
+
"execute": []
|
|
656
|
+
},
|
|
657
|
+
{
|
|
658
|
+
"name": "permitted_organization_ids_for",
|
|
659
|
+
"args": "p_user uuid, p_grant text",
|
|
660
|
+
"returns": "setof uuid",
|
|
661
|
+
"execute": []
|
|
662
|
+
},
|
|
663
|
+
{
|
|
664
|
+
"name": "permitted_customer_ids_for",
|
|
665
|
+
"args": "p_user uuid, p_grant text",
|
|
666
|
+
"returns": "setof uuid",
|
|
667
|
+
"execute": []
|
|
668
|
+
},
|
|
669
|
+
{
|
|
670
|
+
"name": "permitted_organization_permission_keys_for",
|
|
671
|
+
"args": "p_user uuid, p_id uuid",
|
|
672
|
+
"returns": "setof text",
|
|
673
|
+
"execute": []
|
|
674
|
+
},
|
|
675
|
+
{
|
|
676
|
+
"name": "permitted_customer_permission_keys_for",
|
|
677
|
+
"args": "p_user uuid, p_id uuid",
|
|
678
|
+
"returns": "setof text",
|
|
679
|
+
"execute": []
|
|
680
|
+
},
|
|
681
|
+
{
|
|
682
|
+
"name": "permitted_organization_users",
|
|
683
|
+
"args": "p_permission text, p_id uuid",
|
|
684
|
+
"returns": "setof uuid",
|
|
685
|
+
"execute": []
|
|
686
|
+
},
|
|
687
|
+
{
|
|
688
|
+
"name": "permitted_customer_users",
|
|
689
|
+
"args": "p_permission text, p_id uuid",
|
|
690
|
+
"returns": "setof uuid",
|
|
691
|
+
"execute": []
|
|
692
|
+
}
|
|
693
|
+
],
|
|
694
|
+
"memberships": [{
|
|
695
|
+
"table": "public.memberships",
|
|
696
|
+
"user": { "column": "user_id" },
|
|
697
|
+
"scope": { "column": "scope" },
|
|
698
|
+
"id": { "column": "scope_id" },
|
|
699
|
+
"role": { "column": "role" },
|
|
700
|
+
"columns": [
|
|
701
|
+
"user_id",
|
|
702
|
+
"scope",
|
|
703
|
+
"scope_id",
|
|
704
|
+
"role"
|
|
705
|
+
]
|
|
706
|
+
}, {
|
|
707
|
+
"table": "public.contacts",
|
|
708
|
+
"user": { "column": "user_id" },
|
|
709
|
+
"scope": { "value": "customer" },
|
|
710
|
+
"id": { "column": "customer_id" },
|
|
711
|
+
"role": { "value": ["contact"] },
|
|
712
|
+
"within": { "columns": { "organization": "organization_id" } },
|
|
713
|
+
"via": { "value": "contact" },
|
|
714
|
+
"columns": [
|
|
715
|
+
"user_id",
|
|
716
|
+
"customer_id",
|
|
717
|
+
"organization_id"
|
|
718
|
+
]
|
|
719
|
+
}],
|
|
720
|
+
"customRoles": true,
|
|
721
|
+
"roles": {
|
|
722
|
+
"table": "permdock.user_roles",
|
|
723
|
+
"user": { "column": "user_id" },
|
|
724
|
+
"role": { "column": "role" }
|
|
725
|
+
}
|
|
726
|
+
},
|
|
727
|
+
decidingColumns: [
|
|
728
|
+
"public.contacts.customer_id",
|
|
729
|
+
"public.contacts.organization_id",
|
|
730
|
+
"public.contacts.user_id",
|
|
731
|
+
"public.memberships.role",
|
|
732
|
+
"public.memberships.scope",
|
|
733
|
+
"public.memberships.scope_id",
|
|
734
|
+
"public.memberships.user_id"
|
|
735
|
+
],
|
|
736
|
+
markers: {
|
|
737
|
+
"hook": "v1",
|
|
738
|
+
"grants": "v1"
|
|
739
|
+
},
|
|
740
|
+
requires: {
|
|
741
|
+
"matrix": "capability-matrix-v1.12.0",
|
|
742
|
+
"capabilities": [
|
|
743
|
+
"auth.session.get_claims",
|
|
744
|
+
"realtime.subscriptions.private_channel",
|
|
745
|
+
"storage.file_buckets.download",
|
|
746
|
+
"storage.file_buckets.list_files",
|
|
747
|
+
"storage.file_buckets.move",
|
|
748
|
+
"storage.file_buckets.remove",
|
|
749
|
+
"storage.file_buckets.update_file",
|
|
750
|
+
"storage.file_buckets.upload"
|
|
751
|
+
]
|
|
752
|
+
},
|
|
753
|
+
managementApi: {
|
|
754
|
+
"hook_custom_access_token_enabled": true,
|
|
755
|
+
"hook_custom_access_token_uri": "pg-functions://postgres/permdock/custom_access_token_hook",
|
|
756
|
+
"jwt_exp": 3600
|
|
757
|
+
}
|
|
758
|
+
};
|
|
759
|
+
//#endregion
|
|
760
|
+
//#region src/testing/fixtures/index.ts
|
|
761
|
+
/**
|
|
762
|
+
* The `permissions.catalog.json` of `apps/examples/next-better-supabase`, a
|
|
763
|
+
* `catalog-v1` document with resources, permissions, scopes, roles, grants
|
|
764
|
+
* and delegations, for testing a catalog consumer such as a Cloud.
|
|
765
|
+
*/
|
|
766
|
+
const betterSupabaseCatalog = parseCatalog(better_supabase_catalog_default);
|
|
767
|
+
/** The `permdock.manifest.json` of the same app, a `supabase-manifest-v1` document. */
|
|
768
|
+
const betterSupabaseManifest = parseSupabaseManifest(better_supabase_manifest_default);
|
|
769
|
+
//#endregion
|
|
770
|
+
export { betterSupabaseCatalog, betterSupabaseManifest };
|