# Better logic with homeyscript

**URL:** <https://community.homey.app/t/better-logic-with-homeyscript/13420>\
**Category:** Questions & Help\
**Created:** [May 20, 2019, 7:03pm UTC](https://community.homey.app/t/better-logic-with-homeyscript/13420 "2019-05-20T19:03:03Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![Satoer](https://sea1.discourse-cdn.com/flex025/user_avatar/community.homey.app/satoer/32/38113_2.png) [@Satoer](https://community.homey.app/u/Satoer)\
**Post date:** [June 17, 2020, 2:24pm UTC](https://community.homey.app/t/better-logic-with-homeyscript/13420/9 "2020-06-17T14:24:55Z")

</div>

I’ve had some struggling also setting / reading better logic variables. Athom did some syntax changes. Read this topic for solutions:

> [@Setting Logic Variable by HomeyScript](https://community.homey.app/t/setting-logic-variable-by-homeyscript/14819/27):
>
> After digging into the Homey developer API, Ive finally discovered the right syntax to get the tokens (which contain the Better Logic variables)! It should be: let allTokens = await Homey.flowToken.getFlowTokens(); Apparently Athom changed the syntax. So if anyone stumbles on the same problem, this is the code to use.

---

_[View the full topic](https://community.homey.app/t/better-logic-with-homeyscript/13420)._
