Intent (Service Abstraction)
What is Intent?β
Intent helps the server by standardizing the INPUT and OUTPUT of common services.
For example, getting an email is a common intent for all email services.
Instead of the server calling the email services with different inputs and outputs, the services can adopt the intentβs input and output to standardize the call for the servers.
Configuring the Intentβ
Create a new Intentβ
Create an ID for the Intent.β
Define the input and outputβ
π‘ Behind the scene, JSON Schema used to perform the input and output validation
Create Input and Output arguments
π‘ Arguments are the keys for the JSON Schema properties For example, for the below JSON, username and password are the arguments
"username_intent": { "type": "string" },
"password_intent": { "type": "string" },
How to use an Intentβ
Go to the Server page
Add an Intent to the Service operationβ
Select the intent to useMap the Service input and output with Intentβ
Applying actions between mappingβ
Method 1: Select Execution Action from the Data Element popupβ
This is used to directly apply the action between the mapping
Select an actionApply the actionMethod 2: Click on the Action buttonβ
This is used to create an action that can be used during the mapping.
For example, making a database query and making the data available for use during the mapping.
Store the value in the variable scope for use
Using Intent from the Serverβ
When selecting the Service operation from the Server, you now have to option to use the intent with the service.
Versioning the Serviceβ
You can version the Service for easier rollback and management.
Add new versionβ
Press the plus button next to "Version" to create a new version