1 Reply Latest reply: Sep 11, 2013 5:39 PM by ross_c RSS

    Return value of inferred entity instance from relationship in SOAP Determinations

    ross_c

      Hey,

      I had an original thread open which indicates the problem I was trying to solve (Multiple Conclusion based on input values ). My rule base now behaves as expected and I can test it in the debugger as expected, only now I can't get the actual identifying values back I want using the determinations web service.


      I get a whole bunch of inferred entity instances back from an inferred relationship the same as the situation/screen shot at the bottom of the "Investigate an inferred relationship" page on the Oracle Policy Automation Cloud Service User Guide, but in my SOAP response I only get the instances with hashed IDs. I want the actual identifying value of the entity.


      e.g. Currently get this:


      <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/11.0/rulebase/assess/types">
         <SOAP-ENV:Header>
            <i18n:international>
               <i18n:locale>en_GB</i18n:locale>
               <i18n:tz>GMT-0500</i18n:tz>
            </i18n:international>
         </SOAP-ENV:Header>
         <SOAP-ENV:Body>
            <typ:assess-response>
               <typ:global-instance>
                  <typ:attribute id="course_code" type="text">
                     <typ:text-val>AHPY</typ:text-val>
                  </typ:attribute>
                  <typ:entity id="the_supplementary_documents" inferred="true">
                     <typ:instance id="0x608c2dc220e15d8c"></typ:instance>
                     <typ:instance id="0x5b7e2d02e8780325"></typ:instance>
                  </typ:entity>
                  <typ:entity id="the_informational_documents" inferred="true">
                     <typ:instance id="0x19387621439a43c7"></typ:instance>
                  </typ:entity>
               </typ:global-instance>
            </typ:assess-response>
         </SOAP-ENV:Body>
      </SOAP-ENV:Envelope>
      
      


      But I want something like below and I'm having a lot of trouble figuring out how to actually do this. Also is there anywhere that defines the meaning of errors you get from OPA? I have tried to modify my rulebase and I got a few OPA-EXXXXX errors but apart from the description you get in OPM, I can't find anywhere that gives more detail on these and explains what they mean/how to fix it.


      <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/11.0/rulebase/assess/types">
         <SOAP-ENV:Header>
            <i18n:international>
               <i18n:locale>en_GB</i18n:locale>
               <i18n:tz>GMT-0500</i18n:tz>
            </i18n:international>
         </SOAP-ENV:Header>
         <SOAP-ENV:Body>
            <typ:assess-response>
               <typ:global-instance>
                  <typ:attribute id="course_code" type="text">
                     <typ:text-val>AHPY</typ:text-val>
                  </typ:attribute>
                  <typ:entity id="the_supplementary_documents" inferred="true">
                     <typ:instance id="http://mydomain.com/mydocument.pdf">
                     </typ:instance>
                     <typ:instance id="http://mydomain.com/mydocument.pdf"></typ:instance>
                  </typ:entity>
                  <typ:entity id="the_informational_documents" inferred="true">
                     <typ:instance id="http://mydomain.com/mydocument.pdf"></typ:instance>
                  </typ:entity>
               </typ:global-instance>
            </typ:assess-response>
         </SOAP-ENV:Body>
      </SOAP-ENV:Envelope>
      
      

       



        • 1. Re: Return value of inferred entity instance from relationship in SOAP Determinations
          ross_c

          I managed to get this working by referring to this thread: Inferred Entity Instances IDs in output response

           

          I had tried something similar but not quite the same. In the end my request looked something like this:

           

          <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:typ="http://oracle.com/determinations/server/11.0/rulebase/assess/types">
             <soapenv:Header/>
             <soapenv:Body>
                <typ:assess-request>
                   <typ:config>
                     <typ:outcome>
                    <typ:entity id="the_supplementary_documents">
                      <typ:attribute-outcome id="supplementary_documents" outcome-style="value-only"/>
                    </typ:entity>
                    <typ:entity id="the_informational_documents">
                      <typ:attribute-outcome id="informational_documents" outcome-style="value-only"/>
                    </typ:entity>
                 </typ:outcome>
                   </typ:config>
                   <typ:global-instance>
                      <typ:attribute id="course_code">
                      <typ:text-val>AHPY</typ:text-val>
             </typ:attribute>
                    </typ:global-instance>
                </typ:assess-request>
             </soapenv:Body>
          </soapenv:Envelope>