MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    MMM-Remote-Control

    Scheduled Pinned Locked Moved Utilities
    52 Posts 9 Posters 2.1k Views 8 Watching
    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.
    • V Offline
      vtek
      last edited by

      hey guys…

      having some issues using the shutdown/reboot commands…they throw this error, even though I have the API key in the config

      {“success”:false,“message”:“Forbidden: API Key Not Provided!”}

      here’s the config

                  {
                          module: 'MMM-Remote-Control',
                          // position: 'bottom_left', // Required to show URL/QR code on mirror
                          // you can hide this module afterwards from the remote control itself
                          config: {
                                  showModuleApiMenu: true,
                                  secureEndpoints: true,
                                  apiKey: "111111111-2222-3333-4444-555555555555",
                                  customCommand: {
                                                  monitorOnCommand: 'loginctl unlock-session 1',
                                                  monitorOffCommand: 'loginctl lock-session 1',
                                                  shutdownCommand: 'systemctl poweroff',
                                                  rebootCommand: 'systemctl reboot',  // Optional, See "Using Custom Commands" below
                                                  },
      
                  }
                  },
      
      V 1 Reply Last reply Reply Quote 0
      • V Offline
        vtek @vtek
        last edited by

        said in MMM-Remote-Control:

        hey guys…

        having some issues using the shutdown/reboot commands…they throw this error, even though I have the API key in the config

        {“success”:false,“message”:“Forbidden: API Key Not Provided!”}

        here’s the config

                    {
                            module: 'MMM-Remote-Control',
                            // position: 'bottom_left', // Required to show URL/QR code on mirror
                            // you can hide this module afterwards from the remote control itself
                            config: {
                                    showModuleApiMenu: true,
                                    secureEndpoints: true,
                                    apiKey: "111111111-2222-3333-4444-555555555555",
                                    customCommand: {
                                                    monitorOnCommand: 'loginctl unlock-session 1',
                                                    monitorOffCommand: 'loginctl lock-session 1',
                                                    shutdownCommand: 'systemctl poweroff',
                                                    rebootCommand: 'systemctl reboot',  // Optional, See "Using Custom Commands" below
                                                    },
        
                    }
                    },
        

        i figure it out…had to append the apiKey at the end of the url for all commands
        http://192.168.1.5:8888/api/command/rebootCommand?apiKey=111111111-2222-33333-4444

        1 Reply Last reply Reply Quote 2
        • 1
        • 2
        • 3
        • 4
        • 5
        • 6
        • 6 / 6
        • First post
          Last post
        Enjoying MagicMirror? Please consider a donation!
        MagicMirror created by Michael Teeuw.
        Forum managed by Sam, technical setup by Karsten.
        This forum is using NodeBB as its core | Contributors
        Contact | Privacy Policy