[Release] [Beta] Slack Notifications (v. 0.10)

It's on my top 10 list of things I always install on any new device (PC, laptop, phone, etc). I use Slack for work, but also at home for all sorts of things. There's a NodeRed node for it as well. :wink:

But, you know how I like to label things as "rabbit holes"? Slack is a rabbit hole once you start integrating stuff into it. :wink:

3 Likes

Just got through my first app install. Very interesting. In some ways it reminds me of Lotus Notes of centuries ago.

Worse... think IRC... on steroids...

Funny fact, I used to be a Lotus Notes developer back in the late 90s. I also wrote one of the first proof of concept "viruses" for it as well. Using LotusScript and some embedded C++, I was able to get it to launch a command prompt and type out "deltree /y" and just sit there and wait for the return key to be pressed. IBM kept telling me it couldn't be done until I showed them, yes, it could be. :smiley:

3 Likes

I hope that goes into your autobiography.

2 Likes

It's been on my resume for years actually. LOL

3 Likes

Still new to hubitat and its community. Not familiar with where you'd stash the beta of this driver. Is it GA to beta volunteers? Is there source code (I'd <3 to learn from it)? Thanks for any info! Best regards, Mike

Hi Mike! Welcome to the community :cowboy_hat_face:

This beta is available for anyone to use---simply copy the driver code in from my first post and follow the rest of the instructions to integrate it with your Hubitat setup.

I label things as beta when I haven't completed the feature set or when I haven't been able to test everything. In this case, what's there is tested and is reliably working (I use it for notifications at our office).

If you'd like to make any changes or add to the source, feel free to submit a PR to the GitHub file! Otherwise, enjoy using the Slack integration, and let me know if there's anything not covered in the first post in this thread.

1 Like

Are you planning on adding more features?

"So, I know I'm not real..."

The humor in program Q&A :rofl:

1 Like

Yes. Slack is my lowest-priority project right now, though.

Tayne is programmed to deliver some fun phrases. He’s based off of a Paul Rudd character from a Tim and Eric sketch—Paul Rudd’s computer, it’s called.

4 Likes

I’ve been thinking about this driver a lot.

What would everyone think about the following setup:

Parent app (manages messages and returns) and a child device (transmits messages from RM/wherever)

Create messages with individual Names. Rule machine can pass data as parameters in a map format [Ceiling Fan, On, Image]

and the slack parent app can parse this to a message with the picture formatted properly.

Then, you could attach webhooks as your return actions.
{turn fan off hook}.

I’m trying to think of a better way to manage this, and implement a little more. Any thoughts?

Could you give an example of how you use this today or your thoughts on where others could?
I need some inspiration! :slight_smile:

I use this for our office. Everyone on our team has Slack installed, and I don’t want to make people install the Hubitat app—it’s unreasonable to get that many people to install and manage it.

We have one bot running right now—Tayne. He’s got his own personality, and he manages our security. A good example of this is with our company’s exterior sliding glass door. Hubitat will automatically shut the door off at 5 pm, and Tayne will notify us. If someone opens the door while it’s off, we get Slack notifications saying that the door has been forced open. In a perfect world, I’d also attach a security picture of who opened the door, but we’re not quite there (yet).

I’ve also considered adding hooks to this app—where you could tag a bot and use it as a trigger event in Hubitat. E.g.

Tayne, is the door on?
The door is off, want me to turn it back on?

I'm not entirely sure why, but I am getting the following error in my logs when reporting a door opened. If you have any suggestions on how I can narrow down the error that would be appreciated.

The message does get sent, so despite the error it does work.

Is your message sending successfully to slack? I get the feeling I just left some debug code in the driver that I forgot to remove.

Correct. The best I can tell there is no actual error or failure, beyond the log entry.

1 Like

Cool. I’ll see to adding a logDebug option in there to silence that.

1 Like

My openhab installation failed at the beginning of the year and I'm just getting to setting everything up again with Hubitat. Had all my notifications from OH going to Slack. This has made it so easy to setup again in Hubitat. Thanks!

I did a quick fork here and added the logging option which I copied from here.

2 Likes

Sweet---Thanks!

Feel free to submit a PR :slight_smile: