Post XML file to remote server

I am attempting to use a gateway to an external interface for data exchange between my institution and an external site. Data is exchanged using XML documents defined by the third party. I am new to XML and have been able to get a 200 OK response from the external server, but the anticipated result of rates on the site changing does not occur.

Can you review the code below and point me in a direction as to where I might be going wrong?

Below is my attempt at the post code and also the xml file. I have followed the remote companies example xml file and it should be good, my main concern is with the post code.

Also, attached is their Rate Integration Guide.

Assistance would be greatly appreciated.
Dim xmlDoc
Dim xmlHTTP 
Dim ConfirmationXML
Set xmlDoc = server.CreateObject("Microsoft.XMLDOM")
xmlDoc.async = False
xmlDoc.Load "E:\file.xml"
Set xmlHTTP = server.CreateObject("WinHttp.WinHttpRequest.5.1")
xmlHTTP.Open "POST",
"https://test-interface.mortgagewebcenter.com/XML/Gateway.asp", False
xmlHTTP.send xmlDoc.xml
xmlHTTP.WaitForResponse
ConfirmationXML = xmlHTTP.Status & " " & xmlHTTP.StatusText
Set xmlDoc = Nothing
Set xmlHTTP = Nothing
response.Write(ConfirmationXML)
 
 
 
<?xml version="1.0" encoding="UTF-8"?>
<TRANSACTION Type="MR_HTTPS_01" ProcessFeedback="Error" >
<MWC_AUTHENTICATION>
<USER_CODE>######</USER_CODE>
<PASSWORD>#######</PASSWORD>
<DOMAIN_CODE>#######</DOMAIN_CODE>
</MWC_AUTHENTICATION>
<RATE_UPLOAD>
<PARTNER Partner_Id="123"/>
<RATE_DATA>
PARTNER_ID,PRODUCT_ID,STATE_ID,COUNTY_CODE,MIN_LOAN_AMOUNT,MAX_LOAN_AMOUNT,L
OCK_PERIOD_ID,RATE,POINTS,REBATE,LOCK_EXPIRATION_DATE,ARM_INDEX_VALUE,HEQ_LO
C_MARGIN,
2761,0,3,0,1000000,4.75,0,0,10/1/08,0,
19053,0,3,0,1000000,4.75,0,0,10/1/08,0,
2767,0,3,0,1000000,4.75,0,0,10/1/08,0,
2811,0,3,0,1000000,4.75,0,0,10/1/08,0,
2762,0,3,0,1000000,4.75,0,0,10/1/08,0,
2812,0,3,0,1000000,4.75,0,0,10/1/08,0,
2763,0,3,0,1000000,4.75,0,0,10/1/08,0,
2813,0,3,0,1000000,4.75,0,0,10/1/08,0,
2768,0,3,0,1000000,4.75,0,0,10/1/08,0,
2769,0,3,0,1000000,4.75,0,0,10/1/08,0,
8303,0,3,0,1000000,4.75,0,0,10/1/08,0,
8304,0,3,0,1000000,4.75,0,0,10/1/08,0,
2764,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
2765,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
7893,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
2766,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
7894,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
7769,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
7770,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
16779,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
16780,0,3,0,1000000,4.75,0,0,10/1/08,0.64,
</RATE_DATA>
</RATE_UPLOAD>
</TRANSACTION>

Open in new window

MortgagebotRateIntegrationGuide.doc
sstillisAsked:
Who is Participating?
 
BigRatConnect With a Mentor Commented:
You're not setting the content type. See MS Knowledge Base Q290591 Add :-

xmlhttp.setRequestHeader("Content-Type", "text/xml");


You may have to use application/xml instead of text/xml. Ask the receiver of the data.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.