hangupsjs
hangupsjs copied to clipboard
Send timestamp in syncrecentconversations
It seems like conversations/syncrecentconversations
can accept a timestamp (in microseconds), which allows you to grab older conversations.
It would be great if the syncrecentconversations
call could take this argument.
The timestamp is at index 1
of the request payload.
I'll see if I can make something work in the library.
Adding the timestamp as a second argument here: https://github.com/algesten/hangupsjs/blob/master/src/client.coffee#L467 seems to work.
The gmail web client sends null
for the first request, so that could be a default parameter.
Since the converstation state also returns timestamps for each of the converstations, a higher level 'find all converstations' function could be implemented by just repeating the request for older timestamps until the result is empty (although I think there's some way to tell if a request is the last one, since the gmail web client never makes a request which turns out to be empty).
Just checked yakyak/yakyak, that also only shows the limited results