About ima-dai-sdk
An integration skill for developers using the IMA DAI SDK to load live and on-demand streams in apps, including content configured or ingested in Google Ad Manager. It outlines initialization, stream requests, metadata forwarding, and cleanup across platforms.
Key features
- 01Load HLS or DASH streams
- 02Support livestream and VOD content
- 03Listen for stream events
- 04Forward timed metadata
- 05Clean up after stream errors or exit
Use cases
- 01Integrate Google Ad Manager livestreams
- 02Play VOD ingested into Google Ad Manager
- 03Set up DAI streams on supported platforms
Install
Copy the command and run it in a terminal.
npx skills add https:/ / github.com/ google/ skills --skill ima-dai-sdkAfter installing, type/ima-dai-sdkin Claude Code to confirm it loaded.
Bundled files
References and scripts installed along with SKILL.md.
references/android-ImaServerSideAdInsertionMediaSource-guide.mdcast-StreamManager-guide.mdios-IMAStreamRequest-guide.mdroku-StreamManager-guide.mdweb-StreamManager-guide.mdDetails
From the project READMEIMA DAI SDK
Use the IMA DAI SDK to load HLS or DASH streams into the app for:
- Livestream events configured in Google Ad Manager.
- Video on demand (VOD) content ingested into Google Ad Manager.
Prerequisites
Review the platform-specific integration guides for the target platforms:
-
Web/HTML5/ReactJs/NodeJs/Angular: Read StreamManager guide for loading stream URL from Google full-service DAI into
<video>element. -
ChromeCast: Read StreamManager guide for integrating the IMA DAI SDK into a ChromeCast Web Receiver.
-
Android: Read ImaServerSideAdInsertionMediaSource guide for integrating Media3 Exoplayer IMA extension.
-
iOS/tvOS: Read IMAStreamRequest guide for playing streams with
AVPlayer. -
Roku: Read StreamManager guide for implementing DAI on Roku SceneGraph.
Quick start (general workflow)
- Import the SDK
- Initialize the SDK
- Add stream event listeners
- Set up timed metadata forwarding
- Make a stream request
- Clean up SDK resources when the stream fails or the user leaves the stream.