@usecrow/client 0.1.36 → 0.1.37
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/PageController-Cu6KUkcn.cjs +9 -0
- package/dist/{PageController-BweWYS-Z.js → PageController-D3uwrwlG.js} +588 -382
- package/dist/browser.cjs +1 -1
- package/dist/browser.d.ts +65 -0
- package/dist/browser.js +2 -2
- package/dist/{browserUse-Btg7osSj.js → browserUse-Cioetz2-.js} +1 -1
- package/dist/{browserUse-BjeJDX8x.cjs → browserUse-DYW8fqvT.cjs} +1 -1
- package/dist/index.cjs +3 -3
- package/dist/index.d.ts +415 -0
- package/dist/index.js +208 -78
- package/package.json +1 -1
- package/dist/PageController-BDcmu8Xe.cjs +0 -9
package/dist/index.d.ts
CHANGED
|
@@ -1,9 +1,28 @@
|
|
|
1
|
+
declare interface ActionResult {
|
|
2
|
+
success: boolean;
|
|
3
|
+
message: string;
|
|
4
|
+
}
|
|
5
|
+
|
|
1
6
|
export declare interface ActiveWorkflow {
|
|
2
7
|
name: string;
|
|
3
8
|
todos: WorkflowTodo[];
|
|
4
9
|
isComplete?: boolean;
|
|
5
10
|
}
|
|
6
11
|
|
|
12
|
+
/**
|
|
13
|
+
* Structured browser state for LLM consumption
|
|
14
|
+
*/
|
|
15
|
+
declare interface BrowserState {
|
|
16
|
+
url: string;
|
|
17
|
+
title: string;
|
|
18
|
+
/** Page info + scroll position hint (e.g. "Page info: 1920x1080px...\n[Start of page]") */
|
|
19
|
+
header: string;
|
|
20
|
+
/** Simplified HTML of interactive elements */
|
|
21
|
+
content: string;
|
|
22
|
+
/** Page footer hint (e.g. "... 300 pixels below ..." or "[End of page]") */
|
|
23
|
+
footer: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
7
26
|
declare interface BrowserUseConfig {
|
|
8
27
|
productId: string;
|
|
9
28
|
apiUrl: string;
|
|
@@ -20,6 +39,8 @@ export declare interface Citation {
|
|
|
20
39
|
page?: number;
|
|
21
40
|
}
|
|
22
41
|
|
|
42
|
+
declare function cleanUpHighlights(): void;
|
|
43
|
+
|
|
23
44
|
export declare interface ContextData {
|
|
24
45
|
/** Current page URL or path */
|
|
25
46
|
page?: string;
|
|
@@ -317,6 +338,87 @@ export declare const DEFAULT_TOOLS: ToolHandlers;
|
|
|
317
338
|
|
|
318
339
|
export declare type DefaultToolName = keyof typeof DEFAULT_TOOLS;
|
|
319
340
|
|
|
341
|
+
declare namespace dom {
|
|
342
|
+
export {
|
|
343
|
+
getFlatTree,
|
|
344
|
+
flatTreeToString,
|
|
345
|
+
getSelectorMap,
|
|
346
|
+
getElementTextMap,
|
|
347
|
+
cleanUpHighlights,
|
|
348
|
+
DomConfig,
|
|
349
|
+
getAllTextTillNextClickableElement
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
declare interface DomConfig {
|
|
354
|
+
interactiveBlacklist?: (Element | (() => Element))[];
|
|
355
|
+
interactiveWhitelist?: (Element | (() => Element))[];
|
|
356
|
+
include_attributes?: string[];
|
|
357
|
+
highlightOpacity?: number;
|
|
358
|
+
highlightLabelOpacity?: number;
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
declare type DomNode = TextDomNode | ElementDomNode | InteractiveElementDomNode;
|
|
362
|
+
|
|
363
|
+
declare interface ElementDomNode {
|
|
364
|
+
tagName: string;
|
|
365
|
+
attributes?: Record<string, string>;
|
|
366
|
+
xpath?: string;
|
|
367
|
+
children?: string[];
|
|
368
|
+
isVisible?: boolean;
|
|
369
|
+
isTopElement?: boolean;
|
|
370
|
+
isInViewport?: boolean;
|
|
371
|
+
isNew?: boolean;
|
|
372
|
+
isInteractive?: false;
|
|
373
|
+
highlightIndex?: number;
|
|
374
|
+
extra?: Record<string, any>;
|
|
375
|
+
[key: string]: unknown;
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
/**
|
|
379
|
+
* Derived from @page-agent/page-controller
|
|
380
|
+
* Original: https://github.com/alibaba/page-agent
|
|
381
|
+
* Copyright (c) 2025 Alibaba Group Holding Limited
|
|
382
|
+
* Licensed under MIT License
|
|
383
|
+
*/
|
|
384
|
+
declare interface FlatDomTree {
|
|
385
|
+
rootId: string;
|
|
386
|
+
map: Record<string, DomNode>;
|
|
387
|
+
}
|
|
388
|
+
|
|
389
|
+
/**
|
|
390
|
+
* 对应 python 中的 views::clickable_elements_to_string,
|
|
391
|
+
* 将 dom 信息处理成适合 llm 阅读的文本格式
|
|
392
|
+
* @形如
|
|
393
|
+
* ``` text
|
|
394
|
+
* [0]<a aria-label=page-agent.js 首页 />
|
|
395
|
+
* [1]<div >P />
|
|
396
|
+
* [2]<div >page-agent.js
|
|
397
|
+
* UI Agent in your webpage />
|
|
398
|
+
* [3]<a >文档 />
|
|
399
|
+
* [4]<a aria-label=查看源码(在新窗口打开)>源码 />
|
|
400
|
+
* UI Agent in your webpage
|
|
401
|
+
* 用户输入需求,AI 理解页面并自动操作。
|
|
402
|
+
* [5]<a role=button>快速开始 />
|
|
403
|
+
* [6]<a role=button>查看文档 />
|
|
404
|
+
* 无需后端
|
|
405
|
+
* ```
|
|
406
|
+
* 其中可交互元素用序号标出,提示llm可以用序号操作。
|
|
407
|
+
* 缩进代表父子关系。
|
|
408
|
+
* 普通文本则直接列出来。
|
|
409
|
+
*
|
|
410
|
+
* @todo 数据脱敏过滤器
|
|
411
|
+
*/
|
|
412
|
+
declare function flatTreeToString(flatTree: FlatDomTree, include_attributes?: string[]): string;
|
|
413
|
+
|
|
414
|
+
declare const getAllTextTillNextClickableElement: (node: TreeNode, maxDepth?: number) => string;
|
|
415
|
+
|
|
416
|
+
declare function getElementTextMap(simplifiedHTML: string): Map<number, string>;
|
|
417
|
+
|
|
418
|
+
declare function getFlatTree(config: DomConfig): FlatDomTree;
|
|
419
|
+
|
|
420
|
+
declare function getSelectorMap(flatTree: FlatDomTree): Map<number, InteractiveElementDomNode>;
|
|
421
|
+
|
|
320
422
|
export declare interface IdentifyOptions {
|
|
321
423
|
/** JWT token from your backend for user verification */
|
|
322
424
|
token: string;
|
|
@@ -372,6 +474,30 @@ export declare interface IdentityState {
|
|
|
372
474
|
isVerified: boolean;
|
|
373
475
|
}
|
|
374
476
|
|
|
477
|
+
export declare interface InputSchemaFieldDef {
|
|
478
|
+
name: string;
|
|
479
|
+
type: 'string' | 'number' | 'bool';
|
|
480
|
+
required: boolean;
|
|
481
|
+
default_value?: string;
|
|
482
|
+
}
|
|
483
|
+
|
|
484
|
+
declare interface InteractiveElementDomNode {
|
|
485
|
+
tagName: string;
|
|
486
|
+
attributes?: Record<string, string>;
|
|
487
|
+
xpath?: string;
|
|
488
|
+
children?: string[];
|
|
489
|
+
isVisible?: boolean;
|
|
490
|
+
isTopElement?: boolean;
|
|
491
|
+
isInViewport?: boolean;
|
|
492
|
+
isInteractive: true;
|
|
493
|
+
highlightIndex: number;
|
|
494
|
+
/**
|
|
495
|
+
* 可交互元素的 dom 引用
|
|
496
|
+
*/
|
|
497
|
+
ref: HTMLElement;
|
|
498
|
+
[key: string]: unknown;
|
|
499
|
+
}
|
|
500
|
+
|
|
375
501
|
export declare interface Message {
|
|
376
502
|
id: string;
|
|
377
503
|
content: string;
|
|
@@ -392,6 +518,193 @@ export declare interface NavigationRoute {
|
|
|
392
518
|
params?: Record<string, string>;
|
|
393
519
|
}
|
|
394
520
|
|
|
521
|
+
/**
|
|
522
|
+
* PageController manages DOM state and element interactions.
|
|
523
|
+
* It provides async methods for all DOM operations, keeping state isolated.
|
|
524
|
+
*
|
|
525
|
+
* @lifecycle
|
|
526
|
+
* - beforeUpdate: Emitted before the DOM tree is updated.
|
|
527
|
+
* - afterUpdate: Emitted after the DOM tree is updated.
|
|
528
|
+
*/
|
|
529
|
+
declare class PageController extends EventTarget {
|
|
530
|
+
private config;
|
|
531
|
+
/** Corresponds to eval_page in browser-use */
|
|
532
|
+
private flatTree;
|
|
533
|
+
/**
|
|
534
|
+
* All highlighted index-mapped interactive elements
|
|
535
|
+
* Corresponds to DOMState.selector_map in browser-use
|
|
536
|
+
*/
|
|
537
|
+
private selectorMap;
|
|
538
|
+
/** Index -> element text description mapping */
|
|
539
|
+
private elementTextMap;
|
|
540
|
+
/**
|
|
541
|
+
* Simplified HTML for LLM consumption.
|
|
542
|
+
* Corresponds to clickable_elements_to_string in browser-use
|
|
543
|
+
*/
|
|
544
|
+
private simplifiedHTML;
|
|
545
|
+
/** last time the tree was updated */
|
|
546
|
+
private lastTimeUpdate;
|
|
547
|
+
/** Whether the tree has been indexed at least once */
|
|
548
|
+
private isIndexed;
|
|
549
|
+
/** Visual mask overlay for blocking user interaction during automation */
|
|
550
|
+
private mask;
|
|
551
|
+
private maskReady;
|
|
552
|
+
constructor(config?: PageControllerConfig);
|
|
553
|
+
/**
|
|
554
|
+
* Initialize mask asynchronously (dynamic import to avoid CSS loading in Node)
|
|
555
|
+
*/
|
|
556
|
+
initMask(): void;
|
|
557
|
+
/**
|
|
558
|
+
* Get current page URL
|
|
559
|
+
*/
|
|
560
|
+
getCurrentUrl(): Promise<string>;
|
|
561
|
+
/**
|
|
562
|
+
* Get last tree update timestamp
|
|
563
|
+
*/
|
|
564
|
+
getLastUpdateTime(): Promise<number>;
|
|
565
|
+
/**
|
|
566
|
+
* Get structured browser state for LLM consumption.
|
|
567
|
+
* Automatically calls updateTree() to refresh the DOM state.
|
|
568
|
+
*/
|
|
569
|
+
getBrowserState(): Promise<BrowserState>;
|
|
570
|
+
/**
|
|
571
|
+
* Update DOM tree, returns simplified HTML for LLM.
|
|
572
|
+
* This is the main method to refresh the page state.
|
|
573
|
+
* Automatically bypasses mask during DOM extraction if enabled.
|
|
574
|
+
*/
|
|
575
|
+
updateTree(): Promise<string>;
|
|
576
|
+
/**
|
|
577
|
+
* Clean up all element highlights
|
|
578
|
+
*/
|
|
579
|
+
cleanUpHighlights(): Promise<void>;
|
|
580
|
+
/**
|
|
581
|
+
* Ensure the tree has been indexed before any index-based operation.
|
|
582
|
+
* Throws if updateTree() hasn't been called yet.
|
|
583
|
+
*/
|
|
584
|
+
private assertIndexed;
|
|
585
|
+
/**
|
|
586
|
+
* Click element by index
|
|
587
|
+
*/
|
|
588
|
+
clickElement(index: number): Promise<ActionResult>;
|
|
589
|
+
/**
|
|
590
|
+
* Input text into element by index
|
|
591
|
+
*/
|
|
592
|
+
inputText(index: number, text: string): Promise<ActionResult>;
|
|
593
|
+
/**
|
|
594
|
+
* Select dropdown option by index and option text
|
|
595
|
+
*/
|
|
596
|
+
selectOption(index: number, optionText: string): Promise<ActionResult>;
|
|
597
|
+
/**
|
|
598
|
+
* Scroll vertically
|
|
599
|
+
*/
|
|
600
|
+
scroll(options: {
|
|
601
|
+
down: boolean;
|
|
602
|
+
numPages: number;
|
|
603
|
+
pixels?: number;
|
|
604
|
+
index?: number;
|
|
605
|
+
}): Promise<ActionResult>;
|
|
606
|
+
/**
|
|
607
|
+
* Scroll horizontally
|
|
608
|
+
*/
|
|
609
|
+
scrollHorizontally(options: {
|
|
610
|
+
right: boolean;
|
|
611
|
+
pixels: number;
|
|
612
|
+
index?: number;
|
|
613
|
+
}): Promise<ActionResult>;
|
|
614
|
+
/**
|
|
615
|
+
* Execute arbitrary JavaScript on the page
|
|
616
|
+
*/
|
|
617
|
+
executeJavascript(script: string): Promise<ActionResult>;
|
|
618
|
+
/**
|
|
619
|
+
* Find an interactive element index by visible text (exact match).
|
|
620
|
+
* Scans the elementTextMap for a match.
|
|
621
|
+
*/
|
|
622
|
+
findElementByText(text: string, exact?: boolean): number | null;
|
|
623
|
+
/**
|
|
624
|
+
* Find an interactive element index by CSS selector.
|
|
625
|
+
* Queries the DOM, then reverse-looks up in selectorMap.
|
|
626
|
+
*/
|
|
627
|
+
findElementBySelector(cssSelector: string): number | null;
|
|
628
|
+
/**
|
|
629
|
+
* Find an interactive element index by XPath.
|
|
630
|
+
* Evaluates the XPath, then reverse-looks up in selectorMap.
|
|
631
|
+
*/
|
|
632
|
+
findElementByXPath(xpath: string): number | null;
|
|
633
|
+
/**
|
|
634
|
+
* Find an interactive element index by aria-label attribute.
|
|
635
|
+
*/
|
|
636
|
+
findElementByAriaLabel(label: string): number | null;
|
|
637
|
+
/**
|
|
638
|
+
* Find an interactive element index by placeholder text.
|
|
639
|
+
*/
|
|
640
|
+
findElementByPlaceholder(placeholder: string): number | null;
|
|
641
|
+
/**
|
|
642
|
+
* Multi-strategy element finder. Tries strategies in priority order.
|
|
643
|
+
* Returns the index of the first match, or null if nothing found.
|
|
644
|
+
*/
|
|
645
|
+
findElementByStrategies(strategies: Array<{
|
|
646
|
+
type: 'text_exact' | 'text_contains' | 'aria_label' | 'placeholder' | 'css' | 'xpath';
|
|
647
|
+
value: string;
|
|
648
|
+
priority: number;
|
|
649
|
+
}>): number | null;
|
|
650
|
+
/**
|
|
651
|
+
* Press a key on an element (or the active element if no index provided).
|
|
652
|
+
*/
|
|
653
|
+
pressKey(key: string, index?: number): Promise<ActionResult>;
|
|
654
|
+
/**
|
|
655
|
+
* Navigate to a URL. Restricts to same-origin http(s) URLs for security.
|
|
656
|
+
*/
|
|
657
|
+
navigateToUrl(url: string): Promise<ActionResult>;
|
|
658
|
+
/**
|
|
659
|
+
* Go back in browser history.
|
|
660
|
+
*/
|
|
661
|
+
goBack(): Promise<ActionResult>;
|
|
662
|
+
/**
|
|
663
|
+
* Go forward in browser history.
|
|
664
|
+
*/
|
|
665
|
+
goForward(): Promise<ActionResult>;
|
|
666
|
+
/**
|
|
667
|
+
* Wait until an element matching the given strategies appears in the DOM,
|
|
668
|
+
* or until the timeout is reached. Refreshes the DOM tree on each poll.
|
|
669
|
+
*/
|
|
670
|
+
waitForElement(strategies: Array<{
|
|
671
|
+
type: 'text_exact' | 'text_contains' | 'aria_label' | 'placeholder' | 'css' | 'xpath';
|
|
672
|
+
value: string;
|
|
673
|
+
priority: number;
|
|
674
|
+
}>, timeoutMs?: number, pollIntervalMs?: number): Promise<number | null>;
|
|
675
|
+
/**
|
|
676
|
+
* Get the current selectorMap (for external use like WorkflowExecutor).
|
|
677
|
+
*/
|
|
678
|
+
getSelectorMap(): Map<number, InteractiveElementDomNode>;
|
|
679
|
+
/**
|
|
680
|
+
* Get the current elementTextMap (for external use like WorkflowExecutor).
|
|
681
|
+
*/
|
|
682
|
+
getElementTextMap(): Map<number, string>;
|
|
683
|
+
/**
|
|
684
|
+
* Show the visual mask overlay.
|
|
685
|
+
* Only works after mask is setup.
|
|
686
|
+
*/
|
|
687
|
+
showMask(): Promise<void>;
|
|
688
|
+
/**
|
|
689
|
+
* Hide the visual mask overlay.
|
|
690
|
+
* Only works after mask is setup.
|
|
691
|
+
*/
|
|
692
|
+
hideMask(): Promise<void>;
|
|
693
|
+
/**
|
|
694
|
+
* Dispose and clean up resources
|
|
695
|
+
*/
|
|
696
|
+
dispose(): void;
|
|
697
|
+
}
|
|
698
|
+
|
|
699
|
+
/**
|
|
700
|
+
* Configuration for PageController
|
|
701
|
+
*/
|
|
702
|
+
declare interface PageControllerConfig extends dom.DomConfig {
|
|
703
|
+
viewportExpansion?: number;
|
|
704
|
+
/** Enable visual mask overlay during operations (default: false) */
|
|
705
|
+
enableMask?: boolean;
|
|
706
|
+
}
|
|
707
|
+
|
|
395
708
|
/**
|
|
396
709
|
* Parse SSE chunk into lines and extract data
|
|
397
710
|
*/
|
|
@@ -402,6 +715,26 @@ export declare function parseSSEChunk(chunk: string): Generator<string>;
|
|
|
402
715
|
*/
|
|
403
716
|
export declare function parseSSEData(data: string): StreamEvent | null;
|
|
404
717
|
|
|
718
|
+
export declare interface RecordedStepDef {
|
|
719
|
+
type: 'click' | 'input' | 'select' | 'keypress' | 'navigation';
|
|
720
|
+
description: string;
|
|
721
|
+
target_text: string;
|
|
722
|
+
selector_strategies: SelectorStrategy[];
|
|
723
|
+
value?: string;
|
|
724
|
+
url?: string;
|
|
725
|
+
element_tag: string;
|
|
726
|
+
container_hint?: string;
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
export declare interface RecordedWorkflowDef {
|
|
730
|
+
id: string;
|
|
731
|
+
name: string;
|
|
732
|
+
description?: string;
|
|
733
|
+
steps: RecordedStepDef[];
|
|
734
|
+
input_schema: InputSchemaFieldDef[];
|
|
735
|
+
enabled: boolean;
|
|
736
|
+
}
|
|
737
|
+
|
|
405
738
|
/**
|
|
406
739
|
* Resolve a route template by interpolating :param placeholders with actual values.
|
|
407
740
|
*
|
|
@@ -411,6 +744,21 @@ export declare function parseSSEData(data: string): StreamEvent | null;
|
|
|
411
744
|
*/
|
|
412
745
|
export declare function resolveRoute(routes: NavigationRoute[], pageName: string, params?: Record<string, unknown>): string | null;
|
|
413
746
|
|
|
747
|
+
export declare interface SelectorStrategy {
|
|
748
|
+
type: 'text_exact' | 'text_contains' | 'aria_label' | 'placeholder' | 'css' | 'xpath';
|
|
749
|
+
value: string;
|
|
750
|
+
priority: number;
|
|
751
|
+
}
|
|
752
|
+
|
|
753
|
+
export declare interface StepResult {
|
|
754
|
+
step_index: number;
|
|
755
|
+
step_type: string;
|
|
756
|
+
description: string;
|
|
757
|
+
success: boolean;
|
|
758
|
+
message: string;
|
|
759
|
+
element_index?: number;
|
|
760
|
+
}
|
|
761
|
+
|
|
414
762
|
export declare type StreamEvent = {
|
|
415
763
|
type: 'content';
|
|
416
764
|
text: string;
|
|
@@ -481,6 +829,13 @@ export declare type StreamEvent = {
|
|
|
481
829
|
*/
|
|
482
830
|
export declare function streamResponse(response: Response, signal?: AbortSignal): AsyncGenerator<StreamEvent>;
|
|
483
831
|
|
|
832
|
+
declare interface TextDomNode {
|
|
833
|
+
type: 'TEXT_NODE';
|
|
834
|
+
text: string;
|
|
835
|
+
isVisible: boolean;
|
|
836
|
+
[key: string]: unknown;
|
|
837
|
+
}
|
|
838
|
+
|
|
484
839
|
export declare type ToolHandler = (args: Record<string, unknown>) => Promise<ToolResult> | ToolResult;
|
|
485
840
|
|
|
486
841
|
export declare type ToolHandlers = Record<string, ToolHandler>;
|
|
@@ -515,6 +870,66 @@ export declare interface ToolResult {
|
|
|
515
870
|
error?: string;
|
|
516
871
|
}
|
|
517
872
|
|
|
873
|
+
/**
|
|
874
|
+
* elementsToString 内部使用的类型
|
|
875
|
+
*/
|
|
876
|
+
declare interface TreeNode {
|
|
877
|
+
type: 'text' | 'element';
|
|
878
|
+
parent: TreeNode | null;
|
|
879
|
+
children: TreeNode[];
|
|
880
|
+
isVisible: boolean;
|
|
881
|
+
text?: string;
|
|
882
|
+
tagName?: string;
|
|
883
|
+
attributes?: Record<string, string>;
|
|
884
|
+
isInteractive?: boolean;
|
|
885
|
+
isTopElement?: boolean;
|
|
886
|
+
isNew?: boolean;
|
|
887
|
+
highlightIndex?: number;
|
|
888
|
+
extra?: Record<string, any>;
|
|
889
|
+
}
|
|
890
|
+
|
|
891
|
+
export declare class WorkflowExecutor {
|
|
892
|
+
private controller;
|
|
893
|
+
private config;
|
|
894
|
+
constructor(controller: PageController, config?: WorkflowExecutorConfig);
|
|
895
|
+
/**
|
|
896
|
+
* Execute a recorded workflow with variable substitution.
|
|
897
|
+
*/
|
|
898
|
+
execute(workflow: RecordedWorkflowDef, inputs?: Record<string, string | number | boolean>): Promise<WorkflowResult>;
|
|
899
|
+
/**
|
|
900
|
+
* Execute a single step.
|
|
901
|
+
*/
|
|
902
|
+
private executeStep;
|
|
903
|
+
/**
|
|
904
|
+
* Replace {variable_name} placeholders in step fields with actual values.
|
|
905
|
+
*/
|
|
906
|
+
private resolveVariables;
|
|
907
|
+
private delay;
|
|
908
|
+
}
|
|
909
|
+
|
|
910
|
+
export declare interface WorkflowExecutorConfig {
|
|
911
|
+
/** Time to wait for elements to appear after actions (ms). Default: 3000 */
|
|
912
|
+
waitTimeout?: number;
|
|
913
|
+
/** Time between DOM polls when waiting for elements (ms). Default: 300 */
|
|
914
|
+
pollInterval?: number;
|
|
915
|
+
/** Default delay between steps (ms). Default: 500 */
|
|
916
|
+
stepDelay?: number;
|
|
917
|
+
/** Stop execution on first failure. Default: false */
|
|
918
|
+
stopOnFailure?: boolean;
|
|
919
|
+
/** Callback for step progress updates */
|
|
920
|
+
onStepProgress?: (result: StepResult) => void;
|
|
921
|
+
}
|
|
922
|
+
|
|
923
|
+
export declare interface WorkflowResult {
|
|
924
|
+
success: boolean;
|
|
925
|
+
workflow_name: string;
|
|
926
|
+
total_steps: number;
|
|
927
|
+
completed_steps: number;
|
|
928
|
+
failed_steps: number;
|
|
929
|
+
step_results: StepResult[];
|
|
930
|
+
error?: string;
|
|
931
|
+
}
|
|
932
|
+
|
|
518
933
|
export declare interface WorkflowTodo {
|
|
519
934
|
id: string;
|
|
520
935
|
text: string;
|