AnsweredAssumed Answered

API from command line give invalid XML error

Question asked by wkolatac on Feb 25, 2018
Latest reply on Feb 28, 2018 by wkolatac

Hi -

I'm running the following command from the Windows command line:

curl -u "<user:password>" -H "content-type: text/xml" --data-binary -@ -k < .\file.xml


The response message is:
<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="" xsi:noNamespaceSchemaLocation="">
<errorMessage>Invalid XML format: Content is not allowed in prolog.</errorMessage>


The file.xml contains a very simple request filter (see attachment).


Any idea what is wrong?  I've checked the file.xml many times and doesn't appear to be any hidden characters before the <ServiceRequest> tag ....


I've even tried just the beginning/end Service Request tag with different API calls and get the same result so I'm wondering if the error message is correct...

Any help is appreciated.