Creating an Amazon Fire TV App (Java based) Creating an Amazon Fire TV App (Java based)

Creating an Amazon Fire TV App (Java based)

Taylor Kirchwehm Taylor Kirchwehm

Prerequisites

  1. Install Android Studio
  2. Install Android Debug Bridge (ADB)
  3. Create an Amazon developer account

Note: IT or developer support is strongly recommended. Visit our Partner Marketplace for app production and publishing resources.

Downloading and Opening the Bundle

In order to generate an Amazon Fire TV Java-based bundle using this SDK, you must first pull the latest source code from Zype's GitHub repository. This can be found at "https://github.com/zype/zype-firebuilder".


Click the green button on the right, to Clone or download a copy of the repository.

image6.png

Next, pick a location on your computer to save the .zip file or clone the repository. Once the .zip file download is complete, unzip the file to reveal its contents.

Open Android Studio, and open the Application folder in Android Studio (File > Open > zype-firebuilder-master > Application).

image1.png

* Android Studio typically prompts users to update the Gradle plugin version at startup or whenever the project is synced with Gradle files, please make sure to dismiss these notifications as updating Gradle may conflict with codebase dependencies.

2021-03-10_16-04-08.png

 

App Customizations (Required)

App Name

Navigate to app > res > values > strings.xml

You’ll need to update the app_name and app_name_short in the following strings.xml files:

  • strings.xml (template)

image3.png

Note: Your app_name and app_name_short can be the same.

You’ll need to update the app_name in the other remaining strings.xml files:

  • strings.xml (de, template)
  • strings.xml (en, template)
  • strings.xml (ja, template)
<string name="app_name">APP_NAME</string>

Make sure to save your changes (File > Save All).

 

Application ID

Navigate to Application > app > build.gradle

You’ll need to update the <APPLICATION_ID> from within this file.

image8.png

Be mindful of the following naming rules for the application ID:

  • It must have at least two segments (one or more dots).
  • Each segment must start with a letter.
  • All characters must be alphanumeric or an underscore [a-zA-Z0-9_].

e.g.

flavorDimensions "main"
productFlavors {
zype {

}
template {
applicationId "my.application.id"
}
}

If you are resubmitting your Amazon Fire TV app, you should use the same application ID that is associated with your existing live app. 

Note: the defaultConfig and template applicationID should be the same (see image above). 

 

Images

- Company Logo

Navigate to app > src > template > res > drawable > logo_company.png

The image dimensions should be approximately 356 x 108 px and have a transparent background. You should keep the image file name as logo_company.

 

- App Icon

Navigate to:

app > src > template > res > mipmap-mdpi

app > src > template > res > mipmap-hdpi

app > src > template > res > mipmap-xhdpi

app > src > template > res > mipmap-xxhdpi

You will need to replace the ic_launcher.png in all of the folders above with your custom asset. Make sure to keep all of the image file names as ic_launcher.

The image dimensions should be approximately 512 x 512 px.

 

Root Playlist, App, and OAuth Keys

Navigate to ZypeAPI > src > main > java > com > zype > fire > api > ZypeSettings.java

You'll need to replace the following keys in order to pull in your content, playlists, and metadata information stored in Zype:

  • APP_KEY
  • CLIENT_ID
  • ROOT_PLAYLIST_ID

2021-03-16_16-58-17.png

These keys can be found in your Zype account by creating an Amazon Fire TV app under CONNECTORS > 'Video Apps' section.

2021-03-16_17-02-49.png2021-03-16_17-06-09.png

Make sure to save your changes (File > Save All).

 

App Customizations (Optional)

Brand Color

To use your brand color for highlighting buttons and widgets, navigate to app > src > template> res > values > custom.xml

Update the accent color resource using HEX color code:

<color name="accent"><BRAND_COLOR></color>

e.g. --> <color name="accent">#00AEEF</color>

 

Monetization

Navigate to ZypeAPI > src > main > java > com > zype > fire > api > ZypeSettings.java

Set the subscription details to true/false as you see fit.

 

Disable Universal Subscription: public static final boolean UNIVERSAL_SUBSCRIPTION_ENABLED = false;

Enable Universal Subscription: public static final boolean UNIVERSAL_SUBSCRIPTION_ENABLED = true;

 

Disable Universal TVOD: public static final boolean UNIVERSAL_TVOD = false;

Enable Universal TVOD: public static final boolean UNIVERSAL_TVOD = true;

 

image4.png

Note: Advertising is supported as part of the template.   

 

Make sure that you save all your changes (File > Save All). Then, proceed to generate your signed APK. 

 

Generate Signed APK

Please follow these step-by-step instructions for signing an APK here.

image5.png

You’ll want to generate a key and keystore and proceed to manually signing your APK.  

The .apk file that is generated during the signing process will be what you upload to your Amazon developer account and submit to the marketplace.