Sponsored Content
Top Forums Web Development Error on executing soap request using Curl command Post 302956314 by siramitsharma on Tuesday 29th of September 2015 01:51:31 AM
Old 09-29-2015
Error on executing soap request using Curl command

hi,
i have curl command to POST a soap request to web service. I have a file (query.xml) which has all the soap message attached to it I just don't seem to be able to properly post it.

curl command
Code:
curl -s -H "Content-Type: text/soap+xml;charset=UTF-8" -H "SOAPAction:" -d @query.xml http://10.130.9.79:7782/services/CBSInterfaceBusinessMgrService

query.xml
Code:
<q2:QueryBasicInfoRequestMsg
        xmlns:q0="http://www.huawei.com/bme/cbsinterface/cbs/businessmgr"
        xmlns:q1="http://www.huawei.com/bme/cbsinterface/common"
        xmlns:q2="http://www.huawei.com/bme/cbsinterface/cbs/businessmgrmsg">
        <parameter name="enableREST">true</parameter>
        <RequestHeader>
                <q1:CommandId>QueryBasicInfo
                </q1:CommandId>
                <q1:Version>1
                </q1:Version>
                <q1:TransactionId/>
                        <q1:SequenceId>1
                        </q1:SequenceId>
                        <q1:RequestType>Event
                        </q1:RequestType>
                        <q1:SerialNo>03020000003
                        </q1:SerialNo>
        </RequestHeader>
<QueryBasicInfoRequest>
<q0:SubscriberNo>9150000014</q0:SubscriberNo> <q0:QueryType>3</q0:QueryType> </QueryBasicInfoRequest> </q2:QueryBasicInfoRequestMsg>

error coming is
Code:
<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:wsa="http://www.w3.org/2005/08/addressing" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><soapenv:Header>
<wsa:ReplyTo><wsa:Address>http://www.w3.org/2005/08/addressing/none
</wsa:Address>
</wsa:ReplyTo><wsa:MessageID>urn:uuid:AAC81E84BC63EF7AA81443502795856131
</wsa:MessageID><wsa:Action>http://www.w3.org/2005/08/addressing/soap/fault
</wsa:Action>
</soapenv:Header>
<soapenv:Body>
<soapenv:Fault>
<faultcode></faultcode><faultstring>com.ctc.wstx.exc.WstxUnexpectedCharException: Unexpected character '-' (code 45) in prolog; expected '&lt;'
 at [row,col {unknown-source}]: [1,22]</faultstring><detail /></soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>

 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

error while executing the mail command

Hi, I am getting an error while executing the mail command.... It says saved letter in dead.letter even though the email id id correct . Please do help.. Madhu (2 Replies)
Discussion started by: madhumathikv
2 Replies

2. UNIX for Advanced & Expert Users

Issue in Curl to send http POST request with attachment/multipart

Hi, I am using curl to hit a url using http in solaris 10 using commandline, I want to transfer an attachment(using multipart curl -F) also as a part of the request. If anyone has used kindly help me with the syntax. I am using below command: Code: /usr/local/bin/curl -v... (1 Reply)
Discussion started by: manishmaha
1 Replies

3. Red Hat

Error while executing isql command on RHEL4

Hi, I am using RHEL4 and Oracle11g , my application requires odbc connection hence I modified ODBC.ini file and when I exceute isql commande I got the following error. isql: error while loading shared libraries: /opt/nastel/apwmq/odbc/lib/libodbc.so.1: requires glibc 2.5 or later dynamic... (1 Reply)
Discussion started by: roopalidalvi231
1 Replies

4. Red Hat

Error while executing isql command on RHEL4

Hi, I am using RHEL4 and Oracle11g , my application requires odbc connection hence I modified ODBC.ini file and when I exceute isql commande I got the following error. isql: error while loading shared libraries: /opt/nastel/apwmq/odbc/lib/libodbc.so.1: requires glibc 2.5 or later dynamic... (4 Replies)
Discussion started by: roopalidalvi231
4 Replies

5. Shell Programming and Scripting

Error while executing sh command

Hi, I have 2 files temp1.sh and temp2.sh as follows: =========== temp1.sh =========== echo "session1" sh temp2.sh echo "exit session2 and enter session1" ================================= ============= temp2.sh ============= echo "session2" sh echo "exit session2"... (5 Replies)
Discussion started by: RP09
5 Replies

6. Solaris

Access Sharepoint site using SOAP request in unix

Hi, We are using a java application (Java 6 , Using JAX-WS 2.0 to Create a Simple Web Service) that accesses SharePoint API through web services. We were able to get the data in windows and do all operations the API allows. When we deploy this application on UNIX environment (Solaris 10)... (0 Replies)
Discussion started by: johninweb
0 Replies

7. UNIX for Advanced & Expert Users

Error executing sqlcmd command through UNIX

Hi All, I am trying to execute a set of sql statements in sql server 2008 using the sqlcmd command in unix and passing the query in the "input" parameter. It is giving me an error "incorrect syntax near 2014". The below statement is giving an error : declare date_val datetime, ... (4 Replies)
Discussion started by: Rahul Raj
4 Replies

8. IP Networking

CurL command Rest API call with oauth 2.0 secutity error

Hi I need to get rates for different security form REST API . the API is oauth 2.0 secured. i need to use curl command to get json response from api . token URL - is HTTP data URL is - HTTPS when trigger my command from bash script it passing and failing intermittently with... (0 Replies)
Discussion started by: shobhit.working
0 Replies

9. Web Development

Curl Command Error

Good afternnon. I need your help please to understand the basics of curl command to test web services. Ive heard i can test a web service using this command,so: curl http://glb_osb_fs.nh.inet:7110/serverglobal/services/StrategicPlanning/NotifyMNPAction_v1 it yields some errors, i would... (5 Replies)
Discussion started by: alexcol
5 Replies
XML::CommonNS(3pm)					User Contributed Perl Documentation					XML::CommonNS(3pm)

NAME
XML::CommonNS - A list of commonly used namespaces SYNOPSIS
# import $RDF, $RDFS, $OWL, $DC use XML::CommonNS qw(RDF RDFS OWL DC); my %CONFIG = ( Namespaces => { rdf => "$RDF", rdfs => "$RDFS", owl => "$OWL", foaf => "$FOAF", }, ExpandQNames => 1, ); # or the uri() method my $foaf = XML::CommonNS->uri('FOAF'); DESCRIPTION All you need do to use this module is import the namespaces you want from the list below. All of those will then become available to you. They are XML::NamespaceFactory object and can thus be used both as simple strings and as XML::NamespaceFactory objects. See XML::NamespaceFactory for how that may help you. I hesitated for a while before releasing this module. As a directory of namespaces that can't (and almost certainly shouldn't) be exhaustive, it implies editorial decisions and I wasn't certain it was CPAN worthy. However, after getting really tired of tracking down namespaces in every single small XML muning script I made, I wrote it for myself. After a while using it, I don't see why others wouldn't find it useful as well. NAMESPACES
The currently available namespaces are listed below. Should you consider one worthy of addition (it needs to be common enough) please simply notify me. Those marked with a start are subject to change. I WILL change them when the corresponding specification changes. XML http://www.w3.org/XML/1998/namespace XMLNS http://www.w3.org/2000/xmlns/ XLINK http://www.w3.org/1999/xlink SVG http://www.w3.org/2000/svg XHTML http://www.w3.org/1999/xhtml XHTML2 http://www.w3.org/2002/06/xhtml2 XFORMS http://www.w3.org/2002/xforms/cr XMLEVENTS http://www.w3.org/2001/xml-events DC http://purl.org/dc/elements/1.1/ DC_TERMS http://purl.org/dc/terms/ RDF http://www.w3.org/1999/02/22-rdf-syntax-ns# RDFS http://www.w3.org/2000/01/rdf-schema# OWL http://www.w3.org/2002/07/owl# FOAF http://xmlns.com/foaf/0.1/ REL http://purl.org/vocab/relationship/ RSS1 http://purl.org/rss/1.0/ COMMENTS http://purl.org/net/rssmodules/blogcomments/ SYN http://purl.org/rss/1.0/modules/syndication/ RNG http://relaxng.org/ns/structure/1.0 XSD http://www.w3.org/2001/XMLSchema XSI http://www.w3.org/2001/XMLSchema-instance MATHML http://www.w3.org/1998/Math/MathML XSLT http://www.w3.org/1999/XSL/Transform XSLFO http://www.w3.org/1999/XSL/Format SOAPENC11 http://schemas.xmlsoap.org/soap/encoding/ SOAPENV11 http://schemas.xmlsoap.org/soap/envelope/ SOAPENC12 http://www.w3.org/2003/05/soap-encoding SOAPENV12 http://www.w3.org/2003/05/soap-envelope WSDL11 http://schemas.xmlsoap.org/wsdl/ WSDL12 http://www.w3.org/2003/06/wsdl METHODS
uri Allows you to directly retrieve one of the URI objects without doing the import() dance. AUTHOR
Chris Prather, <chris@prather.org> Robin Berjon, <robin.berjon@expway.fr> COPYRIGHT AND LICENSE
Copyright 2003 by Robin Berjon This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself. perl v5.10.1 2011-03-05 XML::CommonNS(3pm)
All times are GMT -4. The time now is 03:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy