Many connectors in Workato support a search object function, but certain applications, such as Freshdesk are only able to search using a partial match. For example, if you search for a company "ABC Inc.", it will give you all the companies that contain the words "ABC" and "Inc.", meaning you could potentially get multiple matches, and even the first result may not be what you're looking for. In order to circumvent this issue, you can run the following logic: When a new object is created, search for the object in another app. For each object that is obtained in the search, check if there is an exact match. If yes, do something. If no, do nothing.
Lets take a look at an example using Salesforce Account and Freshdesk Companies.
What this recipe does is when a new Account is created in Salesforce:
- It runs a search for Companies in Freshdesk using the account name from Salesforce
- For each item in the list of search results from step 1,
- If the company name in Freshdesk matches the account name in Freshdesk,
- Perform your desired action.
With this set of logic, you can be sure that you will receive an exact match for your searches.
NOTE: For certain apps like Freshdesk, the search result has a limit to the number of results it can show, which means if your desired result is past the limit, you will not be able to perform the action, even though it exists in your apps.