Build on Sunflare
Using OSC
OSC (Open Sound Control) lets an external tool (a DJ rig, a VJ setup, a custom script) drive your Rich Presence directly, for whatever Windows' own media-session APIs can't see on their own. It's a small UDP listener built into the desktop app.
Turning it on
Settings → Rich Presence → Accept OSC input. Pick a port (default 9222, must be between 1024–65535) and the app starts listening on it immediately. The same pane shows a live status line ("Listening on port N") so you can confirm it actually bound.
The listener binds to 127.0.0.1 only, deliberately. Only something running on the same machine can send it messages; nothing on your LAN or the internet can reach it, and there's no separate password/token on top of that.
Messages it understands
| Address | Arguments | Effect |
|---|---|---|
/sunflare/nowplaying | s title, s artist, i positionMs, i durationMs, i isPlaying, s source | Sets the current track. Requires at least the first 5 args and a non-empty title, or it's ignored. |
/sunflare/nowplaying/art | s url | Sets the album art shown alongside the track. |
/sunflare/nowplaying/clear | none | Clears whatever's currently showing. |
/sunflare/status | s text | Sets a custom status line. An empty string clears it. |
Argument type tags: s = string, i = 32-bit big-endian int, f = 32-bit big-endian float. Any other type tag stops parsing at that point in the message rather than misreading the rest of it. Keep messages to exactly the types listed above.
Priority over other Rich Presence sources
While OSC messages are actively arriving, they take priority over the desktop app's own OS media-session scanner: no conflict, no fighting over what's shown. That priority expires 15 seconds after the last message, so a crashed or closed sender doesn't leave Rich Presence stuck showing stale data forever; it just falls back to whatever the normal scanner finds next.
Example: sending a message
Using node-osc (or any OSC 1.0 client library; nothing Sunflare-specific is required):
const { Client } = require('node-osc');
const client = new Client('127.0.0.1', 9222);
client.send('/sunflare/nowplaying', [
'Track Title', 'Artist Name',
45000, // position, ms
210000, // duration, ms
1, // 1 = playing, 0 = paused
'My App' // source label
]);
client.send('/sunflare/nowplaying/art', ['https://example.com/cover.jpg']);
To clear it when playback stops:
client.send('/sunflare/nowplaying/clear', []);
Things worth knowing
- Malformed or unparseable packets are silently dropped. Nothing gets logged or surfaced back to the sender, so double-check your message shape against the table above if nothing's showing up.
#bundle-wrapped OSC messages aren't supported. Send plain, single messages.- This is desktop-only; there's no browser or mobile equivalent.
Docs