Protocols
The API server listens on TCP port 8080 and accepts two protocols:
- HTTP
- JSON over TCP
The server can handle multiple simultaneous connections, but due to the limited power of the screen, graphical slowdowns may occur during large simultaneous requests.
A password can be set for API access.
HTTP
The server accepts HTTP protocols in versions 1.0 and 1.1. Only the GET and POST methods are allowed.
If a password is defined, it must be sent in the POST/GET data preceded by the attribute password
. The password must be transmitted with each request.
JSON TCP
The server also accepts receiving data in JSON stringified format, it is mandatory to send a double CRLF to indicate the end of the JSON data.
The server sends a response in JSON stringified format ending with a double CRLF.
If a password is defined, it must be sent in the JSON with the attribute password
. It is necessary to send the password only once in the first request.
For each message, an ID in string
format can be defined with the id
attribute, this ID will be returned in the message response.
It is possible to subscribe to events for receive messages when the user interacts with the screen. For more information, please refer to the Events section.