Skip to content

Custom Commands

ManuelKlettner edited this page May 23, 2021 · 1 revision

How to create your own custom-commands

To create your own command, switch to the custom-commands tab and click on the plus button. Specify how the command should be called and provide the notification and payload that should be created on the mirror. In addition to notifications, MMM-Remote-Control endpoints are supported as well.

MMM-Remote-Control endpoints

  • You can find all available endpoints here
  • To use one of the endpoints write everything after /api in the notification field

Examples

  • Refreshing the screen of your MagicMirror instance
    • Use /refresh in the notification field
  • Switch the monitor to off
    • Use /monitor/off in the notification field
  • You can also execute an action of a module (e.g. alert)
    • Use /module/alert/showalert in the notification field
    • Use {"title": "Hello World", "timer": "10000"} in the payload filed

Notifications

  • You can also use regular notifications to control the mirror

Examples

  • Increment the page of MMM-Pages
    • Use PAGE_INCREMENT in the notification field