How to Get the XML Structure of a Case Type
Each Case Type typically has its own custom form with fields specific to that Case Type. When the user clicks "Save", the page collects all of the case and custom form data into an XML string. For example:
XML Code for EMAIL
XML
<CustomData>
<Attributes>
<Object ObjectCode="CASE">
<Item>
<OBJECTCODE>
<![CDATA[CASE]]>
</OBJECTCODE>
<ID>-3</ID>
<PARENTID>0</PARENTID>
<PARENTCODE></PARENTCODE>
<_KEY>
<![CDATA[CASE]]>
</_KEY>
<CASESYSTYPE_ID>22</CASESYSTYPE_ID>
<PRIORITY_ID>7</PRIORITY_ID>
<SUMMARY></SUMMARY>
<DESCRIPTION></DESCRIPTION>
<DRAFT>0</DRAFT>
</Item>
</Object>
<Object ObjectCode="CDM_EMAIL">
<Item>
<PARENTID>-3</PARENTID>
<OBJECTCODE>
<![CDATA[CDM_EMAIL]]>
</OBJECTCODE>
<ID>-2</ID>
<PARENTCODE></PARENTCODE>
<_KEY>
<![CDATA[CDM_EMAIL--2]]>
</_KEY>
<MODELID>83</MODELID>
<DOMOBJECTCODE>
<![CDATA[CDM_EMAIL]]>
</DOMOBJECTCODE>
<CDM_EMAIL_POTENTIALDUPLICATE>0</CDM_EMAIL_POTENTIALDUPLICATE>
<MAIL_CATEGORY_NAME>
<![CDATA[Internal Mail]]>
</MAIL_CATEGORY_NAME>
<_MAIL_CATEGORY_REFNAME>
<![CDATA[Internal Mail]]>
</_MAIL_CATEGORY_REFNAME>
<MAIL_CATEGORY_ID>821</MAIL_CATEGORY_ID>
</Item>
</Object>
</Attributes>
</CustomData>
To get the XML code of the case you need, use the Developer Tools in our browser.
- In Google Chrome press CTRL-SHIFT- I to open the Developer Tools window.
- Select the Network tab, check only Fetch/XHR requests type and then clean the screen.
- Create a new case using dummy data.
- After creating the new case, filter the view for DCM to show only rules containing DCM and then click on the root_DCM_createCaseWithOptions rule to see the details.
- In the Headers section scroll down to see the Form Data property and look for the InputXML parameter. This is the full XML code needed to create new cases.
- Save the InputXML content for further references.