I’m making a python script that shows todo list items in the ubuntu system try and starts and stops a aw-stopwatch timer for tasks.
I have created a running stopwatch event like this:
requests.post('http://localhost:5600/api/0/buckets/aw-stopwatch/events', json={"data": {"running": True, "label":"My todo list item"} })
What is the simplest correct way to stop it later on when I’m done?
I have tried sending a similar request with: {“data”: {“running”: False} which does seem to stop the event but it starts another one with “no label” as the label.
Looking at the network activity from http://localhost:5600/#/stopwatch when I stop a stopwatch I see the request looks like this
[
"id":238596,
"timestamp":"2024-05-30T18:27:33.512Z",
"duration":4348.865,
"data":{
"running":false,
"label":"label for the task I'm trying to stop"
}
}]
Is all of that data necessary to stop a running stopwatch?
Thanks for your help!