[Solved] Rule machine bug with a local maker api url

I made a bunch of rules using the http get url using maker api local urls but its not working.

My setup created a virtual button device then created a rule to execute the local maker api url and the logs show its being executed but nothing is happening. The cloud urls works just fine...

The local maker api urls do work as I tested them in the browser so I know its not that.

You can't use rule machine and the maker API at the same time since they are both on port 80. Your request is going out on port 80 and trying to go back to the hub also on port 80. So, you will get a crash in the outbound request and the inbound message on the same hub. Make the request with the backdoor HTTP port, 8080. So, your rule machine rule will use the local url except as ":8080" after the hub IP.


Ya know I thought that was it but didn't test it. Thanks

While you're right about the end result, I don't believe that's an accurate description of why. Outgoing TCP connections are assigned a local TCP/IP port by the OS, it wouldn't be going out over port 80. While HE doesn't support doing this, having a web server make requests to itself is actually somewhat common in the world.

Then why does it work when you change the requested port to port 8080? Obviously there is a crash going on blocking the request when the outbound and inbound requests are on the same port. I mean, otherwise it would work without changing the port, right?

And i didn't say it was true of anything other than Hubitat. :slight_smile:

1 Like

Just curious for my own edification. But why would you need to call Maker API from RM? Can't you just control whatever it is directly from RM?

Could be any number of reasons... firewall rules, routing tables, any number of things. But it’s not because both are 80. That’s just not the way tcp works.

Seriously -- this is OT now. Port 8080 worked for my situation so who cares how it's used?

@bobbyD please delete or lock thread please.

I was talking about routing rules and firewall rules IN the hub. Not on your network. Not sure why you’re getting so hostile, I just wanted to make sure for future reference people don’t misunderstand how tcp works. Sorry if my message came off as offensive somehow.

STOP IT... this is juvenile now.

I flagged no one... and yes I gave you credit for solving my issue