Developer Console

Setup the Fire TV Integration SDK Sample Reference App

Most developers using the Fire TV Integration SDK feature already have a robust Fire TV app. However, many times you may want to explore the Fire TV Integration SDK workflow without jumping into your own app to make changes. Amazon provides a sample reference app that includes some configuration and setup to demonstrate working feature integration. You can use this sample reference app to explore a feature, and then after you've finished exploring, you can go back through this same process with your own app.

Alternatively, if preferred, rather than editing the sample reference app first, you can also make updates directly to your own Fire TV app instead. The documentation here provides a mixed flow that accommodates both scenarios: updating the sample reference app or using your own app.

About the Fire TV Integration SDK sample reference app

The sample app is a basic Android app that incorporates the Fire TV Integration SDK.

Additionally, this sample app is meant as a companion to the documentation, not as a starting point or template for your own app. Almost every video partner that uses the Fire TV Integration SDK already has a custom-developed app. The sample app simply provides some context for some integration instructions.

When you run the sample reference app, it will look like this:

Submitted Fire TV Integration SDK reference app screen.

Android Studio

To work with the sample reference app, you need to install Android Studio, the official IDE for Android projects. Android Studio includes a bundled version of the JDK, which compiles the Android projects into APKs. See Getting Started with Android Studio for information about setting up the Android Studio development environment on your machine.

The sample reference app requires you to have certain SDK tools and APIs installed with Android Studio. Selecting these tools from the Standalone SDK Manager ahead of time isn't necessary. When you open the sample reference app project, Android Studio will prompt you to install any missing build tools or APIs.

Download Sample Fire TV App with Content Personalization

To download the sample reference app:

  1. Go to the GitHub repository.
  2. Click Code > Download ZIP.
  3. Save the zip file to a convenient location and then unzip it.
  4. If desired, remove the .git folder, since Android Studio will attempt to identify the VCS mapping.

Open the Sample App in Android Studio

Open the project in Android Studio and build the app:

  1. Start Android Studio.
  2. At the Welcome dialog, click Open an existing Android Studio project.
  3. Browse and select the parent directory (e.g., ftv-integration-sample-app) that contains the app directory, and then click Open.

    When you first open the project, Android Studio might detect an incorrect location for the Android SDK and suggest a path mapped to your machine, accept the suggestion.

    Additionally, you might see "Invalid VCS root mapping." Remove the project's .git folder (invisible), and this prompt should go away.

    Gradle will begin building the project. If prompted to update Gradle, click Don't remind me again for this project.

    The first time you open the project, it can take several minutes for Gradle to build the project, depending on the assets Gradle needs to download, your network speed, and your processor speed. Subsequent times should be faster. If Android Studio is missing any needed libraries or files, you'll be prompted to install them.

    When Gradle finishes building the project, you should see a green check mark in the Build tab to indicate success.

    Successful build
    Successful build

    If you run into build failures, you can try rebuilding the project by choosing Build > Rebuild Project.

Next Steps

Next, let's take a look at the various data types, starting with Watch Activity.

Last updated: Jan 24, 2024