# Flow examples for UniFi node

**URL:** <https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925>\
**Category:** General\
**Created:** [6 September 2018 23:16 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925 "2018-09-06T23:16:34Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![nodecentral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nodecentral/32/10432_2.png) [@nodecentral](https://discourse.nodered.org/u/nodecentral)\
**Post date:** [6 September 2018 23:16 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/1 "2018-09-06T23:16:34Z")

</div>

Hi

If anyone using the UniFi node, please could they share an example flow

Many thanks

---

<div class="post-metadata">

**Author:** ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)\
**Post date:** [6 September 2018 23:25 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/2 "2018-09-06T23:25:14Z")

</div>

Haven't you asked for this before?

If not you - I think someone did in the past month - maybe worth searching the forum

---

<div class="post-metadata">

**Author:** ![nodecentral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nodecentral/32/10432_2.png) [@nodecentral](https://discourse.nodered.org/u/nodecentral)\
**Post date:** [7 September 2018 03:25 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/3 "2018-09-07T03:25:10Z")

</div>

Hi , I did ask about it within anither thread I posted about trying to monitor my kids smart device usage, but I had no reply and the subject was quickly moved on from,

This post/thread is an attempt to give the UniFi node some dedicated focus/attention.

---

<div class="post-metadata">

**Author:** ![nodecentral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nodecentral/32/10432_2.png) [@nodecentral](https://discourse.nodered.org/u/nodecentral)\
**Post date:** [23 October 2018 08:59 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/4 "2018-10-23T08:59:08Z")

</div>

Here’s a flow I created to check for remote users connecting to my UniFi network via its VPN  
 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/2X/4/4c53175ede9920ac8330f53b08911747bc24e0a3.jpeg)  
This is the function (I can’t claim any credit, I just reworked a similar one)

```
[{"id":"56a77f10.b269a","type":"function","z":"c9098f3d.e2474","name":"Check for remote users","func":"var json = msg.payload[0].health;\n\nfor(var i = 0; i < json.length; i++) {\nvar obj = json[i];\nif (obj.remote_user_num_active >= 1) {\n//Found\nmsg.payload = \"Remote user(s) are connected to your network\";\nreturn msg;\n} else {\n//Not found\nmsg.payload = \"No remote user(s) are connected to your network\";\n}\n}\n\nreturn msg;","outputs":1,"noerr":0,"x":730,"y":160,"wires":[["3912a849.a19cb8","ccbffbd0.2e42c8"]]}]
```

---

<div class="post-metadata">

**Author:** ![janvda](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/janvda/32/234_2.png) [@janvda](https://discourse.nodered.org/u/janvda)\
**Post date:** [23 October 2018 13:06 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/5 "2018-10-23T13:06:00Z")

</div>

> [@nodecentral](#):
>
> Hi
> 
> If anyone using the UniFi node, please could they share an example flow
> 
> Many thanks

Can you provide some links to what you exactly mean by UniFi ?  
I am a bit curious. 🙂

---

<div class="post-metadata">

**Author:** ![nodecentral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nodecentral/32/10432_2.png) [@nodecentral](https://discourse.nodered.org/u/nodecentral)\
**Post date:** [23 October 2018 13:35 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/6 "2018-10-23T13:35:55Z")

</div>

Here you go @janvda

> **[Ubiquiti Networks - Democratizing Professional Network Technology](https://www.ubnt.com)**
>
> Technology platforms for Internet Access, Enterprise, and SmartHome applications.

I have the secure gateway and a number of their access points.

---

<div class="post-metadata">

**Author:** ![janvda](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/janvda/32/234_2.png) [@janvda](https://discourse.nodered.org/u/janvda)\
**Post date:** [23 October 2018 14:19 UTC](https://discourse.nodered.org/t/flow-examples-for-unifi-node/2925/7 "2018-10-23T14:19:34Z")

</div>

OK, so I guess you have very specific devices that support "UniFi".
