Tasker Plugins + Android Widgets Ending

SharpTools.io automatically takes care of and manages its own event subscriptions. You don’t have to worry about manually subscribing to things as the platform takes care of it for you. :slight_smile:

We’ve already pushed the next-gen connection live for new SharpTools users. It looks like you have a legacy connection on your SharpTools account, but if you’re just getting started, you might consider just using the next-gen connection directly. I just added you to the beta group so you can view details on the beta thread for existing user.

We also plan on introducing migration tools for existing users to migrate dashboards and rules which have legacy devices over to the next-gen connection. :slight_smile:

Q: How do I know if I’m using the legacy or next-gen connection?

On your SharpTools User Page , the legacy connection uses the ‘circle’ icon from the classic app. The next-gen connection uses the 5 spoke icon from the Samsung app.

image

Additionally, you can tap the ... next to a location to view the location details and the Platform would be reported as samsung-smartthings for the next-gen connection.

Great. Thanks. Does the next gen connection break anything right away with Tasker tasks that use the Tasker Plugin now?

LATER: Nevermind. I think this is answered on the beta page.

Maby i should be added to the beta aswell to start moving stuff :slight_smile:

@josh With the SharpTools tasker app is going away. Would you be able to help explain it and possibly supply some example of how to use the http action an the API calls to help us that depends on SharpTools to interact with tasker and SmartThings.

1 Like

Control Devices

If you want to use SharpTools.io Rule HTTP Triggers to control devices in SmartThings, here’s a brief summary.

  1. Create a rule in SharpTools and add an HTTP Trigger (Event → HTTP).
    Note: You can optionally define a parameter here if you want to send data/variables from Tasker.

  2. Add desired conditions/actions to your Rule Flow
    Note: You can use the parameters that were passed in from Tasker (defined in the first step) by tapping the </> button next to a parameter, then when prompted to select a variable, tap the Context Variables tab → Event → HTTP Event → Parameters

  3. Copy the HTTP trigger URL to your clipboard and save the rule
    You can tap the copy icon in the HTTP trigger to copy it to your clipboard. You can always visit SharpTools.io from your phone and reopen the rule to more easily copy the HTTP Trigger URL. :slight_smile:

  4. Update your Tasker Task to use an HTTP Request which calls the HTTP Trigger URL
    You can find the action in Tasker under Net → HTTP Request. The default ‘GET’ method is fine, so all we need to do is fill in out URL and optionally add our Query Parameters.

    Note that the Query Parameters field in tasker is in the form parameter:value where parameter is the name of the parameter to send to the HTTP Trigger.

I’ve kept this example intentionally simple, but of course you can take advantage of the full suite of features in the SharpTools Rule Engine once you’ve triggered an HTTP task. Some examples:

  • Pass in a device identifier as a parameter and then use conditions to determine which device to send actions to.
  • Use conditions to determine what type of action to take within the rule (eg. if the value is above a threshold, turn the humidifier on, otherwise send a notification)
  • Store values into SharpTools variables for display in dashboards or as triggers/conditions in other rules. For example, you might compare a passed in parameter or variable against a device’s state within your rule before determining what action to take.
  • Use notifications with Email, Pushbullet, Pushover, SMS and more.
  • Interact with SmartThings and other platforms like Hubitat or Home Assistant
  • Run SmartThings Scenes with our next gen integration
  • And more! Let me know if you have specific questions!

Push Events to Phone

You can also use the SharpTools.io Rule Engine to send push events to your phone (using Pushbullet, Pushover, or Tasker Plugins like Join) and react to those in your Tasker profiles.

  1. Create a Rule in SharpTools that triggers based on whatever device changes you are interested in
    image

  2. In the Flow, use your desired push service to push the message to your device
    For example, you could use Action → Notification → Pushover

    In my example, I’m using Context Variables to get the name of the device for the Title of the message and the value of the triggering device to pass to Tasker.

    Pushover has some nice features where you can access the value of the title / message through %pushovertitle and %pushovermessage variables in Tasker.

  3. In Tasker, create a profile using your desired push service’s plugin
    From here, you can setup your Tasker profiles however you like. Using the Pushover example from above, we have access to the device name in the %pushovertitle variable and the device value in the %pushovermessage variable. You could of course change what data you include in the title and message and adapt to your use case as needed.

2 Likes

@josh You sir are amazing! This is just one of the reasons I love this platform!

1 Like

We need a premium subscription for HTTP, right? Or can we try them out cuz we are the beta test? I think I’m going to have to get a premium subscription at some point for HTTP, anyway, so I might just go ahead and plunge right in. I haven’t done before because I don’t really use the dashboards much. Instead, I just use the rules. Thanks.

Yes. The HTTP Triggers and Actions as well as Variables are part of premium. We can reset your trial if you’d like - just send a note to support@sharptools.io and we’ll get you taken care of.

You could also use the SmartThings REST API directly with a Personal Access Token if you just want to control devices.

Thanks for the offer, but no worries. Also, with respect to SmartThings REST API, I am at a complete loss with all the API stuff. I looked at the Rules API and couldn’t even figure out how to get started. It’s going to be hard enough for me to figure out how to send HTTP requests to SharpTools so I’ll get a subscription and move on. :wink:

LATER: I got a subscription. Created my first HTTP request to test and it was almost instantaneous turning off a light even though it all went through the cloud. Neat. Won’t be hard to substitute HTTP requests for some of my Tasker routines that open garage doors, turn on lights, and unlock doors.

2 Likes

By the way, I’ve been using Tasker to react to Pushover events for a while now. Very useful.

1 Like

I too am lost on this. Could you offer some guidance to us mere mortals?

I’m pretty heads down on migration work at the moment, but if anyone else has figured this out, I would encourage them to share.

Can I be added to the beta group thank you!

Is it possible to check a device’s status using an HTTP request? I’ve looked through the help topic on this and don’t see it. But maybe there’s a way that’s not obvious? I’m starting to move some Tasker routines to SharpTools that relied on the SharpTools plugin and I used the plugin to check the status of devices more often than I thought. I suppose this is probably available from the SmartThings Rules API? I might have to investigate that. But as I said, who has time to completely reconfigure their lives? Ha. Thanks.

EDIT: It’s not the Rules API you mentioned, is it? It was something else where I could use HTTP to query SmartThings? Or maybe not…

I have been down the rabbit hole of the SmartThings Rest API. I have figured out how to get the status and send commands(at a basic level) using tasker and the HTTP Request.

I will share a set of Tasker tasks when I have more time to do the write up on a Get request and Post.

2 Likes

Great. Thanks. Appreciate it.

By the way, I think I just figured out that I don’t need to check status in advance for all the Tasker profiles I’ve created. For example, I check if garage doors are open during the night and if they are close them. I just figured out that if I send a close command to the door and it’s already closed, nothing happens. However, I will need to check the status of the Hub because I terminate my Tasker task if the Hub is in Pause mode. A small victory I guess for not having to be able to check everything first, just some things. :laughing:

Edit: Also, I started looking at all this because I was going to move rules out of Tasker because my phone quit working, which meant my routines weren’t running, so I thought it would be better if they were on a Hub or SharpTools instead…

@RichB what devices are you wanting to control. I am almost done building the tasker tasks.

I currently have tasks for

Turn on/off device
Turn on dimmer and set level
Get Devices
Get Device info(on, off, open, closed, ect)
Lock/unlock a lock.
Open/close Garage Door.

1 Like

Well, not to be greedy, but I do all those things and all tasks would be helpful. Thanks!