- Informationen zu diesem Leitfaden
- Erste Schritte
- Installieren
- Upgrades
- Connecting and licensing
- Konfigurieren
- Konfigurationsdateien
- Weiterleitung von Robotern über einen Proxy-Server
- Einrichten von Paketordnern und Netzwerkpfaden
- Konfigurieren von Aktivitätsfeeds
- Konfigurieren der Paketsignaturüberprüfung
- Implementieren der Authentifizierung mit Anmeldeinformationsanbietern
- Konfigurieren der vorab geladenen Ausführung
- Running workloads
- RPA processes and tests
- Agents, functions, and API workflows
- Limits
- Securing and governing
- Überwachung
- Fehlersuche und ‑behebung
- Fehlerbehebung für den Roboterdienst
- Fehlerbehebung für die Ausführung
- Unified Runtime troubleshooting
- Fehlerbehebung bei Aufzeichnung und Steuerelement
- Fehlerbehebung für Netzwerke
- Fehlerbehebung für die Verbindung
- Fehlerbehebung bei der Lizenzierung
- Fehlerbehebung bei Paketen
- Fehlerbehebung für .NET
- Fehlerbehebung für Protokollierung
- Fehlerbehebung für Sitzung
- Referenz (Reference)
- Roboter-Befehlszeilenschnittstelle
- Umgebungsvariablen
- Protokollfelder
- Details zur Ablaufverfolgung
Roboter-Befehlszeilenschnittstelle
Robot Command Line Interface (UiRobot.exe) for starting automations, connecting to Orchestrator, and managing the Robot from a terminal.
The UiPath Robot Command Line Interface is a tool that allows you to interact with the Robot from a command line terminal. It uses the UiRobot.exe file to start automations, install processes, connect and disconnect the Robot from Orchestrator, and manage logs, tracing, the Robot session (PiP), proxy credentials, and the NuGet cache directly from the command line.
Wie es funktioniert
Um die CLI zu verwenden, stellen Sie die folgenden Aspekte sicher:
- Der UiPath-Roboterdienst wird ausgeführt
- Sie befinden sich in dem Verzeichnis, in dem der Roboter installiert ist.
Then enter instructions or commands that refer to the UiRobot.exe program along with the necessary parameters, depending on what you want your automation to achieve.
UiRobot.exe is in the Robot installation folder: %ProgramFiles%\UiPathPlatform\Robot\<version> for a per-machine installation, or %LocalAppData%\Programs\UiPathPlatform\Robot\<version> for a per-user installation.
Command and option names aren't case-sensitive.
When the Robot runs in service mode, the connect, disconnect, and flushlogs commands require an elevated command prompt (run as administrator).
Um beispielsweise einen Prozess über die Befehlszeile zu starten, würden Sie den folgenden Befehl verwenden:
UiRobot.exe execute --file "C:\UiPath\Projects\YourProject\project.1.0.0.nupkg"
UiRobot.exe execute --file "C:\UiPath\Projects\YourProject\project.1.0.0.nupkg"
Allgemeine UiRobot.exe-Befehle
Ausführen
Verwenden Sie diesen Befehl, um die Ausführung einer Projektdatei der folgenden Typen zu starten:
- NUPKG
- JSON (legacy projects only)
- XAML (legacy projects only)
Mit der Robot-Version 2023.4 und höher aktualisiert UiPath die Prozessliste gleichzeitig, wenn ein Prozess ausgeführt wird. Wenn beim Start des Auftrags ein Prozessupdate verfügbar ist, verwendet der Auftrag die ältere Version des Prozesses. Nachfolgende Ausführungen wenden den aktualisierten Prozess an.
Der Ausführungsbefehl verwendet die folgenden Argumente:
UiRobot.exe execute (--package-id <Package_ID> | --process-name <Process_Name> | --file <File_Path>) [--input <Input_Parameters>] [--folder <Orchestrator_Folder_Path>] [--entry <Entry_Point_Path>]
UiRobot.exe execute (--package-id <Package_ID> | --process-name <Process_Name> | --file <File_Path>) [--input <Input_Parameters>] [--folder <Orchestrator_Folder_Path>] [--entry <Entry_Point_Path>]
Use exactly one of --package-id, --process-name, and --file.
-
-p,--package-id <Package_ID>- Starts the process with this package ID, from the Orchestrator feed or the local feed. The Robot uses the available version of the package.Beispiele:
UiRobot.exe execute --package-id UiPathDemoUiRobot.exe execute --package-id UiPathDemoUiRobot.exe execute -p UiPathDemoUiRobot.exe execute -p UiPathDemo -
-r,--process-name <Process_Name>- Starts the process with this name, as defined in Orchestrator.Beispiel:
UiRobot.exe execute --process-name UiPathDemoProcessUiRobot.exe execute --process-name UiPathDemoProcess -
-f,--file <File_Path>- Starts the execution of a local project file. The target file can be NUPKG, or JSON or XAML for legacy projects only.Beispiel:
UiRobot.exe execute --file "C:\UiPath\Automation\project.1.0.0.nupkg"UiRobot.exe execute --file "C:\UiPath\Automation\project.1.0.0.nupkg" -
--folder <Orchestrator_Folder_Path>(optional) - The path of the Orchestrator folder from which to install and execute the target process, such asProduct/Development/QA. Required when the process is deployed in more than one folder.Beispiel:
UiRobot.exe execute --package-id UiPathDemo --folder "Product/Development/QA"UiRobot.exe execute --package-id UiPathDemo --folder "Product/Development/QA" -
-i,--input <Input_Parameters>(optional) - Input arguments for the execution, in JSON format.Beispiele:
UiRobot.exe execute --package-id UiPathDemo --input "{\"intArg\" : 3, \"strArg\" : \"hello\"}"UiRobot.exe execute --package-id UiPathDemo --input "{\"intArg\" : 3, \"strArg\" : \"hello\"}"UiRobot.exe execute --file "C:\UiPath\Automation\project.1.0.0.nupkg" --input "{\"intArg\" : 3, \"strArg\" : \"hello\"}"UiRobot.exe execute --file "C:\UiPath\Automation\project.1.0.0.nupkg" --input "{\"intArg\" : 3, \"strArg\" : \"hello\"}"In PowerShell, enclose the JSON in single quotes:
--input '{\"intArg\" : 3, \"strArg\" : \"hello\"}'. -
--entry <Entry_Point_Path>(optional) - Selects the entry point of the process. It applies to.nupkgfiles and--package-id. It is ignored when--filepoints to a.xamlor.jsonfile, and you can't use it with--process-name.Beispiel:
UiRobot.exe execute --file "C:\UiPath\Project\project.1.0.3.nupkg" --entry "OtherEntryPoint.xaml"UiRobot.exe execute --file "C:\UiPath\Project\project.1.0.3.nupkg" --entry "OtherEntryPoint.xaml"Wichtig:- Die folgenden Befehle werden für Windows- oder plattformübergreifende Projekte nicht unterstützt:
UiRobot.exe execute --file "C:\UiPath\Automation\Main.xaml"UiRobot.exe execute --file "C:\UiPath\Automation\Main.xaml"UiRobot.exe execute --file "C:\UiPath\Automation\Project.json"UiRobot.exe execute --file "C:\UiPath\Automation\Project.json" - The
--processargument of earlier versions still works as an alias of--package-id.
- Die folgenden Befehle werden für Windows- oder plattformübergreifende Projekte nicht unterstützt:
Prozess installieren
Verwenden Sie diesen Befehl, um einen Prozess zu installieren. Wenn der Roboter mit dem Orchestrator verbunden ist, sucht er im Orchestrator-Feed nach dem Prozess. Ohne Orchestrator-Verbindung verwendet der Roboter den lokalen Feed.
Der Befehl für den Installationsprozess verwendet die folgenden Argumente:
UiRobot.exe installprocess --process-name <process_name> [--folder <orchestrator_folder_path>]
UiRobot.exe installprocess --process-name <process_name> [--folder <orchestrator_folder_path>]
-
-p,--process-name <process_name>(mandatory) - The name of the process you want to install. The-pshort form means process name here, but package ID in theexecutecommand.Beispiel:
UiRobot.exe installprocess --process-name MyProcessUiRobot.exe installprocess --process-name MyProcess -
--folder <orchestrator_folder_path>(optional) - The full path of the Orchestrator folder containing the process you want to install, such asProduct/Development/QA. This argument applies only when the connection to Orchestrator is active. If only one folder contains the process for installation, skip this parameter.Beispiel:
UiRobot.exe installprocess --process-name MyProcess --folder "Product/Development/QA"UiRobot.exe installprocess --process-name MyProcess --folder "Product/Development/QA"
Verbinden
Use this command to connect your Robot to an Orchestrator instance. If your Robot is already connected to a different Orchestrator instance or with different credentials, the command returns the "Orchestrator already connected" message. Run disconnect first to switch. Running it again with the same URL and credentials succeeds and changes nothing.
Der Verbindungsbefehl verwendet die folgenden Argumente:
UiRobot.exe connect --url <Orchestrator_Server_URL> --clientId <Client_ID> --clientSecret <Client_Secret>
UiRobot.exe connect --url <Orchestrator_Server_URL> --clientId <Client_ID> --clientSecret <Client_Secret>
-
connect- Establishes the connection to Orchestrator. Must be used together with the--url,--clientId, and--clientSecretarguments.Beispiel:
UiRobot.exe connect --url https://cloud.uipath.com/<Organization_Name>/<Tenant_Name>/orchestrator_ --clientId <Client_ID> --clientSecret <your-client-secret>UiRobot.exe connect --url https://cloud.uipath.com/<Organization_Name>/<Tenant_Name>/orchestrator_ --clientId <Client_ID> --clientSecret <your-client-secret>The command also accepts
--urlwith--key <Machine_Key>for a machine key connection. Robots connected with a machine key don't run agents, functions, or API workflows by default, and the command prints a message that calls machine key connections deprecated. For the differences, refer to Connecting the Robot to Orchestrator.
Trennen
Verwenden Sie diesen Befehl, um den Roboter von der aktuellen Orchestrator-Instanz zu trennen.
Der Befehl zum Trennen verwendet die folgenden Argumente:
UiRobot.exe disconnect [--force | --wait]
UiRobot.exe disconnect [--force | --wait]
-
disconnect– Trennt den Roboter nur dann vom Orchestrator, wenn auf der Robotermaschine keine laufenden Aufträge vorhanden sind.Beispiel:
UiRobot.exe disconnectUiRobot.exe disconnect -
--force– Beendet alle auf der Maschine ausgeführten Aufträge und trennt dann die Verbindung des Roboters mit dem Orchestrator.Beispiel:
UiRobot.exe disconnect --forceUiRobot.exe disconnect --force -
--wait– Wartet auf den Abschluss von ausgeführten Aufträgen, bevor der Roboter vom Orchestrator getrennt wird.Beispiel:
UiRobot.exe disconnect --waitUiRobot.exe disconnect --wait
You can't use --force and --wait together. The disconnectandsignout command takes the same arguments, and also signs out the current user.
Ablaufverfolgung
Use this command to enable or disable low-level tracing of the UiPath drivers and the browser extension. Tracing of the Robot Executor and Service is always on, and the command prints a warning about it.
Der Ablaufverfolgungsbefehl verwendet die folgenden Argumente:
UiRobot.exe trace --enableLowLevel | --disableLowLevel
UiRobot.exe trace --enableLowLevel | --disableLowLevel
-
--enableLowLevel- Starts low-level tracing of the UiPath drivers and the browser extension. Requires administrator rights.Beispiel:
UiRobot.exe trace --enableLowLevelUiRobot.exe trace --enableLowLevel -
--disableLowLevel- Stops it and saves the trace asUiPathTrace-<id>.etlon the Desktop of the user who runs the command. Requires administrator rights. Without them, the command shows an error but still returns exit code0.Beispiel:
UiRobot.exe trace --disableLowLevelUiRobot.exe trace --disableLowLevel
PiP
Verwenden Sie diesen Befehl, um die Robotersitzung oder die Bild-in-Bild-Funktion auf der Maschine zu aktivieren oder zu deaktivieren. Diese Einstellung ändert vorhandene Installationen und gilt für alle Benutzer auf der lokalen Maschine. Erfordert Administratorrechte.
Der BiB-Befehl verwendet die folgenden Argumente:
UiRobot.exe pip --enable | --disable
UiRobot.exe pip --enable | --disable
-
--enable- Enables the Robot session (PiP functionality) of the machine.Beispiel:
UiRobot.exe pip --enableUiRobot.exe pip --enable -
--disable- Disables the Robot session (PiP functionality) of the machine.Beispiel:
UiRobot.exe pip --disableUiRobot.exe pip --disable
NuGet-Cache leeren
Verwenden Sie diesen Befehl, um die NuGet-Caches zu löschen: den Cache für globale Pakete (wo sich wiederhergestellte .nupkg Inhalte befinden) und den HTTP-Cache (NuGet-Feed-Antwort-Cache). Während dieses Vorgangs sollten keine Aufträge laufen.
Der Befehl zum Bereinigen des NuGet-Caches verwendet die folgenden Argumente:
UiRobot.exe cleannugetcache [--period <period_in_days>] [--timeout <timeout_in_minutes>] [--allow-unsafe]
UiRobot.exe cleannugetcache [--period <period_in_days>] [--timeout <timeout_in_minutes>] [--allow-unsafe]
-
-p,--period <period_in_days>(optional, default30) - Deletes global-packages entries whose.nupkg.metadatafile has not been accessed in the last X days. Stale or corrupt package folders (missing.nupkg.metadata) are removed regardless of this value, unless they are listed innugetclean.ignore. The HTTP cache is wiped in full regardless of this value. Must be greater than0.Beispiel:
UiRobot.exe cleannugetcache --period 60UiRobot.exe cleannugetcache --period 60 -
-t,--timeout <timeout_in_minutes>(optional, default10) - Maximum time, in minutes, to wait for the cleanup. Press Ctrl+C to cancel the cleanup; the command then prints a partial summary.Beispiel:
UiRobot.exe cleannugetcache --timeout 20UiRobot.exe cleannugetcache --timeout 20 -
--allow-unsafe(optional, defaultfalse) - By default, the command refuses to run if the Robot packages folder (PackagesInstallationFolderinUiPath.config) differs from the default NuGet global-packages folder (a folder that may be shared with other users). Use this flag to force cleanup of the Robot packages folder.Wichtig:Cleaning a shared packages folder may break running jobs or apps belonging to other users sharing the folder.
Beispiel:
UiRobot.exe cleannugetcache --period 30 --allow-unsafeUiRobot.exe cleannugetcache --period 30 --allow-unsafe
Der Befehl druckt eine Zusammenfassung der Bereinigung, aufgeschlüsselt nach global-packages und http-cache, einschließlich der Anzahl der Einträge, die von der Gesamtzahl der übereinstimmenden Einträge gelöscht wurden.
To protect package folders from the cleanup, list them in a nugetclean.ignore file in the global-packages folder. Write one package folder per line, as an absolute path or a path relative to the global-packages folder. A line with only a package ID keeps every version of that package. Blank lines and lines that start with # are ignored.
Anmeldeinformationen für die Proxy-Standardauthentifizierung festlegen
Verwenden Sie diesen Befehl, um die Anmeldeinformationen für die Proxy-Standardauthentifizierung des aktuellen Benutzers festzulegen. Der Roboter speichert die Anmeldeinformationen lokal und nutzt sie für die Kommunikation über einen Proxy, der eine Standardauthentifizierung erfordert.
Der Befehl "setproxy" verwendet die folgenden Argumente:
UiRobot.exe setproxy --username <user> --password <password> [--domain <domain>]
UiRobot.exe setproxy --username <user> --password <password> [--domain <domain>]
-
--username <user>(Obligatorisch) – Der Benutzername für die Proxy-Standardauthentifizierung. -
--password <password>(obligatorisch) – Das Kennwort für die Proxy-Standardauthentifizierung.Beispiel:
UiRobot.exe setproxy --username myuser --password <your-password>UiRobot.exe setproxy --username myuser --password <your-password> -
--domain <domain>(optional) – Die Domäne für die Proxy-Standardauthentifizierung. Verwenden Sie diese Option, wenn der Proxy Anmeldedaten mit Domänenangabe erfordert.Beispiel:
UiRobot.exe setproxy --username myuser --password <your-password> --domain MYDOMAINUiRobot.exe setproxy --username myuser --password <your-password> --domain MYDOMAIN
Wenn Sie den Befehl ausführen, werden alle zuvor gespeicherten Proxy-Anmeldeinformationen überschrieben.
Andere Argumente
Die folgenden Argumente sind rein informativ und haben keine Auswirkungen auf Ihre Automatisierungsprojekte:
version- Displays information about the Robot version. The--versionform also works.--help– Zeigt die Liste der unterstützten Befehle sowie die entsprechenden Informationen und Beispiele an.flushlogs [--timeout <timeout_in_seconds>]- Sends all pending logs to Orchestrator. The default timeout is 30 seconds.
Exitcodes
UiRobot.exe returns the following exit codes:
| Code beenden | Bedeutung |
|---|---|
0 | The command succeeded. For execute, the job completed successfully. |
1 | For execute, the job failed. For cleannugetcache, the cleanup didn't complete successfully. |
2 | For execute, the job suspended. The command prints the resumeId of the suspended job. |
-1 | The command was used incorrectly (invalid or missing arguments), or it failed with an error. |