API Commands Automation
The API Commands Automation activity allows you to run API command such as execute DLL files and REST APIs. You can use these activities to perform the following types of task:
- Run the functions in a DLL file by providing class, methods, and associated parameters.
- Perform basic Create, Read, Update, and Delete (CRUD) operations by using REST API.
API Commands Automation Actions
You can use the following activities to design an RPA bot that can run API commands:
Use the functions provided in a Dynamic Link Library (DLL) for creating custom activities to improve the automated process flow.
Properties
- Name: Enter the display name of the action.
- DLL file path: Enter the name (including extension) and path of the DLL file, you want to use.
- Class Name: Select the Class.
- Method Name: Select the method that defines the objects created by the class.
- Parameter: Define the associated parameter name and value in the following fields: Parameter Name and Parameter Value.
- Variables to receive the result: Specify the variable that stores any return values.
Method Name Format: Specify the method name in the following format:
Method Name Format |
Return Type of Method |
---|---|
Int32 MyMethod(Int32, Int32) |
Int |
System.String MyMethod(Int32, Int32) |
string |
Single MyMethod(Int32, Int32) |
float |
Boolean MyMethod(Int32, Int32) |
Boolean |
Double MyMethod(Int32, Int32) |
double |
Class Name Format: Specify the class name in the following format:
[namespace name].[class name]
Perform basic Create, Read, Update, and Delete (CRUD) operations.
Properties
- Name: Enter the display name of the action.
- Base URL: Specify the base URL to which the endpoint paths are appended.
- API End Point: Specify the end-point address.
- API Method Type: Select the method for the action performed by the API.
- GET: If you select this method type, you also have to specify the following:
- Conversion Type: Select the file type (that is CSV and XML) to which the return value is appended.
- File Directory Location: Enter the full path where the CSV and XML are stored.
- File Name: Specify the name of the CSV and XML file.
- POST
- PUT
- DELETE
- GET: If you select this method type, you also have to specify the following:
- Type, Name, Value parameter: Define the associated parameter: Type, Name, and Value.
- Variable to receive the result: Specify the variable that stores any return values.
Trigger allocation of any value to a variable. You can use this action to prompt different types of value allocation such as, assign the result of a variable to a different variable, increase the value of a variable in a loop, assign value to an array, and assign value to a variable in a different process flow step.
Properties
- Name: Enter the display name of the action.
-
- RPA Variable: Select the result provided by the ASG Bot Engine you want to assign to a variable. Enter the left square bracket ([) to view and then select the available result.
- API Variable: Specify the key you want to pass from RPA Model activities to the Business Process Model elements.