SENSBLUE ATLAS/Datasheet: Difference between revisions
Appearance
No edit summary |
|||
| Line 8,750: | Line 8,750: | ||
Published once the command's action has finished. <code>task.action</code> is the internal command name (<code>set_digital_output</code>, <code>set_relay</code>, <code>set_ssh</code>, <code>set_mobile_data</code>, <code>set_vpn</code>). <code>taskResult.answer</code> is the SMS reply that was actually sent — <code>null</code>/absent if the action failed or is not implemented. | Published once the command's action has finished. <code>task.action</code> is the internal command name (<code>set_digital_output</code>, <code>set_relay</code>, <code>set_ssh</code>, <code>set_mobile_data</code>, <code>set_vpn</code>). <code>taskResult.answer</code> is the SMS reply that was actually sent — <code>null</code>/absent if the action failed or is not implemented. | ||
For a multi-line SMS, this event is published '''once per matched line''', each with its own <code>smsPayload</code> (that line's text) and <code>result</code>. However, <code>taskResult.answer</code> here is that line's own reply text (e.g. <code>"RL1St:Close"</code>); the SMS actually sent to the user is the '''combination''' of every successful line's answer (see ''<u>Multiple commands per SMS</u>''). | For a multi-line SMS, this event is published '''once per matched line''', each with its own <code>smsPayload</code> (that line's text) and <code>result</code>. However, <code>taskResult.answer</code> here is that line's own reply text (e.g. <code>"RL1St:Close"</code>); the SMS actually sent to the user is the '''combination''' of every successful line's answer (see [[#c) Multiple commands per SMS|''<u>Multiple commands per SMS</u>'']]). | ||
'''Example — <code>set_digital_output</code>:'''<syntaxhighlight lang="json"> | '''Example — <code>set_digital_output</code>:'''<syntaxhighlight lang="json"> | ||