How to integrate Corticon Decision Services
- Last Updated: October 13, 2023
- 2 minute read
- Corticon
- Documentation
Calling a Decision Service means making an execute call to, or invocation of, Corticon Server. The topics in this section focus on the types of payloads, calls, their components, and the tools available to help you assemble them.
The call/invocation/request (these three terms are interchangeable) consists of:
- Name and version of the Decision Service to execute
- Data or payload to be processed by the rules in the Decision Service
- Location (URL) of Corticon Server if deployed as a web service
Service Contracts: Describing the call
A service contract defines the interface to a service, thus letting the consuming client applications know what they must send to it (the type and structure of the input data) and what they can expect to receive in return (the type and structure of the output data). If a service contract conforms to a standardized format, it can be analyzed by consuming applications, which can then generate, populate and send compliant service requests automatically.
While the data itself may vary for a given Decision Service from transaction to transaction and call to call, the structure of that data – how it is arranged and organized – must not vary. The data contained in each call must be structured in a way Corticon Server expects and can understand. Likewise, when Corticon Server executes a Decision Service and responds to the client with new data, that data too must be structured in a consistent manner. If not, then the client or calling application will not understand it. The payload must match the contract.
Web Services standards define two such service contract formats, the Web Services Description Language, or WSDL and the XML Schema known as an XSD because of its file extension, .xsd. Because both the WSDL and XSD are physical documents describing the service contract for a specific Web Service, they are known as explicit service contracts. A Java service may also have a service contract, or interface, but no standard description exists for an explicit service contract. REST services with JSON do not have a service contract.
.wsdl or .xsd text and a
report .html file. If you want WSDL or reports in the Decision Service
package, add the following lines to the brms.properties file where
Corticon will do the compilation: com.corticon.server.compile.add.wsdl=true
com.corticon.server.compile.add.report=true.