Robot

Compare Account Data Between Salesforce and SAP

This robot demonstrates how to get accounts details from Salesforce and SAP. Robot also can start process to fix accounts in Salesforce if the Salesforce account data does not match account data in SAP.

SAP
Salesforce
MS Excel

This robot demonstrates how to get accounts details from Salesforce and SAP.

Robot can be used to start process to fix accounts in Salesforce if the Salesforce account data does not match account data in SAP.

Task descriptions

This robot includes several different tasks and their task descriptions are provided below. The tasks that are started either via Control Room or using Robocorp Assistant are Compare Salesforce and SAP accounts and Fix comparison errors.

Task: Compare Salesforce and SAP accounts

  • Run type: Unattended using Robocorp Agent (Windows)
  • Description: This task will get list of accounts from SFDC using Salesforce API and compares those accounts with SAP account data using SAP GUI interface. Results are stored into Excel file, which is stored into Google Drive.

Task: Fix comparison errors

  • Run Type: Attended using Robocorp Assistant (Windows/MacOS/Linux)
  • Description: This task will download the comparison Excel from Google Drive and creates user dialog, which will prompt user to select accounts to be fixed.

Task: List accounts from SAP

  • Run Type: Unattended (Windows)
  • Description: This task views set of SAP accounts using SAP GUI.

Task: List accounts from Salesforce

  • Run Type: Unattended (Windows/MacOS/Linux)
  • Description: This task gets all Salesforce accounts via Salesforce API and views them on Salesforce site using browser. Screenshot of each account's details are saved into files.

Task: List accounts from Salesforce (no browser)

  • Run Type: Unattended (Windows/MacOS/Linux)
  • Description: This task gets all Salesforce accounts via Salesforce API and saves data from each account into PDF file.

Task: Create New Accounts to Salesforce

  • Run Type: Unattended (Windows/MacOS/Linux)
  • Description: This task reads account data from a CSV file and adds an account (if it does not exist) or updates account data (if account already exists) in Salesforce.

Task: Fix Account Name in SFDC

  • Run Type: Unattended (Windows/MacOS/Linux)
  • Description: This task reads account data from a work item variable and adds an account (if it does not exist) or updates account data (if account already exists) in Salesforce.

The robot

Libraries

The RPA.Cloud.Google library handles operations with Google Drive.

The RPA.Browser.Selenium manages the browser automation duties.

The RPA.Tables library takes care of saving the data into a CSV file.

The RPA.Excel.Files library takes care of saving the data into a Excel file.

The RPA.Desktop library is used to take desktop screenshots.

The RPA.Desktop.Windows library handles starting of SAP GUI application.

The RPA.SAP library manages interactions with SAP GUI interface.

The RPA.Salesforce library handles operations with Salesforce REST API.

The RPA.PDF library creates PDFs with account details.

The RPA.Dialogs library manages attended UI interface.

The ControlRoomLibrary custom library is used to manage Control Room processes via Process API.

Other Robotframework libraries in use are Collections, OperatingSystem and String

Configuration

Common variables for the robot are stored in variables.py file.

The Google Drive credentials and several other sensitive data has been stored into Robocorp Vault.

Learn how to use the Robocorp vault to store secrets.

Create a vault.json file for the credentials

Create a new file: /Users/<username>/vault.json

Create a items.json file for the work item variables

Create a new file: /Users/<username>/items.json

Point devdata/env.json to your vault.json and items.json files

Control Room vault

Create new secrets with names sap_ides, control_room_api and salesforce. The key-value pairs can be seen above in the vault.json.

I want to learn more!

Visit Robocorp docs to learn more about developing robots to automate your processes!

Robocorp portal contains many example robots with all the source code included.

Follow the

for automation-related videos.

Visit the Software Robot Developer forum to discuss all-things automation. Ask questions, get answers, share your robots, help others!

Technical information

Last updated

3 March 2022

License

Not defined