What Can The Custom URL Do? Both Mac OS and iOS

As I mentioned in http://www.autorefinancing.us/t/keyboard-maestro-remote-web-trigger-works-on-mac/56/1 you can get a Custom URL on Mac OS to drive Keyboard Maestro.

However if I enter a URL to, say, http://www.ibm.com it has no effect when the button is pushed. This is true on both Mac OS and iOS.

So, when I press a button that is defined a Custom, with a URL what is it supposed to do? Pop up a browser window?

Actually on iOS I wanted to use a URL of the form editorial:// to kick off the Editorial app. Nothing seems to happen here. So workflow:// would be nice for kicking off on-device automation.

I’m not sure iOS is allowed to handle that. I don’t believe apps can launch other apps in the background.

Actually they can and do all the time…

… I would look up x-callback-url and also note that apps like Launcher and LaunchCenter Pro do this. Heck, Workflow is almost entirely built on that capability.

It would be ironic if you had built code to only allow http and https - as that would be missing a great opportunity to launch apps, complete with parameters.

Sure but not from the background, which is why it’s not so useful for the remote.

OK. Thanks for clarifying that aspect.

So what is the purpose of Custom URLs - on Mac OS and iOS?

There’s a number of advanced home IoT systems out there that people have setup that can take webhooks on the local network. I’m not 100% clear on which systems those are but people use them and requested a custom URL app, which is why I built it.

Right. But is it sticking a URL in a browser (I think not) or doing a wget (I think so).

Doing a wget - where the side effect on the server is the thing, rather than the returned data - explains what I see…

  1. It explains why Keyboard Maestro “Remote URL” works.

  2. Given no background execution it explains why eg editorial:// does nothing on iOS (though that might be your code filtering it out).

I think I have a better understanding now of what it can and can’t do. Thanks!

Hi! Hope you’re recovering from your injury well.

Can you tell me what happens if I invoke a custom URL? (My previous question) wget in effect?

A custom URL simply makes a GET request to the URL. Right now you cannot add custom headers, but this should work well enough for now.