Update x8.md

This commit is contained in:
Dean Eigenmann 2019-08-27 13:41:25 +02:00 committed by Oskar Thoren
parent 8f0144cbe9
commit ef34861169
No known key found for this signature in database
GPG Key ID: B2ECCFD3BC2EF77E

14
x8.md
View File

@ -63,13 +63,15 @@ The type `Message` represents a text message exchanged between clients.
### Payload
Payload is a struct (a compound data type) with the following fields (order is important):
1. text `string`
2. content type `enum` (more in [Content types](#content-types))
3. message type `enum` (more in [Message types](#message-types))
4. clock `int64`
5. timestamp `int64`
6. content `struct { chat-id string, text string }`
| Field | Name | Type |
| ----- | ---- | ---- |
| 1 | text | `string` |
| 2 | content type | `enum` (more in [Content types](#content-types)) |
| 3 | message type | `enum` (more in [Message types](#message-types)) |
| 4 | clock | `int64` |
| 5 | timestamp | `int64` |
| 6 | content | `struct { chat-id string, text string }` |
### Content types