UiPath Documentation
robot
latest
false
Robot-Entwicklerhandbuch
  • Robot JavaScript SDK
    • Über das Roboter-JavaScript-SDK
    • Konfigurationsschritte
Wichtig :
Es kann 1–2 Wochen dauern, bis die Lokalisierung neu veröffentlichter Inhalte verfügbar ist.

Konfigurationsschritte

Voraussetzungen und Konfigurationsschritte für das Robot JavaScript SDK: JavaScript-Add-On und Einrichtung des Anwendungszugriffs.

This page covers the prerequisites and configuration for using the Robot JavaScript SDK in custom web applications, including setting up browser and Robot consent access, installing the SDK, and configuring the JavaScript Add-On.

Voraussetzungen

The following prerequisites must be met for automation projects to use the Robot JavaScript SDK:

  • Studio- und Roboterversion 2021.10 oder höher installiert
  • Das auf der Robotermaschine installierte UiPath JavaScript Add-On

Zugriff zulassen

When the UiPath Robot JavaScript Add-On is run, access must be granted for your custom application or web page to connect to the Robot. The access is handled by a two-step dialog — both steps must be confirmed to run RobotJS. Both dialogs support automation as described in the following sections.

Dialogfeld „Browserzugriff“

Dieser Schritt bezieht sich auf den Browser, der Berechtigungen zum Öffnen des UiPath Assistant anfordert.

Automatisches Akzeptieren des Browserzugriffsdialogfelds

The uipath-web://* value, added as a trusted URL in the browser's settings, automates this dialog. The uipath-web://* refers to the UiPath Robot web protocol handler.

Hinweis:

Je nach verwendetem Browser müssen unterschiedliche Einstellungen konfiguriert werden. Wenn Sie beispielsweise Google Chrome verwenden, führen Sie die in der Dokumentation zu Google Chrome URLAllowlist beschriebenen Schritte aus.

Das Dialogfeld „Roboterzustimmung“ wird verwendet, um die Verbindung zwischen dem Robot JavaScript SDK und dem Robot Executor zuzulassen.

The UIPATH_ROBOTJS_ALLOWLIST System Environment Variable automatically accepts the robot consent dialog.

The variable value must contain the URLs of your custom application or web page, separated by semicolons. The URL should contain the port number only if a standard port is not used (80 or 443).

Das Roboter-JavaScript-SDK

Dieses SDK bietet alle erforderlichen Methoden und Eigenschaften, die Sie in Ihre benutzerdefinierte Anwendung oder Webseite aufnehmen können. Sie können es wie folgt herunterladen:

NPM

The npm package is available with TypeScript bindings. To include it in your project:

  1. Run the following command at the root of your project directory:

    npm install --save @uipath/robot
    npm install --save @uipath/robot
    

CDN

For CDN:

  1. Add the following script tag before the closing </body> tag:

    <body>
    ...
    ...
    <script href="//download.uipath.com/js/1.3.2/UiPathRobot.js"></script>
    </body>
    <body>
    ...
    ...
    <script href="//download.uipath.com/js/1.3.2/UiPathRobot.js"></script>
    </body>
    

Direct download

Download the Robot JavaScript SDK via direct download.

Add-on-Einstellungen

To configure add-on settings:

  1. Open the uipath.config file in the installation folder.
  2. Add the ListenerPort and TokenExpiryInDays parameters to the <robotJsSettings> section. By default, the section does not contain any keys:
<robotJsSettings>
    <add key="ListenerPort" value="2323" />
    <add key="TokenExpiryInDays" value="30" />
</robotJsSettings>
<robotJsSettings>
    <add key="ListenerPort" value="2323" />
    <add key="TokenExpiryInDays" value="30" />
</robotJsSettings>
AttributBeschreibung
ListenerPortThe UiPath.RobotJS.ServiceHost.exe starts a HttpListener on the configured port and contains the information about other local listeners from the active user session on that system. The port value must match the one configured in the SDK Settings.
TokenExpiryInDaysJede Anforderung, die von einer neuen Domäne kommt, muss die Zustimmung des Benutzers haben, um den Zugriff auf UiPath Robots von einer Webanwendung aus zu ermöglichen. Diese Einwilligungen gelten für die genannte Anzahl von Tagen, die in dieser Einstellung angegeben sind.

War diese Seite hilfreich?

Verbinden

Benötigen Sie Hilfe? Support

Möchten Sie lernen? UiPath Academy

Haben Sie Fragen? UiPath-Forum

Auf dem neuesten Stand bleiben