Hey that was a quick response and thanks.. I am now able to get xPath added to my template.
my Request is:
<upi:ReqListAccount xmlns:upi="
http://npci.org/upi/schema/">
<Head ver="2.0" ts="" orgId="" msgId=""/>
<Txn id="1234567" note="" refId="" refUrl="" ts="" type="ListAccount" />
am trying to template it as..
"serveEventListeners": [
{
"name": "webhook",
"parameters": {
"method": "POST",
"url": "
http://10.140.138.12:8081/upi/RespListAccount/2.0",
"body": "<upi:RespListAccount xmlns:upi=\"
http://npci.org/upi/schema/\">\n <Head ver=\"*{{xPath originalRequest.body '/upi:ReqListAccount/Head/ver()*'}}\" ts=\"\" orgId=\"\" msgId=\"\"/>\n <Txn id=\"123456\" note=\"\" refId=\"123456\" refUrl=\"\" ts=\"\" type=\"ListAccount\"/>\n <Resp reqMsgId=\"\" result=\"SUCCESS\" errCode=\"\"/>\n <AccountList>\n <Account accType=\"SAVINGS\" mbeba=\"\" accRefNumber=\"\" maskedAccnumber=\"\" ifsc=\"HDFC0000101\" mmid=\"9056014\" name=\"\" aeba=\"Y\" aadhaarNo=\"1234 5678 9012\">\n <CredsAllowed type=\"PIN\" subType=\"ATMPIN\" dType=\"\" dLength=\"\"/>\n </Account>\n <Account accType=\"SAVINGS\" mbeba=\"\" accRefNumber=\"\" maskedAccnumber=\"\" ifsc=\"HDFC0000103\" mmid=\"9056114\" name=\"\" aeba=\"N\">\n <CredsAllowed type=\"PIN\" subType=\"MPIN\" dType=\"\" dLength=\"\"/>\n </Account>\n </AccountList>\n</upi:RespListAccount>",
"headers": {
"Content-Type": "application/xml"
},
"delay": {
"type": "fixed",
"milliseconds": 3000
},
"transformRequestBody": true,
"transformers": ["response-template"]
}
am getting an error saying
<Head ver="[ERROR: /upi:ReqListAccount/Head/ver() is not a valid XPath expression]"