hassio-addons/addon-node-red

Unable to send camera screenshot together with actions to android device. #701

wasyl00 posted onGitHub

Problem/Motivation

Unable to send mobile notification to Android device containing image camera screenshot with actions.

Expected behavior

I would expect to both to be visible but when I add image to code the actions in the notifications disappear.

Actual behavior

I'm either able to send actions or screenshot but not both.

Steps to reproduce

If I use this code to send notification I get the picture and message but no actions.

{
    "title": "Hey",
    "message": "Your 3D print: {{print.name}} is done!",
    "data": {
        "image": "/api/camera_proxy/camera.octoprint",
        "clickAction": "/lovelace/3d-print",
        "sticky": "true",
        "actions": [
            {
                "action": "URI",
                "title": "Go To Printer Tab",
                "uri": "/lovelace/3d-print"
            },
            {
                "action": "printer_soft_shutdown",
                "title": "Shutdown Printer"
            }
        ]
    }
}

But if I remove image line and use this I will get message and working actions.

{
    "title": "Hey",
    "message": "Your 3D print: {{print.name}} is done!",
    "data": {
        "clickAction": "/lovelace/3d-print",
        "sticky": "true",
        "actions": [
            {
                "action": "URI",
                "title": "Go To Printer Tab",
                "uri": "/lovelace/3d-print"
            },
            {
                "action": "printer_soft_shutdown",
                "title": "Shutdown Printer"
            }
        ]
    }
}

Home assistant: 0.115.3 Node-red: 7.2.2 I also have Node-red integration installed.


The addon wraps the existing software, I would suggest seeking help with the node that you are using.

posted by sinclairpaul over 4 years ago

Fund this Issue

$0.00
Funded

Pull requests