Hello,
I am using the following to email an image from an IP camera. Kindly supplied by a user on the forum.
Works well when viewing on outlook but when viewing on iphone the image does not always update as the file name is the same as the previous one. Is there a way to randomly change the filename of the image to alleviate this?
[{"id":"b0839d62.4385d","type":"inject","z":"707d0adc.1fe6f4","name":"Start","topic":"","payload":"","payloadType":"date","repeat":"","crontab":"","once":false,"x":174.4444580078125,"y":575.5555419921875,"wires":[["f4929d12.117b1"]]},{"id":"7652ccef.dd5714","type":"e-mail","z":"707d0adc.1fe6f4","server":"","port":"","secure":false,"name":"","dname":"Send mail","x":963.4444713592529,"y":574.5555458068848,"wires":[]},{"id":"f4929d12.117b1","type":"http request","z":"707d0adc.1fe6f4","name":"Get image","method":"GET","ret":"bin","url":"http://192.168.9.111/snap.jpeg","tls":"","x":367.69056510925293,"y":575.8446083068848,"wires":[["e8959f8e.4af228"]]},{"id":"e8959f8e.4af228","type":"change","z":"707d0adc.1fe6f4","name":"Flow 3 : Setup mail content","rules":[{"t":"set","p":"attachments","pt":"msg","to":"[{\t \"filename\": 'camera_snapshot.jpg', \t \"content\": $$.payload,\t \"cid\": 'some_unique_file_id'\t}]","tot":"jsonata"},{"t":"set","p":"topic","pt":"msg","to":"Visitor DC Yard","tot":"str"},{"t":"set","p":"payload","pt":"msg","to":"<img src=\"cid:some_unique_file_id\"/>","tot":"str"}],"action":"","property":"","from":"","to":"","reg":false,"x":636.4444713592529,"y":575.055606842041,"wires":[["7652ccef.dd5714"]]},{"id":"7e8d23f7.053e34","type":"http in","z":"707d0adc.1fe6f4","name":"","url":"/fanvilyard","method":"get","upload":false,"swaggerDoc":"","x":180.68665885925293,"y":657.5555458068848,"wires":[["f4929d12.117b1","d7bf3f58.0703c8"]]},{"id":"d7bf3f58.0703c8","type":"http response","z":"707d0adc.1fe6f4","name":"","statusCode":"","headers":{},"x":348.68665885925293,"y":662.5555458068848,"wires":[]}]
Thanks
James