MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord
    MagicMirror² v2.20.0 is available! For more information about this release, check out this topic.

    Mycommute is not working for me

    Troubleshooting
    2
    4
    83
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M
      matelot20 last edited by

      I got the API from Google. Tested with google link below and was able to see the results in json format.
      (https://maps.googleapis.com/maps/api/directions/json?origin=Disneyland&destination=Universal+Studios+Hollywood&key=enter_my_api_key)

      When I tried running in MM, I get “Must use an API key to authenticate each request”. Any pointers?

      My config is as follow

          module: "MMM-MyCommute",
          position: "top_center",
          header: "Traffic",
          config: {
             apikey:  [my api key],
             origin: "Disneyland",
             destinations: [
                  { destination: "Universal+Studios+Hollywood",
                    label: "Fun",
                    mode: "driving" }
                  ]
          }
      
      1 Reply Last reply Reply Quote 0
      • G
        gwiz last edited by gwiz

        Hi @matelot20,

        I know that MMM-MyCommute was having some issues on my mirror yesterday as well, but fixed itself later in the day without me having to do anything (still not sure why exactly that was happening, but it’s better now). I know that for it to recognize your destinations you have to have the address as it shows in Google Maps, for example: Disneyland Anaheim would be “1313 Disneyland Dr, Anaheim, CA 92802” instead of “Disneyland” as you have it in your config. As for the API message, it could be something different.

        Please let me know if that helps!

        Edit - I just realized that if you are running the latest update of MMM-MyCommute, there was an update that changed the config text “apikey” to “apiKey”, so

        apikey:  [my api key],
        

        would now be

        apiKey:  [my api key],
        

        That could be where your API issue stems from

        1 Reply Last reply Reply Quote 1
        • M
          matelot20 last edited by

          @gwiz you are right on. It was the apiKey that causes the problem. Thanks so much for pointing it out. Would have never guessed it. Have a good day.

          G 1 Reply Last reply Reply Quote 0
          • G
            gwiz @matelot20 last edited by

            @matelot20 Awesome, glad I could help!

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post
            Enjoying MagicMirror? Please consider a donation!
            MagicMirror created by Michael Teeuw.
            Forum managed by Paul-Vincent Roll and Rodrigo Ramírez Norambuena.
            This forum is using NodeBB as its core | Contributors
            Contact | Privacy Policy