wrtc.onList() is an event function called when lists are stored to or retrieved from the central IXNX server.
Lists are different types of data that a client might want to store at a secure, central location so it survives power off. The stored data is supposed to be as little as possible, a few KB at most. Or it might be a list that the IXNX server generated by itself, containing data clients might request.
wrtc.onList(type, list, data, error)
If no error argument error is empty.
The format of the JSON structure returned in argument data depends on the list's name in argument list:
When reporting list of calls user has made or received the retrieved JSON structure in data has the following format:
{last_id:…, data:[{…},{…},…]}
There:
When reporting list of chat messages user has sent or received the retrieved JSON structure in data has the following format:
{last_id:…, data:[{…},{…},…]}
There:
Ignored.
To fetch the list of calls user has made call wrtc.getList("call_log").
It will trigger an answer:
wrtc.onList("get_list", "call_log", {last_id:85632, data:[{id:50372, time:1647016200,from:"adam",to:"david",durtn:23}, {id:85632, time:1647016300,from:"david",to:"peter",durtn:0}]})