• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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-Api - port specifics

Scheduled Pinned Locked Moved Troubleshooting
3 Posts 2 Posters 1.4k Views 2 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.
  • C Offline
    chef
    last edited by chef Mar 26, 2018, 2:45 PM Mar 26, 2018, 2:43 PM

    Good day,

    After installing the MM-Api module, I was having issues returning info from the server.

    reading the documentation, it would seem as though port 3001 is used (from the examples).

    I can see the endpoints being created in the “node-helper.js”

    this.expressApp.get("/api/v1/modules", (req, res) => {
    	res.send({'success': 'true', 'modules': this.moduleData});
    });
    

    But I don’t see any specifics on the actual port to use or forward through my router inorder to hit these endpoints.

    Is it indeed port 3001?

    unfortunately, any testing I’ve done doesn’t seem to return any information or control the server in any way… so far.

    My goal is to have the “MMM-RSTP” module show it’s camera stream when I post to an endpoint through the “MMM-Api”, for a particular amount of time.

    The endpoint would be requested by ‘unityhome.online’ Alexa Cognitive Security Service

    Anyway, I digress…

    Has anyone got the Api Endpoints working on MagicMirror?

    Many thanks!

    S 1 Reply Last reply Mar 26, 2018, 9:32 PM Reply Quote 0
    • S Offline
      strawberry 3.141 Project Sponsor Module Developer @chef
      last edited by Mar 26, 2018, 9:32 PM

      @chef it is the same port your magicmirror is running on, it’s only extending the server from magicmirror not setting up a new one

      Please create a github issue if you need help, so I can keep track

      1 Reply Last reply Reply Quote 0
      • C Offline
        chef
        last edited by chef Mar 31, 2018, 2:42 AM Mar 31, 2018, 2:41 AM

        Make sure in the config.js that the IP address is not ‘localhost’, but is the IP address of the raspi.

        Default port is 8080. This is how the plugin will accept URL commands.

        Also, make sure any other PC or computers ip is added to the ‘white list’.

        That is how it is done

        1 Reply Last reply Reply Quote 0
        • 1 / 1
        1 / 1
        • First post
          2/3
          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