Skip to content

feat: kick chat read path via pusher websocket#80

Merged
ImpulseB23 merged 3 commits intomainfrom
feat/kick-read-path
Apr 19, 2026
Merged

feat: kick chat read path via pusher websocket#80
ImpulseB23 merged 3 commits intomainfrom
feat/kick-read-path

Conversation

@ImpulseB23
Copy link
Copy Markdown
Owner

Kick Pusher WebSocket client in Go, Rust parser, platform tag byte dispatch.

  • Go internal/kick package: Pusher protocol 7 WebSocket client with reconnect backoff, ping/pong, activity timeout, fatal close detection (4000-4099)
  • Platform tag byte system: 1-byte prefix on ring buffer payloads (0x01 Twitch, 0x02 Kick, 0x03 YouTube reserved). Rust parse_batch dispatches by tag
  • Twitch EventSub client updated to prepend tag byte
  • Sidecar wired with kick_connect/kick_disconnect commands
  • Rust parse_kick_event handles Pusher double-encoded JSON, badge mapping, timestamp parsing
  • build_kick_connect_line helper for Rust host
  • ADR 38: Kick auth/read strategy (Pusher for read, official API for write/mod)
  • platform-apis.md Kick section updated with official API docs

Copilot AI review requested due to automatic review settings April 18, 2026 21:54
@github-actions github-actions bot added size/l 500-1000 lines changed rust Rust/Tauri changes go Go sidecar changes docs Documentation labels Apr 18, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds Kick chat read support end-to-end (Go sidecar Pusher client → ringbuf payload tag dispatch → Rust Kick parser), plus documentation/ADR updates describing the strategy and platform protocol.

Changes:

  • Introduce Kick Pusher (protocol 7) WebSocket client in the Go sidecar and wire kick_connect / kick_disconnect commands.
  • Add 1-byte platform tag prefix on ringbuf payloads and dispatch parsing in Rust by tag.
  • Implement Rust Kick Pusher event parsing into UnifiedMessage, with unit tests; update docs/ADR for Kick API strategy.

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
docs/platform-apis.md Document Kick auth scopes, read strategy (Pusher), write/mod endpoints, and operational constraints.
docs/adr.md Add ADR 38 capturing Kick read/write/mod strategy and tag-byte framing rationale.
apps/desktop/src-tauri/src/message.rs Add Kick Pusher event → UnifiedMessage parser and Kick-focused unit tests.
apps/desktop/src-tauri/src/host.rs Add tag-byte dispatch in parse_batch and kick_connect command serialization helper; update tests for tagged payloads.
apps/desktop/src-sidecar/internal/twitch/eventsub_test.go Update tests to account for the new Twitch tag byte prefix.
apps/desktop/src-sidecar/internal/twitch/eventsub.go Prepend Twitch platform tag byte before forwarding envelopes to the shared out channel.
apps/desktop/src-sidecar/internal/sidecar/sidecar.go Wire Kick connect/disconnect command handlers and manage Kick client lifecycle in the shared client registry.
apps/desktop/src-sidecar/internal/kick/types.go Define Pusher/Kick message framing types used by the Kick client and tests.
apps/desktop/src-sidecar/internal/kick/client_test.go Add Kick client tests for message forwarding, ping/pong handling, fatal closes, and context cancellation.
apps/desktop/src-sidecar/internal/kick/client.go Implement Kick Pusher WebSocket client with reconnect backoff, subscription, and forwarding tagged events to the out channel.
apps/desktop/src-sidecar/internal/control/control.go Define platform tag byte constants and extend control.Command with chatroom_id.

Comment thread apps/desktop/src-sidecar/internal/kick/client.go Outdated
Comment thread apps/desktop/src-sidecar/internal/kick/client.go Outdated
Comment thread apps/desktop/src-sidecar/internal/kick/client.go Outdated
Comment thread apps/desktop/src-sidecar/internal/kick/client.go Outdated
Comment thread apps/desktop/src-sidecar/internal/twitch/eventsub.go
Comment thread apps/desktop/src-tauri/src/message.rs
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 18, 2026

@github-actions github-actions bot added size/xl > 1000 lines, needs splitting and removed size/l 500-1000 lines changed labels Apr 18, 2026
@github-actions
Copy link
Copy Markdown

This PR has 1302 lines changed. Consider splitting it into smaller PRs for easier review.

@ImpulseB23 ImpulseB23 merged commit 9eafe58 into main Apr 19, 2026
13 checks passed
@ImpulseB23 ImpulseB23 deleted the feat/kick-read-path branch April 19, 2026 00:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation go Go sidecar changes rust Rust/Tauri changes size/xl > 1000 lines, needs splitting

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants