uipath-cli
latest
false
重要 :
请注意,此内容已使用机器翻译进行了本地化。
新发布内容的本地化可能需要 1-2 周的时间才能完成。
UiPath CLI 用户指南
uip flow创建、打包、调试和运营UiPath 流项目,这是由通过边线连接的节点(活动、触发器、连接器)组成的图形工作流。Flow 是 UiPath 中的两个编排界面之一请参阅uip maestro ,了解其基于 BPMN 的业务流程编排。
该工具作为@uipath/flow-tool插件(命令前缀flow )提供。有关插件的安装方式和版本控制方式,请参阅工具(插件) 。
何时使用 Flow,何时使用 Maestro
| 表面 | 图形形状 | 资产文件 | 主要用例 |
|---|---|---|---|
| 流 | 可视化节点边图 | .flow (JSON) | 智能体工作流、连接器自动化、AI 节点链接 |
| Maestro | BPMN 2.0 图表 | .bpmn | 长时间运行的人机回圈业务流程编排 |
这两个工具都将.nupkg包发布到 Orchestrator,并共享运行时基元( processes 、 instance 、 incident 、 job 、 registry )。
创作流程
流项目是一个目录,其中包含project.uiproj清单和一个或多个.flow文件(以及打包时生成的支持文件)。
# 1. Scaffold a new project
uip flow init invoice-flow
# 2. Discover nodes in the registry
uip flow registry pull
uip flow registry search slack
# 3. Edit the .flow file — add nodes, edges, variables, bindings
uip flow node add invoice-flow/invoice-flow.flow uipath.connector.slack.send-message --label "Notify"
uip flow edge add invoice-flow/invoice-flow.flow start node_a1b2c3d4
uip flow node configure invoice-flow/invoice-flow.flow node_a1b2c3d4 --detail '{"connectionId":"…","folderKey":"…","method":"POST","endpoint":"/…"}'
# 4. Validate structure (and optionally governance policy)
uip flow validate invoice-flow/invoice-flow.flow
# 5. Run against Studio Web to smoke-test
uip flow debug ./invoice-flow
# 6. Pack for deployment
uip flow pack ./invoice-flow ./dist --version 1.0.0
# 1. Scaffold a new project
uip flow init invoice-flow
# 2. Discover nodes in the registry
uip flow registry pull
uip flow registry search slack
# 3. Edit the .flow file — add nodes, edges, variables, bindings
uip flow node add invoice-flow/invoice-flow.flow uipath.connector.slack.send-message --label "Notify"
uip flow edge add invoice-flow/invoice-flow.flow start node_a1b2c3d4
uip flow node configure invoice-flow/invoice-flow.flow node_a1b2c3d4 --detail '{"connectionId":"…","folderKey":"…","method":"POST","endpoint":"/…"}'
# 4. Validate structure (and optionally governance policy)
uip flow validate invoice-flow/invoice-flow.flow
# 5. Run against Studio Web to smoke-test
uip flow debug ./invoice-flow
# 6. Pack for deployment
uip flow pack ./invoice-flow ./dist --version 1.0.0
创作命令
| 命令 | 用途 |
|---|---|
uip flow init | 创建新的 Flow 项目 |
uip flow node | 在.flow文件中添加、配置、列出和删除节点 |
uip flow edge | 添加、列出和删除节点之间的边线 |
uip flow validate | 根据架构(和监管策略)验证.flow文件 |
uip flow debug | 将项目上传到 Studio Web 并运行调试会话 |
uip flow pack | 生成可部署的 .nupkg |
uip flow registry | 浏览和搜索可用节点类型(OOTB + 连接器) |
变量、绑定和布局帮助程序
这些 CLI 界面尚未显示在侧边栏中,但现在可以调用 — 它们是精简包装器,用于以编程方式编辑.flow JSON:
uip flow variable— 添加/列出/删除顶级工作流变量(in、out、inout)。请参阅node-edge.md 。uip flow variable-update— 将 JS 赋值表达式附加到完成时运行的节点 (=js:ctx.output)。uip flow binding— 添加/列出/删除在发布时解析的资源绑定(流程、智能体、连接等)。uip flow tidy— 自动布局:重新定位节点以删除重叠。
运行时
在运行时,已发布的流包将成为 Orchestrator 上的流程。启动其中一个会创建实例;每次执行尝试都是一个作业;故障显示为事件。
| 命令 | 用途 |
|---|---|
uip flow process | 列出并运行已部署的 Flow 流程( list 、 get 、 run ) |
uip flow processes | 跨文件夹的流程摘要,以及每个流程的事件 |
uip flow instances | 检查和引导正在运行的实例( list 、 get 、 pause 、 resume 、 cancel 、 retry 、 migrate 、 goto 、 variables ……) |
uip flow incidents | 阅读事件摘要和详细信息 |
uip flow job | 流式传输追踪 ( traces ) 并检查作业状态 |
Orchestrator 中的作业和流程本身通过 Orchestrator 工具进行操作 — 请参阅Orchestrator 作业和Orchestrator 流程。
约定
- 每个
uip flow子命令都遵循全局选项(--output、--output-filter、--log-level、--log-file)。 - 默认输出为JSON 。
- 退出代码遵循标准合同。
- 大多数运行时命令首先需要
uip login— 请参阅身份验证。
另请参阅
uip maestro— 用于业务流程编排的同级 BPMN- 工具(插件)
- 身份验证
- 全局选项、退出代码