Powered by Zoomin Software. For more details please contactZoomin

Deploying a Decision Service as a Web Service forJava

Prepare requests

  • Last Updated: October 26, 2026
  • 1 minute read
    • Corticon
    • Version 7.1
    • Documentation

When a Web Service client sends a request message to a Decision Service that is exposed as a Web Service, the message contains data enclosed within XML or JSON tags. For this tutorial, our request messages use JSON and XML.

The JSON request message looks like this:

{
  "__metadataRoot": {},
  "name": "Cargo",
  "Objects": [
    {
      "volume": 10,
      "container": null,
      "itemWeight": 1000,
      "__metadata": {
        "#type": "Shipment",
        "#id": "Cargo_id_1"
      }
    }
  ]
}

Copy this code, and then save it as ShipmentPayload.json.

The XML request message looks like this:

<?xml version="1.0" encoding="UTF-8"?>
<CorticonRequest xmlns="urn:Corticon" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" decisionServiceName="Cargo">
  <WorkDocuments>
    <Shipment id="Shipment_id_1">
      <itemWeight>1000</itemWeight>
      <volume>10</volume>
      <container xsi:nil="true" />
    </Shipment>
  </WorkDocuments>
</CorticonRequest>

Copy this code, and then save it as ShipmentPayload.xml.

Alert