EDIT 1: According to my domain provider, the problem is not coming from our server. they tried accessing the URL in the request from a browser physically on the server my website is on and they say it works. i would guess that accessing through a the browser goes a different "route" and maybe wasn't blocked? Also, they say they disabled the firewall on the server and the result was the same.
In the effort of connecting to the WhatsApp API through 360diualog I was successfully sending http requests using the code below:
Set SXHttp = Server.CreateObject("MSXML2.XMLHTTP.6.0")
SXHttp.Open "GET", "https://waba.360dialog.io/v1/configs/phone_number"
SXHttp.SetRequestHeader "D360-API-KEY", "API_KEY_HERE"
SXHttp.Send
Sadly, a few days ago this code started returning this error on line SXHttp.Send
:
msxml6.dll error '800c0005'
The system cannot locate the resource specified.
/wa/setwebhook.asp, line 10
in the effort of debugging I added there:
response.write("Err.Number: "&Err.Number&"<BR>")
response.write("Err.Description: "&Err.Description&"<BR>")
response.write("Err.Source: "&Err.Source&"<BR>")
response.write("status: "&SXHttp.status&"<BR>")
response.write("statusText: "&SXHttp.statusText&"<BR>")
response.write("readyState: "&SXHttp.readyState&"<BR>")
response.write("responseBody: "&SXHttp.responseBody&"<BR>")
response.write("responseStream: "&SXHttp.responseStream&"<BR>")
and that returned:
Err.Number: -2146697211
Err.Description: The system cannot locate the resource specified.
Err.Source: msxml6.dll
status: 12029
statusText:
readyState: 4
responseBody:
responseStream:
Since, I am using successfully the same code directed to 2 different services (1. sending regular text messages; 2. creating invoices). And, when sending a request from postman.com it works. I think this means the problem has to do with the specific pairing of my server and the 360dialog server?
also, I've think that status 12029
means:
ERROR_INTERNET_CANNOT_CONNECT inetmsg.h
ERROR_INTERNET_CANNOT_CONNECT wininet.h
Err.Number: -2146697211
is some signed in 32bit thingmajig that I tried converting with 5 different calculators all all gave me a different answer, so I guess I'm not doing it right.
conclusion:
- the request to 360Dialog gives error
- same request method works when sent to sms or invoice servers
- postman request to 360Dialog with the same request doesn't return errors
QUESTION: how should I proceed? what might be the cause?