Spruce up MeshMS REST API tech doc a bit

This commit is contained in:
Andrew Bettison 2017-10-20 17:04:27 +10:30
parent f53be7c6a6
commit 58573a4345
2 changed files with 24 additions and 18 deletions

View File

@ -195,8 +195,8 @@ This document is available under the [Creative Commons Attribution 4.0 Internati
[Serval Keyring]: ./doc/REST-API-Keyring.md
[MDP]: ./doc/Mesh-Datagram-Protocol.md
[VoMP]: http://developer.servalproject.org/dokuwiki/doku.php?id=content:tech:vomp
[MeshMS]: http://developer.servalproject.org/dokuwiki/doku.php?id=content:tech:meshms
[Rhizome]: ./doc/REST-API-Rhizome.md
[MeshMS]: ./doc/REST-API-MeshMS.md
[Serval Infrastructure]: ./doc/Serval-Infrastructure.md
[JNI]: http://en.wikipedia.org/wiki/Java_Native_Interface
[Bash]: http://en.wikipedia.org/wiki/Bash_(Unix_shell)

View File

@ -11,35 +11,40 @@ distributed one-to-one messaging using [Rhizome][] as transport.
The [Serval DNA][] daemon that runs on every node gives applications access to
the [MeshMS][] service via the **MeshMS REST API** described in this document.
### Basic concepts
Basic concepts
--------------
#### Ply
In rhizome, each author can only update rhizome bundles that they first created.
A ply is a rhizome journal bundle where each participant records their outgoing messages,
and any other changes to the conversation.
In rhizome, each author can only update rhizome bundles that they first
created. A ply is a rhizome journal bundle where each participant records
their outgoing messages, and any other changes to the conversation.
A ply can contain the following types of records;
* ACK - A pointer to a range of content within another ply.
* MESSAGE - A plain text message encoded in UTF-8.
* TIME - A timestamp related to the previous record.
* ACK - A pointer to a range of content within another ply
* MESSAGE - A plain text message encoded in UTF-8
* TIME - A timestamp related to the previous record
#### Conversation
A MeshMS conversation consists of one or two message ply's. Each participant sets
the sender and recipient manifest fields to the identities of the two parties in the
conversation.
A MeshMS conversation consists of one or two message [plys](#ply). Each
participant sets the sender and recipient manifest fields to the identities of
the two parties in the conversation.
Both ply's are encrypted such that only the sender and recipient can read their contents.
Both ply's are encrypted such that only the sender and recipient can read their
contents.
Whenever a new MESSAGE is detected on an incoming ply, a new ACK record is written to the
end of the outgoing ply. This is used to indicate successful delivery, and to thread the
display of messages in the conversation.
Whenever a new MESSAGE is detected on an incoming ply, a new ACK record is
written to the end of the outgoing ply. This is used to indicate successful
delivery, and to thread the display of messages in the conversation.
There is no central server to assign a common ordering to messages in a conversation,
both parties will see their outgoing messages threaded with received messages in the order
they arrived locally.
There is no central server to assign a common ordering to messages in a
conversation, both parties will see their outgoing messages threaded with
received messages in the order they arrived locally.
MeshMS REST API operations
--------------------------
### GET /restful/meshms/SENDERSID/conversationlist.json
@ -60,6 +65,7 @@ Send a new message from SENDERSID to RECIPIENTSID.
-----
**Copyright 2015 Serval Project Inc.**
**Copyright 2016 Flinders University**
![CC-BY-4.0](./cc-by-4.0.png)
Available under the [Creative Commons Attribution 4.0 International licence][CC BY 4.0].