@pgflow/dsl 0.5.3 → 0.5.4
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 +88 -7
- package/dist/CHANGELOG.md +41 -0
- package/dist/README.md +88 -7
- package/dist/dsl.d.ts +42 -16
- package/dist/dsl.d.ts.map +1 -1
- package/dist/dsl.js +1 -1
- package/dist/example-flow.d.ts +1 -1
- package/dist/package.json +12 -2
- package/dist/platforms/index.d.ts +2 -0
- package/dist/platforms/index.d.ts.map +1 -0
- package/dist/platforms/index.js +2 -0
- package/dist/platforms/supabase.d.ts +30 -0
- package/dist/platforms/supabase.d.ts.map +1 -0
- package/dist/platforms/supabase.js +4 -0
- package/dist/supabase.d.ts +2 -0
- package/dist/supabase.d.ts.map +1 -0
- package/dist/supabase.js +2 -0
- package/package.json +12 -2
package/README.md
CHANGED
|
@@ -13,7 +13,7 @@ Key features:
|
|
|
13
13
|
|
|
14
14
|
- **Type Safety** - Complete TypeScript type checking from flow inputs to outputs
|
|
15
15
|
- **Fluent Interface** - Chainable method calls for defining steps and dependencies
|
|
16
|
-
- **Functional Approach** - Clean separation between task implementation and flow orchestration
|
|
16
|
+
- **Functional Approach** - Clean separation between task implementation and flow orchestration
|
|
17
17
|
- **JSON-Compatible** - All inputs and outputs are JSON-serializable for database storage
|
|
18
18
|
- **Immutable Flow Definitions** - Each step operation returns a new Flow instance
|
|
19
19
|
|
|
@@ -68,21 +68,101 @@ In pgflow, each step receives an `input` object that contains:
|
|
|
68
68
|
2. **`input.{stepName}`** - Outputs from dependency steps
|
|
69
69
|
|
|
70
70
|
This design ensures:
|
|
71
|
+
|
|
71
72
|
- Original flow parameters are accessible throughout the entire flow
|
|
72
73
|
- Data doesn't need to be manually forwarded through intermediate steps
|
|
73
74
|
- Steps can combine original input with processed data from previous steps
|
|
74
75
|
|
|
76
|
+
### Context Object
|
|
77
|
+
|
|
78
|
+
Step handlers can optionally receive a second parameter - the **context object** - which provides access to platform resources and runtime information.
|
|
79
|
+
|
|
80
|
+
```typescript
|
|
81
|
+
.step(
|
|
82
|
+
{ slug: 'saveToDb' },
|
|
83
|
+
async (input, context) => {
|
|
84
|
+
// Access platform resources through context
|
|
85
|
+
const result = await context.sql`SELECT * FROM users WHERE id = ${input.userId}`;
|
|
86
|
+
return result[0];
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
#### Core Context Resources
|
|
92
|
+
|
|
93
|
+
All platforms provide these core resources:
|
|
94
|
+
|
|
95
|
+
- **`context.env`** - Environment variables (`Record<string, string | undefined>`)
|
|
96
|
+
- **`context.shutdownSignal`** - AbortSignal for graceful shutdown handling
|
|
97
|
+
- **`context.rawMessage`** - Original pgmq message with metadata
|
|
98
|
+
```typescript
|
|
99
|
+
interface PgmqMessageRecord<T> {
|
|
100
|
+
msg_id: number;
|
|
101
|
+
read_ct: number;
|
|
102
|
+
enqueued_at: Date;
|
|
103
|
+
vt: Date;
|
|
104
|
+
message: T; // <-- this is your 'input'
|
|
105
|
+
}
|
|
106
|
+
```
|
|
107
|
+
- **`context.stepTask`** - Current step task details (flow handlers only)
|
|
108
|
+
```typescript
|
|
109
|
+
interface StepTaskRecord<TFlow> {
|
|
110
|
+
flow_slug: string;
|
|
111
|
+
run_id: string;
|
|
112
|
+
step_slug: string;
|
|
113
|
+
input: StepInput<TFlow, StepSlug>; // <-- this is handler 'input'
|
|
114
|
+
msg_id: number;
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
#### Supabase Platform Resources
|
|
119
|
+
|
|
120
|
+
When using the Supabase platform with EdgeWorker, additional resources are available:
|
|
121
|
+
|
|
122
|
+
- **`context.sql`** - PostgreSQL client (postgres.js)
|
|
123
|
+
- **`context.anonSupabase`** - Supabase client with anonymous key
|
|
124
|
+
- **`context.serviceSupabase`** - Supabase client with service role key
|
|
125
|
+
|
|
126
|
+
To use Supabase resources, import the `Flow` class from the Supabase preset:
|
|
127
|
+
|
|
128
|
+
```typescript
|
|
129
|
+
import { Flow } from '@pgflow/dsl/supabase';
|
|
130
|
+
|
|
131
|
+
const MyFlow = new Flow<{ userId: string }>({
|
|
132
|
+
slug: 'my_flow',
|
|
133
|
+
}).step({ slug: 'process' }, async (input, context) => {
|
|
134
|
+
// TypeScript knows context includes Supabase resources
|
|
135
|
+
const { data } = await context.serviceSupabase
|
|
136
|
+
.from('users')
|
|
137
|
+
.select('*')
|
|
138
|
+
.eq('id', input.userId);
|
|
139
|
+
|
|
140
|
+
// Use SQL directly
|
|
141
|
+
const stats = await context.sql`
|
|
142
|
+
SELECT COUNT(*) as total FROM events
|
|
143
|
+
WHERE user_id = ${input.userId}
|
|
144
|
+
`;
|
|
145
|
+
|
|
146
|
+
return { user: data[0], eventCount: stats[0].total };
|
|
147
|
+
});
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
> [!NOTE]
|
|
151
|
+
> Context is optional - handlers that don't need platform resources can omit the second parameter for backward compatibility.
|
|
152
|
+
|
|
153
|
+
For more details on available resources and platform configuration, see the [@pgflow/edge-worker documentation](https://github.com/pgflow-org/pgflow/tree/main/pkgs/edge-worker#context-resources).
|
|
154
|
+
|
|
75
155
|
### Flow Configuration
|
|
76
156
|
|
|
77
157
|
Configure flows and steps with runtime options:
|
|
78
158
|
|
|
79
159
|
```typescript
|
|
80
160
|
new Flow<Input>({
|
|
81
|
-
slug: 'my_flow',
|
|
82
|
-
maxAttempts: 3,
|
|
83
|
-
baseDelay: 5,
|
|
84
|
-
timeout: 10,
|
|
85
|
-
})
|
|
161
|
+
slug: 'my_flow', // Required: Unique flow identifier
|
|
162
|
+
maxAttempts: 3, // Optional: Maximum retry attempts (default: 1)
|
|
163
|
+
baseDelay: 5, // Optional: Base delay in seconds for retries (default: 1)
|
|
164
|
+
timeout: 10, // Optional: Task timeout in seconds (default: 30)
|
|
165
|
+
});
|
|
86
166
|
```
|
|
87
167
|
|
|
88
168
|
## Compiling Flows
|
|
@@ -120,4 +200,5 @@ Run `nx test dsl` to execute the unit tests via [Vitest](https://vitest.dev/).
|
|
|
120
200
|
## Documentation
|
|
121
201
|
|
|
122
202
|
For detailed documentation on the Flow DSL, visit:
|
|
123
|
-
|
|
203
|
+
|
|
204
|
+
- [Understanding the Flow DSL](https://pgflow.dev/explanations/flow-dsl/)
|
package/dist/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,46 @@
|
|
|
1
1
|
# @pgflow/dsl
|
|
2
2
|
|
|
3
|
+
## 0.5.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 9f219a4: Add context object as second parameter to handlers
|
|
8
|
+
|
|
9
|
+
Queue and flow handlers now receive an optional context parameter that provides platform resources like database connections, environment variables, and Supabase clients - eliminating boilerplate and connection management.
|
|
10
|
+
|
|
11
|
+
```typescript
|
|
12
|
+
// Queue handler
|
|
13
|
+
EdgeWorker.start(async (payload, context) => {
|
|
14
|
+
await context.sql`INSERT INTO tasks (data) VALUES (${payload})`;
|
|
15
|
+
});
|
|
16
|
+
|
|
17
|
+
// Flow step handler
|
|
18
|
+
.step({ slug: 'process' }, async (input, context) => {
|
|
19
|
+
const result = await context.serviceSupabase.from('users').select();
|
|
20
|
+
})
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
**Core resources** (always available):
|
|
24
|
+
|
|
25
|
+
- `context.env` - Environment variables
|
|
26
|
+
- `context.shutdownSignal` - AbortSignal for graceful shutdown
|
|
27
|
+
- `context.rawMessage` - Original pgmq message with metadata
|
|
28
|
+
- `context.stepTask` - Current step task details (flow handlers only)
|
|
29
|
+
|
|
30
|
+
**Supabase platform resources**:
|
|
31
|
+
|
|
32
|
+
- `context.sql` - PostgreSQL client (postgres.js)
|
|
33
|
+
- `context.anonSupabase` - Supabase client with anonymous key
|
|
34
|
+
- `context.serviceSupabase` - Supabase client with service role key
|
|
35
|
+
|
|
36
|
+
To use Supabase resources in flows, import from the Supabase preset:
|
|
37
|
+
|
|
38
|
+
```typescript
|
|
39
|
+
import { Flow } from '@pgflow/dsl/supabase';
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
The context parameter is optional for backward compatibility - existing single-parameter handlers continue to work unchanged.
|
|
43
|
+
|
|
3
44
|
## 0.5.3
|
|
4
45
|
|
|
5
46
|
### Patch Changes
|
package/dist/README.md
CHANGED
|
@@ -13,7 +13,7 @@ Key features:
|
|
|
13
13
|
|
|
14
14
|
- **Type Safety** - Complete TypeScript type checking from flow inputs to outputs
|
|
15
15
|
- **Fluent Interface** - Chainable method calls for defining steps and dependencies
|
|
16
|
-
- **Functional Approach** - Clean separation between task implementation and flow orchestration
|
|
16
|
+
- **Functional Approach** - Clean separation between task implementation and flow orchestration
|
|
17
17
|
- **JSON-Compatible** - All inputs and outputs are JSON-serializable for database storage
|
|
18
18
|
- **Immutable Flow Definitions** - Each step operation returns a new Flow instance
|
|
19
19
|
|
|
@@ -68,21 +68,101 @@ In pgflow, each step receives an `input` object that contains:
|
|
|
68
68
|
2. **`input.{stepName}`** - Outputs from dependency steps
|
|
69
69
|
|
|
70
70
|
This design ensures:
|
|
71
|
+
|
|
71
72
|
- Original flow parameters are accessible throughout the entire flow
|
|
72
73
|
- Data doesn't need to be manually forwarded through intermediate steps
|
|
73
74
|
- Steps can combine original input with processed data from previous steps
|
|
74
75
|
|
|
76
|
+
### Context Object
|
|
77
|
+
|
|
78
|
+
Step handlers can optionally receive a second parameter - the **context object** - which provides access to platform resources and runtime information.
|
|
79
|
+
|
|
80
|
+
```typescript
|
|
81
|
+
.step(
|
|
82
|
+
{ slug: 'saveToDb' },
|
|
83
|
+
async (input, context) => {
|
|
84
|
+
// Access platform resources through context
|
|
85
|
+
const result = await context.sql`SELECT * FROM users WHERE id = ${input.userId}`;
|
|
86
|
+
return result[0];
|
|
87
|
+
}
|
|
88
|
+
)
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
#### Core Context Resources
|
|
92
|
+
|
|
93
|
+
All platforms provide these core resources:
|
|
94
|
+
|
|
95
|
+
- **`context.env`** - Environment variables (`Record<string, string | undefined>`)
|
|
96
|
+
- **`context.shutdownSignal`** - AbortSignal for graceful shutdown handling
|
|
97
|
+
- **`context.rawMessage`** - Original pgmq message with metadata
|
|
98
|
+
```typescript
|
|
99
|
+
interface PgmqMessageRecord<T> {
|
|
100
|
+
msg_id: number;
|
|
101
|
+
read_ct: number;
|
|
102
|
+
enqueued_at: Date;
|
|
103
|
+
vt: Date;
|
|
104
|
+
message: T; // <-- this is your 'input'
|
|
105
|
+
}
|
|
106
|
+
```
|
|
107
|
+
- **`context.stepTask`** - Current step task details (flow handlers only)
|
|
108
|
+
```typescript
|
|
109
|
+
interface StepTaskRecord<TFlow> {
|
|
110
|
+
flow_slug: string;
|
|
111
|
+
run_id: string;
|
|
112
|
+
step_slug: string;
|
|
113
|
+
input: StepInput<TFlow, StepSlug>; // <-- this is handler 'input'
|
|
114
|
+
msg_id: number;
|
|
115
|
+
}
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
#### Supabase Platform Resources
|
|
119
|
+
|
|
120
|
+
When using the Supabase platform with EdgeWorker, additional resources are available:
|
|
121
|
+
|
|
122
|
+
- **`context.sql`** - PostgreSQL client (postgres.js)
|
|
123
|
+
- **`context.anonSupabase`** - Supabase client with anonymous key
|
|
124
|
+
- **`context.serviceSupabase`** - Supabase client with service role key
|
|
125
|
+
|
|
126
|
+
To use Supabase resources, import the `Flow` class from the Supabase preset:
|
|
127
|
+
|
|
128
|
+
```typescript
|
|
129
|
+
import { Flow } from '@pgflow/dsl/supabase';
|
|
130
|
+
|
|
131
|
+
const MyFlow = new Flow<{ userId: string }>({
|
|
132
|
+
slug: 'my_flow',
|
|
133
|
+
}).step({ slug: 'process' }, async (input, context) => {
|
|
134
|
+
// TypeScript knows context includes Supabase resources
|
|
135
|
+
const { data } = await context.serviceSupabase
|
|
136
|
+
.from('users')
|
|
137
|
+
.select('*')
|
|
138
|
+
.eq('id', input.userId);
|
|
139
|
+
|
|
140
|
+
// Use SQL directly
|
|
141
|
+
const stats = await context.sql`
|
|
142
|
+
SELECT COUNT(*) as total FROM events
|
|
143
|
+
WHERE user_id = ${input.userId}
|
|
144
|
+
`;
|
|
145
|
+
|
|
146
|
+
return { user: data[0], eventCount: stats[0].total };
|
|
147
|
+
});
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
> [!NOTE]
|
|
151
|
+
> Context is optional - handlers that don't need platform resources can omit the second parameter for backward compatibility.
|
|
152
|
+
|
|
153
|
+
For more details on available resources and platform configuration, see the [@pgflow/edge-worker documentation](https://github.com/pgflow-org/pgflow/tree/main/pkgs/edge-worker#context-resources).
|
|
154
|
+
|
|
75
155
|
### Flow Configuration
|
|
76
156
|
|
|
77
157
|
Configure flows and steps with runtime options:
|
|
78
158
|
|
|
79
159
|
```typescript
|
|
80
160
|
new Flow<Input>({
|
|
81
|
-
slug: 'my_flow',
|
|
82
|
-
maxAttempts: 3,
|
|
83
|
-
baseDelay: 5,
|
|
84
|
-
timeout: 10,
|
|
85
|
-
})
|
|
161
|
+
slug: 'my_flow', // Required: Unique flow identifier
|
|
162
|
+
maxAttempts: 3, // Optional: Maximum retry attempts (default: 1)
|
|
163
|
+
baseDelay: 5, // Optional: Base delay in seconds for retries (default: 1)
|
|
164
|
+
timeout: 10, // Optional: Task timeout in seconds (default: 30)
|
|
165
|
+
});
|
|
86
166
|
```
|
|
87
167
|
|
|
88
168
|
## Compiling Flows
|
|
@@ -120,4 +200,5 @@ Run `nx test dsl` to execute the unit tests via [Vitest](https://vitest.dev/).
|
|
|
120
200
|
## Documentation
|
|
121
201
|
|
|
122
202
|
For detailed documentation on the Flow DSL, visit:
|
|
123
|
-
|
|
203
|
+
|
|
204
|
+
- [Understanding the Flow DSL](https://pgflow.dev/explanations/flow-dsl/)
|
package/dist/dsl.d.ts
CHANGED
|
@@ -4,6 +4,13 @@ export type Json = string | number | boolean | null | Json[] | {
|
|
|
4
4
|
export type Simplify<T> = {
|
|
5
5
|
[KeyType in keyof T]: T[KeyType];
|
|
6
6
|
} & {};
|
|
7
|
+
type AwaitedReturn<T> = T extends (...args: any[]) => Promise<infer R> ? R : T extends (...args: any[]) => infer R ? R : never;
|
|
8
|
+
export interface Env {
|
|
9
|
+
[key: string]: string | undefined;
|
|
10
|
+
}
|
|
11
|
+
export type ValidEnv<T> = T extends Env ? T : never;
|
|
12
|
+
export interface UserEnv extends Env {
|
|
13
|
+
}
|
|
7
14
|
export type AnyInput = Json;
|
|
8
15
|
export type AnyOutput = Json;
|
|
9
16
|
export type EmptySteps = Record<never, never>;
|
|
@@ -14,35 +21,47 @@ export type AnyDeps = Record<string, string[]>;
|
|
|
14
21
|
/**
|
|
15
22
|
* Represents a Flow that has not steps nor deps defined yet
|
|
16
23
|
*/
|
|
17
|
-
export type EmptyFlow = Flow<AnyInput, EmptySteps, EmptyDeps>;
|
|
24
|
+
export type EmptyFlow = Flow<AnyInput, BaseContext, EmptySteps, EmptyDeps>;
|
|
18
25
|
/**
|
|
19
|
-
* Represents any Flow with flexible input, steps, and dependencies.
|
|
26
|
+
* Represents any Flow with flexible input, context, steps, and dependencies.
|
|
20
27
|
* This type is intentionally more permissive to allow for better type inference
|
|
21
28
|
* in utility types like StepOutput.
|
|
22
29
|
*/
|
|
23
|
-
export type AnyFlow = Flow<any, any, any>;
|
|
30
|
+
export type AnyFlow = Flow<any, any, any, any>;
|
|
24
31
|
/**
|
|
25
32
|
* Extracts the input type from a Flow
|
|
26
33
|
* @template TFlow - The Flow type to extract from
|
|
27
34
|
*/
|
|
28
|
-
export type ExtractFlowInput<TFlow extends AnyFlow> = TFlow extends Flow<infer TI, infer _TS, infer _TD> ? TI : never;
|
|
35
|
+
export type ExtractFlowInput<TFlow extends AnyFlow> = TFlow extends Flow<infer TI, infer _TC, infer _TS, infer _TD> ? TI : never;
|
|
36
|
+
/**
|
|
37
|
+
* Utility type to extract all possible step inputs from a flow
|
|
38
|
+
* This creates a union of all step input types
|
|
39
|
+
*/
|
|
40
|
+
export type AllStepInputs<TFlow extends AnyFlow> = {
|
|
41
|
+
[K in keyof ExtractFlowSteps<TFlow> & string]: StepInput<TFlow, K>;
|
|
42
|
+
}[keyof ExtractFlowSteps<TFlow> & string];
|
|
29
43
|
/**
|
|
30
44
|
* Extracts the output type from a Flow
|
|
31
45
|
* @template TFlow - The Flow type to extract from
|
|
32
46
|
*/
|
|
33
|
-
export type ExtractFlowOutput<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer _TS, infer _TD> ? {
|
|
47
|
+
export type ExtractFlowOutput<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer _TC, infer _TS, infer _TD> ? {
|
|
34
48
|
[K in keyof ExtractFlowLeafSteps<TFlow> as K extends string ? K : never]: StepOutput<TFlow, K & string>;
|
|
35
49
|
} : never;
|
|
36
50
|
/**
|
|
37
51
|
* Extracts the steps type from a Flow
|
|
38
52
|
* @template TFlow - The Flow type to extract from
|
|
39
53
|
*/
|
|
40
|
-
export type ExtractFlowSteps<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer TS, infer _TD> ? TS : never;
|
|
54
|
+
export type ExtractFlowSteps<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer _TC, infer TS, infer _TD> ? TS : never;
|
|
41
55
|
/**
|
|
42
56
|
* Extracts the dependencies type from a Flow
|
|
43
57
|
* @template TFlow - The Flow type to extract from
|
|
44
58
|
*/
|
|
45
|
-
export type ExtractFlowDeps<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer _TS, infer TD> ? TD : never;
|
|
59
|
+
export type ExtractFlowDeps<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer _TC, infer _TS, infer TD> ? TD : never;
|
|
60
|
+
/**
|
|
61
|
+
* Extracts the context type from a Flow
|
|
62
|
+
* @template TFlow - The Flow type to extract from
|
|
63
|
+
*/
|
|
64
|
+
export type ExtractFlowContext<TFlow extends AnyFlow> = TFlow extends Flow<infer _TI, infer TC, infer _TS, infer _TD> ? TC : never;
|
|
46
65
|
/**
|
|
47
66
|
* Extracts the dependencies type from a Flow
|
|
48
67
|
* @template TFlow - The Flow type to extract from
|
|
@@ -73,16 +92,23 @@ export interface RuntimeOptions {
|
|
|
73
92
|
baseDelay?: number;
|
|
74
93
|
timeout?: number;
|
|
75
94
|
}
|
|
95
|
+
export interface BaseContext {
|
|
96
|
+
env: Env & ValidEnv<UserEnv>;
|
|
97
|
+
shutdownSignal: AbortSignal;
|
|
98
|
+
}
|
|
99
|
+
export type Context<T extends Record<string, unknown> = Record<string, never>> = BaseContext & T;
|
|
100
|
+
type ExtractHandlerContext<T> = T extends (input: any, context: infer C) => any ? C : never;
|
|
76
101
|
export interface StepRuntimeOptions extends RuntimeOptions {
|
|
77
102
|
startDelay?: number;
|
|
78
103
|
}
|
|
79
|
-
export interface StepDefinition<TInput extends AnyInput, TOutput extends AnyOutput> {
|
|
104
|
+
export interface StepDefinition<TInput extends AnyInput, TOutput extends AnyOutput, TContext = BaseContext> {
|
|
80
105
|
slug: string;
|
|
81
|
-
handler: (input: TInput) => TOutput | Promise<TOutput>;
|
|
106
|
+
handler: (input: TInput, context: TContext) => TOutput | Promise<TOutput>;
|
|
82
107
|
dependencies: string[];
|
|
83
108
|
options: StepRuntimeOptions;
|
|
84
109
|
}
|
|
85
|
-
export declare class Flow<TFlowInput extends AnyInput = AnyInput,
|
|
110
|
+
export declare class Flow<TFlowInput extends AnyInput = AnyInput, TContext = BaseContext, // Accumulated context requirements (starts with BaseContext)
|
|
111
|
+
Steps extends AnySteps = EmptySteps, StepDependencies extends AnyDeps = EmptyDeps> {
|
|
86
112
|
/**
|
|
87
113
|
* Store step definitions with their proper types
|
|
88
114
|
*
|
|
@@ -106,15 +132,15 @@ export declare class Flow<TFlowInput extends AnyInput = AnyInput, Steps extends
|
|
|
106
132
|
} & {
|
|
107
133
|
[K in StepDependencies[SlugType][number]]: K extends keyof Steps ? Steps[K] : never;
|
|
108
134
|
}>, Steps[SlugType]>;
|
|
109
|
-
step<Slug extends string,
|
|
110
|
-
slug: Slug;
|
|
111
|
-
dependsOn?: Deps[];
|
|
112
|
-
} & StepRuntimeOptions>, handler: (input: Simplify<{
|
|
135
|
+
step<Slug extends string, THandler extends (input: Simplify<{
|
|
113
136
|
run: TFlowInput;
|
|
114
137
|
} & {
|
|
115
138
|
[K in Deps]: K extends keyof Steps ? Steps[K] : never;
|
|
116
|
-
}
|
|
117
|
-
|
|
139
|
+
}>, context: BaseContext & TContext) => any, Deps extends Extract<keyof Steps, string> = never>(opts: Simplify<{
|
|
140
|
+
slug: Slug;
|
|
141
|
+
dependsOn?: Deps[];
|
|
142
|
+
} & StepRuntimeOptions>, handler: THandler): Flow<TFlowInput, TContext & BaseContext & ExtractHandlerContext<THandler>, Steps & {
|
|
143
|
+
[K in Slug]: AwaitedReturn<THandler>;
|
|
118
144
|
}, StepDependencies & {
|
|
119
145
|
[K in Slug]: Deps[];
|
|
120
146
|
}>;
|
package/dist/dsl.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dsl.d.ts","sourceRoot":"","sources":["../src/dsl.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,IAAI,GACZ,MAAM,GACN,MAAM,GACN,OAAO,GACP,IAAI,GACJ,IAAI,EAAE,GACN;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;CAAE,CAAC;AAGxC,MAAM,MAAM,QAAQ,CAAC,CAAC,IAAI;KAAG,OAAO,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC;CAAE,GAAG,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"dsl.d.ts","sourceRoot":"","sources":["../src/dsl.ts"],"names":[],"mappings":"AAOA,MAAM,MAAM,IAAI,GACZ,MAAM,GACN,MAAM,GACN,OAAO,GACP,IAAI,GACJ,IAAI,EAAE,GACN;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,CAAA;CAAE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,CAAC,EACxD,KAAK,GAAG;SAAG,CAAC,IAAI,IAAI,GAAG,aAAa,CAAC,QAAQ,CAAC;KAAE,EAChD,gBAAgB,GAAG;SAAG,CAAC,IAAI,IAAI,GAAG,IAAI,EAAE;KAAE,CAC3C;CAyEF"}
|
package/dist/dsl.js
CHANGED
package/dist/example-flow.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { Flow } from './dsl.js';
|
|
|
2
2
|
type Input = {
|
|
3
3
|
url: string;
|
|
4
4
|
};
|
|
5
|
-
export declare const AnalyzeWebsite: Flow<Input, import("./dsl.js").EmptySteps & {
|
|
5
|
+
export declare const AnalyzeWebsite: Flow<Input, import("./dsl.js").BaseContext, import("./dsl.js").EmptySteps & {
|
|
6
6
|
website: {
|
|
7
7
|
content: string;
|
|
8
8
|
};
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pgflow/dsl",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -14,12 +14,22 @@
|
|
|
14
14
|
".": {
|
|
15
15
|
"types": "./dist/index.d.ts",
|
|
16
16
|
"import": "./dist/index.js"
|
|
17
|
+
},
|
|
18
|
+
"./platforms": {
|
|
19
|
+
"types": "./dist/platforms/index.d.ts",
|
|
20
|
+
"import": "./dist/platforms/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./supabase": {
|
|
23
|
+
"types": "./dist/platforms/supabase.d.ts",
|
|
24
|
+
"import": "./dist/platforms/supabase.js"
|
|
17
25
|
}
|
|
18
26
|
},
|
|
19
27
|
"publishConfig": {
|
|
20
28
|
"access": "public"
|
|
21
29
|
},
|
|
22
30
|
"devDependencies": {
|
|
23
|
-
"@types/node": "^22.14.1"
|
|
31
|
+
"@types/node": "^22.14.1",
|
|
32
|
+
"postgres": "^3.4.5",
|
|
33
|
+
"@supabase/supabase-js": "^2.47.10"
|
|
24
34
|
}
|
|
25
35
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/platforms/index.ts"],"names":[],"mappings":"AACA,YAAY,EAAE,WAAW,EAAE,OAAO,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { Sql } from 'postgres';
|
|
2
|
+
import type { SupabaseClient } from '@supabase/supabase-js';
|
|
3
|
+
import { Flow as CoreFlow, type AnyInput, type AnySteps, type AnyDeps, EmptySteps, EmptyDeps, type Env, type UserEnv, type ValidEnv, type AnyFlow, type Json, type BaseContext } from '../index.js';
|
|
4
|
+
export interface SupabaseResources extends Record<string, unknown> {
|
|
5
|
+
sql: Sql;
|
|
6
|
+
anonSupabase: SupabaseClient;
|
|
7
|
+
serviceSupabase: SupabaseClient;
|
|
8
|
+
}
|
|
9
|
+
export interface SupabaseEnv extends Env {
|
|
10
|
+
EDGE_WORKER_DB_URL: string;
|
|
11
|
+
SUPABASE_URL: string;
|
|
12
|
+
SUPABASE_ANON_KEY: string;
|
|
13
|
+
SUPABASE_SERVICE_ROLE_KEY: string;
|
|
14
|
+
SB_EXECUTION_ID: string;
|
|
15
|
+
EDGE_WORKER_LOG_LEVEL?: string;
|
|
16
|
+
}
|
|
17
|
+
export type SupabasePlatformContext = BaseContext & SupabaseResources & {
|
|
18
|
+
env: SupabaseEnv & ValidEnv<UserEnv>;
|
|
19
|
+
};
|
|
20
|
+
export type SupabaseMessageContext<T extends Json = Json> = SupabasePlatformContext & {
|
|
21
|
+
rawMessage: any;
|
|
22
|
+
};
|
|
23
|
+
export type SupabaseStepTaskContext<F extends AnyFlow = AnyFlow> = SupabasePlatformContext & {
|
|
24
|
+
rawMessage: any;
|
|
25
|
+
stepTask: any;
|
|
26
|
+
};
|
|
27
|
+
export declare class Flow<I extends AnyInput = AnyInput, ExtraCtx extends Record<string, unknown> = Record<string, never>, S extends AnySteps = EmptySteps, D extends AnyDeps = EmptyDeps> extends CoreFlow<I, SupabasePlatformContext & ExtraCtx, // <── full ctx in handlers
|
|
28
|
+
S, D> {
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=supabase.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"supabase.d.ts","sourceRoot":"","sources":["../../src/platforms/supabase.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,UAAU,CAAC;AACpC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EACL,IAAI,IAAI,QAAQ,EAChB,KAAK,QAAQ,EAAE,KAAK,QAAQ,EAAE,KAAK,OAAO,EAC1C,UAAU,EAAE,SAAS,EAAE,KAAK,GAAG,EAAE,KAAK,OAAO,EAAE,KAAK,QAAQ,EAC5D,KAAK,OAAO,EAAE,KAAK,IAAI,EAAE,KAAK,WAAW,EAC1C,MAAM,aAAa,CAAC;AAGrB,MAAM,WAAW,iBAAkB,SAAQ,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;IAChE,GAAG,EAAc,GAAG,CAAC;IACrB,YAAY,EAAK,cAAc,CAAC;IAChC,eAAe,EAAE,cAAc,CAAC;CACjC;AAGD,MAAM,WAAW,WAAY,SAAQ,GAAG;IACtC,kBAAkB,EAAQ,MAAM,CAAC;IACjC,YAAY,EAAc,MAAM,CAAC;IACjC,iBAAiB,EAAS,MAAM,CAAC;IACjC,yBAAyB,EAAE,MAAM,CAAC;IAClC,eAAe,EAAW,MAAM,CAAC;IACjC,qBAAqB,CAAC,EAAI,MAAM,CAAC;CAClC;AAGD,MAAM,MAAM,uBAAuB,GACjC,WAAW,GAAG,iBAAiB,GAAG;IAChC,GAAG,EAAE,WAAW,GAAG,QAAQ,CAAC,OAAO,CAAC,CAAC;CACtC,CAAC;AAGJ,MAAM,MAAM,sBAAsB,CAAC,CAAC,SAAS,IAAI,GAAG,IAAI,IACtD,uBAAuB,GAAG;IACxB,UAAU,EAAE,GAAG,CAAC;CACjB,CAAC;AAEJ,MAAM,MAAM,uBAAuB,CAAC,CAAC,SAAS,OAAO,GAAG,OAAO,IAC7D,uBAAuB,GAAG;IACxB,UAAU,EAAE,GAAG,CAAC;IAChB,QAAQ,EAAE,GAAG,CAAC;CACf,CAAC;AAGJ,qBAAa,IAAI,CACf,CAAC,SAAS,QAAQ,GAAG,QAAQ,EAC7B,QAAQ,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,EAChE,CAAC,SAAS,QAAQ,GAAG,UAAU,EAC/B,CAAC,SAAS,OAAO,GAAK,SAAS,CAC/B,SAAQ,QAAQ,CAChB,CAAC,EACD,uBAAuB,GAAG,QAAQ,EAAI,2BAA2B;AACjE,CAAC,EAAE,CAAC,CACL;CAAG"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"supabase.d.ts","sourceRoot":"","sources":["../src/supabase.ts"],"names":[],"mappings":"AACA,cAAc,yBAAyB,CAAC"}
|
package/dist/supabase.js
ADDED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pgflow/dsl",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.4",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -14,12 +14,22 @@
|
|
|
14
14
|
".": {
|
|
15
15
|
"types": "./dist/index.d.ts",
|
|
16
16
|
"import": "./dist/index.js"
|
|
17
|
+
},
|
|
18
|
+
"./platforms": {
|
|
19
|
+
"types": "./dist/platforms/index.d.ts",
|
|
20
|
+
"import": "./dist/platforms/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./supabase": {
|
|
23
|
+
"types": "./dist/platforms/supabase.d.ts",
|
|
24
|
+
"import": "./dist/platforms/supabase.js"
|
|
17
25
|
}
|
|
18
26
|
},
|
|
19
27
|
"publishConfig": {
|
|
20
28
|
"access": "public"
|
|
21
29
|
},
|
|
22
30
|
"devDependencies": {
|
|
23
|
-
"@types/node": "^22.14.1"
|
|
31
|
+
"@types/node": "^22.14.1",
|
|
32
|
+
"postgres": "^3.4.5",
|
|
33
|
+
"@supabase/supabase-js": "^2.47.10"
|
|
24
34
|
}
|
|
25
35
|
}
|