@upstash/workflow 0.2.8 → 0.2.10-hono-generics
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/astro.d.mts +8 -3
- package/astro.d.ts +8 -3
- package/astro.js +393 -82
- package/astro.mjs +36 -8
- package/{chunk-BPUSHNSD.mjs → chunk-IPXJZU3K.mjs} +1226 -943
- package/cloudflare.d.mts +9 -4
- package/cloudflare.d.ts +9 -4
- package/cloudflare.js +392 -88
- package/cloudflare.mjs +35 -14
- package/express.d.mts +7 -3
- package/express.d.ts +7 -3
- package/express.js +400 -92
- package/express.mjs +43 -18
- package/h3.d.mts +9 -7
- package/h3.d.ts +9 -7
- package/h3.js +397 -95
- package/h3.mjs +40 -21
- package/hono.d.mts +10 -4
- package/hono.d.ts +10 -4
- package/hono.js +391 -90
- package/hono.mjs +34 -16
- package/index.d.mts +47 -33
- package/index.d.ts +47 -33
- package/index.js +315 -92
- package/index.mjs +32 -30
- package/nextjs.d.mts +14 -5
- package/nextjs.d.ts +14 -5
- package/nextjs.js +408 -77
- package/nextjs.mjs +63 -17
- package/package.json +1 -1
- package/serve-many-BVDpPsF-.d.mts +13 -0
- package/serve-many-e4zufyXN.d.ts +13 -0
- package/solidjs.d.mts +3 -3
- package/solidjs.d.ts +3 -3
- package/solidjs.js +289 -71
- package/solidjs.mjs +7 -10
- package/svelte.d.mts +13 -6
- package/svelte.d.ts +13 -6
- package/svelte.js +391 -88
- package/svelte.mjs +34 -14
- package/{types-B62AnIU3.d.mts → types-CYhDXnf8.d.mts} +74 -8
- package/{types-B62AnIU3.d.ts → types-CYhDXnf8.d.ts} +74 -8
package/cloudflare.d.mts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { R as RouteFunction, k as PublicServeOptions } from './types-
|
|
1
|
+
import { R as RouteFunction, k as PublicServeOptions, t as InvokableWorkflow } from './types-CYhDXnf8.mjs';
|
|
2
|
+
import { s as serveManyBase } from './serve-many-BVDpPsF-.mjs';
|
|
2
3
|
import '@upstash/qstash';
|
|
3
4
|
import 'zod';
|
|
4
5
|
import 'ai';
|
|
@@ -23,7 +24,7 @@ type PagesHandlerArgs = [{
|
|
|
23
24
|
*/
|
|
24
25
|
type WorkersHandlerArgs = [Request, Record<string, string | undefined>];
|
|
25
26
|
/**
|
|
26
|
-
* Serve method to serve a Upstash Workflow in a
|
|
27
|
+
* Serve method to serve a Upstash Workflow in a Cloudflare project
|
|
27
28
|
*
|
|
28
29
|
* See for options https://upstash.com/docs/qstash/workflows/basics/serve
|
|
29
30
|
*
|
|
@@ -31,8 +32,12 @@ type WorkersHandlerArgs = [Request, Record<string, string | undefined>];
|
|
|
31
32
|
* @param options workflow options
|
|
32
33
|
* @returns
|
|
33
34
|
*/
|
|
34
|
-
declare const serve: <TInitialPayload = unknown>(routeFunction: RouteFunction<TInitialPayload>, options?: PublicServeOptions<TInitialPayload>) => {
|
|
35
|
+
declare const serve: <TInitialPayload = unknown, TResult = unknown>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: PublicServeOptions<TInitialPayload>) => {
|
|
35
36
|
fetch: (...args: PagesHandlerArgs | WorkersHandlerArgs) => Promise<Response>;
|
|
36
37
|
};
|
|
38
|
+
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: PublicServeOptions<TInitialPayload> | undefined) => InvokableWorkflow<TInitialPayload, TResult>;
|
|
39
|
+
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"], options?: Parameters<typeof serveManyBase>[0]["options"]) => {
|
|
40
|
+
fetch: (...params: PagesHandlerArgs | WorkersHandlerArgs) => Promise<any>;
|
|
41
|
+
};
|
|
37
42
|
|
|
38
|
-
export { type PagesHandlerArgs, type WorkersHandlerArgs, type WorkflowBindings, serve };
|
|
43
|
+
export { type PagesHandlerArgs, type WorkersHandlerArgs, type WorkflowBindings, createWorkflow, serve, serveMany };
|
package/cloudflare.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import { R as RouteFunction, k as PublicServeOptions } from './types-
|
|
1
|
+
import { R as RouteFunction, k as PublicServeOptions, t as InvokableWorkflow } from './types-CYhDXnf8.js';
|
|
2
|
+
import { s as serveManyBase } from './serve-many-e4zufyXN.js';
|
|
2
3
|
import '@upstash/qstash';
|
|
3
4
|
import 'zod';
|
|
4
5
|
import 'ai';
|
|
@@ -23,7 +24,7 @@ type PagesHandlerArgs = [{
|
|
|
23
24
|
*/
|
|
24
25
|
type WorkersHandlerArgs = [Request, Record<string, string | undefined>];
|
|
25
26
|
/**
|
|
26
|
-
* Serve method to serve a Upstash Workflow in a
|
|
27
|
+
* Serve method to serve a Upstash Workflow in a Cloudflare project
|
|
27
28
|
*
|
|
28
29
|
* See for options https://upstash.com/docs/qstash/workflows/basics/serve
|
|
29
30
|
*
|
|
@@ -31,8 +32,12 @@ type WorkersHandlerArgs = [Request, Record<string, string | undefined>];
|
|
|
31
32
|
* @param options workflow options
|
|
32
33
|
* @returns
|
|
33
34
|
*/
|
|
34
|
-
declare const serve: <TInitialPayload = unknown>(routeFunction: RouteFunction<TInitialPayload>, options?: PublicServeOptions<TInitialPayload>) => {
|
|
35
|
+
declare const serve: <TInitialPayload = unknown, TResult = unknown>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: PublicServeOptions<TInitialPayload>) => {
|
|
35
36
|
fetch: (...args: PagesHandlerArgs | WorkersHandlerArgs) => Promise<Response>;
|
|
36
37
|
};
|
|
38
|
+
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: PublicServeOptions<TInitialPayload> | undefined) => InvokableWorkflow<TInitialPayload, TResult>;
|
|
39
|
+
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"], options?: Parameters<typeof serveManyBase>[0]["options"]) => {
|
|
40
|
+
fetch: (...params: PagesHandlerArgs | WorkersHandlerArgs) => Promise<any>;
|
|
41
|
+
};
|
|
37
42
|
|
|
38
|
-
export { type PagesHandlerArgs, type WorkersHandlerArgs, type WorkflowBindings, serve };
|
|
43
|
+
export { type PagesHandlerArgs, type WorkersHandlerArgs, type WorkflowBindings, createWorkflow, serve, serveMany };
|