as

Settings
Sign out
Notifications
Alexa
Amazonアプリストア
AWS
ドキュメント
Support
Contact Us
My Cases
開発
設計と開発
公開
リファレンス
サポート
アクセスいただきありがとうございます。こちらのページは現在英語のみのご用意となっております。順次日本語化を進めてまいりますので、ご理解のほどよろしくお願いいたします。

react-native-device-info

Device Info is a library for using DeviceInfo React Native in React Native for Vega apps. The library provides device-related information for React Native for Vega apps.

Installation

To use the package, add the JavaScript library dependency in your app's package.json file.

Copied to clipboard.

"dependencies": {
         ...
         "@amazon-devices/react-native-device-info": "~2.0.0"
    }

Examples

Copied to clipboard.

import DeviceInfo from '@amazon-devices/react-native-device-info';

// or ES6+ destructured imports

import { getBaseOs, getBaseOsSync } from '@amazon-devices/react-native-device-info';

const baseOsSync = getBaseOsSync();
const baseOs = await getBaseOs();

API reference

Vega only supports the APIs mentioned in this document. Many APIs from react-native-device-info APIs are platform-specific. If there is no implementation for a platform, then the "default" return values you will receive are unknown for string, -1 for number, and false for boolean. Arrays and Objects will be empty ([] and {} respectively).

Most of the APIs return a Promise but also have a corresponding API with Sync on the end that operates synchronously. For example, you may prefer to call getBaseOsSync() during your app bootstrap to avoid async calls during the first parts of app startup.

Note: The values shown in the examples are for informational purposes only and don't represent the actual output.

getBaseOs()

The base OS build the product is based on.

Examples

Copied to clipboard.

DeviceInfo.getBaseOs().then((baseOs) => {
  // "Kepler"
});

getFirstInstallTime()

Gets the time at which the app was first installed, in milliseconds.

Examples

Copied to clipboard.

DeviceInfo.getFirstInstallTime().then((firstInstallTime) => {
  // 1517681764528
});

getInstallerPackageName()

The internal value used by the underlying source control to represent this build.

Examples

Copied to clipboard.

DeviceInfo.getInstallerPackageName().then((installerPackageName) => {
  // "com.amazon.venezia"
});

getManufacturer()

Gets the device manufacturer.

Examples

Copied to clipboard.

DeviceInfo.getManufacturer().then((manufacturer) => {
   // "Amazon"
});

getLastUpdateTime()

Gets the time at which the app was last updated, in milliseconds.

Examples

Copied to clipboard.

DeviceInfo.getLastUpdateTime().then((lastUpdateTime) => {
  //  1517681764992
});

getUserAgent()

Gets the device User Agent.

Examples

Copied to clipboard.

DeviceInfo.getUserAgent().then((userAgent) => {
  // "Kepler/1.1 (Linux; AFTCA002)"
});

Known issue

getuserAgent may not return a value in the Vega Virtual Device, but returns a value on the Fire TV Stick.


getApplicationName()

Gets the application name.

Examples

Copied to clipboard.

let appName = DeviceInfo.getApplicationName();
// "AwesomeApp"

getVersion()

Gets the application version.

Examples

Copied to clipboard.

let version = DeviceInfo.getVersion();
//  "1.0.0"

getModel()

Gets the device model.

Examples

Copied to clipboard.

let model = DeviceInfo.getModel();
// AFTCA001

getSystemName()

Gets the device OS name.

Examples

Copied to clipboard.

let systemName = DeviceInfo.getSystemName();
// "Kepler"

getSystemVersion()

Gets the device OS version.

Examples

Copied to clipboard.

let systemVersion = DeviceInfo.getSystemVersion();
// "1.1"

getBundleId()

Gets the application bundle identifier.

Examples

Copied to clipboard.

let bundleId = DeviceInfo.getBundleId();
// "com.example.awesomeApp"

getDeviceType()

Returns the device's type as a string

Examples

Copied to clipboard.

let type = DeviceInfo.getDeviceType();
// 'TV'
// unknown

getDeviceId()

Gets the device ID.

Examples

Copied to clipboard.

let deviceId = DeviceInfo.getDeviceId();
// AFTCA001

Supported versions

Package name Amazon NPM library version Vega OS build number Vega SDK version Release notes
@amazon-devices/react-native-device-info 2.1.0+10.11.0 OS 1.1 (201010438050) 0.20  

Last updated: Oct 02, 2025