[DEPRECATED] webCoRE Beta Milestone 2

@ady624 Something seems amiss with using expressions when sending push notifications to contacts: in the following piston

Looking at the Send notification step in the editor, it evaluates correctly:

However, the actual notification I received is:

It seems as if uses some intermediate value of the replacement rather than the final results to send the notification. Is this a command optimization issue or something else I can do on my side (other than assigning to another variable first)?

I’m wanting to do a Piston which when you run a routine, waits for “no activity” for 2 minutes then switches a light off, I’d have thought the below would work.

“However I’m getting ║║Error calling comparison comp_was: java.lang.NullPointerException: Cannot get property ‘id’ on null object” in the logs.

Thanks,

If Routine executes…
Then (Here put another If)
If Motion is inactive
Then
Using Bulb
Wait 2 Minutes
Turn Off

Add webCoRE to github
https://wiki.webcore.co/GitHub_Install
Then when you update (in IDE), goto SmartApp-Update from Repo-webCoRE-then select webCore and the Child Apps and be sure to click publish then execute.

When updating you can do them all at once

1 Like

When the routine runs I want the bulbs to switch off 2 minutes AFTER the last movement.

That’s exactly what that will do. If there is motion within the 2 minute wait period, the counter will reset. Cancel on Condition State Change is on by default.

Old Habits. Thanks! Fixed above.

1 Like

Hello,

I am new to webCoRE since I just discovered this after getting into CoRE.

Do I have to always first define my devices at the beginning of the program/script before including them into my condition or action? I would just first review the webCoRE wiki as i did with CoRE’s, but it looks like it’s down as write this.

Anyway, i know in CoRE there are predefined devices that i already have listed in Smartthings. I was wondering if i can just do a lookup for the devices in webCoRE UI, while i write out my script rather than manually type all my devices out?

thanks

Have you actually used webCoRE yet? Or is this a preemptive question?

You don’t type** into webCoRE, the output display looks typed.
You pick triggers, conditions, actions, select devices, etc. from menus. You then get that typed output as a result of your selections.

It’s been some time since I set it all up, but I believe you install the webCoRE apps, run through the setup on your phone, make the devices available to webCoRE, and then you can get to work on the web interface.

** NOTE, there will be typing, as in, variables, comments, etc. As you get more advanced.

If you go into the settings for WebCoRE you can define your various devices by attribute.
Motion sensor, switch, light etc.
Then when you define a piston, you can pick the various devices from a drop down list.
Makes it very easy.
Edit. As said above. :slight_smile:

Also, he might have seen some pistons where a device type variable is defined.

You don’t have to define any variables (unless your piston has a complexity that really calls for variables) - some people define variables and put their devices in those variables because they later down the script use the variable instead of the actual devices. The main benefit of this is you can later change that variable to contain more, less, or different devices, as you need. It just makes it much easier to add/remove/swap devices at a later time, as you only have to change one spot. But you don’t have to do that. Programmer-like-thinkers do that.

no. actually using it from a web browser to build out an automation. at least i am in the beginning stages that is.

Exhibit A:

As you can see $devices is a variable. I was just hoping to limit typing there would be a link of some kind for devices that map to my actual devices that i have in the Smartthings app. if i have to declare all the devices, sobeit.

I see what you mean.

Just getting my feet wet that/s all.

EDIT: I found where you need to identify the smart devices you have already configured with smartthings, to add to webCoRE’s configuration. it’s found in the webCoRE smart app itself; under Settings.

i have what i need now.

thanks for the help.

$devices is a system maintained variable - it will be automatically populated with all devices in use in the current with block - you cannot set that variable and you have no control over its contents, other than selecting which devices go into the with block. If you want to use a variable to avoid selecting the same device list several times, add your own, define it as device-typed and choose your devices in there.

ill remember not to use any system maintained variable.

thanks

You can use them, you just can’t assign values to them since they’re read-only … same as in coRE.

There isn’t any method of no-user auto updating is there?

No you must update manually through the IDE github integration or copy and pasting the code