@upstash/workflow 0.2.8-rc-invoke → 0.2.9
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 +4 -4
- package/astro.d.ts +4 -4
- package/astro.js +282 -135
- package/astro.mjs +17 -15
- package/{chunk-IWAW7GIG.mjs → chunk-IPXJZU3K.mjs} +851 -592
- package/cloudflare.d.mts +4 -4
- package/cloudflare.d.ts +4 -4
- package/cloudflare.js +278 -135
- package/cloudflare.mjs +13 -15
- package/express.d.mts +4 -4
- package/express.d.ts +4 -4
- package/express.js +281 -144
- package/express.mjs +16 -22
- package/h3.d.mts +4 -4
- package/h3.d.ts +4 -4
- package/h3.js +275 -135
- package/h3.mjs +10 -15
- package/hono.d.mts +4 -4
- package/hono.d.ts +4 -4
- package/hono.js +277 -134
- package/hono.mjs +12 -14
- package/index.d.mts +268 -5
- package/index.d.ts +268 -5
- package/index.js +297 -43
- package/index.mjs +60 -3
- package/nextjs.d.mts +6 -6
- package/nextjs.d.ts +6 -6
- package/nextjs.js +286 -143
- package/nextjs.mjs +21 -23
- 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 +1 -1
- package/solidjs.d.ts +1 -1
- package/solidjs.js +207 -41
- package/solidjs.mjs +1 -1
- package/svelte.d.mts +8 -9
- package/svelte.d.ts +8 -9
- package/svelte.js +278 -135
- package/svelte.mjs +13 -15
- package/{types-C7Y7WUQd.d.mts → types-CYhDXnf8.d.mts} +110 -18
- package/{types-C7Y7WUQd.d.ts → types-CYhDXnf8.d.ts} +110 -18
- package/chunk-LCZMBGEM.mjs +0 -95
- package/serve-many-BlBvXfBS.d.mts +0 -10
- package/serve-many-Dw-UUnH6.d.ts +0 -10
package/cloudflare.mjs
CHANGED
|
@@ -1,11 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
createInvokeCallback,
|
|
3
|
-
serveManyBase
|
|
4
|
-
} from "./chunk-LCZMBGEM.mjs";
|
|
5
1
|
import {
|
|
6
2
|
SDK_TELEMETRY,
|
|
7
|
-
serveBase
|
|
8
|
-
|
|
3
|
+
serveBase,
|
|
4
|
+
serveManyBase
|
|
5
|
+
} from "./chunk-IPXJZU3K.mjs";
|
|
9
6
|
|
|
10
7
|
// platforms/cloudflare.ts
|
|
11
8
|
var getArgs = (args) => {
|
|
@@ -42,22 +39,23 @@ var serve = (routeFunction, options) => {
|
|
|
42
39
|
return { fetch };
|
|
43
40
|
};
|
|
44
41
|
var createWorkflow = (...params) => {
|
|
45
|
-
const
|
|
42
|
+
const [routeFunction, options = {}] = params;
|
|
46
43
|
return {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
44
|
+
workflowId: void 0,
|
|
45
|
+
routeFunction,
|
|
46
|
+
options
|
|
50
47
|
};
|
|
51
48
|
};
|
|
52
|
-
var serveMany = (workflows) => {
|
|
49
|
+
var serveMany = (workflows, options) => {
|
|
53
50
|
return {
|
|
54
51
|
fetch: serveManyBase({
|
|
55
52
|
workflows,
|
|
56
|
-
|
|
53
|
+
getUrl(...params) {
|
|
57
54
|
const { request } = getArgs(params);
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
55
|
+
return request.url;
|
|
56
|
+
},
|
|
57
|
+
options,
|
|
58
|
+
serveMethod: (...params) => serve(...params).fetch
|
|
61
59
|
}).handler
|
|
62
60
|
};
|
|
63
61
|
};
|
package/express.d.mts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import * as express_serve_static_core from 'express-serve-static-core';
|
|
2
|
-
import { R as RouteFunction, W as WorkflowServeOptions, t as InvokableWorkflow } from './types-
|
|
2
|
+
import { R as RouteFunction, W as WorkflowServeOptions, t as InvokableWorkflow } from './types-CYhDXnf8.mjs';
|
|
3
3
|
import { Router } from 'express';
|
|
4
|
-
import { s as serveManyBase } from './serve-many-
|
|
4
|
+
import { s as serveManyBase } from './serve-many-BVDpPsF-.mjs';
|
|
5
5
|
import '@upstash/qstash';
|
|
6
6
|
import 'zod';
|
|
7
7
|
import 'ai';
|
|
8
8
|
import '@ai-sdk/openai';
|
|
9
9
|
|
|
10
10
|
declare function serve<TInitialPayload = unknown, TResult = unknown>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<globalThis.Response, TInitialPayload>, "onStepFinish">): Router;
|
|
11
|
-
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<Response, TInitialPayload>, "onStepFinish"> | undefined) => InvokableWorkflow<TInitialPayload, TResult
|
|
12
|
-
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"]) => express_serve_static_core.Router;
|
|
11
|
+
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<Response, TInitialPayload>, "onStepFinish"> | undefined) => InvokableWorkflow<TInitialPayload, TResult>;
|
|
12
|
+
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"], options?: Parameters<typeof serveManyBase>[0]["options"]) => express_serve_static_core.Router;
|
|
13
13
|
|
|
14
14
|
export { createWorkflow, serve, serveMany };
|
package/express.d.ts
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import * as express_serve_static_core from 'express-serve-static-core';
|
|
2
|
-
import { R as RouteFunction, W as WorkflowServeOptions, t as InvokableWorkflow } from './types-
|
|
2
|
+
import { R as RouteFunction, W as WorkflowServeOptions, t as InvokableWorkflow } from './types-CYhDXnf8.js';
|
|
3
3
|
import { Router } from 'express';
|
|
4
|
-
import { s as serveManyBase } from './serve-many-
|
|
4
|
+
import { s as serveManyBase } from './serve-many-e4zufyXN.js';
|
|
5
5
|
import '@upstash/qstash';
|
|
6
6
|
import 'zod';
|
|
7
7
|
import 'ai';
|
|
8
8
|
import '@ai-sdk/openai';
|
|
9
9
|
|
|
10
10
|
declare function serve<TInitialPayload = unknown, TResult = unknown>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<globalThis.Response, TInitialPayload>, "onStepFinish">): Router;
|
|
11
|
-
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<Response, TInitialPayload>, "onStepFinish"> | undefined) => InvokableWorkflow<TInitialPayload, TResult
|
|
12
|
-
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"]) => express_serve_static_core.Router;
|
|
11
|
+
declare const createWorkflow: <TInitialPayload, TResult>(routeFunction: RouteFunction<TInitialPayload, TResult>, options?: Omit<WorkflowServeOptions<Response, TInitialPayload>, "onStepFinish"> | undefined) => InvokableWorkflow<TInitialPayload, TResult>;
|
|
12
|
+
declare const serveMany: (workflows: Parameters<typeof serveManyBase>[0]["workflows"], options?: Parameters<typeof serveManyBase>[0]["options"]) => express_serve_static_core.Router;
|
|
13
13
|
|
|
14
14
|
export { createWorkflow, serve, serveMany };
|