How you implement your receiver may depend upon which media
types your application needs to support.

In accordance with the Google Cast SDK Additional Developer Terms
of Service, a Cast media application must use the Media
Playback Messages defined for the SDK to control media playback on the receiver. Doing
so provides the media app with a consistent user experience across platforms and it ensures that a
Cast application will support new and future use cases. These structures also support custom data,
where appropriate, and an application may define its own messages for commands not supported by the
SDK.

Install API libraries

In this section you can download the APIs that will enable your application to cast
content to a Google Cast receiver device.

The Google Cast SDK and API libraries support the development of Android, iOS, and Chrome sender
applications, and the development of receiver applications in JavaScript - written for the Chrome
browser.

Chrome Sender API library

To use the Chrome Sender API, include
https://www.gstatic.com/cv/js/sender/v1/cast_sender.js
in your Chrome page. The API requires Chrome version 32 or later and the
Cast Extension version 14.123.1.2 or later.

If you are using the Game Manager API, append ?loadGamesSDK
to the cast_sender.js reference shown above.

Receiver API library

The receiver API is available from the receiver application once you
register your receivers and devices
for development. To use the API, include
https://www.gstatic.com/cast/sdk/libs/receiver/2.0.0/cast_receiver.js
in your receiver application.

If you are using the Game Manager API, also include a reference to
https://www.gstatic.com/cast/sdk/libs/games/1.0.0/cast_games_receiver.js
in your application.