studio
2024.10
true
- Release Notes
- Getting Started
- Setup and Configuration
- Automation Projects
- Dependencies
- Types of Workflows
- Control Flow
- File Comparison
- Automation Best Practices
- Source Control Integration
- Debugging
- Logging
- The Diagnostic Tool
- Workflow Analyzer
- About Workflow Analyzer
- ST-NMG-001 - Variables Naming Convention
- ST-NMG-002 - Arguments Naming Convention
- ST-NMG-004 - Display Name Duplication
- ST-NMG-005 - Variable Overrides Variable
- ST-NMG-006 - Variable Overrides Argument
- ST-NMG-008 - Variable Length Exceeded
- ST-NMG-009 - Prefix Datatable Variables
- ST-NMG-011 - Prefix Datatable Arguments
- ST-NMG-012 - Argument Default Values
- ST-NMG-016 - Argument Length Exceeded
- ST-NMG-017 - Class name matches default namespace
- ST-DBP-002 - High Arguments Count
- ST-DBP-003 - Empty Catch Block
- ST-DBP-007 - Multiple Flowchart Layers
- ST-DPB-010 - Multiple instances of [Workflow] or [Test Case]
- ST-DBP-020 - Undefined Output Properties
- ST-DBP-021 - Hardcoded Timeout
- ST-DBP-023 - Empty Workflow
- ST-DBP-024 - Persistence Activity Check
- ST-DBP-025 - Variables Serialization Prerequisite
- ST-DBP-026 - Delay Activity Usage
- ST-DBP-027 - Persistence Best Practice
- ST-DBP-028 - Arguments Serialization Prerequisite
- ST-USG-005 - Hardcoded Activity Arguments
- ST-USG-009 - Unused Variables
- ST-USG-010 - Unused Dependencies
- ST-USG-014 - Package Restrictions
- ST-USG-020 - Minimum Log Messages
- ST-USG-024 - Unused Saved for Later
- ST-USG-025 - Saved Value Misuse
- ST-USG-026 - Activity Restrictions
- ST-USG-027 - Required Packages
- ST-USG-028 - Restrict Invoke File Templates
- ST-USG-032 - Required Tags
- ST-USG-034 - Automation Hub URL
- Variables
- Arguments
- Imported Namespaces
- Coded automations
- Introduction
- Studio IDE
- Working with Input and Output arguments
- Best practices
- Working with Coded automations
- Invoking coded automations using libraries
- Creating Connections for services in coded automations
- Registering custom services
- Before and After contexts
- Generating code
- Generating coded test case from manual test cases
- Trigger-based Attended Automation
- Recording
- UI Elements
- Selectors
- Object Repository
- Data Scraping
- Image and Text Automation
- Citrix Technologies Automation
- RDP Automation
- VMware Horizon Automation
- Salesforce Automation
- SAP Automation
- macOS UI Automation
- The ScreenScrapeJavaSupport Tool
- The WebDriver Protocol
- Extensions
- About extensions
- SetupExtensions tool
- UiPathRemoteRuntime.exe is not running in the remote session
- UiPath Remote Runtime blocks Citrix session from being closed
- UiPath Remote Runtime causes memory leak
- UiPath.UIAutomation.Activities package and UiPath Remote Runtime versions mismatch
- The required UiPath extension is not installed on the remote machine
- Screen resolution settings
- Group Policies
- Cannot communicate with the browser
- Chrome extension is removed automatically
- The extension may have been corrupted
- Check if the extension for Chrome is installed and enabled
- Check if ChromeNativeMessaging.exe is running
- Check if ComSpec variable is defined correctly
- Enable access to file URLs and Incognito mode
- Multiple browser profiles
- Group Policy conflict
- Known issues specific to MV3 extensions
- List of extensions for Chrome
- Chrome Extension on Mac
- Group Policies
- Cannot communicate with the browser
- Edge extension is removed automatically
- The extension may have been corrupted
- Check if the Extension for Microsoft Edge is installed and enabled
- Check if ChromeNativeMessaging.exe is running
- Check if ComSpec variable is defined correctly
- Enable access to file URLs and InPrivate mode
- Multiple browser profiles
- Group Policy conflict
- Known issues specific to MV3 extensions
- List of extensions for Edge
- Extension for Safari
- Extension for VMware Horizon
- Extension for Amazon WorkSpaces
- SAP Solution Manager plugin
- Excel Add-in
- Test Suite - Studio
- Troubleshooting
Creating Connections for services in coded automations
Studio User Guide
Last updated Nov 18, 2024
Creating Connections for services in coded automations
This section helps you create connections needed to access APIs from services that use connections, such as GSuite.Activities and Excel.Activities within coded automations.
Start by creating a connection in Integration Service. The connections can be accessed
within the same organization, and tenant of your coded automation project. Inside the
coded automation, use the
connections
object to access the earlier
created connections in Integration Service, and then access the corresponding APIs.
After you complete the automation and publish it to Orchestrator, you can override the original connection configurations set up in code, if needed.
Create a connection in Integration Service:
- Go to Integration Service, and select the tenant that your Studio is connected to.
- Navigate to Connections.
- Select Add connection, and create a connection for one of the following
applications:
- Google Drive
- Gmail
- Google Sheets
- Microsoft Office 365
- Open an existing coded automation from the same organization, and tenant where you initially created your connection.
- Inside the
Execute()
body, typeconnections
, and then pressCtrl + Space
to see the available connections.Depending on the application for which you previously created theconnection
, you can choose from the following connection types:GDrive
Gmail
GoogleSheets
Excel
OneDrive
O365Mail
- Further configure your connection
by adding the Orchestrator folder and subfolder name, and the specific
connection address you want. Use underlines to separate this information.
For example, a Gmail connection for the
My Workspace
folder, andMy Gmail Worskapce
subfolder in Orchestrator, and for thejohn.doe@gmail.com
address would be written in code as:connections.Gmail.My_Workspace_My_Gmail_Workspace_john_doe_gmail_com
.Recommendation
We recommend you to create your connections in one step to avoid potential errors. We also recommend you to create a variable for the connection. This way, if changes occur in Integration Service, you'll avoid updating every instance of the connection throughout your automation. Use the following approach:Avoid creating your connections in two separate steps like:var myGmailConnection = connections.Gmail.My_Workspace_My_Gmail_Workspace_john_doe_gmail_com;
var myGmailConnection = connections.Gmail.My_Workspace_My_Gmail_Workspace_john_doe_gmail_com;var myGmailConnection = connections.Gmail; myGmailConnection.My_Workspace_My_Gmail_Workspace_john_doe_gmail_com;
var myGmailConnection = connections.Gmail; myGmailConnection.My_Workspace_My_Gmail_Workspace_john_doe_gmail_com; - Once you've established the
connection
, you can access the relevant APIs specific to a service through thatconnection
.For example, if you have set up a Gmail connection as follows:var myGmailConnection = connections.Gmail.My_Workspace_john_doe_gmail.com
, you can use the service's API usingmyGmailConnection
.
- Publish your project to Orchestrator.
- Go to the Orchestrator feed where you've published the project.
- Go to the published process and select Edit.
- In Process Configuration, choose the coded automation containing your configured connection as the entry point.
- In Package Requirements,
find and select the corresponding connection type for your coded
automation.
Be careful to select the connection type for your coded automation, as connections for XAML files within your project also appear in the list.
- Identify and select the account address you plan to associate with the connection when it runs.