@oomol-lab/open-flow 0.1.0-beta.61 → 0.1.0-beta.63
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/dist/browser/{createResourceDialog-D71fO68i.js → createResourceDialog-BAJXbzNH.js} +20 -7
- package/dist/browser/flow-authoring.js +8 -7
- package/dist/browser/flow-change-schema.d.ts +1 -0
- package/dist/browser/flow-change.d.ts +1 -0
- package/dist/browser/flow-change.js +8 -7
- package/dist/browser/{flowChanges-DSA0FxxN.js → flowChanges-DpZOQuJE.js} +3001 -2588
- package/dist/browser/{flowRunInputEditorStore-Dsxyfwae.js → flowRunInputEditorStore-B2Rw4VsT.js} +1 -1
- package/dist/browser/{flowWorkspace-0sUJ5JhQ.js → flowWorkspace-B7a5NNA_.js} +217 -83
- package/dist/browser/{icons-DVJvrj1H.js → icons-Db2Jb2iX.js} +2907 -2887
- package/dist/browser/preview.css +5 -6
- package/dist/browser/preview.js +889 -541
- package/dist/browser/{typeScriptSession-fXPMFGjW.js → typeScriptSession-D0bjYDeg.js} +1 -1
- package/dist/browser/ui.css +4 -5
- package/dist/browser/ui.js +2 -2
- package/dist/browser/{value-DL_poNiC.js → value-BADHeZ9I.js} +12 -1
- package/dist/browser/workbench-contract.d.ts +10 -0
- package/dist/browser/workbench.css +9 -26
- package/dist/browser/workbench.d.ts +5 -3
- package/dist/browser/workbench.js +272 -178
- package/dist/browser/{workbenchSelect-cr4-mKq3.js → workbenchSelect-C-jf6NIM.js} +1 -1
- package/dist/command/index.js +45 -44
- package/dist/common/authoring.d.ts +1 -1
- package/dist/common/authoringSchema.d.ts +1 -0
- package/dist/common/connector-action.d.ts +1 -0
- package/dist/common/connector-action.js +15 -12
- package/dist/common/control-api-conformance.js +1371 -1207
- package/dist/common/control-api-errors.d.ts +0 -4
- package/dist/common/control-api.d.ts +18 -11
- package/dist/common/control-api.js +2053 -2274
- package/dist/common/control-requests.d.ts +6 -0
- package/dist/common/control-requests.js +64 -33
- package/dist/common/decision.js +8 -7
- package/dist/common/flow-connectionUsage.d.ts +1 -0
- package/dist/common/flow-encoding.d.ts +1 -0
- package/dist/common/flow-encoding.js +202 -10
- package/dist/common/flow-semantics.js +64 -46
- package/dist/common/flow-workflowFile.d.ts +23 -0
- package/dist/common/integration-trigger.js +8 -7
- package/dist/common/liveDetails.d.ts +138 -0
- package/dist/common/localization.d.ts +1 -0
- package/dist/common/localization.js +12 -1
- package/dist/common/mcp.d.ts +55 -26
- package/dist/common/mcp.js +377 -245
- package/dist/common/openapi.js +8 -7
- package/dist/common/poll-trigger.js +8 -7
- package/dist/common/runtime-contract.js +1 -1
- package/dist/common/scheduler.d.ts +22 -2
- package/dist/common/scheduler.js +354 -83
- package/dist/common/trigger-config.d.ts +2 -0
- package/dist/common/webhook-trigger.js +8 -7
- package/dist/index.d.ts +2 -2
- package/package.json +1 -1
- package/skills/open-flow/SKILL.md +6 -3
- package/skills/open-flow/references/flow-authoring.md +48 -24
- package/dist/common/publicationResources.d.ts +0 -29
|
@@ -5924,7 +5924,8 @@ var managedFields = object({
|
|
|
5924
5924
|
object({
|
|
5925
5925
|
kind: literal("connector"),
|
|
5926
5926
|
action: text,
|
|
5927
|
-
connectionId: text.optional()
|
|
5927
|
+
connectionId: text.optional(),
|
|
5928
|
+
outputMode: literal("value").optional()
|
|
5928
5929
|
}),
|
|
5929
5930
|
object({
|
|
5930
5931
|
kind: literal("openapi"),
|
|
@@ -7309,10 +7310,10 @@ function compileEnumAndConst(context, enumList, constValue, schema) {
|
|
|
7309
7310
|
}
|
|
7310
7311
|
if (compiledEnum.length === 0) recordWarn(context, "all of elements from list is rejected by currently schema object", "enum");
|
|
7311
7312
|
}
|
|
7312
|
-
if (constValue && valid(schema, constValue) === ValidResult.Invalid) isNever = true;
|
|
7313
|
+
if (constValue !== void 0 && valid(schema, constValue) === ValidResult.Invalid) isNever = true;
|
|
7313
7314
|
if (compiledEnum) {
|
|
7314
7315
|
if (compiledEnum.length === 0) isNever = true;
|
|
7315
|
-
else if (constValue) {
|
|
7316
|
+
else if (constValue !== void 0) {
|
|
7316
7317
|
let foundEquals = false;
|
|
7317
7318
|
for (const enumValue of compiledEnum) if (isDeepEquals(enumValue, constValue)) {
|
|
7318
7319
|
foundEquals = true;
|
|
@@ -7325,7 +7326,7 @@ function compileEnumAndConst(context, enumList, constValue, schema) {
|
|
|
7325
7326
|
const compiledSchema = {};
|
|
7326
7327
|
if (schema.type) compiledSchema.type = schema.type;
|
|
7327
7328
|
if (compiledEnum) compiledSchema.enum = compiledEnum;
|
|
7328
|
-
if (constValue) compiledSchema.const = wrapCompiledValue(deepCopy(constValue));
|
|
7329
|
+
if (constValue !== void 0) compiledSchema.const = wrapCompiledValue(deepCopy(constValue));
|
|
7329
7330
|
return wrapCompiledSchema(kind, compiledSchema, context.delegate, context.path);
|
|
7330
7331
|
}
|
|
7331
7332
|
//#endregion
|
|
@@ -7720,7 +7721,7 @@ function compileSchema(context, schema) {
|
|
|
7720
7721
|
let targetSchema = schema;
|
|
7721
7722
|
let shouldHandleEnumAndConst = false;
|
|
7722
7723
|
const { enum: enumList, const: constValue } = schema;
|
|
7723
|
-
if (enumList || constValue) {
|
|
7724
|
+
if (enumList || constValue !== void 0) {
|
|
7724
7725
|
const { enum: _0, const: _1, ...rest } = schema;
|
|
7725
7726
|
targetSchema = rest;
|
|
7726
7727
|
shouldHandleEnumAndConst = true;
|
|
@@ -8310,7 +8311,7 @@ function schemaEqualsChecker(extendsContext) {
|
|
|
8310
8311
|
}
|
|
8311
8312
|
function isValueEquals(value1, value2) {
|
|
8312
8313
|
if (value1 === value2) return true;
|
|
8313
|
-
if (value1 === null) return false;
|
|
8314
|
+
if (value1 === null || value2 === null) return false;
|
|
8314
8315
|
if (typeof value1 !== "object") return false;
|
|
8315
8316
|
if (typeof value1 !== typeof value2) return false;
|
|
8316
8317
|
if (isCompiledSchema(value1) && isCompiledSchema(value2)) return isCompiledSchemaEquals(value1, value2);
|
|
@@ -8876,7 +8877,7 @@ function findMismatchPath(source, target) {
|
|
|
8876
8877
|
if ((sourceSchema.maxProperties ?? Number.POSITIVE_INFINITY) > (targetSchema.maxProperties ?? Number.POSITIVE_INFINITY)) return [...targetPath, "maxProperties"];
|
|
8877
8878
|
break;
|
|
8878
8879
|
}
|
|
8879
|
-
case CompiledKind.EnumOrConst: return [...targetPath, targetSchema.const
|
|
8880
|
+
case CompiledKind.EnumOrConst: return [...targetPath, targetSchema.const === void 0 ? "enum" : "const"];
|
|
8880
8881
|
}
|
|
8881
8882
|
return targetPath;
|
|
8882
8883
|
}
|
package/dist/index.d.ts
CHANGED
|
@@ -75,8 +75,8 @@ export interface TaskContext<Actions extends object = Record<string, never>> {
|
|
|
75
75
|
readonly artifact: ArtifactCapability;
|
|
76
76
|
readonly fetch: typeof fetch;
|
|
77
77
|
readonly logger: TaskLogger;
|
|
78
|
-
/** Reads the
|
|
79
|
-
getPrevious(): Promise<PreviousNode
|
|
78
|
+
/** Reads the selected direct predecessors, sorted by node ID; empty for a graph root. */
|
|
79
|
+
getPrevious(): Promise<readonly PreviousNode[]>;
|
|
80
80
|
preview(payload: PreviewPayload, id?: string): Promise<void>;
|
|
81
81
|
reportProgress(progress: number): Promise<void>;
|
|
82
82
|
}
|
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@ Use `<!-- agentic:var flowCommand -->` to operate the selected deployment.
|
|
|
9
9
|
Consult the references relevant to the task:
|
|
10
10
|
|
|
11
11
|
- [Flow capabilities and examples](references/flow-authoring.md): inspect, edit,
|
|
12
|
-
connect, validate, run and publish;
|
|
12
|
+
connect, validate, run and publish; import/export workflow templates; online entries and Flow enable/disable;
|
|
13
13
|
concurrency and Run diagnostics.
|
|
14
14
|
- [n8n conversion](references/flow-n8n-conversion.md): represent collections,
|
|
15
15
|
branches, provider operations and state while preserving source behavior.
|
|
@@ -29,5 +29,8 @@ Server; do not duplicate them in the CLI.
|
|
|
29
29
|
<!-- agentic:endif -->
|
|
30
30
|
|
|
31
31
|
Keep the requested boundary: editing a Draft does not authorize a Run,
|
|
32
|
-
publication, or enabling automatic execution.
|
|
33
|
-
|
|
32
|
+
publication, or enabling automatic execution. Inspecting an entry does not
|
|
33
|
+
by itself authorize invoking it. For edits, report the Flow and Revision,
|
|
34
|
+
verification result, and unresolved configuration. For a publication, report
|
|
35
|
+
the Publication and available online entries. For a query, report the observed
|
|
36
|
+
online state.
|
|
@@ -22,12 +22,33 @@ text. It builds internal definitions, ports and Module identities for you.
|
|
|
22
22
|
`schema TYPE` supplies the current contract and a node example; `schema edit`
|
|
23
23
|
supplies the edit operations. Use these when a configuration is unfamiliar.
|
|
24
24
|
|
|
25
|
+
## Share a workflow template
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
<!-- agentic:var flowCommand --> export FLOW_ID > template.openflow.json
|
|
29
|
+
<!-- agentic:var flowCommand --> import --file template.openflow.json --name "Imported workflow" --idempotency-key IMPORT_KEY --json
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Export writes only JSON to stdout. Import also accepts `--file -` for stdin and creates
|
|
33
|
+
a new unpublished Draft; it never overwrites the source Flow. Keep the same file, name,
|
|
34
|
+
and idempotency key when retrying an uncertain import. MCP equivalents are `flow_export`
|
|
35
|
+
with `flowId`, and `flow_import` with the JSON `file`, `idempotencyKey`, optional `name`
|
|
36
|
+
and optional target `teamId`.
|
|
37
|
+
|
|
38
|
+
Both operations clear structured accounts, Variables, error-source workflows and
|
|
39
|
+
Trigger resource selections. Graphs, shared code Modules, fixed inputs, prompts, model
|
|
40
|
+
choices and layout remain. Inspect the imported Draft, configure missing resources with
|
|
41
|
+
the normal editor or authoring interface, and check it before running or publishing.
|
|
42
|
+
Code, prompts and business JSON may still contain literal sensitive data. Review the
|
|
43
|
+
file before sharing; cleanup does not rewrite arbitrary strings.
|
|
44
|
+
|
|
25
45
|
## Find a Flow or a relevant part
|
|
26
46
|
|
|
27
47
|
```bash
|
|
28
48
|
<!-- agentic:var flowCommand --> list --json
|
|
29
49
|
<!-- agentic:var flowCommand --> create "Order summary" --json
|
|
30
50
|
<!-- agentic:var flowCommand --> show FLOW_ID --json
|
|
51
|
+
<!-- agentic:var flowCommand --> live FLOW_ID --json
|
|
31
52
|
<!-- agentic:var flowCommand --> read FLOW_ID --json
|
|
32
53
|
<!-- agentic:var flowCommand --> search FLOW_ID --input '{"query":"Customer summary","type":"agent"}' --json
|
|
33
54
|
<!-- agentic:var flowCommand --> read FLOW_ID --input '{"revision":"REVISION","nodes":["NODE"]}' --json
|
|
@@ -35,7 +56,10 @@ supplies the edit operations. Use these when a configuration is unfamiliar.
|
|
|
35
56
|
```
|
|
36
57
|
|
|
37
58
|
A known Flow ID avoids a list lookup. `show` gives lifecycle and publication
|
|
38
|
-
state. `
|
|
59
|
+
state. `live` gives the current published version, enablement, and online entries,
|
|
60
|
+
including Webhook URLs and request fields. `resourceReferences.draft` in Flow
|
|
61
|
+
metadata describes Draft dependencies, not online resources. `read` defaults to
|
|
62
|
+
the Draft and gives a graph outline, selected node details, or a text excerpt;
|
|
39
63
|
`nodes` and `text` are alternative modes. `search` finds matches in names,
|
|
40
64
|
configuration and source text, optionally restricted by node type.
|
|
41
65
|
|
|
@@ -342,33 +366,27 @@ Use the observed Live publication ID for `--expected-publication`; if it changed
|
|
|
342
366
|
read the current state before deciding whether to apply the switch to that version.
|
|
343
367
|
The MCP equivalent is `flow_set_enabled({ flowId, expectedPublicationId, enabled })`.
|
|
344
368
|
|
|
369
|
+
Successful `publish` includes the same `live` details as `live FLOW_ID --json`;
|
|
370
|
+
use that result without immediately querying again. Query `live` after waiting
|
|
371
|
+
for an asynchronous publication, when details are missing, or when current state
|
|
372
|
+
is needed later. An unpublished Flow returns `status: not-published` with no entries.
|
|
373
|
+
|
|
374
|
+
For an authorized Webhook call, use the entry's `binding.endpointUrl`,
|
|
375
|
+
`config.method`, and `config.body` field contracts. These retain schema,
|
|
376
|
+
nullable and default semantics; methods without a request body have no body
|
|
377
|
+
fields. Do not reconstruct URLs from node IDs. Flow `enabled` and `status` are
|
|
378
|
+
independent of a binding's `health` and `listener`; a healthy
|
|
379
|
+
subscription alone does not establish that automatic execution is enabled.
|
|
380
|
+
Shared event source and account references can be inspected through their own
|
|
381
|
+
commands when relevant.
|
|
382
|
+
|
|
345
383
|
`workbench` returns a URL; `open` opens the system browser. Browser authentication
|
|
346
384
|
belongs to the host. An open Workbench receives Revision notifications, so a CLI
|
|
347
385
|
edit does not require a page reload.
|
|
348
386
|
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
<!-- agentic:var flowCommand --> resources FLOW_ID --json
|
|
353
|
-
<!-- agentic:var flowCommand --> resources FLOW_ID RESOURCE_ID --json
|
|
354
|
-
<!-- agentic:var flowCommand --> publications list FLOW_ID --json
|
|
355
|
-
<!-- agentic:var flowCommand --> resources FLOW_ID --publication PUBLICATION_ID --json
|
|
356
|
-
```
|
|
357
|
-
|
|
358
|
-
`resources` defaults to the current Live publication and returns its managed
|
|
359
|
-
Trigger resources, runtime health and Webhook URLs. The response's `enabled`
|
|
360
|
-
describes the Flow switch; healthy resources can belong to a disabled Flow.
|
|
361
|
-
Use a returned `resourceId` for detail, and pin `publicationId` when subsequent
|
|
362
|
-
reads must refer to the same publication. Configuration comes from the fixed
|
|
363
|
-
published Revision, so unpublished Draft edits do not appear here.
|
|
364
|
-
|
|
365
|
-
Historical results contain configuration only, without runtime state, `enabled`
|
|
366
|
-
or callable URLs. Querying history does not reactivate it; restoring a historical
|
|
367
|
-
version requires an authorized rollback. Manual entry nodes are read through
|
|
368
|
-
`read` and are not managed resources. `trigger search` and `trigger show` discover
|
|
369
|
-
provider Trigger definitions; use `resources` to inspect a Flow's published Triggers.
|
|
370
|
-
MCP equivalents are `flow_resources({ flowId, publicationId? })` and
|
|
371
|
-
`flow_resource_get({ flowId, resourceId, publicationId? })`.
|
|
387
|
+
`live` includes Manual entry nodes without a runtime binding. `trigger search`
|
|
388
|
+
and `trigger show` discover provider definitions; `live` inspects the Flow's
|
|
389
|
+
current online entries. The MCP equivalent is `flow_live({ flowId })`.
|
|
372
390
|
|
|
373
391
|
## Recover without losing another change or repeating an effect
|
|
374
392
|
|
|
@@ -380,6 +398,12 @@ MCP equivalents are `flow_resources({ flowId, publicationId? })` and
|
|
|
380
398
|
resolve that uncertainty; a new key describes a new mutation.
|
|
381
399
|
- **Saved with diagnostics:** the edit happened. Repair the saved Revision or
|
|
382
400
|
investigate unavailable validation; resubmitting it is not a validation step.
|
|
401
|
+
- **Published with detail warnings:** a succeeded `operation` confirms the
|
|
402
|
+
publication even if metadata or online details could not be read. Query `live`
|
|
403
|
+
rather than publishing again to retrieve an address. A pending operation still
|
|
404
|
+
requires observing that same operation. If `live.publication.publicationId`
|
|
405
|
+
differs from the successful operation's `publicationId`, the entries describe
|
|
406
|
+
the current Live version, not the earlier publication.
|
|
383
407
|
- **Failed Run:** events and results identify the failing node and available
|
|
384
408
|
inputs. Consider already-completed external effects before running it again.
|
|
385
409
|
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import type { JsonValue, RevisionContent } from '../browser/flow-change.js';
|
|
2
|
-
import type { TriggerBinding } from './control-api.js';
|
|
3
|
-
export interface PublicationResource {
|
|
4
|
-
readonly resourceId: string;
|
|
5
|
-
readonly kind: 'trigger';
|
|
6
|
-
readonly type: TriggerBinding['kind'];
|
|
7
|
-
readonly name: string;
|
|
8
|
-
readonly description?: string;
|
|
9
|
-
readonly config: JsonValue;
|
|
10
|
-
readonly inputs: JsonValue;
|
|
11
|
-
readonly runtime?: TriggerBinding;
|
|
12
|
-
}
|
|
13
|
-
export interface PublicationResourceContext {
|
|
14
|
-
readonly flowId: string;
|
|
15
|
-
readonly publicationId: string;
|
|
16
|
-
readonly revisionId: string;
|
|
17
|
-
readonly status: 'live' | 'historical';
|
|
18
|
-
readonly enabled?: boolean;
|
|
19
|
-
readonly version: 1;
|
|
20
|
-
}
|
|
21
|
-
export interface PublicationResources extends PublicationResourceContext {
|
|
22
|
-
readonly resources: readonly PublicationResource[];
|
|
23
|
-
}
|
|
24
|
-
export interface PublicationResourceDetail extends PublicationResourceContext {
|
|
25
|
-
readonly resource: PublicationResource;
|
|
26
|
-
}
|
|
27
|
-
export declare function publicationResources(content: RevisionContent): readonly PublicationResource[];
|
|
28
|
-
export declare function decodePublicationResources(value: unknown): PublicationResources;
|
|
29
|
-
export declare function decodePublicationResource(value: unknown): PublicationResourceDetail;
|