@uipath/maestro-builder-sdk 6.40.1 → 6.41.1
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/api-index.md +101 -101
- package/dist/api-members.md +292 -292
- package/dist/check.js +8 -487
- package/dist/core/actions.d.ts +0 -391
- package/dist/core/actions.js +0 -167
- package/dist/core/nodes/registry.d.ts +6 -1
- package/dist/core/nodes/registry.js +32 -2
- package/dist/core/nodes/versioned.d.ts +12 -0
- package/dist/core/nodes/versioned.js +7 -2
- package/dist/core/process-resource.d.ts +102 -0
- package/dist/core/process-resource.js +118 -0
- package/dist/core/step-ports.d.ts +1 -1
- package/dist/core/step-ports.js +1 -1
- package/dist/decompile.js +9 -10
- package/dist/flow-node-registry.js +2 -1
- package/dist/flow-sdk.d.ts +1 -0
- package/dist/flow-sdk.js +1 -0
- package/dist/flow-step-exits.js +2 -2
- package/dist/nodes/process/flow/check.d.ts +112 -0
- package/dist/nodes/process/flow/check.js +444 -0
- package/dist/nodes/process/flow/factories.d.ts +158 -0
- package/dist/nodes/process/flow/factories.js +173 -0
- package/dist/nodes/process/flow/family.d.ts +3 -0
- package/dist/nodes/process/flow/family.js +8 -0
- package/dist/nodes/process/flow/index.d.ts +3 -0
- package/dist/nodes/process/flow/index.js +3 -0
- package/dist/nodes/process/flow/node-type.d.ts +23 -0
- package/dist/nodes/process/flow/node-type.js +652 -0
- package/dist/nodes/process/flow/spec.d.ts +255 -0
- package/dist/nodes/process/flow/spec.js +1 -0
- package/dist/serialize.js +41 -612
- package/package.json +2 -2
package/dist/core/actions.d.ts
CHANGED
|
@@ -491,230 +491,6 @@ export interface IxpExtractInputs {
|
|
|
491
491
|
* (`'in-solution'`). Shared by `rpaWorkflow`, `agenticProcess` and `agent`.
|
|
492
492
|
*/
|
|
493
493
|
export type ProcessLocation = 'published' | 'in-solution';
|
|
494
|
-
export interface RpaWorkflowInputs {
|
|
495
|
-
/**
|
|
496
|
-
* The published process's release key (a GUID). It becomes part of the node's
|
|
497
|
-
* type, `uipath.core.rpa-workflow.<key>`. Find it with
|
|
498
|
-
* `uip or processes list --all-folders --process-type Process` (the row's `Key`)
|
|
499
|
-
* or `uip maestro flow registry search "uipath.core.rpa-workflow"`.
|
|
500
|
-
*
|
|
501
|
-
* For an in-solution sibling it is `resource.key` from
|
|
502
|
-
* `resources/solution_folder/process/process/<project>.json` — the suffix of the
|
|
503
|
-
* node type `uip maestro flow registry list --local` shows.
|
|
504
|
-
*/
|
|
505
|
-
key: string;
|
|
506
|
-
/** The process's name in Orchestrator — e.g. `'RPA Workflow'`. */
|
|
507
|
-
name: string;
|
|
508
|
-
/**
|
|
509
|
-
* Where the process lives. `'published'` (the default) is a process deployed
|
|
510
|
-
* to `folderPath`. `'in-solution'` is a sibling RPA project of the same
|
|
511
|
-
* solution: it needs `projectId` and no `folderPath`.
|
|
512
|
-
*/
|
|
513
|
-
location?: ProcessLocation;
|
|
514
|
-
/**
|
|
515
|
-
* The Orchestrator folder holding the process — e.g.
|
|
516
|
-
* `'Shared/uipath-maestro-flow/ProjectEuler RPA'`. Required for a published
|
|
517
|
-
* process; omit it for an in-solution sibling.
|
|
518
|
-
*
|
|
519
|
-
* @enforcedBy RPA_NO_FOLDER A published process needs its folder.
|
|
520
|
-
*/
|
|
521
|
-
folderPath?: string;
|
|
522
|
-
/**
|
|
523
|
-
* The sibling RPA project's `resource.projectKey`, read from
|
|
524
|
-
* `resources/solution_folder/process/process/<project>.json`. Required only
|
|
525
|
-
* when `location` is `'in-solution'`.
|
|
526
|
-
*
|
|
527
|
-
* @enforcedBy RPA_LOCAL_NO_PROJECT_ID An in-solution process needs its project id.
|
|
528
|
-
*/
|
|
529
|
-
projectId?: string;
|
|
530
|
-
/**
|
|
531
|
-
* The PROCESS's own input arguments, by its own argument names (e.g.
|
|
532
|
-
* `{ problemId: 123 }`). Not a fixed schema — every process declares its own,
|
|
533
|
-
* and only the deployed process knows them.
|
|
534
|
-
*/
|
|
535
|
-
inputs?: Record<string, unknown>;
|
|
536
|
-
/**
|
|
537
|
-
* The process's OUTPUT arguments — the fields it returns, and their types
|
|
538
|
-
* (e.g. `{ title: 'string' }`). Required if anything reads the step's output.
|
|
539
|
-
*
|
|
540
|
-
* Why you have to say: the process's output schema lives on the tenant, and
|
|
541
|
-
* authoring happens offline. Without it `$vars.<step>.output.<field>` reads
|
|
542
|
-
* from an object with no declared fields, and nothing could tell a real field
|
|
543
|
-
* from a typo. Declaring
|
|
544
|
-
* the fields here is the same thing the platform's own definition does when it
|
|
545
|
-
* can reach the process, and it is what lets a misspelled read be caught at
|
|
546
|
-
* `uip maestro flow check` instead of at run time.
|
|
547
|
-
*
|
|
548
|
-
* @enforcedBy RPA_READ_UNKNOWN_FIELD A read of the output must name a field declared here.
|
|
549
|
-
* @enforcedBy RPA_READ_WITHOUT_RETURNS Reading a field off the result requires declaring it here.
|
|
550
|
-
*/
|
|
551
|
-
returns?: Record<string, ReturnFieldType>;
|
|
552
|
-
}
|
|
553
|
-
export interface ApiWorkflowInputs {
|
|
554
|
-
/**
|
|
555
|
-
* The published API workflow's key (a GUID). It becomes part of the node's
|
|
556
|
-
* type, `uipath.core.api-workflow.<key>`. Find it with
|
|
557
|
-
* `uip or processes list --all-folders --process-type Api` (an API workflow's
|
|
558
|
-
* `ProcessKey` reads `<name>.api.<name>`; the GUID you want is the row's `Key`)
|
|
559
|
-
* or `uip maestro flow registry search`.
|
|
560
|
-
*/
|
|
561
|
-
key: string;
|
|
562
|
-
/** The workflow's name in Orchestrator — e.g. `'NameToAgeFixed'`. */
|
|
563
|
-
name: string;
|
|
564
|
-
/** The Orchestrator folder holding it — e.g. `'Shared'`. */
|
|
565
|
-
folderPath: string;
|
|
566
|
-
/**
|
|
567
|
-
* The WORKFLOW's own input arguments, by its own argument names (e.g.
|
|
568
|
-
* `{ name: 'tomasz' }`). Not a fixed schema — every workflow declares its own.
|
|
569
|
-
*/
|
|
570
|
-
inputs?: Record<string, unknown>;
|
|
571
|
-
/**
|
|
572
|
-
* The workflow's OUTPUT arguments — the fields it returns, and their types
|
|
573
|
-
* (e.g. `{ EstimatedAge: 'integer' }`). Required if anything reads the step's
|
|
574
|
-
* output, for the same reason as `rpaWorkflow`'s: the schema lives on the
|
|
575
|
-
* tenant and authoring happens offline, so an undeclared read is rejected.
|
|
576
|
-
*
|
|
577
|
-
* `'integer'` is what makes the replay fixture a number rather than a string;
|
|
578
|
-
* see {@link ReturnFieldType} for why the vocabulary carries it.
|
|
579
|
-
*
|
|
580
|
-
* @enforcedBy APIWF_READ_WITHOUT_RETURNS Reading a field off the result requires
|
|
581
|
-
* declaring it here.
|
|
582
|
-
*/
|
|
583
|
-
returns?: Record<string, ReturnFieldType>;
|
|
584
|
-
}
|
|
585
|
-
/**
|
|
586
|
-
* A published Orchestrator **Function** — a small, single-purpose unit of code
|
|
587
|
-
* deployed as its own resource and invoked as one step
|
|
588
|
-
* (`Orchestrator.ExecuteFunctionAsync`). Same published-resource shape as
|
|
589
|
-
* {@link ApiWorkflowInputs}; what differs is the family and the folder.
|
|
590
|
-
*/
|
|
591
|
-
export interface PublishedFunctionInputs {
|
|
592
|
-
/**
|
|
593
|
-
* The function's key (a GUID) — it becomes part of the node's type,
|
|
594
|
-
* `uipath.core.function.<key>`. Find it with
|
|
595
|
-
* `uip maestro flow registry search "uipath.core.function"` (after
|
|
596
|
-
* `registry pull --force`) or the Orchestrator process listing.
|
|
597
|
-
*/
|
|
598
|
-
key: string;
|
|
599
|
-
/** The function's name in Orchestrator, e.g. `'acme-echo'`. */
|
|
600
|
-
name: string;
|
|
601
|
-
/**
|
|
602
|
-
* The Orchestrator folder holding it. A function is usually deployed into a
|
|
603
|
-
* folder of its OWN name (e.g. `'Shared/acme-echo'`), and the binding's
|
|
604
|
-
* `resourceKey` is `<folderPath>.<name>` — copy the folder from the tenant
|
|
605
|
-
* rather than assuming `'Shared'`.
|
|
606
|
-
*/
|
|
607
|
-
folderPath: string;
|
|
608
|
-
/** The function's own input arguments, by its own names. */
|
|
609
|
-
inputs?: Record<string, unknown>;
|
|
610
|
-
/**
|
|
611
|
-
* The function's OUTPUT arguments — the fields it returns, and their types.
|
|
612
|
-
* Required if anything reads the step's output: the schema lives on the
|
|
613
|
-
* tenant and authoring is offline, so an undeclared read is rejected.
|
|
614
|
-
*
|
|
615
|
-
* @enforcedBy FUNCTION_READ_WITHOUT_RETURNS Reading a field off the result
|
|
616
|
-
* requires declaring it here.
|
|
617
|
-
*/
|
|
618
|
-
returns?: Record<string, ReturnFieldType>;
|
|
619
|
-
}
|
|
620
|
-
interface AgenticProcessInputsBase {
|
|
621
|
-
/**
|
|
622
|
-
* The published agentic process's key (a GUID). It becomes part of the node's
|
|
623
|
-
* type, `uipath.core.agentic-process.<key>`. Find it with
|
|
624
|
-
* `uip or processes list --all-folders --process-type ProcessOrchestration` (an
|
|
625
|
-
* agentic process's `ProcessKey` reads `<name>.agentic.<name>`; the GUID you want
|
|
626
|
-
* is the row's `Key`) or `uip maestro flow registry search agentic`.
|
|
627
|
-
*
|
|
628
|
-
* `--all-folders` PAGINATES at 50 rows and says so in `Pagination.HasMore` — pass
|
|
629
|
-
* `--limit`/`--offset`, or scope the call with `--folder-path`, or a process that
|
|
630
|
-
* exists will look as though it does not.
|
|
631
|
-
*/
|
|
632
|
-
key: string;
|
|
633
|
-
/** The process's name in Orchestrator — e.g. `'ProcurementProcess'`. */
|
|
634
|
-
name: string;
|
|
635
|
-
/**
|
|
636
|
-
* Where the process lives. `'published'` (the default) is a process deployed
|
|
637
|
-
* to `folderPath`. `'in-solution'` is a sibling Flow of the same solution, so
|
|
638
|
-
* it needs `form: 'flow'`, `projectId` and no `folderPath`; `key` is the
|
|
639
|
-
* sibling's `resource.key` from `resources/solution_folder/process/flow/<project>.json`.
|
|
640
|
-
* Only the Flow form has been run in-solution; `'bpmn'` and `'case'` siblings
|
|
641
|
-
* are refused until they are.
|
|
642
|
-
*
|
|
643
|
-
* @enforcedBy AGENTIC_LOCAL_FORM_UNVERIFIED In-solution is supported for `form: 'flow'` only.
|
|
644
|
-
*/
|
|
645
|
-
location?: ProcessLocation;
|
|
646
|
-
/**
|
|
647
|
-
* The Orchestrator folder holding it — e.g.
|
|
648
|
-
* `'Shared/uipath-agents/ProcurementProcess'`. Required for a published
|
|
649
|
-
* process; omit it for an in-solution sibling.
|
|
650
|
-
*
|
|
651
|
-
* @enforcedBy AGENTIC_NO_FOLDER A published process needs its folder.
|
|
652
|
-
*/
|
|
653
|
-
folderPath?: string;
|
|
654
|
-
/**
|
|
655
|
-
* The sibling project's `resource.projectKey`, read from the same resource
|
|
656
|
-
* file as `key` (`resources/solution_folder/process/flow/<project>.json`).
|
|
657
|
-
* Required only when `location` is `'in-solution'`.
|
|
658
|
-
*
|
|
659
|
-
* @enforcedBy AGENTIC_LOCAL_NO_PROJECT_ID An in-solution process needs its project id.
|
|
660
|
-
*/
|
|
661
|
-
projectId?: string;
|
|
662
|
-
/**
|
|
663
|
-
* The PROCESS's own input arguments, by its own argument names (e.g.
|
|
664
|
-
* `{ productId: 1 }`). Not a fixed schema — every agentic process declares its
|
|
665
|
-
* own, and only the deployed process knows them.
|
|
666
|
-
*/
|
|
667
|
-
inputs?: Record<string, unknown>;
|
|
668
|
-
/**
|
|
669
|
-
* Which published form this Agentic Process is: the three forms
|
|
670
|
-
* share one public concept and differ only in wire identity. `'bpmn'` (the
|
|
671
|
-
* default, and what this factory always emitted) is a Maestro BPMN process
|
|
672
|
-
* orchestration; `'flow'` is a published Maestro Flow; `'case'` is a Case
|
|
673
|
-
* Management process.
|
|
674
|
-
*/
|
|
675
|
-
form?: 'bpmn' | 'flow' | 'case';
|
|
676
|
-
}
|
|
677
|
-
/**
|
|
678
|
-
* Whether an Agentic Process step waits for the process's result.
|
|
679
|
-
* The discriminated union makes `returns` impossible to declare in the
|
|
680
|
-
* fire-and-forget form: an async dispatch publishes no output, so nothing
|
|
681
|
-
* downstream may read one.
|
|
682
|
-
*/
|
|
683
|
-
export type AgenticProcessCompletion = {
|
|
684
|
-
/** Wait for the process and publish its outputs (the default). */
|
|
685
|
-
completion?: 'wait';
|
|
686
|
-
/**
|
|
687
|
-
* The process's OUTPUT arguments — the fields it returns, and their types (e.g.
|
|
688
|
-
* `{ status: 'boolean' }`). Required if anything reads the step's output, for the
|
|
689
|
-
* same reason as `rpaWorkflow`'s and `apiWorkflow`'s: the schema lives on the
|
|
690
|
-
* tenant and authoring happens offline, so an undeclared read is rejected.
|
|
691
|
-
*
|
|
692
|
-
* `uip maestro flow registry get uipath.core.agentic-process.<process>` shows what
|
|
693
|
-
* the platform synthesizes, under `outputDefinition.output.schema.properties`.
|
|
694
|
-
*
|
|
695
|
-
* Worth knowing before you assert on a value: a process can DECLARE a field and
|
|
696
|
-
* still leave it empty. `Shared/uipath-agents/ProcurementProcess` declares
|
|
697
|
-
* `{status: boolean}` and every job returns `{"status": null}` (measured
|
|
698
|
-
* 2026-07-29, four jobs) — the field arrives, the value does not.
|
|
699
|
-
*
|
|
700
|
-
* @enforcedBy AGENTIC_READ_WITHOUT_RETURNS Reading a field off the result requires
|
|
701
|
-
* declaring it here.
|
|
702
|
-
*/
|
|
703
|
-
returns?: Record<string, ReturnFieldType>;
|
|
704
|
-
} | {
|
|
705
|
-
/**
|
|
706
|
-
* Dispatch the process and continue immediately — the platform's
|
|
707
|
-
* fire-and-forget switch. The node keeps only its `error` output (dispatch
|
|
708
|
-
* failures still route), and `check` rejects any read of the step's result.
|
|
709
|
-
* A local replay treats this as dispatch-only: it never fabricates the
|
|
710
|
-
* output a real run would not publish.
|
|
711
|
-
*/
|
|
712
|
-
completion: 'fire-and-forget';
|
|
713
|
-
/** Impossible by design: an async dispatch publishes no output. */
|
|
714
|
-
returns?: never;
|
|
715
|
-
};
|
|
716
|
-
/** What `agenticProcess()` takes: the shared fields plus the completion policy. */
|
|
717
|
-
export type AgenticProcessInputs = AgenticProcessInputsBase & AgenticProcessCompletion;
|
|
718
494
|
/**
|
|
719
495
|
* Which KIND of agent project was published behind a `uipath.core.agent.<key>`
|
|
720
496
|
* resource. Display-only — see {@link AgentInputs.flavour}.
|
|
@@ -1636,18 +1412,6 @@ export interface ContextIndexRef extends AgentResourcePlacement {
|
|
|
1636
1412
|
* whole body rather than an inputs payload.
|
|
1637
1413
|
*/
|
|
1638
1414
|
export interface FlowActionSpecs {
|
|
1639
|
-
/** The spec {@link rpaWorkflow} builds. */
|
|
1640
|
-
rpaWorkflow: {
|
|
1641
|
-
inputs: RpaWorkflowInputs;
|
|
1642
|
-
};
|
|
1643
|
-
/** The spec {@link apiWorkflow} builds. */
|
|
1644
|
-
apiWorkflow: {
|
|
1645
|
-
inputs: ApiWorkflowInputs;
|
|
1646
|
-
};
|
|
1647
|
-
/** The spec {@link publishedFunction} builds. */
|
|
1648
|
-
publishedFunction: {
|
|
1649
|
-
inputs: PublishedFunctionInputs;
|
|
1650
|
-
};
|
|
1651
1415
|
/** The spec {@link createOutgoingCall} builds. */
|
|
1652
1416
|
createOutgoingCall: {
|
|
1653
1417
|
inputs: CreateOutgoingCallInputs;
|
|
@@ -1664,10 +1428,6 @@ export interface FlowActionSpecs {
|
|
|
1664
1428
|
conversationalAgent: {
|
|
1665
1429
|
inputs: ConversationalAgentInputs;
|
|
1666
1430
|
};
|
|
1667
|
-
/** The spec {@link agenticProcess} builds. */
|
|
1668
|
-
agenticProcess: {
|
|
1669
|
-
inputs: AgenticProcessInputs;
|
|
1670
|
-
};
|
|
1671
1431
|
/** The spec {@link agent} builds. */
|
|
1672
1432
|
agent: {
|
|
1673
1433
|
inputs: AgentInputs;
|
|
@@ -1794,111 +1554,6 @@ export declare function builtinTriggerSpec<S extends object>(spec: S): S;
|
|
|
1794
1554
|
* @returns An action spec to pass to `.step(name, …)`.
|
|
1795
1555
|
*/
|
|
1796
1556
|
export declare function ixpExtract(inputs: IxpExtractInputs): ActionSpec;
|
|
1797
|
-
/**
|
|
1798
|
-
* Invoke a deployed RPA (robotic process automation) workflow — a classic
|
|
1799
|
-
* UI-automation process, published to Orchestrator, run by a robot.
|
|
1800
|
-
*
|
|
1801
|
-
* @remarks
|
|
1802
|
-
* Three fields identify the process and they all come from the tenant, which is
|
|
1803
|
-
* why they are named exactly as the platform names them:
|
|
1804
|
-
*
|
|
1805
|
-
* key the published process's release key (a GUID). It becomes part of
|
|
1806
|
-
* the node's TYPE — `uipath.core.rpa-workflow.<key>` — so the
|
|
1807
|
-
* platform can tell one process's node from another's.
|
|
1808
|
-
* name the process's name in Orchestrator.
|
|
1809
|
-
* folderPath the Orchestrator folder it lives in.
|
|
1810
|
-
*
|
|
1811
|
-
* `name` + `folderPath` are what the robot is actually started by (the runtime
|
|
1812
|
-
* re-resolves the release from them), and together they are also the process's
|
|
1813
|
-
* `resourceKey`: `"<folderPath>.<name>"`. The serializer emits the two of them
|
|
1814
|
-
* as the flow's process bindings and points the node at them, because a
|
|
1815
|
-
* bindings entry the node does not reference is not a bound process.
|
|
1816
|
-
*
|
|
1817
|
-
* `inputs` are the PROCESS's own input arguments — whatever it declares, by its
|
|
1818
|
-
* own argument names. They are not a fixed schema.
|
|
1819
|
-
*
|
|
1820
|
-
* The step publishes whatever the process returns, under `output`: read a field
|
|
1821
|
-
* with `out('<step>', '<field>')`. Nothing local can check that an argument name
|
|
1822
|
-
* or a returned field name matches the deployed process — only the robot knows —
|
|
1823
|
-
* so a wrong name shows up as a faulted job on a live run, not at compile time.
|
|
1824
|
-
*
|
|
1825
|
-
* @example
|
|
1826
|
-
* **Start a deployed process and read what it returns**
|
|
1827
|
-
* ```ts
|
|
1828
|
-
* .step('getTitle', rpaWorkflow({
|
|
1829
|
-
* key: '486edc26-0658-4ac1-92c9-1ef953927151',
|
|
1830
|
-
* name: 'RPA Workflow',
|
|
1831
|
-
* folderPath: 'Shared/uipath-maestro-flow/ProjectEuler RPA',
|
|
1832
|
-
* inputs: { problemId: 123 },
|
|
1833
|
-
* }))
|
|
1834
|
-
* .return({ title: out('getTitle', 'title') })
|
|
1835
|
-
* ```
|
|
1836
|
-
*
|
|
1837
|
-
* @param inputs - The published process to start (`key`, `name`, `folderPath`),
|
|
1838
|
-
* its `inputs`, and the output fields you read back via `returns`.
|
|
1839
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
1840
|
-
*/
|
|
1841
|
-
export declare function rpaWorkflow(inputs: RpaWorkflowInputs): ActionSpec;
|
|
1842
|
-
/**
|
|
1843
|
-
* Invoke a deployed API workflow — a coded workflow published to Orchestrator,
|
|
1844
|
-
* run as a serverless job rather than by a robot.
|
|
1845
|
-
*
|
|
1846
|
-
* @remarks
|
|
1847
|
-
* The same three identifiers as `rpaWorkflow`, for the same reason: `key` is
|
|
1848
|
-
* the key the node's TYPE carries (`uipath.core.api-workflow.<key>`), while
|
|
1849
|
-
* `name` + `folderPath` are what the runtime resolves the job by — and together
|
|
1850
|
-
* they are the workflow's `resourceKey`, `"<folderPath>.<name>"`. The serializer
|
|
1851
|
-
* emits those two as the flow's process bindings and points the node at them.
|
|
1852
|
-
*
|
|
1853
|
-
* The step publishes the job's output arguments under `output`, so
|
|
1854
|
-
* `out('<step>', '<field>')` reads one of the fields `returns` declares. Whether
|
|
1855
|
-
* an argument name or a returned field actually matches the deployed workflow is
|
|
1856
|
-
* something only the tenant knows — a wrong one is a faulted job on a live run,
|
|
1857
|
-
* not a compile error.
|
|
1858
|
-
*
|
|
1859
|
-
* @example
|
|
1860
|
-
* **Start an API workflow and read a declared output argument**
|
|
1861
|
-
* ```ts
|
|
1862
|
-
* .step('getAge', apiWorkflow({
|
|
1863
|
-
* key: 'ce857908-ee1d-4392-b552-38bcea0be29c',
|
|
1864
|
-
* name: 'NameToAgeFixed',
|
|
1865
|
-
* folderPath: 'Shared',
|
|
1866
|
-
* inputs: { name: 'tomasz' },
|
|
1867
|
-
* returns: { EstimatedAge: 'integer' },
|
|
1868
|
-
* }))
|
|
1869
|
-
* .return({ age: out('getAge', 'EstimatedAge') })
|
|
1870
|
-
* ```
|
|
1871
|
-
*
|
|
1872
|
-
* @param inputs - The published API workflow to start (`key`, `name`,
|
|
1873
|
-
* `folderPath`), its `inputs`, and the fields you read back via `returns`.
|
|
1874
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
1875
|
-
*/
|
|
1876
|
-
export declare function apiWorkflow(inputs: ApiWorkflowInputs): ActionSpec;
|
|
1877
|
-
/**
|
|
1878
|
-
* Invoke a published Orchestrator **Function** — a deployed unit of code run as
|
|
1879
|
-
* one step (`uipath.core.function.<key>`, dispatched as
|
|
1880
|
-
* `Orchestrator.ExecuteFunctionAsync`).
|
|
1881
|
-
*
|
|
1882
|
-
* ```ts
|
|
1883
|
-
* .step('echo', publishedFunction({
|
|
1884
|
-
* key: '7059bdb5-fdd7-4e13-9d7b-1748aaeb129d',
|
|
1885
|
-
* name: 'acme-echo',
|
|
1886
|
-
* folderPath: 'Shared/acme-echo',
|
|
1887
|
-
* inputs: { message: 'hello' },
|
|
1888
|
-
* returns: { echoed: 'string' },
|
|
1889
|
-
* }))
|
|
1890
|
-
* ```
|
|
1891
|
-
*
|
|
1892
|
-
* The node type carries the key, so the function must already exist on the
|
|
1893
|
-
* tenant — read `key`, `name` and `folderPath` from the registry rather than
|
|
1894
|
-
* constructing them. Like the other published families, the resource identity
|
|
1895
|
-
* is CLOSED by a binding pair (`<folderPath>.<name>`), and two steps on the
|
|
1896
|
-
* same function share one pair.
|
|
1897
|
-
*
|
|
1898
|
-
* @param inputs - The function's identity, its arguments, and what it returns.
|
|
1899
|
-
* @returns An action spec to pass to `.step(...)`.
|
|
1900
|
-
*/
|
|
1901
|
-
export declare function publishedFunction(inputs: PublishedFunctionInputs): ActionSpec;
|
|
1902
1557
|
/**
|
|
1903
1558
|
* Place an outgoing phone call
|
|
1904
1559
|
* (`uipath.conversational.voice.create-outgoing-call`) and get back the
|
|
@@ -1974,52 +1629,6 @@ export declare function voiceAgent(inputs: VoiceAgentInputs): ActionSpec;
|
|
|
1974
1629
|
* @returns An action spec to pass to `.step(...)`.
|
|
1975
1630
|
*/
|
|
1976
1631
|
export declare function conversationalAgent(inputs: ConversationalAgentInputs): ActionSpec;
|
|
1977
|
-
/**
|
|
1978
|
-
* Invoke a deployed AGENTIC PROCESS — a Maestro process orchestration published to
|
|
1979
|
-
* Orchestrator: a BPMN process that coordinates agents, robots and people, started
|
|
1980
|
-
* as a job the same way an RPA or API workflow is.
|
|
1981
|
-
*
|
|
1982
|
-
* @remarks
|
|
1983
|
-
* The same three identifiers as `rpaWorkflow` and `apiWorkflow`, for the same
|
|
1984
|
-
* reason: `key` is the key the node's TYPE carries
|
|
1985
|
-
* (`uipath.core.agentic-process.<key>`), while `name` + `folderPath` are what
|
|
1986
|
-
* the runtime resolves the job by — and together they are the process's
|
|
1987
|
-
* `resourceKey`, `"<folderPath>.<name>"`. The serializer emits those two as the
|
|
1988
|
-
* flow's process bindings and points the node at them.
|
|
1989
|
-
*
|
|
1990
|
-
* By default the step WAITS for the process and publishes its output arguments
|
|
1991
|
-
* under `output`, so `out('<step>', '<field>')` reads one of the fields
|
|
1992
|
-
* `returns` declares.
|
|
1993
|
-
*
|
|
1994
|
-
* `completion: 'fire-and-forget'` selects the designer's own async switch
|
|
1995
|
-
* instead: the node's service type becomes `Orchestrator.Start…ProcessAsync`
|
|
1996
|
-
* and it publishes no output but `error`. The type is a discriminated union, so
|
|
1997
|
-
* `returns` is impossible in that form and nothing downstream can read one; a
|
|
1998
|
-
* local run dispatches without waiting and yields `{ jobKey, started: true }`.
|
|
1999
|
-
*
|
|
2000
|
-
* `form` picks which published Agentic Process this is — `'bpmn'` (the default,
|
|
2001
|
-
* a Maestro process orchestration), `'flow'` (a published Maestro Flow), or
|
|
2002
|
-
* `'case'` (a Case Management process). They share one public concept and
|
|
2003
|
-
* differ only in wire identity.
|
|
2004
|
-
*
|
|
2005
|
-
* @example
|
|
2006
|
-
* **Start a Maestro process and wait for its result**
|
|
2007
|
-
* ```ts
|
|
2008
|
-
* .step('runIntake', agenticProcess({
|
|
2009
|
-
* key: '4fc450ab-89be-4462-8fc8-21ac4c1d6fb9',
|
|
2010
|
-
* name: 'ProcurementProcess',
|
|
2011
|
-
* folderPath: 'Shared/uipath-agents/ProcurementProcess',
|
|
2012
|
-
* inputs: { productId: 1 },
|
|
2013
|
-
* returns: { status: 'boolean' },
|
|
2014
|
-
* }))
|
|
2015
|
-
* .return({ ok: out('runIntake', 'status') })
|
|
2016
|
-
* ```
|
|
2017
|
-
*
|
|
2018
|
-
* @param inputs - The published Maestro process to start (`key`, `name`,
|
|
2019
|
-
* `folderPath`), its `inputs`, and the fields you read back via `returns`.
|
|
2020
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
2021
|
-
*/
|
|
2022
|
-
export declare function agenticProcess(inputs: AgenticProcessInputs): ActionSpec;
|
|
2023
1632
|
/**
|
|
2024
1633
|
* Invoke an AGENT resource — either one published to Orchestrator or a sibling
|
|
2025
1634
|
* agent project registered in the same solution. Both start through
|
package/dist/core/actions.js
CHANGED
|
@@ -145,117 +145,6 @@ export function builtinTriggerSpec(spec) {
|
|
|
145
145
|
export function ixpExtract(inputs) {
|
|
146
146
|
return builtinActionSpec({ kind: 'ixpExtract', inputs });
|
|
147
147
|
}
|
|
148
|
-
/**
|
|
149
|
-
* Invoke a deployed RPA (robotic process automation) workflow — a classic
|
|
150
|
-
* UI-automation process, published to Orchestrator, run by a robot.
|
|
151
|
-
*
|
|
152
|
-
* @remarks
|
|
153
|
-
* Three fields identify the process and they all come from the tenant, which is
|
|
154
|
-
* why they are named exactly as the platform names them:
|
|
155
|
-
*
|
|
156
|
-
* key the published process's release key (a GUID). It becomes part of
|
|
157
|
-
* the node's TYPE — `uipath.core.rpa-workflow.<key>` — so the
|
|
158
|
-
* platform can tell one process's node from another's.
|
|
159
|
-
* name the process's name in Orchestrator.
|
|
160
|
-
* folderPath the Orchestrator folder it lives in.
|
|
161
|
-
*
|
|
162
|
-
* `name` + `folderPath` are what the robot is actually started by (the runtime
|
|
163
|
-
* re-resolves the release from them), and together they are also the process's
|
|
164
|
-
* `resourceKey`: `"<folderPath>.<name>"`. The serializer emits the two of them
|
|
165
|
-
* as the flow's process bindings and points the node at them, because a
|
|
166
|
-
* bindings entry the node does not reference is not a bound process.
|
|
167
|
-
*
|
|
168
|
-
* `inputs` are the PROCESS's own input arguments — whatever it declares, by its
|
|
169
|
-
* own argument names. They are not a fixed schema.
|
|
170
|
-
*
|
|
171
|
-
* The step publishes whatever the process returns, under `output`: read a field
|
|
172
|
-
* with `out('<step>', '<field>')`. Nothing local can check that an argument name
|
|
173
|
-
* or a returned field name matches the deployed process — only the robot knows —
|
|
174
|
-
* so a wrong name shows up as a faulted job on a live run, not at compile time.
|
|
175
|
-
*
|
|
176
|
-
* @example
|
|
177
|
-
* **Start a deployed process and read what it returns**
|
|
178
|
-
* ```ts
|
|
179
|
-
* .step('getTitle', rpaWorkflow({
|
|
180
|
-
* key: '486edc26-0658-4ac1-92c9-1ef953927151',
|
|
181
|
-
* name: 'RPA Workflow',
|
|
182
|
-
* folderPath: 'Shared/uipath-maestro-flow/ProjectEuler RPA',
|
|
183
|
-
* inputs: { problemId: 123 },
|
|
184
|
-
* }))
|
|
185
|
-
* .return({ title: out('getTitle', 'title') })
|
|
186
|
-
* ```
|
|
187
|
-
*
|
|
188
|
-
* @param inputs - The published process to start (`key`, `name`, `folderPath`),
|
|
189
|
-
* its `inputs`, and the output fields you read back via `returns`.
|
|
190
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
191
|
-
*/
|
|
192
|
-
export function rpaWorkflow(inputs) {
|
|
193
|
-
return builtinActionSpec({ kind: 'rpaWorkflow', inputs });
|
|
194
|
-
}
|
|
195
|
-
/**
|
|
196
|
-
* Invoke a deployed API workflow — a coded workflow published to Orchestrator,
|
|
197
|
-
* run as a serverless job rather than by a robot.
|
|
198
|
-
*
|
|
199
|
-
* @remarks
|
|
200
|
-
* The same three identifiers as `rpaWorkflow`, for the same reason: `key` is
|
|
201
|
-
* the key the node's TYPE carries (`uipath.core.api-workflow.<key>`), while
|
|
202
|
-
* `name` + `folderPath` are what the runtime resolves the job by — and together
|
|
203
|
-
* they are the workflow's `resourceKey`, `"<folderPath>.<name>"`. The serializer
|
|
204
|
-
* emits those two as the flow's process bindings and points the node at them.
|
|
205
|
-
*
|
|
206
|
-
* The step publishes the job's output arguments under `output`, so
|
|
207
|
-
* `out('<step>', '<field>')` reads one of the fields `returns` declares. Whether
|
|
208
|
-
* an argument name or a returned field actually matches the deployed workflow is
|
|
209
|
-
* something only the tenant knows — a wrong one is a faulted job on a live run,
|
|
210
|
-
* not a compile error.
|
|
211
|
-
*
|
|
212
|
-
* @example
|
|
213
|
-
* **Start an API workflow and read a declared output argument**
|
|
214
|
-
* ```ts
|
|
215
|
-
* .step('getAge', apiWorkflow({
|
|
216
|
-
* key: 'ce857908-ee1d-4392-b552-38bcea0be29c',
|
|
217
|
-
* name: 'NameToAgeFixed',
|
|
218
|
-
* folderPath: 'Shared',
|
|
219
|
-
* inputs: { name: 'tomasz' },
|
|
220
|
-
* returns: { EstimatedAge: 'integer' },
|
|
221
|
-
* }))
|
|
222
|
-
* .return({ age: out('getAge', 'EstimatedAge') })
|
|
223
|
-
* ```
|
|
224
|
-
*
|
|
225
|
-
* @param inputs - The published API workflow to start (`key`, `name`,
|
|
226
|
-
* `folderPath`), its `inputs`, and the fields you read back via `returns`.
|
|
227
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
228
|
-
*/
|
|
229
|
-
export function apiWorkflow(inputs) {
|
|
230
|
-
return builtinActionSpec({ kind: 'apiWorkflow', inputs });
|
|
231
|
-
}
|
|
232
|
-
/**
|
|
233
|
-
* Invoke a published Orchestrator **Function** — a deployed unit of code run as
|
|
234
|
-
* one step (`uipath.core.function.<key>`, dispatched as
|
|
235
|
-
* `Orchestrator.ExecuteFunctionAsync`).
|
|
236
|
-
*
|
|
237
|
-
* ```ts
|
|
238
|
-
* .step('echo', publishedFunction({
|
|
239
|
-
* key: '7059bdb5-fdd7-4e13-9d7b-1748aaeb129d',
|
|
240
|
-
* name: 'acme-echo',
|
|
241
|
-
* folderPath: 'Shared/acme-echo',
|
|
242
|
-
* inputs: { message: 'hello' },
|
|
243
|
-
* returns: { echoed: 'string' },
|
|
244
|
-
* }))
|
|
245
|
-
* ```
|
|
246
|
-
*
|
|
247
|
-
* The node type carries the key, so the function must already exist on the
|
|
248
|
-
* tenant — read `key`, `name` and `folderPath` from the registry rather than
|
|
249
|
-
* constructing them. Like the other published families, the resource identity
|
|
250
|
-
* is CLOSED by a binding pair (`<folderPath>.<name>`), and two steps on the
|
|
251
|
-
* same function share one pair.
|
|
252
|
-
*
|
|
253
|
-
* @param inputs - The function's identity, its arguments, and what it returns.
|
|
254
|
-
* @returns An action spec to pass to `.step(...)`.
|
|
255
|
-
*/
|
|
256
|
-
export function publishedFunction(inputs) {
|
|
257
|
-
return builtinActionSpec({ kind: 'publishedFunction', inputs });
|
|
258
|
-
}
|
|
259
148
|
/**
|
|
260
149
|
* Place an outgoing phone call
|
|
261
150
|
* (`uipath.conversational.voice.create-outgoing-call`) and get back the
|
|
@@ -339,62 +228,6 @@ export function voiceAgent(inputs) {
|
|
|
339
228
|
export function conversationalAgent(inputs) {
|
|
340
229
|
return builtinActionSpec({ kind: 'conversationalAgent', inputs });
|
|
341
230
|
}
|
|
342
|
-
/**
|
|
343
|
-
* Invoke a deployed AGENTIC PROCESS — a Maestro process orchestration published to
|
|
344
|
-
* Orchestrator: a BPMN process that coordinates agents, robots and people, started
|
|
345
|
-
* as a job the same way an RPA or API workflow is.
|
|
346
|
-
*
|
|
347
|
-
* @remarks
|
|
348
|
-
* The same three identifiers as `rpaWorkflow` and `apiWorkflow`, for the same
|
|
349
|
-
* reason: `key` is the key the node's TYPE carries
|
|
350
|
-
* (`uipath.core.agentic-process.<key>`), while `name` + `folderPath` are what
|
|
351
|
-
* the runtime resolves the job by — and together they are the process's
|
|
352
|
-
* `resourceKey`, `"<folderPath>.<name>"`. The serializer emits those two as the
|
|
353
|
-
* flow's process bindings and points the node at them.
|
|
354
|
-
*
|
|
355
|
-
* By default the step WAITS for the process and publishes its output arguments
|
|
356
|
-
* under `output`, so `out('<step>', '<field>')` reads one of the fields
|
|
357
|
-
* `returns` declares.
|
|
358
|
-
*
|
|
359
|
-
* `completion: 'fire-and-forget'` selects the designer's own async switch
|
|
360
|
-
* instead: the node's service type becomes `Orchestrator.Start…ProcessAsync`
|
|
361
|
-
* and it publishes no output but `error`. The type is a discriminated union, so
|
|
362
|
-
* `returns` is impossible in that form and nothing downstream can read one; a
|
|
363
|
-
* local run dispatches without waiting and yields `{ jobKey, started: true }`.
|
|
364
|
-
*
|
|
365
|
-
* `form` picks which published Agentic Process this is — `'bpmn'` (the default,
|
|
366
|
-
* a Maestro process orchestration), `'flow'` (a published Maestro Flow), or
|
|
367
|
-
* `'case'` (a Case Management process). They share one public concept and
|
|
368
|
-
* differ only in wire identity.
|
|
369
|
-
*
|
|
370
|
-
* @example
|
|
371
|
-
* **Start a Maestro process and wait for its result**
|
|
372
|
-
* ```ts
|
|
373
|
-
* .step('runIntake', agenticProcess({
|
|
374
|
-
* key: '4fc450ab-89be-4462-8fc8-21ac4c1d6fb9',
|
|
375
|
-
* name: 'ProcurementProcess',
|
|
376
|
-
* folderPath: 'Shared/uipath-agents/ProcurementProcess',
|
|
377
|
-
* inputs: { productId: 1 },
|
|
378
|
-
* returns: { status: 'boolean' },
|
|
379
|
-
* }))
|
|
380
|
-
* .return({ ok: out('runIntake', 'status') })
|
|
381
|
-
* ```
|
|
382
|
-
*
|
|
383
|
-
* @param inputs - The published Maestro process to start (`key`, `name`,
|
|
384
|
-
* `folderPath`), its `inputs`, and the fields you read back via `returns`.
|
|
385
|
-
* @returns An action spec to pass to `.step(name, …)`.
|
|
386
|
-
*/
|
|
387
|
-
export function agenticProcess(inputs) {
|
|
388
|
-
// Types are erased at run time, so the discriminated union alone cannot stop
|
|
389
|
-
// `{ completion: 'fire-and-forget', returns: {...} }` arriving from untyped
|
|
390
|
-
// code — and silently dropping the returns would validate a read that can
|
|
391
|
-
// never be satisfied.
|
|
392
|
-
if (inputs.completion === 'fire-and-forget' && inputs.returns !== undefined) {
|
|
393
|
-
throw new Error("agenticProcess(): completion 'fire-and-forget' publishes no output — remove `returns`, "
|
|
394
|
-
+ "or use completion: 'wait' to read the process result.");
|
|
395
|
-
}
|
|
396
|
-
return builtinActionSpec({ kind: 'agenticProcess', inputs });
|
|
397
|
-
}
|
|
398
231
|
/**
|
|
399
232
|
* Invoke an AGENT resource — either one published to Orchestrator or a sibling
|
|
400
233
|
* agent project registered in the same solution. Both start through
|
|
@@ -50,7 +50,12 @@ export declare class NodeTypeRegistry<Ctx extends ArtifactContexts> {
|
|
|
50
50
|
byKind(kind: string, spec?: unknown): Registered<Ctx> | undefined;
|
|
51
51
|
/** Every node type registered for a kind (several when they share it), in registration order. */
|
|
52
52
|
typesOfKind(kind: string): readonly Registered<Ctx>[];
|
|
53
|
-
/**
|
|
53
|
+
/**
|
|
54
|
+
* The node type for a type name in the file — the exact name, else the type
|
|
55
|
+
* whose `typeNamePrefix` it starts with — or undefined when no type owns it.
|
|
56
|
+
* The bare prefix counts: it is what an empty `key` builds, and the old lift
|
|
57
|
+
* read it as its factory, so it still does.
|
|
58
|
+
*/
|
|
54
59
|
byTypeName(typeName: string): Registered<Ctx> | undefined;
|
|
55
60
|
/** Every registered kind, sorted. */
|
|
56
61
|
kinds(): string[];
|
|
@@ -5,6 +5,8 @@ export class NodeTypeRegistry {
|
|
|
5
5
|
families;
|
|
6
6
|
#byKind = new Map();
|
|
7
7
|
#byTypeName = new Map();
|
|
8
|
+
/** The types that own a family of names (`typeNamePrefix`); no two prefixes overlap. */
|
|
9
|
+
#byPrefix = [];
|
|
8
10
|
/**
|
|
9
11
|
* @param artifact - The artifact's name, for messages (`'flow'`).
|
|
10
12
|
* @param families - Every family this artifact supports, in no significant order.
|
|
@@ -34,6 +36,23 @@ export class NodeTypeRegistry {
|
|
|
34
36
|
if (sharing && (!type.matches || sharing.some((other) => !other.type.matches))) {
|
|
35
37
|
problems.push(`kind "${type.kind}" is registered twice (${[...sharing, { family, type }].map((e) => `${e.family.id}/${e.type.typeName}`).join(' and ')}); node types that share a kind must each declare matches(spec)`);
|
|
36
38
|
}
|
|
39
|
+
if (type.typeNamePrefix !== undefined) {
|
|
40
|
+
const prefix = type.typeNamePrefix;
|
|
41
|
+
if (type.typeName !== `${prefix}*`) {
|
|
42
|
+
problems.push(`${where}: a type that owns the names under "${prefix}" is named "${prefix}*", not "${type.typeName}"`);
|
|
43
|
+
}
|
|
44
|
+
const overlap = this.#byPrefix.find((p) => p.prefix.startsWith(prefix) || prefix.startsWith(p.prefix));
|
|
45
|
+
if (overlap)
|
|
46
|
+
problems.push(`${where}: prefix "${prefix}" overlaps "${overlap.prefix}" (${placeOf(overlap.entry)})`);
|
|
47
|
+
const shadowed = [...this.#byTypeName.keys()].find((n) => n.startsWith(prefix));
|
|
48
|
+
if (shadowed)
|
|
49
|
+
problems.push(`${where}: prefix "${prefix}" would also own the registered type "${shadowed}"`);
|
|
50
|
+
}
|
|
51
|
+
else {
|
|
52
|
+
const owner = this.#byPrefix.find((p) => type.typeName.startsWith(p.prefix));
|
|
53
|
+
if (owner)
|
|
54
|
+
problems.push(`${where}: type name "${type.typeName}" falls under the prefix "${owner.prefix}" (${placeOf(owner.entry)})`);
|
|
55
|
+
}
|
|
37
56
|
const typeOwner = this.#byTypeName.get(type.typeName);
|
|
38
57
|
if (typeOwner) {
|
|
39
58
|
problems.push(`type name "${type.typeName}" is registered twice (${placeOf(typeOwner)} and ${where}); one VersionedNodeType owns every version of a type`);
|
|
@@ -50,6 +69,9 @@ export class NodeTypeRegistry {
|
|
|
50
69
|
const entry = { family, type };
|
|
51
70
|
this.#byKind.set(type.kind, [...(sharing ?? []), entry]);
|
|
52
71
|
this.#byTypeName.set(type.typeName, entry);
|
|
72
|
+
if (type.typeNamePrefix !== undefined) {
|
|
73
|
+
this.#byPrefix.push({ prefix: type.typeNamePrefix, entry });
|
|
74
|
+
}
|
|
53
75
|
}
|
|
54
76
|
}
|
|
55
77
|
if (problems.length > 0) {
|
|
@@ -78,9 +100,17 @@ export class NodeTypeRegistry {
|
|
|
78
100
|
typesOfKind(kind) {
|
|
79
101
|
return this.#byKind.get(kind) ?? [];
|
|
80
102
|
}
|
|
81
|
-
/**
|
|
103
|
+
/**
|
|
104
|
+
* The node type for a type name in the file — the exact name, else the type
|
|
105
|
+
* whose `typeNamePrefix` it starts with — or undefined when no type owns it.
|
|
106
|
+
* The bare prefix counts: it is what an empty `key` builds, and the old lift
|
|
107
|
+
* read it as its factory, so it still does.
|
|
108
|
+
*/
|
|
82
109
|
byTypeName(typeName) {
|
|
83
|
-
|
|
110
|
+
const exact = this.#byTypeName.get(typeName);
|
|
111
|
+
if (exact)
|
|
112
|
+
return exact;
|
|
113
|
+
return this.#byPrefix.find((p) => typeName.startsWith(p.prefix))?.entry;
|
|
84
114
|
}
|
|
85
115
|
/** Every registered kind, sorted. */
|
|
86
116
|
kinds() {
|