# Measure\_xxx\_changed trigger not fired

**URL:** <https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276>\
**Category:** Developers\
**Created:** [September 2, 2020, 10:51am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276 "2020-09-02T10:51:16Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 2, 2020, 10:51am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/1 "2020-09-02T10:51:16Z")

</div>

Hi,

The [documentation](https://apps-sdk-v3.developer.athom.com/tutorial-Drivers-Capabilities.html) states:

> Custom capabilities starting with `alarm_` , `meter_` and `measure_` will automatically try to trigger a Flow. You only need to define this Flow trigger in your `/app.json` .
> 
> ### Numbers
> 
> Calling `setCapabilityValue('measure_my_number', 1)` will try to start a Flow trigger with ID `measure_my_number_changed` , with a [Tag](https://apps-sdk-v3.developer.athom.com/tutorial-Flow-Tokens.html) `value` .

And so I though I had ‘easy’ ‘changed’ trigger flow cards. They show up and I can use them in my flow as expected. The only problem I have is that they do not fire. Can anyone take a look at what I am doing wrong [here](https://github.com/bochove/nl.bochove.knmi/)? The values are correctly updated, and the naming is what it should be, so what is going wrong?

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 2, 2020, 11:03am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/2 "2020-09-02T11:03:34Z")

</div>

> [@Some1](#):
>
> You only need to define this Flow trigger in your `/app.json`

I think you missed that.

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 2, 2020, 11:05am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/3 "2020-09-02T11:05:56Z")

</div>

If I missend them, how would I be able to use them in my flows?

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 2, 2020, 11:19am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/4 "2020-09-02T11:19:11Z")

</div>

So if you add them to `app.json` they still don’t fire?

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 2, 2020, 11:21am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/5 "2020-09-02T11:21:00Z")

</div>

Else I would not have created this topic.

---

<div class="post-metadata">

**Author:** ![robertklep](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/robertklep/32/160628_2.png) [@robertklep](https://community.homey.app/u/robertklep)\
**Post date:** [September 2, 2020, 11:35am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/6 "2020-09-02T11:35:51Z")

</div>

~~The `app.json` in the repository you’re linking to doesn’t contain them, else I wouldn’t have asked…~~

Apologies, I wasn’t looking properly 🥴

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 2, 2020, 11:45am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/7 "2020-09-02T11:45:34Z")

</div>

The one I was testing is on line [594](https://github.com/bochove/nl.bochove.knmi/blob/master/app.json).  
It’s name is:  
measure\_current\_temp\_changed, it is a trigger flow as required.

The linked capability is on line 1150 and 1227 and named measure\_current\_temp. It is a number capability just like in the example.

For the trigger to work the trigger must have a tag/token with id value, that too is present, I don’t know what I am missing.

I can see the current temp property in the device being updated, but the notification that I should receive when it is changed does not come. Manually testing my test flow does result in a notification.

This app can be installed from [this](https://homey.app/a/nl.bochove.knmi/test/) link so you can test the on change triggers for yourself. It’s already certified, but I won’t publish to live prior to there being some nice on change flow triggers that properly work. Perhaps I’ll even wait for Homey v5 to go live before publishing.

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 3, 2020, 9:23am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/8 "2020-09-03T09:23:00Z")

</div>

I realize this is written for the unstable SDK v3, so perhaps this is still a bug?  
Should I just keep my code as it currently is and wait for this to be fixed, or is the documentation incorrect and should I be doing something different?

---

<div class="post-metadata">

**Author:** ![Marcel\_Ubels](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_ubels/32/18860_2.png) [@Marcel\_Ubels](https://community.homey.app/u/Marcel_Ubels)\
**Post date:** [September 3, 2020, 9:32am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/9 "2020-09-03T09:32:05Z")

</div>

Are you making a KNMI app? Looks very promising if so

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 3, 2020, 9:49am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/10 "2020-09-03T09:49:16Z")

</div>

Yes, the topic for this app is [here](https://community.homey.app/t/knmi-dutch-weather/34228).

It is already testable except for the fact that the triggers don’t get fired, except for the one trigger that is fired after manually requesting the latest data via the action card.

It’s already running for a couple of days now on my own Homey, without any other issues whatsoever.

---

<div class="post-metadata">

**Author:** ![Marcel\_Ubels](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/marcel_ubels/32/18860_2.png) [@Marcel\_Ubels](https://community.homey.app/u/Marcel_Ubels)\
**Post date:** [September 3, 2020, 9:56am UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/11 "2020-09-03T09:56:19Z")

</div>

Nice, at this moment i retrieve these data with the http request app, which gives quite a lot off flows.

---

<div class="post-metadata">

**Author:** ![Some1](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/some1/32/8283_2.png) [@Some1](https://community.homey.app/u/Some1)\
**Post date:** [September 3, 2020, 9:05pm UTC](https://community.homey.app/t/measure-xxx-changed-trigger-not-fired/34276/12 "2020-09-03T21:05:34Z")

</div>

The answer here took too long for me, removed the automatic triggers and done it with own code.

The automatic trigger only has one value, the new ones (my own custom triggers) now have the old and the new value. And my custom triggers do fire.
