Skip to content
Hails edited this page Jun 28, 2026 · 2 revisions

hails.widgetcast

A service that bridges an AzuraCast radio station with Discord's profile widget system (Widget v2 / Social Layer). It polls the AzuraCast public API every 9 seconds and pushes live now-playing data to a Discord profile widget.

Preview

Widget expanded view Widget compact view

How It Works

  1. AzuraCast exposes public JSON APIs for the current track, up-next track, listener stats, song history (/api/nowplaying/{station}), plus station details (/api/station/{station}), the upcoming schedule, and the song requests queue.
  2. sync.js fetches those endpoints on an interval and formats a large catalog of named fields into Discord's identity profile payload.
  3. The payload is sent via PATCH to Discord's Social Layer API, updating the widget shown on your Discord profile.
  4. The widget layout itself is configured once in the Discord Developer Portal and maps named data fields to visual elements.

Documentation

  • Installation: prerequisites, server setup, and getting the service running under PM2.
  • Discord App Setup: one-time Discord Developer Portal steps, Social SDK access, and adding the widget to your profile.
  • Configuration: every .env variable, data sources, the field limit, and rate limiting.
  • Field Catalog: the full list of named data fields you can map to your widget layout.
  • AzuraCast API Reference: the public AzuraCast endpoints this service reads.
  • Troubleshooting: common log messages, their causes, and fixes.

Quick start

Head to Installation to get the service running.

Clone this wiki locally