What we need from the underlying protocol:
- Two-way communication
- Keep-alive
Underlying protocol options:
- Raw TCP socket
- Lightweight
- WebSocket / HTTP ✅
- Allows us to create browser-based clients, as the [TCP and UDP Socket API](https://www.w3.org/TR/raw-sockets/) for the browser is still experimental and not well supported
- GraphQL with Subscriptions
Format:
- Custom binary format ✅
- Lightweight
- JSON
- Easier to build clients in languages where raw bit manipulation is difficult / infrequently used
- GraphQL (with the GraphQL protocol)
What requests need sending and what response should they have?
- Game create (HTTP)
- Game id
- Game join (HTTP with upgrade)
- update to all
- Get valid moves of a piece
- valid moves
- Validate move
- boolean
- Make move
- deltas to all
- Get board and pieces
- board and pieces
- Leave game
- update to all
- Account information (HTTP)
Login system:
- Key-based auth ✅
- External system (e.g. Auth0 / Firebase)
Tracking issue - client, server interface
Initial issue: requirements and initial ideas Interface specification: (WIP)