callbacks-and-input

Installation
SKILL.md

Callbacks and Input

Overview

WebRTC, native, SHM, and CUDASHM servers all have reverse channels that surface as four callbacks:

Callback Fires when Available on
on_connection A client connects or disconnects All transports
on_message The client sends a raw text/binary message the protocol layer does not own WebRTC, native, SHM, CUDASHM
on_input The client emits a keyboard / mouse / gamepad / touch event WebRTC, native, SHM, CUDASHM
on_unicode The client emits a composed text event (IME, on-screen kbd, paste, emoji) WebRTC, native, SHM, CUDASHM
on_app_message The client sends an application-addressed message envelope (delivered unwrapped) WebRTC, native
on_resize_request The client requests new stream dimensions (validated) WebRTC, native
on_clipboard The client syncs its clipboard (chunked transfers reassembled) WebRTC, native
on_qos The streaming backend publishes network feedback (recommended resolution / fps, round-trip delay from client feedback, encoder target bitrates) WebRTC, native

RTSP has no input or message channel — only the connection callback fires. SHM and CUDASHM both carry the reverse channel over a local control socket / named pipe (sibling to the pixel transport).

Installs
2
GitHub Stars
14
First Seen
Sep 1, 2026