All projects

Test taskGREEN-API29 Sept 2026

schedar - MAX messenger web client on GREEN-API

schedar - MAX messenger web client on GREEN-API
  • React 19
  • TypeScript
  • Vite
  • Sass
  • Vitest
  • GREEN-API

A browser client for the MAX messenger built on GREEN-API: sign in with an instance id and token, open a chat by phone number, send text through SendMessage and receive replies by long polling receiveNotification and deleteNotification. Messages show optimistically with sending, sent, delivered, read and failed states, and a failed message can be retried. Replies are matched to the right chat even though MAX reports its own numeric chat id instead of the phone the chat was opened with, and a race where the send echo arrives before the API response is handled without duplicates. Only one browser tab polls the queue (Web Locks), the others follow over BroadcastChannel and take over when it closes. History lives in localStorage, long chats and chat lists render incrementally, and the layout goes from two panes on desktop to one on a phone. The look follows web.max.ru's space theme. Checked on a live MAX instance: sending, messages typed on the phone, and incoming one-to-one messages from a bot. React 19, TypeScript, Vite, Sass, Vitest with CI, served static behind Caddy.