Deleting Timeline notifications

Timeline notifications can cause the Homey app to crash/slow down. @Caseda gave me this hint. Therefore i made a flow which checks every 7 days if the timeline notifications exceeds 250 lines. In that case the notifications will be deleted.

await Homey.notifications.getNotifications()
  .then(result => tmp = Object.keys(result).length, 'Notifications')
  .catch(err => {log('Failed: Getting Notifications')});

if(tmp >= 250)
await Homey.notifications.deleteNotifications()

await Homey.flow.runFlowCardAction({
uri: 'homey:manager:notifications',
id: 'create_notification',
args: {
text: 'Timeline notifications exceeded 250 lines. Total amount of notifications: ' +tmp},

Enter @ the THEN part in the homeyscript flowcard Run a script the above script.


Wait, what? You are saying it is easy AF to auto-cap the timeline messages?? Looking for that since I own a Homey man!
There was an app though, but that one didn’t work for me.

1 Like

I didn’t think HomeyScript had the privileges to delete notifications.

But it will be (officially) fixed soon anyway, little birdie told me that.

1 Like

Which means this will be not possible in the future?

It indeed doesn’t actually delete them yet, but if it will in time (soon™) I’ll be happy anyway :wink:

Using for this purpose Timeline Manager2 - Homey Community Store - after install, it’s required to setup Web Api settings / Bearer Token.


Not sure if it will work on the new HP2023, but if all goes well I’ll recieve mine tommorow… :crossed_fingers:

HCS is not yet supported on HP2023 :frowning:

I know, but CLI install should work…

Yes, you can add apps by CLI.
Have already downloaded some apps myself from the HCS, and succesfully installed them by CLI.
Workes like a charm…!