01 Things to know

- reader.open has no connect. It is queued and goes out with the next Wi-Fi connection or the next opted-in sleep drain (everything queued for the plugin rides along).
- At-least-once: if the reader loses Wi-Fi after the server got the request but before it read the 2xx, the event comes again. That's why the receiver dedupes on id.
- Answer 2xx even for junk. A non-2xx response blocks the plugin's queue until it succeeds. Only reject (non-2xx) when a retry could actually help.
- The 4 KB outbox: if the reader is offline for a long time and events pile up past 4 KB, the queue is dropped as a whole. Don't build a billing system on it.
- Book paths with quotes or backslashes break the JSON body (no escaping). If that matters, send the path in a header or URL, and decode it server-side.
- To only send events for books from your service, add "require_meta": "myservice_id" to the handler. Books without that sidecar key are skipped entirely.

Next: Tutorial 5: A File Manager tool.
Reader file (.txt)