UiPath Documentation
studio
latest
false
重要 :
新发布内容的本地化可能需要 1-2 周的时间才能完成。

Studio 用户指南

上次更新日期 2026年5月15日

Mac 上的 Chrome 扩展程序

此扩展可帮助您在 Mac 上的 Google Chrome 中创建浏览器自动化。

安装方法

可以通过多种方式安装UiPath Chrome 扩展程序,具体取决于允许的用户交互量。

可以为特定用户安装扩展程序,也可以按计算机(为所有用户)安装扩展程序。这两种安装类型之间的唯一区别是配置文件的位置。

安装类型配置文件位置
按用户~{userId}/Library/Application Support/Google/Chrome/External Extensions/

~{userId}/Library/Application Support/Google/Chrome/NativeMessagingHosts/

{userId}替换为用户的用户名。
每台计算机/Library/Application Support/Google/Chrome/External Extensions/

/Library/Google/Chrome/NativeMessagingHosts/

从 UiPath Assistant 安装

只要已经安装了UiPath Assistant ,使用 UiPath Assistant 进行安装只需单击几下,无需额外配置。此方法仅为当前用户安装发布到网上应用店的最新扩展程序版本。

  1. 访问 UiPath Assistant

  2. 选择帐户图标。

  3. 选择首选项

  4. 转到 UiPath 扩展程序

  5. 选择“为Google Chrome安装”。

  6. 在 Google Chrome 的确认弹出窗口中选择“启用扩展程序”

结果:扩展程序已安装并启用。

从终端安装(通过 UiPath.ExtensionControl.Portable.dll)

UiPath 提供了一个用于管理扩展程序安装的工具: UiPath.ExtensionControl.Portable.dll 。此工具与UiPath Assistant以及运行扩展程序所需的其他文件一起分发。

先决条件:

  • 始终使用/Applications目录中的UiPath.ExtensionControl.Portable.dll文件运行命令,因为 macOS 在从其他位置执行二进制文件时很敏感。
  • 在运行命令之前,请关闭所有 Chrome 窗口。

您可以使用以下安装方法之一:

当前用户

此方法仅为当前用户安装扩展程序。它会创建或更新 Chrome 用于检测扩展程序的 JSON 配置文件。这些文件定义扩展程序 ID、更新 URL 和原生消息传递主机的路径。

备注:
  • 添加--ext-id={extensionId}选项以针对特定扩展程序版本。将{extensionId}替换为所需扩展程序的 ID。有关可用 ID 的列表,请参阅Studio - Chrome 扩展程序列表
  • 命令的--ext-id={extensionId}部分是可选的。如果省略,则安装发布到网上应用店的扩展程序最新版本。
安装步骤
  1. 打开终端并运行以下命令:

    dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome
    dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome
    
  2. 在 Google Chrome 的确认弹出窗口中选择“启用扩展程序”

结果:扩展程序已安装并启用。

所有用户

此方法为计算机上的所有用户安装扩展程序。它的工作原理与“当前用户”方法类似,创建或更新 Chrome 用于检测扩展程序的 JSON 配置文件。区别在于文件位置:此方法将配置文件写入系统范围内的位置,而“当前用户”方法将其写入特定于用户的位置。

备注:
  • 运行此命令需要sudo ,因为它会更新系统配置文件。
  • 添加--ext-id={extensionId}选项以针对特定扩展程序版本。将{extensionId}替换为所需扩展程序的 ID。有关可用 ID 的列表,请参阅Studio - Chrome 扩展程序列表
  • 命令的--ext-id={extensionId}部分是可选的。如果省略,则安装发布到网上应用店的扩展程序最新版本。
安装步骤
  1. 打开终端并运行以下命令:

    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome --scope=machine
    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome --scope=machine
    
  2. 在 Google Chrome 的确认弹出窗口中选择“启用扩展程序”

结果:扩展程序已安装并启用。

在线组策略

此方法不需要在首次启动 Chrome 后手动步骤来启用扩展程序。这是因为它依赖于由 MDM(移动设备管理)工具部署的配置文件。

“配置”描述文件设置“扩展程序安装强制列表”策略。此策略可确保已启用扩展程序,并且无法手动禁用。

此过程类似于此处所述的 Windows 组策略在线安装方法: Studio - Chrome 扩展程序

要安装配置文件( .mobileconfig文件),计算机上应存在 MDM 应用程序,并且必须注册计算机才能进行管理。

MDM 的示例包括:

如果设备已在 MDM 解决方案中注册,请确保该配置不会被通过 MDM 推送的配置更新覆盖。为防止出现这种情况,请直接通过 MDM 部署配置文件。配置文件应包含类似于以下示例的设置:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>PayloadContent</key>
	<array>
		<dict>
			<!-- This policy ensures that the {extensionId} is enabled -->
			<key>ExtensionInstallForcelist</key>
			<array>
				<string>{extensionId};https://clients2.google.com/service/update2/crx</string>
			</array>

			<!-- The policies below are not mandatory, but they are useful in some systems, 
         depending on the already present configuration -->
         <!-- This policy enables the Developer mode in chrome://extensions -->
			<key>DeveloperToolsAvailability</key>
			<integer>1</integer>
			
			<key>BlockExternalExtensions</key>
			<false/>
			
			<key>ExtensionAllowedTypes</key>
			<array>
				<string>extension</string>
			</array>
			
			<key>NativeMessagingUserLevelHosts</key>
			<true/>
			
			<key>NativeMessagingAllowlist</key>
			<array>
				<string>com.uipath.portable_host</string>
			</array>
			
			<key>PayloadDisplayName</key>
			<string>Google Chrome</string>
			<key>PayloadIdentifier</key>
			<string>com.google.Chrome.2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadType</key>
			<string>com.google.Chrome</string>
			<key>PayloadUUID</key>
			<string>2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadVersion</key>
			<integer>1</integer>
		</dict>
	</array>
	<key>PayloadDisplayName</key>
	<string>UiPath Studio Web Automation Chrome Extension Installation</string>
	<key>PayloadIdentifier</key>
	<string>com.uipath.chrome.extension.A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadOrganization</key>
	<string>com.uipath</string>
	<key>PayloadScope</key>
	<string>System</string>
	<key>PayloadType</key>
	<string>Configuration</string>
	<key>PayloadUUID</key>
	<string>A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadVersion</key>
	<integer>1</integer>
	<key>TargetDeviceType</key>
	<integer>5</integer>
</dict>
</plist>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>PayloadContent</key>
	<array>
		<dict>
			<!-- This policy ensures that the {extensionId} is enabled -->
			<key>ExtensionInstallForcelist</key>
			<array>
				<string>{extensionId};https://clients2.google.com/service/update2/crx</string>
			</array>

			<!-- The policies below are not mandatory, but they are useful in some systems, 
         depending on the already present configuration -->
         <!-- This policy enables the Developer mode in chrome://extensions -->
			<key>DeveloperToolsAvailability</key>
			<integer>1</integer>
			
			<key>BlockExternalExtensions</key>
			<false/>
			
			<key>ExtensionAllowedTypes</key>
			<array>
				<string>extension</string>
			</array>
			
			<key>NativeMessagingUserLevelHosts</key>
			<true/>
			
			<key>NativeMessagingAllowlist</key>
			<array>
				<string>com.uipath.portable_host</string>
			</array>
			
			<key>PayloadDisplayName</key>
			<string>Google Chrome</string>
			<key>PayloadIdentifier</key>
			<string>com.google.Chrome.2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadType</key>
			<string>com.google.Chrome</string>
			<key>PayloadUUID</key>
			<string>2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadVersion</key>
			<integer>1</integer>
		</dict>
	</array>
	<key>PayloadDisplayName</key>
	<string>UiPath Studio Web Automation Chrome Extension Installation</string>
	<key>PayloadIdentifier</key>
	<string>com.uipath.chrome.extension.A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadOrganization</key>
	<string>com.uipath</string>
	<key>PayloadScope</key>
	<string>System</string>
	<key>PayloadType</key>
	<string>Configuration</string>
	<key>PayloadUUID</key>
	<string>A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadVersion</key>
	<integer>1</integer>
	<key>TargetDeviceType</key>
	<integer>5</integer>
</dict>
</plist>

如果设备未在 MDM 解决方案中注册, UiPath.ExtensionControl.Portable.dll工具会将所需的配置写入本地,而不会被 MDM 应用的策略覆盖。这允许 Chrome 应用策略并确保无需用户交互即可启用扩展程序。

备注:
  • 运行此命令需要sudo ,因为它会更新系统配置文件。
  • 使用bypolicy选项会自动将作用域设置为计算机。
  • 可以使用--scope=user代替--scope=machine发出命令,其效果是只有当前用户才能安装并自动启用扩展程序。任何其他用户都将无法安装该扩展程序。
  • 添加--ext-id={extensionId}选项以针对特定扩展程序版本。将{extensionId}替换为所需扩展程序的 ID。有关可用 ID 的列表,请参阅Studio - Chrome 扩展程序列表
  • 命令的--ext-id={extensionId}部分是可选的。如果省略,则安装发布到网上应用店的扩展程序最新版本。
安装步骤

A. 注册 MDM 的计算机:

  1. 打开终端并运行以下命令。如果将通过 MDM 推送的配置设置为覆盖现有值,则可以删除bypolicy参数。

    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome bypolicy --scope=machine
    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome bypolicy --scope=machine
    
  2. 新建.mobileconfig文件以配置所需策略。.mobileconfig文件应大致具有上述内容。

  3. 使用 MDM 提供程序安装配置文件。

  4. 启动 Chrome。

  5. 设计和运行自动化。

结果:扩展程序已安装并启用。

B.未注册 MDM 的计算机:

  1. 打开终端并运行以下命令:

    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome bypolicy --scope=machine
    sudo dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome bypolicy --scope=machine
    
  2. 设计和运行自动化。

结果:扩展程序已安装并启用。

离线组策略

无法使用UiPath.ExtensionControl.Portable.dll完全执行此安装类型,因为它需要干预(在本地计算机上或从管理员计算机进行)。

UiPath.ExtensionControl.Portable.dll为其更新扩展程序与原生主机通信所需的配置文件提供支持。因此,它可用于按用户或按计算机安装扩展程序,如前所述,但需要其他步骤来确保安装并启用扩展程序。

“配置”描述文件设置“扩展程序安装强制列表”策略。此策略可确保已启用扩展程序,并且无法手动禁用。

此方法:

  • 可用于安装任何扩展程序,无论是已发布到网上应用店还是未发布。
  • 在互联网访问受限(无法访问https://clients2.google.com/service/update2/crx )的环境中非常有用。

“配置”描述文件应大致包含以下内容:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>PayloadContent</key>
	<array>
		<dict>
			<!-- This policy ensures that the {extensionId} is enabled -->
			<key>ExtensionInstallForcelist</key>
			<array>
				<string>{extensionId}</string>
			</array>

			<!-- The policies below are not mandatory, but they are useful in some systems, 
         depending on the already present configuration -->
			<!-- This policy enables the Developer mode in chrome://extensions -->
			<key>DeveloperToolsAvailability</key>
			<integer>1</integer>
			
			<key>BlockExternalExtensions</key>
			<false/>
			
			<key>ExtensionAllowedTypes</key>
			<array>
				<string>extension</string>
			</array>
			
			<key>NativeMessagingUserLevelHosts</key>
			<true/>
			
			<key>NativeMessagingAllowlist</key>
			<array>
				<string>com.uipath.portable_host</string>
			</array>
			
			<key>PayloadDisplayName</key>
			<string>Google Chrome</string>
			<key>PayloadIdentifier</key>
			<string>com.google.Chrome.2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadType</key>
			<string>com.google.Chrome</string>
			<key>PayloadUUID</key>
			<string>2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadVersion</key>
			<integer>1</integer>
		</dict>
	</array>
	<key>PayloadDisplayName</key>
	<string>UiPath Studio Web Automation Chrome Extension Installation</string>
	<key>PayloadIdentifier</key>
	<string>com.uipath.chrome.extension.A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadOrganization</key>
	<string>com.uipath</string>
	<key>PayloadScope</key>
	<string>System</string>
	<key>PayloadType</key>
	<string>Configuration</string>
	<key>PayloadUUID</key>
	<string>A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadVersion</key>
	<integer>1</integer>
	<key>TargetDeviceType</key>
	<integer>5</integer>
</dict>
</plist>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
	<key>PayloadContent</key>
	<array>
		<dict>
			<!-- This policy ensures that the {extensionId} is enabled -->
			<key>ExtensionInstallForcelist</key>
			<array>
				<string>{extensionId}</string>
			</array>

			<!-- The policies below are not mandatory, but they are useful in some systems, 
         depending on the already present configuration -->
			<!-- This policy enables the Developer mode in chrome://extensions -->
			<key>DeveloperToolsAvailability</key>
			<integer>1</integer>
			
			<key>BlockExternalExtensions</key>
			<false/>
			
			<key>ExtensionAllowedTypes</key>
			<array>
				<string>extension</string>
			</array>
			
			<key>NativeMessagingUserLevelHosts</key>
			<true/>
			
			<key>NativeMessagingAllowlist</key>
			<array>
				<string>com.uipath.portable_host</string>
			</array>
			
			<key>PayloadDisplayName</key>
			<string>Google Chrome</string>
			<key>PayloadIdentifier</key>
			<string>com.google.Chrome.2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadType</key>
			<string>com.google.Chrome</string>
			<key>PayloadUUID</key>
			<string>2C2280F4-2955-49E9-8161-A599B9BB6685</string>
			<key>PayloadVersion</key>
			<integer>1</integer>
		</dict>
	</array>
	<key>PayloadDisplayName</key>
	<string>UiPath Studio Web Automation Chrome Extension Installation</string>
	<key>PayloadIdentifier</key>
	<string>com.uipath.chrome.extension.A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadOrganization</key>
	<string>com.uipath</string>
	<key>PayloadScope</key>
	<string>System</string>
	<key>PayloadType</key>
	<string>Configuration</string>
	<key>PayloadUUID</key>
	<string>A64BC628-4ECF-4A71-91D5-20D7C7475C38</string>
	<key>PayloadVersion</key>
	<integer>1</integer>
	<key>TargetDeviceType</key>
	<integer>5</integer>
</dict>
</plist>

扩展程序安装强制列表字符串具有以下格式:

  • {extensionId}
  • {extensionId};{urlWithThePathToTheUpdateManifestXmlFile}

必须将{urlWithThePathToTheUpdateManifestXmlFile}值替换为更新清单 XML 文件的 URL( https://file:// )。该文件包含以下内容:

<?xml version='1.0' encoding='UTF-8'?>
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
	<app appid='{extensionId}'>
	<updatecheck
		codebase='{crxUrl}'
		version='{extensionVersion}' />
	</app>
</gupdate>
<?xml version='1.0' encoding='UTF-8'?>
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
	<app appid='{extensionId}'>
	<updatecheck
		codebase='{crxUrl}'
		version='{extensionVersion}' />
	</app>
</gupdate>
备注:
  • {extensionId}替换为扩展程序的 ID。
  • 必须将{crxUrl}替换为 CRX 的 URL(如果 CRX 托管在服务器上,则为https:// ;如果文件放置在本地计算机上,则为file:// )。
  • 必须将{extensionVersion}替换为扩展程序的版本(例如 24.10.3)。
安装步骤
备注:

在管理员计算机上执行步骤 1 和 2。

  1. 按照上述说明创建配置文件。

  2. 使用 MDM 提供程序推送配置文件。

  3. 通过打开终端并运行以下命令来安装原生消息传递主机:

    dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome native-messaging-host-only --scope=machine
    dotnet /Applications/UiPath\ Assistant.app/Contents/Extensions/UiPath.ExtensionControl.Portable.dll install chrome native-messaging-host-only --scope=machine
    
  4. 启动 Chrome。

  5. 设计和运行自动化。

结果:扩展程序已安装并启用。

此方法依赖于 MDM(移动设备管理)工具部署的配置文件。“配置”配置文件将应用“ExtensionInstallForcelist”策略,该策略可确保扩展程序自动启用,并且用户无法禁用。

此过程类似于此处所述的 Windows 组策略离线安装方法: Studio - Chrome 扩展程序

卸载

从 UiPath Assistant 卸载

  1. 访问 UiPath Assistant

  2. 转到 UiPath 扩展程序

  3. Google Chrome选择“卸载”

结果:扩展程序被卸载。

从终端卸载

无论使用何种安装方法,您都可以通过运行以下命令来卸载适用于 Chrome 的 UiPath 扩展程序:

dotnet UiPath.ExtensionControl.Portable.dll cleanup chrome
dotnet UiPath.ExtensionControl.Portable.dll cleanup chrome

结果:扩展程序被卸载。

检查状态

要检查 Chrome 扩展程序的状态,请根据您的安装方法运行相应的终端命令:

  • 当前用户
    dotnet UiPath.ExtensionControl.Portable.dll status chrome
    dotnet UiPath.ExtensionControl.Portable.dll status chrome
    
  • 所有用户
    dotnet UiPath.ExtensionControl.Portable.dll status chrome --scope=machine
    dotnet UiPath.ExtensionControl.Portable.dll status chrome --scope=machine
    
  • 在线组策略
    dotnet UiPath.ExtensionControl.Portable.dll status chrome bypolicy --scope=machine
    dotnet UiPath.ExtensionControl.Portable.dll status chrome bypolicy --scope=machine
    
  • 离线组策略
    dotnet UiPath.ExtensionControl.Portable.dll status chrome native-messaging-host-only --scope=machine
    dotnet UiPath.ExtensionControl.Portable.dll status chrome native-messaging-host-only --scope=machine
    

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新