You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何通过命令行或REST API执行Workfusion RPA业务流程?

Great questions! As someone who’s worked with WorkFusion RPA a fair bit, let’s break down your two queries clearly:

1. Exporting a runnable package & executing via Command Prompt

Absolutely, you can run your WorkFusion workflow via the command line—though it’s not a standalone .exe, but a packaged robot that uses WorkFusion’s runtime to execute. Here’s how to do it:

  • First, package your project in the IDE: Go to Project > Export Robot Package, pick a save location, and you’ll get a .zip file containing your full workflow.
  • Ensure the WorkFusion RPA Runtime is installed (it comes included with RPA Express; if you’re running on a separate machine, you’ll need to install it there first).
  • Open Command Prompt, navigate to the Runtime directory (default path is usually C:\Program Files\WorkFusion\RPA Express\Runtime), then run this command:
    robotrunner.bat -package "C:\path\to\your\robot-package.zip"
    
  • If your workflow uses variables, you can pass them directly in the command like this:
    robotrunner.bat -package "C:\path\to\your\robot-package.zip" -variables "inputPath=C:\data\file.csv,outputPath=C:\results"
    
2. Exposing a REST API to trigger the workflow

Yes, you have two reliable options depending on your use case:

Option 1: Use WorkFusion Control Room’s built-in API

If you’re using the Control Room (ideal for managing and scaling workflows), you can trigger executions via its native REST API:

  • First, deploy your workflow to the Control Room and register a robot to run it.
  • Generate an API token from your Control Room user settings (go to Profile > API Tokens to create one).
  • Send a POST request to the Control Room API endpoint: http://<control-room-ip>:<port>/api/v1/executions
    The request body should include details like the robot ID and workflow parameters. Example JSON body:
    {
      "robotId": "your-robot-uuid",
      "variables": {
        "inputParam": "value-from-external-app"
      }
    }
    
    Don’t forget to include your API token in the Authorization header as Bearer <your-token>.

Option 2: Add an HTTP Listener directly in your workflow

For a lightweight, direct approach without the Control Room, use the HTTP Listener component in the IDE:

  • Drag the HTTP Listener component from the component library to the start of your workflow.
  • Configure it: Set a port (e.g., 8080), a path (e.g., /start-workflow), and choose the request method (GET or POST).
  • Add logic to parse incoming request parameters (if needed) using components like Get HTTP Request Parameter, then connect it to your existing workflow steps.
  • To send a response back to the calling app, add an HTTP Response component at the end of your workflow to return status codes or custom data.
  • Once you start the workflow, external apps can trigger it by sending an HTTP request to http://<your-robot-machine-ip>:8080/start-workflow.

Hope that clears things up! Let me know if you hit any snags with specific steps.

内容的提问来源于stack exchange,提问作者Rahul

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.15 03:47:43