Option Explicit
Sub TEST2()
Dim objCurlHttp As Object
Dim strResult As String
Dim varReqToken As Variant
Dim strWebServiceUrl As String
Dim strOwnerKey As String
Dim strQry As String, MYEMAYL As String
MYEMAYL = "gss.italy@iol.it"
strWebServiceUrl = "https://api.apilayer.com/email_verification/" & MYEMAYL
strOwnerKey = "99999999999999999999999"
Set objCurlHttp = CreateObject("MSXML2.serverXMLHTTP")
With objCurlHttp
.Open "GET", strWebServiceUrl, False
.setRequestHeader "cache-control", "no-cache"
.setRequestHeader "Content-type", "application/json; charset=utf-8"
.setRequestHeader "Content-type", "Accept"
.setRequestHeader "apikey", strOwnerKey
.send
strResult = .responseText
Debug.Print .Status
Debug.Print .getAllResponseHeaders
Debug.Print strResult
End With
Set objCurlHttp = Nothing
End Sub
see the result of debug.print:
200
Connection: keep-alive
Date: Tue, 28 Jan 2025 17:44:04 GMT
Content-Length: 389
Content-Type: application/json
Server: cloudflare
X-Cloud-Trace-Context: 217ba070ab6075e4109d6e7b7f8d8750
Access-Control-Allow-Origin: *
X-RateLimit-Limit-Month: 100
X-RateLimit-Remaining-Day: 81
RateLimit-Reset: 195356
RateLimit-Limit: 100
RateLimit-Remaining: 81
X-RateLimit-Limit-Day: 100
X-RateLimit-Remaining-Month: 81
cf-cache-status: DYNAMIC
Report-To: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v4?s=i3ZMekmCw%2Bio9S4cyoM3v7tiuPtu4wU04%2ByYWdOP4RlZc8qEsECKATKaVsk69Qh5PYWzgicdmsO2T2sWSmYaqdfvlOYFVRINb9obZC6DXjc6ap7lS2mhfGEjQv10vRMhLTmvGTaaOnpg3AsdoVI%3D"}],"group":"cf-nel","max_age":604800}
NEL: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
Strict-Transport-Security: max-age=2592000; includeSubDomains
X-Content-Type-Options: nosniff
CF-RAY: 9092c9d40bd5edaf-MXP
alt-svc: h3=":443"; ma=86400
server-timing: cfL4;desc="?proto=TCP&rtt=64719&min_rtt=52458&rtt_var=28467&sent=11&recv=11&lost=0&retrans=1&sent_bytes=5932&recv_bytes=1249&delivery_rate=32463&cwnd=256&unsent_bytes=0&cid=ce0c12e80c1a77a8&ts=59714&x=0"
{
"email": "gss.italy@iol.it",
"did_you_mean": "",
"user": "gss.italy",
"domain": "iol.it",
"syntax_valid": true,
"is_disposable": false,
"is_role_account": false,
"is_catch_all": false,
"is_deliverable": false,
"can_connect_smtp": false,
"is_inbox_full": "",
"is_disabled": "",
"mx_records": true,
"free": true,
"score": 0.48
}
the email address is corect? or not?
Sub TEST2()
Dim objCurlHttp As Object
Dim strResult As String
Dim varReqToken As Variant
Dim strWebServiceUrl As String
Dim strOwnerKey As String
Dim strQry As String, MYEMAYL As String
MYEMAYL = "gss.italy@iol.it"
strWebServiceUrl = "https://api.apilayer.com/email_verification/" & MYEMAYL
strOwnerKey = "99999999999999999999999"
Set objCurlHttp = CreateObject("MSXML2.serverXMLHTTP")
With objCurlHttp
.Open "GET", strWebServiceUrl, False
.setRequestHeader "cache-control", "no-cache"
.setRequestHeader "Content-type", "application/json; charset=utf-8"
.setRequestHeader "Content-type", "Accept"
.setRequestHeader "apikey", strOwnerKey
.send
strResult = .responseText
Debug.Print .Status
Debug.Print .getAllResponseHeaders
Debug.Print strResult
End With
Set objCurlHttp = Nothing
End Sub
see the result of debug.print:
200
Connection: keep-alive
Date: Tue, 28 Jan 2025 17:44:04 GMT
Content-Length: 389
Content-Type: application/json
Server: cloudflare
X-Cloud-Trace-Context: 217ba070ab6075e4109d6e7b7f8d8750
Access-Control-Allow-Origin: *
X-RateLimit-Limit-Month: 100
X-RateLimit-Remaining-Day: 81
RateLimit-Reset: 195356
RateLimit-Limit: 100
RateLimit-Remaining: 81
X-RateLimit-Limit-Day: 100
X-RateLimit-Remaining-Month: 81
cf-cache-status: DYNAMIC
Report-To: {"endpoints":[{"url":"https:\/\/a.nel.cloudflare.com\/report\/v4?s=i3ZMekmCw%2Bio9S4cyoM3v7tiuPtu4wU04%2ByYWdOP4RlZc8qEsECKATKaVsk69Qh5PYWzgicdmsO2T2sWSmYaqdfvlOYFVRINb9obZC6DXjc6ap7lS2mhfGEjQv10vRMhLTmvGTaaOnpg3AsdoVI%3D"}],"group":"cf-nel","max_age":604800}
NEL: {"success_fraction":0,"report_to":"cf-nel","max_age":604800}
Strict-Transport-Security: max-age=2592000; includeSubDomains
X-Content-Type-Options: nosniff
CF-RAY: 9092c9d40bd5edaf-MXP
alt-svc: h3=":443"; ma=86400
server-timing: cfL4;desc="?proto=TCP&rtt=64719&min_rtt=52458&rtt_var=28467&sent=11&recv=11&lost=0&retrans=1&sent_bytes=5932&recv_bytes=1249&delivery_rate=32463&cwnd=256&unsent_bytes=0&cid=ce0c12e80c1a77a8&ts=59714&x=0"
{
"email": "gss.italy@iol.it",
"did_you_mean": "",
"user": "gss.italy",
"domain": "iol.it",
"syntax_valid": true,
"is_disposable": false,
"is_role_account": false,
"is_catch_all": false,
"is_deliverable": false,
"can_connect_smtp": false,
"is_inbox_full": "",
"is_disabled": "",
"mx_records": true,
"free": true,
"score": 0.48
}
the email address is corect? or not?