Call a robot
In this microlearning, we'll explore how to use Robot Process Automation (RPA) technology to extract information from websites that aren’t accessible through traditional methods like APIs or (S)FTP. Specifically, we’ll focus on how to trigger and manage robots built with the dexi.io platform from within eMagiz. While we won't delve into the details of building these robots, we'll guide you through the steps to execute them, handle authentication, and retrieve the output effectively.
Should you have any questions, please get in touch with academy@emagiz.com.
1. Prerequisites
- Expert knowledge of the eMagiz platform
- An additional license on the platform is needed
2. Key concepts
- In case you need information from a party that is only available on a website and not via traditional methods, you can use robot process automation (RPA) technology
- From eMagiz, you can execute the robot and retrieve the output of the robot when it is built via the dexi.io platform
- Building robots via this platform requires an additional license on the platform
- Using robots to retrieve information should be considered a last resort.
- We will not explain how to build robots in this microlearning. For this see the dexi.io documentation.
3. Call a robot
Sometimes you need to retrieve information from a specific website that cannot be accessed via any traditional integration method (i.e., API, Kafka, SOAP, (S)FTP). In these circumstances, you can use robot process automation (RPA) technology to your advantage. Robots built via the dexi.io platform can be triggered (i.e., executed) via an API call. Depending on the use case of the robot, you can either wait for the result or just run the robot and retrieve the output at a different time.
In the remainder of this course, we will focus on the option you want to wait for the results of your call. To call a robot, we need a trigger point in eMagiz (which can be done via a "Standard inbound channel adapter"), authentication (in the form of two headers), and an HTTP outbound gateway that triggers the execution of the robot. Optionally, additional logic is needed when the robot requires specific input values (i.e., username/password to log in on a website).
3.1 Trigger point
As a trigger point you can either use a standard JMS component (JMS message driven channel adapter) if you want another system to start the executing of the robot (and retrieve its output) or you can use a standard inbound channel adapter that triggers based on a specific schedule. An example of this is shown below.
3.2 Authentication
Once the process is started the next step within the context of the flow will be the authentication towards dexi.io. Dexi requires two authentication headers called X-DexiIO-Access and X-DexiIO-Account. Subsequently, an additional header is needed to define the contentType which can be filled hardcoded with the value "application/json". With the help of a standard header enricher component you can add this information to your message to use it in the next step to call the dexi API.
3.3 Trigger robot execution
When all headers are defined the last step to trigger the execution of the robot is to call an endpoint of dexi.io with the help of an HTTP outbound component. Most logical component to select in this case is the HTTP outbound gateway. With the help of this HTTP outbound gateway you can call the correct endpoint of dexi.io to trigger the execution and wait for the results (this last part is optional) which you can then handle in the best way for you.
4. Key takeaways
- In case you need information from a party that is only available on a website and not via traditional methods, you can use robot process automation (RPA) technology
- From eMagiz, you can execute the robot and retrieve the output of the robot when it is built via the dexi.io platform
- Building robots via this platform requires an additional license on the platform
- Using robots to retrieve information should be considered a last resort.
- We will not explain how to build robots in this microlearning. For this see the dexi.io documentation.
5. Suggested Additional Readings
To learn more about dexi.io and the API of dexi.io, please check out the following additional readings.