OpenSprinkler Forums OpenSprinkler Unified Firmware Invalid API key has been detected.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #35976

    zeddy
    Participant

    Hello

    I have recently upgraded my opensprinkler to the latest version of firmware. I have setup the wunderground API key, and when I click verify it goes green, which to me indicates that it is valid. I then go to the main menu and click “Weather Diagnostics” and get an error “Invalid API key detected”

    When I log into the weather underground site I can see it making API calls on the graph so it appears to be working. How to I fix the diagnostics menu?

     

    App Version 1.3.0

    Hardware Version V2.0

    Firmware 2.1.3

    #35991

    Samer
    Keymaster

    Although the app is saying “An invalid API key has been detected” the reality is the error is being thrown because WUnderground is giving an error. The line of code specifically triggering the error you are seeing is below:

    if (typeof data.response.error === “object”) {
    showerror(_(“An invalid API key has been detected”));
    return;
    }

    This means it WUnderground returns data with an error then the app stops processing the request and shows the message.

    The reality is, this can be due to your API key having no more calls for that day or it could be the location is not valid. In order to debug this, I would navigate directly to WUnderground by using the below URL to discover the actual error:

    http://api.wunderground.com/api/APIKEY/yesterday/conditions/q/LOCATION.json

    Change the APIKEY to your WUnderground API key and LOCATION to the location you have provided in the location box on the options page. Once we have the actual error we can troubleshoot from there.

    Thank you

    #36072

    zeddy
    Participant

    Hi Samer
    Long story short I had manually typed in my location, this did show the correct weather for the week but obviously it was wrong enough that the diagnostics page threw an error. I used the find location button and selected my location that way and now the diagnostics work.

    Thanks for the help.

    #42648

    dyewell
    Participant

    Thanks for the posts. I had the same problem as a result of manually selecting location as well. Accepting the default location returned via search fixed the API key error for me as well.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.

OpenSprinkler Forums OpenSprinkler Unified Firmware Invalid API key has been detected.