MQTT with AWS IOT Core or httpPost with Certificate authentication

@bravenel or @gopher.ny

Do you all know of any examples of using AWS IOT Core with the Hubitat MQTT method provided in documentation? I have tried a few things and can't seem to get it to work.

I attempted to update an existing mqtt driver and it just disconnects and gets a java EOF error.

Another not as good option for what i need is to use HTTPS to post the messages to AWS IOT Core. But that still requires authentication with Certs. So similar to the AWS MQTT example. I need a way to submit certs as part of the HTTPS Post. Is that supported as i don't see it as part of the additional options for the method in documentation?

There are options to pass certificate and other related parameters to the MQTT interface, all of them optional:

tlsVersion (optional, accepts "TLSv" values)
caCertificate
clientCertificate (optional but must be provided when privateKey is provided)
privateKey (optional but must be provided when clientCertificate is provided)

If they don't work right out of the box, send me sample code, and I'll take a look.

@gopher.ny

I just wanted to make sure you got my DM and hopefully just a update that it is being looked at. I know there will be a bunch of happy folks if i can get one of those options to send commands to the AWS IOT core cloud.

Watching this ... :+1:

@mavrrick58 & @gopher.ny I'm interested in better understanding what is involved to get Hubitat to connect/communicate with AWS IoT Core. Is an additional physical layer resource with a constant running processor (RPi, Arduino, Laptop running x?, Other?) needed to bridge things here? I'm a self-professed neophyte when it comes to understanding the underlying tech. building blocks, custom device drivers, call methods, MQTT Brokers, etc., etc. that would be required from the get-go. Are we talking Herculean levels of effort to build or something more straightforward that even this newbie can follow instructions to enable. Certainly hope to increase insight & understanding from anybody knowledgeable within the Hubitat Community so don't be shy ...

Honestly as of right now I haven't made any more progress. Part of the issue is with how the AWS IoT core seems to works. It seems to require a few programming libraries Amazon created to connect to it.

Gopher.ny has been great helping and was looking at it, but with some of the higher priority stuff happening now i wouldn't be suprised if it slipped a bit down the list.

My need has also dropped a bit as the hardware manufacturer i am supporting released a new API this month with most of the features i was trying to get from the AWS IoT Core.

Sorry not better news.

I've been sitting on it. It requires hub code changes, and the focus has lately been on this: Release 2.3.7 Available

1 Like

So in simple terms - is an additional physical computing device required to integrate between HE and this Cloud service or could it (event data comms?) be implemented just with software/coding?
Trying to put together a punch list of sorts…

I recently found a need for this capability. Given the discussion so far, it doesn’t appear there’s a 100%-in-hubitat solution for this yet. My thought to solve this in a minimal way is to run a Mosquitto Broker, since that basic MQTT functionality appears to be in HE today, on a Raspberry Pi and have it bridged to AWS IoT using a blog post describing the process published by AWS themselves.

No idea if that’s gonna work, but I’m gonna give it a good try.

Share what you find out here … onwards & upwards.

Yes, please keep us in the loop. I tried a bunch of stuff originally when I was looking at this and the conclusion i came up with was amazon made connecting to it's service harder then it needed to be and pretty much requires you to use their SDK Libraries to connect. This is why I originally opened this thread and started talking with Gopher.ny

You can send a message to a topic via HTTPS call with Cert Creds, but that doesn't help you get info from the MQTT protocol. Look forward to hear how this goes.

1 Like