diff options
author | Kegan Dougal <kegan@matrix.org> | 2014-08-19 13:43:45 +0100 |
---|---|---|
committer | Kegan Dougal <kegan@matrix.org> | 2014-08-19 13:43:45 +0100 |
commit | 8464009a66e234738edddcd17d313a22d0b83e3b (patch) | |
tree | afad433aa1a0248d61444be01bdf6b05675ae6cd /docs/client-server/howto.rst | |
parent | Added a first cut for a 'how to' on the client-server API. (diff) | |
download | synapse-8464009a66e234738edddcd17d313a22d0b83e3b.tar.xz |
Added top level TODO and a bit more info on storing the 'end' token.
Diffstat (limited to 'docs/client-server/howto.rst')
-rw-r--r-- | docs/client-server/howto.rst | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/docs/client-server/howto.rst b/docs/client-server/howto.rst index dcfc538e34..139ccaed8b 100644 --- a/docs/client-server/howto.rst +++ b/docs/client-server/howto.rst @@ -1,6 +1,10 @@ How to use the client-server API ================================ +TODO(kegan): Tweak joinalias API keys/path? Event stream historical > live needs +a token (currently doesn't). im/sync responses include outdated event formats +(room membership change messages). + If you haven't already, get a home server up and running on localhost:8080. @@ -237,7 +241,11 @@ listen for incoming events. This can be done like so: This will block waiting for an incoming event, timing out after several seconds. A client should repeatedly make requests with the "from" query parameter with -the value of "end" (in this case "215"). +the value of "end" (in this case "215"). This value should be stored so when the +client reopens your app after a period of inactivity, you can resume from where +you got up to in the event stream. If it has been a long period of inactivity, +there may be LOTS of events waiting for you. In this case, you may wish to get +all state instead and then resume getting live state from a newer end token. NB: The timeout can be changed by adding a "timeout" query parameter, which is in milliseconds. A timeout of 0 will not block. |