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.

    sendSocketNotification not working

    Development
    1
    3
    967
    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
      mongo116 Module Developer last edited by

      Hi,

      Does anybody know whether you can use sendSocketNotification when using nested Request functions?

      Basically, the way the api works, is that you have to login to get a sessionID and then I have another request using that sessionID to pull back JSON data. For some reason the second requests sendSocketNotification is working fine, but the first one isn’t.

      The first request is definitely working, as the sessionID is being pulled from the response.

      I’m trying to do this so I can update the MMM-Hive module as British Gas made some changes and the module no longer works.

      1 Reply Last reply Reply Quote 0
      • M
        mongo116 Module Developer last edited by

        If you look at the MMM-Hive code, what I am trying to do, is add a sendSocketNotification to the 2nd request in the node_helper.js. The second and third requests in node_helper.js are the ‘nested’ ones.

        1 Reply Last reply Reply Quote 0
        • M
          mongo116 Module Developer last edited by

          Got this sorted - found there is another url that holds the information so added another request. The request I was having issues with was a post request, whereas the one I am using is a get.

          1 Reply Last reply Reply Quote 1
          • 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