Send on-line notices

To send an on-line notice to a user, use the command user/update_user_notification:

svc=user/update_user_notification&params={"itemId":<long>,
					  "id":<long>,
					  "callMode":<text>,
					  "h":<text>,
					  "d":"{
					      \"body\":\"<text>\",
					      \"head\":{
					      \"c\":<uint>,
					      \"fs\":\"<text>\"},
					      \"multiple\":<int>}",
					  "s":<text>,
					  "ttl":<uint>}

:!: You can find an example of this request in the sample Executing several commands at once.

Parameters

Name Description
itemId user ID
id notice ID (required for deleting)
callMode action: create, delete
Optional parameters (required for create and update)
h subject
d message text settings
body text
с color, RGB
fs font size
multiple multiple activation: 1 - да, 0 - нет
s sender
ttl lifetime, when expires the notice will be deleted (UTC)

If ttl-param points to the date in past, then notifications trigger only while online (aren't stored on server). ttl – date in millisecs from 1 Jan 1970.

Response

On create:

[
	<long>,		/* notice ID */
	{
		"id":<long>,	/* notice ID */
		"t":<uint>,	/* lifetime (UTC) */
		"d":<text>,	/* message text settings*/
		"h":<text>,	/* subject */
		"s":<text>	/* sender */
	}
]

On delete:

[
	<long>, 	/* notice ID */
	null
]
Follow us on Facebook Gurtam Wialon Twitter Gurtam Wialon info@gurtam.com   |   Copyright © 2002-2019 Gurtam