Files
RadioPlayer/cast-receiver/README.md
2026-01-15 07:07:00 +01:00

1.1 KiB

Radio Player - Custom Cast Receiver

This folder contains a minimal Google Cast Web Receiver that displays a purple gradient background, station artwork, title and subtitle. It accepts customData hints sent from the sender (your app) for backgroundImage, backgroundGradient and appName.

Hosting requirements

  • The receiver must be served over HTTPS and be publicly accessible.
  • Recommended: host under GitHub Pages (gh-pages branch or /docs folder) or any static host (Netlify, Vercel, S3 + CloudFront).

Registering with Google Cast Console

  1. Go to the Cast SDK Developer Console and create a new Application.
  2. Choose "Custom Receiver" and provide the public HTTPS URL to index.html (e.g. https://example.com/cast-receiver/index.html).
  3. Note the generated Application ID.

Sender changes

  • After obtaining the Application ID, update your sender (sidecar) to launch that app ID instead of the DefaultMediaReceiver. The sidecar already supports passing metadata.appId when launching.

Testing locally

  • You can serve this folder locally during development, but Chromecast devices require public HTTPS endpoints to use a registered app.