Hi
thank you Lena for your support.
I follow the instruction and I get "my solution"
Now I want to add a switch on the dashboard. The switch should trigger different strings.
When the switch is on the Text "switch on" should be add in my function.
When the switch is offthe Text "switch off" should be add in my function.
How can I add these msg.payload to the Text in the funtion?
With batch or join?
For join there can I configure the msg.part?
But at first the request for the status of the switch is not working.
Thank you for your help.
[{"id":"8f4069de.4584f8","type":"tab","label":"dashboard send PhoneNumber to ws","disabled":false,"info":""},{"id":"54b3c884.9694f8","type":"function","z":"8f4069de.4584f8","name":"","func":"var Data = msg.payload;\n//var Text = msg.payload.Data.Sms.Text;\n\nmsg.payload = {\n \"RequestType\": \"SmsSend\",\n \"Data\": {\n \"Sms\": {\n \"PhoneNumber\" : Data,\n \"Text\": \"Text\",\n }\n }\n};\nreturn msg;\n\n//\"Guid\": \"69c6ee52-7bae-4000-b19f-88153d926a77\",\n// \"MessageId\": \"string\",","outputs":1,"noerr":0,"x":1254.0001125335696,"y":285.99986362457287,"wires":[["9b3190ac.67b77"]]},{"id":"25f8e3b0.5faf0c","type":"change","z":"8f4069de.4584f8","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.Data.Sms.PhoneNumber","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":714.0000762939455,"y":285.99986362457287,"wires":[["54b3c884.9694f8"]]},{"id":"567b584f.0a1c38","type":"ui_text_input","z":"8f4069de.4584f8","name":"PhoneNumber","label":"PhoneNumber","tooltip":"","group":"f990197b.29b4b8","order":10,"width":0,"height":0,"passthru":true,"mode":"text","delay":"0","topic":"sms","x":480.00009918212913,"y":285.99992108345043,"wires":[["25f8e3b0.5faf0c"]]},{"id":"1230280f.44dd48","type":"change","z":"8f4069de.4584f8","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.Data.Sms.Text","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":762.0001029968262,"y":739.9999685287476,"wires":[["e13c0031.31609"]]},{"id":"a83631f3.25643","type":"ui_text_input","z":"8f4069de.4584f8","name":"Switch on","label":"Switch on","tooltip":"","group":"f990197b.29b4b8","order":10,"width":0,"height":0,"passthru":false,"mode":"text","delay":"0","topic":"sms","x":556.000072479248,"y":739.9999685287476,"wires":[["1230280f.44dd48"]]},{"id":"bff63c0c.20fb7","type":"status","z":"8f4069de.4584f8","name":"","scope":["43e62a7.a391ed4"],"x":336.00007247924805,"y":739.9999685287476,"wires":[["a83631f3.25643","25be9964.e5fdd6"]]},{"id":"43e62a7.a391ed4","type":"ui_switch","z":"8f4069de.4584f8","name":"","label":"switch","tooltip":"","group":"f990197b.29b4b8","order":0,"width":0,"height":0,"passthru":true,"decouple":"false","topic":"","style":"","onvalue":"true","onvalueType":"bool","onicon":"","oncolor":"","offvalue":"false","offvalueType":"bool","officon":"","offcolor":"","x":325.5682144165039,"y":610.7783451080322,"wires":[[]]},{"id":"e13c0031.31609","type":"join","z":"8f4069de.4584f8","name":"","mode":"auto","build":"string","property":"payload","propertyType":"msg","key":"topic","joiner":"\\n","joinerType":"str","accumulate":false,"timeout":"","count":"","reduceRight":false,"reduceExp":"","reduceInit":"","reduceInitType":"","reduceFixup":"","x":1053.5681724548338,"y":688.5624608993529,"wires":[["54b3c884.9694f8"]]},{"id":"2104a001.4d812","type":"change","z":"8f4069de.4584f8","name":"","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.Data.Sms.Text","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":764.0285301208496,"y":894.0113592147827,"wires":[["e13c0031.31609"]]},{"id":"a05e3eb9.9b60c","type":"ui_text_input","z":"8f4069de.4584f8","name":"Switch off","label":"Switch off","tooltip":"","group":"f990197b.29b4b8","order":10,"width":0,"height":0,"passthru":false,"mode":"text","delay":"0","topic":"sms","x":558.0284996032715,"y":894.0113592147827,"wires":[["2104a001.4d812"]]},{"id":"8c7e7c64.d7639","type":"batch","z":"8f4069de.4584f8","name":"","mode":"count","count":10,"overlap":0,"interval":10,"allowEmptySequence":false,"topics":[{"topic":""}],"x":1045.5852813720703,"y":594.8692598342896,"wires":[[]]},{"id":"86676a24.827b08","type":"status","z":"8f4069de.4584f8","name":"","scope":["43e62a7.a391ed4"],"x":346.0284996032715,"y":898.0113592147827,"wires":[[]]},{"id":"9b3190ac.67b77","type":"debug","z":"8f4069de.4584f8","name":"function","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":1501.5625457763672,"y":287.65901374816895,"wires":[]},{"id":"a8de3082.db296","type":"comment","z":"8f4069de.4584f8","name":"or ","info":"","x":1025.5624694824219,"y":640.9259996414185,"wires":[]},{"id":"7f0e167.340ece8","type":"comment","z":"8f4069de.4584f8","name":"I want to add","info":"","x":325.57948303222656,"y":558.9488410949707,"wires":[]},{"id":"6462ef47.0f8b","type":"comment","z":"8f4069de.4584f8","name":"My solution","info":"","x":429.57948303222656,"y":232.94886875152588,"wires":[]},{"id":"25be9964.e5fdd6","type":"debug","z":"8f4069de.4584f8","name":"status","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","x":551.5738220214843,"y":821.3181304931638,"wires":[]},{"id":"f990197b.29b4b8","type":"ui_group","z":"","name":"test switch","tab":"50f5f1b7.91df7","order":1,"disp":true,"width":"7","collapse":false},{"id":"50f5f1b7.91df7","type":"ui_tab","z":"","name":"Home","icon":"dashboard","disabled":false,"hidden":false}]