Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

feat: add API key policy for supplierProcess table

Rob Carringtonb5ac7614de18
diff --git a/packages/database/supabase/migrations/20240829135223_supplierProcess-api-key-access.sql b/packages/database/supabase/migrations/20240829135223_supplierProcess-api-key-access.sql
new file mode 100644
index 0000000000..4ea1258b89
--- /dev/null
+++ b/packages/database/supabase/migrations/20240829135223_supplierProcess-api-key-access.sql
@@ -0,0 +1,5 @@
+-- supplierProcess
+CREATE POLICY "Requests with an API key can access supplier processes" ON "supplierProcess"
+FOR ALL USING (
+ has_valid_api_key_for_company("companyId")
+);
\ No newline at end of file