# Homeyscript functionality

**URL:** https://community.homey.app/t/homeyscript-functionality/30066
**Category:** Questions & Help
**Tags:** flow
**Created:** [May 18, 2020, 9:52am UTC](https://community.homey.app/t/homeyscript-functionality/30066 "2020-05-18T09:52:41Z")
**Posts on this page:** 1
**Showing post:** 13

<div class="post-metadata">

### Author: ![BartOverdevest](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/bartoverdevest/32/38783_2.png) [@BartOverdevest](https://community.homey.app/u/BartOverdevest)
#### Post date: [April 3, 2021, 9:15am UTC](https://community.homey.app/t/homeyscript-functionality/30066/13 "2021-04-03T09:15:04Z")

</div>

I posted the question on GitHub as well and this is Jeroen Wienk’s answer. I thought good to share here because “there are many ways to do this’ 😀 and because as Jeroen mentioned values are cached and he gives the solution to circumvent this.

> It’s possible with the API but it’s not a very clear solution since the values are cached. But you can do this;
> 
> ```
> await tag('my-tag', false);
> 
> // value is false
> console.log(await Homey.flowToken.getFlowToken({
> uri: 'homey:app:com.athom.homeyscript',
> id: 'my-tag'
> }));
> 
> await tag('my-tag', true);
> 
> // value is false (cached)
> console.log(await Homey.flowToken.getFlowToken({
> uri: 'homey:app:com.athom.homeyscript',
> id: 'my-tag'
> }));
> 
> // value is true (skipped cache)
> console.log(await Homey.flowToken.getFlowToken({
> $skipCache: true,
> uri: 'homey:app:com.athom.homeyscript',
> id: 'my-tag'
> }));
> 
> ```
> 
> Notice the last call with `$skipCache`.

So apparently it depends on the use case if you want to call the value between multiple executions or call the value you just updated within the script.

---

_[View the full topic](https://community.homey.app/t/homeyscript-functionality/30066)._
