Find out the installed version of Determinations Server
Find out what rulebases are deployed on the Determinations Server
Create and execute an Assess operation
To import the Determinations Server WSDL into soapUI, do the following:
soapUI will create a new project and import the WSDL into that project giving you a service definition named odsServer. If you left the option Create sample requests for all operations on, you will have a sample operation for the three Determinations Server Service Operations: GetServerInfo, ListRulebases and LoadRulebase.
If an error occurred, it is probably because the Initial WSDL URL is incorrect.
You can use soapUI to test a rulebase deployed in the Determinations Server
To import the rulebase WSDL, do the following:
Now that you have created the rulebase service you can test a simple request. It is a good idea to have the rulebase open in Oracle Policy Modeling so you can create attributes, entities and relationships with the correct name. You can see the attributes, entities and relationships that the rulebase uses by viewing the Build Model or the Data Model (View menu > Build Model/Data Model).
Looking at the Data Model for the Simple Benefits rulebase (examples\rulebases\compiled\SimpleBenefits.zip in the Oracle Policy Automation Runtime package), we can see that the Global has some attributes and a relationship to the child entity.
For this example we will investigate the goal “eligible_low_income_allowance” and “eligible_teenage_allowance”.
Start the Assess request by adding the two attribute outcomes that we want to investigate in the global entity instance. In this case we will ask for value-only if the attribute is known and a full decision report if the value is unknown. The entire Assess request now looks like:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://oracle.com/determinations/server/10.4/rulebase/assess/types">
<soapenv:Header/>
<soapenv:Body>
<typ:assess-request>
<typ:global-instance>
<typ:attribute id="eligible_teenage_allowance" known-outcome-style="value-only" unknown-outcome-style="decision-report"/>
<typ:attribute id="eligible_low_income_allowance" known-outcome-style="value-only" unknown-outcome-style="decision-report"/>
</typ:global-instance>
</typ:assess-request>
</soapenv:Body>
</soapenv:Envelope>
If we execute this request now, each attribute outcome will be unknown, with a decision report telling us which attributes require values in order to reach a determination for the given outcome.
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:i18n="http://www.w3.org/2005/09/ws-i18n" xmlns:typ="http://oracle.com/determinations/server/10.4/rulebase/assess/types">
<SOAP-ENV:Header>
<i18n:international>
<i18n:locale>en_US</i18n:locale>
<i18n:tz>GMT+0800</i18n:tz>
</i18n:international>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<typ:assess-response>
<typ:global-instance>
<typ:attribute id="eligible_low_income_allowance" type="boolean" inferred="false">
<typ:unknown-val/>
<typ:decision-report report-style="decision-report">
<typ:attribute-node id="dn:0" entity-id="global" instance-id="global" hypothetical-instance="false" attribute-id="eligible_low_income_allowance" type="boolean" text="Is the claimant eligible for low income allowance?" inferred="false">
<typ:unknown-val/>
<typ:attribute-node id="dn:1" entity-id="global" instance-id="global" hypothetical-instance="false" attribute-id="claimant_income" type="currency" text="The claimant's annual income is unknown." inferred="false">
<typ:unknown-val/>
</typ:attribute-node>
<typ:attribute-node id="dn:2" entity-id="global" instance-id="global" hypothetical-instance="false" attribute-id="claimant_public_housing_client" type="boolean" text="Is the claimant a public housing client?" inferred="false">
<typ:unknown-val/>
</typ:attribute-node>
<typ:attribute-node id="dn:3" entity-id="global" instance-id="global" hypothetical-instance="false" attribute-id="claimant_date_of_birth" type="date" text="The claimant's date of birth is unknown." inferred="false">
<typ:unknown-val/>
</typ:attribute-node>
</typ:attribute-node>
</typ:decision-report>
</typ:attribute>
<typ:attribute id="eligible_teenage_allowance" type="boolean" inferred="false">
<typ:unknown-val/>
<typ:decision-report report-style="decision-report">
<typ:attribute-node id="dn:0" entity-id="global" instance-id="global" hypothetical-instance="false" attribute-id="eligible_teenage_allowance" type="boolean" text="Is the claimant eligible for the teenage child allowance?" inferred="false">
<typ:unknown-val/>
<typ:relationship-node id="dn:1" source-entity-id="global" source-instance-id="global" hypothetical-instance="false" target-entity-id="child" relationship-id="claimantschildren" state="unknown" inferred="false"></typ:relationship-node>
</typ:attribute-node>
</typ:decision-report>
</typ:attribute>
</typ:global-instance>
</typ:assess-response>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>
From the decision report we can see that for the eligible_low_income_allowance attribute to have a value, we need to provide answers for the following attributes:
We can do that by adding the following to the global entity instance.
<typ:attribute id="claimant_income">
<typ:number-val>13000</typ:number-val>
</typ:attribute>
<typ:attribute id="claimant_public_housing_client">
<typ:boolean-val>true</typ:boolean-val>
</typ:attribute>
<typ:attribute id="claimant_date_of_birth">
<typ:date-val>1981-03-22</typ:date-val>
</typ:attribute>
According to the decision report for the eligible_teenage_allowance goal, the relationship ‘claimantschildren’ needs to be known. As this is a containment relationship, this can be done by adding some instances of the ‘child’ entity to the global entity instance:
<typ:entity id="child"> <typ:instance id="child_1"> <typ:attribute id="child_age"> <typ:number-val>9</typ:number-val> </typ:attribute> </typ:instance> <typ:instance id="child_2"> <typ:attribute id="child_age"> <typ:number-val>5</typ:number-val> </typ:attribute> </typ:instance> </typ:entity>
Our Assess request should now look like the request below. Now the response (see below) provides the following answers for our goal:
eligible_teenage_allowance is false (the claimant is not eligible because neither of their children is between 13 and 19 years of age)
eligible_low_income_allowance is true (the claimant is eligible because they are a public housing client, they have an income below 20,000, and claimant date of birth is known).
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://oracle.com/determinations/server/10.4/rulebase/assess/types">
<soapenv:Header/>
<soapenv:Body>
<typ:assess-request>
<typ:global-instance>
<typ:attribute id="eligible_teenage_allowance" known-outcome-style="value-only" unknown-outcome-style="decision-report"/>
<typ:attribute id="eligible_low_income_allowance" known-outcome-style="value-only" unknown-outcome-style="decision-report"/>
<typ:attribute id="claimant_income">
<typ:number-val>13000</typ:number-val>
</typ:attribute>
<typ:attribute id="claimant_public_housing_client">
<typ:boolean-val>true</typ:boolean-val>
</typ:attribute>
<typ:attribute id="claimant_date_of_birth">
<typ:date-val>1981-03-22</typ:date-val>
</typ:attribute>
<typ:entity id="child">
<typ:instance id="child_1">
<typ:attribute id="child_age">
<typ:number-val>9</typ:number-val>
</typ:attribute>
</typ:instance>
<typ:instance id="child_2">
<typ:attribute id="child_age">
<typ:number-val>5</typ:number-val>
</typ:attribute>
</typ:instance>
</typ:entity>
</typ:global-instance>
</typ:assess-request>
</soapenv:Body>
</soapenv:Envelope>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:i18n="http://www.w3.org/2005/09/ws-i18n" xmlns:typ="http://oracle.com/determinations/server/10.4/rulebase/assess/types">
<SOAP-ENV:Header>
<i18n:international>
<i18n:locale>en_US</i18n:locale>
<i18n:tz>GMT+0800</i18n:tz>
</i18n:international>
</SOAP-ENV:Header>
<SOAP-ENV:Body>
<typ:assess-response>
<typ:global-instance>
<typ:attribute id="eligible_low_income_allowance" type="boolean" inferred="true">
<typ:boolean-val>true</typ:boolean-val>
</typ:attribute>
<typ:attribute id="eligible_teenage_allowance" type="boolean" inferred="true">
<typ:boolean-val>false</typ:boolean-val>
</typ:attribute>
<typ:attribute id="claimant_income" type="currency">
<typ:number-val>13000.0</typ:number-val>
</typ:attribute>
<typ:attribute id="claimant_date_of_birth" type="date">
<typ:date-val>1981-03-22</typ:date-val>
</typ:attribute>
<typ:attribute id="claimant_public_housing_client" type="boolean">
<typ:boolean-val>true</typ:boolean-val>
</typ:attribute>
<typ:entity id="child" inferred="false">
<typ:instance id="child_1">
<typ:attribute id="child_age" type="number">
<typ:number-val>9.0</typ:number-val>
</typ:attribute>
</typ:instance>
<typ:instance id="child_2">
<typ:attribute id="child_age" type="number">
<typ:number-val>5.0</typ:number-val>
</typ:attribute>
</typ:instance>
</typ:entity>
</typ:global-instance>
</typ:assess-response>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>