List updates of the user's folders/files.
Optionally, takes the parameter diffid, which if provided returns only changes since that diffid.
Alternatively you can provide date/time in after parameter and you will only receive events generated after that time.
Another alternative to providing diffid or after is providing last, which will return last number of events with highest diffids (that is the last events).
Especially setting last to 0 is optimized to do nothing more than return the last diffid.If the optional parameter block is set and there are no changes since the provided diffid, the connection will block until an event arrives. Blocking only works when diffid is provided and does not work with either after or last.
IMPORTANT When a folder/file is created/delete/moved in or out of a folder, you are supposed to update modification time of the parent folder to the timestamp of the event.
IMPORTANT If your state is more than 6 months old, you are advised to re-download all your state again, as we reserve the right to compact data that is more than 6 months old.Compacting means that if a deletefolder/deletefile event is more than 6 month old, it will disappear altogether with all create/modify events. Also, if modifyfile is more than 6 months old, it can become createfile and the original createfile will disappear. That is not comprehensive list of compacting activities, so you should generally re-download from zero rather than trying to cope with compacting.
|diffid||int receive only changes since that diffid.|
|after||datetime receive only events generated after that time|
|last||int return last number of events with highest diffids (that is the last events)|
|block||int if set, the connection will block until an event arrives. Works only with diffid|
|limit||int if provided, no more than limit entries will be returned|
On success in the reply there will be entries array of objects and diffid. Set your current diffid to the provided diffid after you process all events, during processing set your state to the diffid of the event preferably in a single transaction with the event itself.
Each object will have at least:
|diffid||int the event's identificator|
|time||datetime timestamp of the event|
|event||event see the possible events here|
|1000||Log in required.|
|1013||Date/time format not understood.|
|2000||Log in failed.|
|4000||Too many login tries from this IP address.|
|5000||Internal error. Try again later.|