Git Product home page Git Product logo

Comments (22)

andrei-tatar avatar andrei-tatar commented on May 26, 2024 1

Can we send notification to Google devices, like a Home or Nest Hub?

No. As far as I know, there's no API for this via smarthome actions.

Can I pass setting into the notify tab to change the Title, Body, etc? Or I need to set it all on the node properties page?

Yes. Most of the properties can be passed via msg.payload object. I need to write some doc.

What tag is used for?

Notifications with a tag will override previous ones with the same tag.

What can I put into the icon field?

A link to an image. It needs to be hosted publicly and I think it needs to be https (not sure).

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024 1

I think you have site notifications turned off in your browser.
If you click the "3 dots" on the right -> Settings and follow: https://photos.app.goo.gl/zMVqJXPFUZ42metm6

Are the notifications turned off anywhere?

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

You need to go to https://smart-nora.eu/my-nora on the device you want to receive the notifications and click the button:
image

I will update the node to show the error status when the request fails

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

See in above comment
I have used the "click here to receive notifications" which reacts with "subscribed succesfuly".
Clicked it once more but it does not resolve the problem.

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

What device are you using (to subscribe to the notifications)?
I will need the user id to check the db and the logs but it's not exposed anywhere yet.

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

The device i expect to receive the notification is an android smartphone (LG G6).
My id is uPaTNUtar4b3i4G6WJhgQK1w2cI3
Is there an option to select a device? I did not come across such option.

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

Should i use the "click here to receive notifications" on the device i want to receive the notification?

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

Should i use the "click here to receive notifications" on the device i want to receive the notification?

Yes

I did check the db and there are no tokens for your user, unfortunately there is a bug in the code that always says Subscribed successfully. Will fix it.
Also make sure you allow the permission for notifications for he site (there should be a popup from Chrome asking if you want to allow the permission):
image

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

@jvdpas I see you have device tokens now in the db. Is this fixed?

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

No does not work yet.
The error in node-red is gone but no messages.
I use Chrome with notifications allowed.
After click here i get the message "Subscription is succesfull"

Thanx for asking (used id is uPaTNUtar4b3i4G6WJhgQK1w2cI3.)

from node-red-contrib-smartnora.

nygma2004 avatar nygma2004 commented on May 26, 2024

I just tested it on my system. I updated to 1.0.3 a few hours ago. I visited the site on my phone an enabled the notifications and it did come through. Did not even had to enable notification on Google.

May I use this issue to ask some related question?

  • Can we send notification to Google devices, like a Home or Nest Hub?
  • Can I pass setting into the notify tab to change the Title, Body, etc? Or I need to set it all on the node properties page?
  • What tag is used for?
  • What can I put into the icon field?

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

No does not work yet.

Can you post the flow you're using?

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

Flow Works when i inject timestamps fast, debug message appears(no messages on slow injects):

while sending notification too many notifications per sec: Error: too many notifications per sec at mergeJob (/home/pi/.node-red/node_modules/node-red-contrib-smartnora/build/firebase/sync.js:131:32) at SafeSubscriber.source.subscribe.event [as _next] (/home/pi/.node-red/node_modules/node-red-contrib-smartnora/build/index.js:51:29) at SafeSubscriber.__tryOrUnsub (/home/pi/.node-red/node_modules/rxjs/internal/Subscriber.js:205:16) at SafeSubscriber.next (/home/pi/.node-red/node_modules/rxjs/internal/Subscriber.js:143:22) at Subscriber._next (/home/pi/.node-red/node_modules/rxjs/internal/Subscriber.js:89:26) at Subscriber.next (/home/pi/.node-red/node_modules/rxjs/internal/Subscriber.js:66:18) at Subject.next (/home/pi/.node-red/node_modules/rxjs/internal/Subject.js:60:25) at GroupBySubscriber._group (/home/pi/.node-red/node_modules/rxjs/internal/operators/groupBy.js:98:19) at GroupBySubscriber._next (/home/pi/.node-red/node_modules/rxjs/internal/opera...

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

The used flow :
[{"id":"8ab4def4.c54a4","type":"noraf-notify","z":"ff65e0c4.4d1ff","tag":"","title":"Hello","body":"It works!","icon":"","name":"","nora":"7342540d.39289c","topic":"","actions":[],"x":390,"y":100,"wires":[["84d661fc.d03cd"]]},{"id":"1db51cd1.aa7b33","type":"inject","z":"ff65e0c4.4d1ff","name":"","props":[{"p":"payload"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":150,"y":100,"wires":[["8ab4def4.c54a4"]]},{"id":"84d661fc.d03cd","type":"debug","z":"ff65e0c4.4d1ff","name":"","active":true,"tosidebar":true,"console":true,"tostatus":true,"complete":"true","targetType":"full","statusVal":"payload","statusType":"auto","x":590,"y":100,"wires":[]},{"id":"7342540d.39289c","type":"noraf-config","name":"nora config","group":"","twofactor":"off","twofactorpin":"","structure":"Thuis"}]

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

I think it has to do with the receiving device.

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

Flow Works when i inject timestamps fast, debug message appears(no messages on slow injects):

The error when you want to send too many notifications is by design.

I think it has to do with the receiving device.

Might be...

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

I'm not able to subscribe with my smartphone.
Via chrome on win10 laptop subscription succeeds but no messages are received.

Capture+_2021-04-22-12-08-03

from node-red-contrib-smartnora.

andrei-tatar avatar andrei-tatar commented on May 26, 2024

On win 10, the messages are received in the windows notification center sidebar thingie.
On your device, if you click the lock next to the address, what do you see?
image

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

Capture+_2021-04-21-17-06-41

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

It is android version 9

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

Win 10 works now. The "sidebar thingie" triggered me (had notifications off).
So android device is the problem Can't subscibe (sorry for the dutch)
Capture+_2021-04-22-12-25-40

from node-red-contrib-smartnora.

jvdpas avatar jvdpas commented on May 26, 2024

Needed an other settings tab and indeed now it is 👍 i'm happy.
Thanx for your support it works.

from node-red-contrib-smartnora.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.