Not a coder, but a tinkerer and learning. Would appriciate any help.
I have this script working with another simmilar API, but I am getting this error both with Cat & Dog API
"‘Object doesn’t support this property or method: ‘j.url’’ v )"
I have a API key, but as the URL works without the API Key, I am trying without it, would appriciate if someone can show me how to use the API key in the below script.
aURL = “https://api.thecatapi.com/v1/images/search”
Set http = CreateObject(“Msxml2.XMLHTTP”)
http.open "GET",aURL,False http.send strJson = http.responseText EKOManager.StatusMessage ("the URL to get is" & strJson) Set j = ParseJson(strJson) Result = j.url EKOManager.StatusMessage ("the URL for the image is " & Result)
Set html = CreateObject(“htmlfile”)
Set window = html.parentWindow
window.execScript "var json = " & strJson, “JScript”
Set ParseJson = window.json