Postgres-centric workflow engine with deep integration with Supabase
See the code
AI workflows in Supabase, no extra infra.
TypeScript workflows with full autocomplete, zero boilerplate, automatic retries and realtime progress. Built on Postgres + Edge Functions.
Docs |
Demo |
GitHub |
Discord
"A workflow engine built on Supabase primitives."
Paul Copplestone, CEO, Supabase (via X)
# Install pgflow in your Supabase project
npx pgflow@latest install
# Restart Supabase and apply migrations
npx supabase stop && npx supabase start
npx supabase migrations up
Then define your workflow (full guide):
import { Flow } from '@pgflow/dsl';
new Flow<{ url: string }>({ slug: 'analyzeArticle' })
.step({ slug: 'scrape' }, (flowInput) => scrapeWebsite(flowInput.url))
.step({ slug: 'summarize', dependsOn: ['scrape'] }, (deps) =>
summarize(deps.scrape)
)
.step({ slug: 'extractKeywords', dependsOn: ['scrape'] }, (deps) =>
extractKeywords(deps.scrape)
)
.step(
{ slug: 'publish', dependsOn: ['summarize', 'extractKeywords'] },
(deps) =>
publish({ summary: deps.summarize, keywords: deps.extractKeywords })
);
This replaces ~240 lines of queue setup, state management, and coordination code. See full comparison
Building workflows in Supabase today means wiring together pgmq, pg_cron, state tables, and Edge Functions yourself. It works, but it's tedious.
pgflow gives you:
See how pgflow compares to Trigger.dev, Inngest, DBOS, and Vercel Workflows.
The execution engine handles scheduling, retries, and result aggregation automatically.
| Package | Version | Description |
|---|---|---|
| pgflow | CLI for installing pgflow into your Supabase project | |
| @pgflow/core | SQL Core - foundational tables and functions | |
| @pgflow/dsl | TypeScript DSL for defining flows with type inference | |
| @pgflow/edge-worker | Task queue worker for Supabase Edge Functions | |
| @pgflow/client | TypeScript client for starting and monitoring workflows |
[!NOTE] This project and all its components are licensed under Apache 2.0 license.
PLpgSQL
39.4%
TypeScript
38.3%
MDX
11.5%
Shell
4.0%
Svelte
3.0%
JavaScript
1.8%
Astro
1.3%
Postgres-centric workflow engine with deep integration with Supabase
See the code
AI workflows in Supabase, no extra infra.
TypeScript workflows with full autocomplete, zero boilerplate, automatic retries and realtime progress. Built on Postgres + Edge Functions.
Docs |
Demo |
GitHub |
Discord
"A workflow engine built on Supabase primitives."
Paul Copplestone, CEO, Supabase (via X)
# Install pgflow in your Supabase project
npx pgflow@latest install
# Restart Supabase and apply migrations
npx supabase stop && npx supabase start
npx supabase migrations up
Then define your workflow (full guide):
import { Flow } from '@pgflow/dsl';
new Flow<{ url: string }>({ slug: 'analyzeArticle' })
.step({ slug: 'scrape' }, (flowInput) => scrapeWebsite(flowInput.url))
.step({ slug: 'summarize', dependsOn: ['scrape'] }, (deps) =>
summarize(deps.scrape)
)
.step({ slug: 'extractKeywords', dependsOn: ['scrape'] }, (deps) =>
extractKeywords(deps.scrape)
)
.step(
{ slug: 'publish', dependsOn: ['summarize', 'extractKeywords'] },
(deps) =>
publish({ summary: deps.summarize, keywords: deps.extractKeywords })
);
This replaces ~240 lines of queue setup, state management, and coordination code. See full comparison
Building workflows in Supabase today means wiring together pgmq, pg_cron, state tables, and Edge Functions yourself. It works, but it's tedious.
pgflow gives you:
See how pgflow compares to Trigger.dev, Inngest, DBOS, and Vercel Workflows.
The execution engine handles scheduling, retries, and result aggregation automatically.
| Package | Version | Description |
|---|---|---|
| pgflow | CLI for installing pgflow into your Supabase project | |
| @pgflow/core | SQL Core - foundational tables and functions | |
| @pgflow/dsl | TypeScript DSL for defining flows with type inference | |
| @pgflow/edge-worker | Task queue worker for Supabase Edge Functions | |
| @pgflow/client | TypeScript client for starting and monitoring workflows |
[!NOTE] This project and all its components are licensed under Apache 2.0 license.
PLpgSQL
39.4%
TypeScript
38.3%
MDX
11.5%
Shell
4.0%
Svelte
3.0%
JavaScript
1.8%
Astro
1.3%