Troubleshooting
Problem
Attempts to invoke service through REST URL in IBM Sterling Order Management leads to Invalid XML error.
Symptom
Steps to replicate:
- Create a service called TestService which is used to get the order list
- Invoked the service through a REST URL as follows:
http://localhost:8084/smcfs/restapi/executeFlow/TestService
The following error message is thrown:
"ErrorDescription": "YFS:Invalid XML", "ErrorUniqueExceptionId": "9.112..245.20214830783994690000000000004", "ErrorCode": "YFS10013", "MoreInfo": { "Expected Root YFCNode": "Order", "Actually received YFCNode": "TestService"}
Cause
The REST framework sends the root element name as the service name.
Diagnosing The Problem
For a service named TestService when the Json input is sent as {"Order": { "EnterpriseCode": "DEFAULT", "OrderNo": "Y100000000" } } the XML input sent to the SDF service is:
<TestService>
<Order EnterpriseCode="DEFAULT" OrderNo="Y100000000"/>
</TestService>
Resolving The Problem
Since the REST framework does not know which API/services are configured inside the TestService, it places the service name as the root xml element name. The service can include suitable XSL/custom API components to parse the input as per needs.
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg22000753