From specifications of notifications of gadgetbridge (https://www.espruino.com/Gadgetbridge), cmd can be
t:"call", cmd:"accept/incoming/outgoing/reject/start/end", name: "name", number: "+491234" - call
example shows :
GB({"t":"call","cmd":"incoming","name":"name","number":"+441234123123"})
Tried this way and incoming calls show on my bangle.js 2
I didn't check however how to accept or refuse calls...
Notifications (sendAlert)
Put an unique identifier.
Also, filter out messages which have an empty body and subject. Not convinced 100%, but something similar is done for instance for MiBandService::sendAlert
For me, it concerns mails which sends two notifications, the second with "courriel" (so in French) in the sender field, with empty subject and message.
I suppose it would be better to filter out those based on the event, but I do not master this part of code.
From specifications of notifications of gadgetbridge (https://www.espruino.com/Gadgetbridge), cmd can be t:"call", cmd:"accept/incoming/outgoing/reject/start/end", name: "name", number: "+491234" - call
example shows : GB({"t":"call","cmd":"incoming","name":"name","number":"+441234123123"})
Tried this way and incoming calls show on my bangle.js 2 I didn't check however how to accept or refuse calls...
Put an unique identifier. Also, filter out messages which have an empty body and subject. Not convinced 100%, but something similar is done for instance for MiBandService::sendAlert For me, it concerns mails which sends two notifications, the second with "courriel" (so in French) in the sender field, with empty subject and message.
I suppose it would be better to filter out those based on the event, but I do not master this part of code.