Smart Home AppSelector Trait Schema

action.devices.traits.AppSelector - This trait is used for devices which are able to switch between applications.

Device ATTRIBUTES

Devices with this trait may report the following attributes as part of the SYNC operation. To learn more about handling SYNC intents, see Intent fulfillment.

Attributes Type Description
availableApplications Array

Required.

A list of applications. Each application has one or more synonyms in each supported language. The first synonym is used in the response.

[item, ...] Object

Application that users of this device can interact with.

key String

Required.

Unique key for the application which is not exposed to users in speech or response.

names Array

Required.

Name of each application and its language-specific synonyms.

[item, ...] Object

Application synonyms.

name_synonym Array

Required.

User-friendly synonyms for the application name for a given language. The first synonym is used in the response.

[item, ...] String

Application name.

lang String

Required.

Language code.

Examples

Device with YouTube app

{
  "availableApplications": [
    {
      "key": "youtube",
      "names": [
        {
          "name_synonym": [
            "YouTube",
            "YouTube US"
          ],
          "lang": "en"
        },
        {
          "name_synonym": [
            "YouTube",
            "YouTube DE"
          ],
          "lang": "de"
        }
      ]
    }
  ]
}

Device STATES

Entities with this trait may report the following states as part of the QUERY operation. To learn more about handling QUERY intents, see Intent fulfillment.

States Type Description
currentApplication String

Required.

Key value of the current application that is active in the foreground.

Examples

Device with YouTube app currently active on foreground.

{
  "currentApplication": "YouTube"
}

Device COMMANDS

Devices with this trait may respond to the following commands as part of the EXECUTE operation. To learn more about handling EXECUTE intents, see Intent fulfillment.

action.devices.commands.appInstall

Install the given application.

Parameters

Parameters Type Description
newApplication String

Key of the application to install.

newApplicationName String

Name of the application to install.

Examples

Install YouTube app by key

{
  "command": "action.devices.commands.appInstall",
  "params": {
    "newApplication": "YouTube"
  }
}

Install YouTube app by name

{
  "command": "action.devices.commands.appInstall",
  "params": {
    "newApplicationName": "YouTube US"
  }
}

action.devices.commands.appSearch

Search for the given application.

Parameters

Parameters Type Description
newApplication String

Key of the application to search for.

newApplicationName String

Name of the application to search for.

Examples

Search for YouTube app by key

{
  "command": "action.devices.commands.appSearch",
  "params": {
    "newApplication": "YouTube"
  }
}

Search for YouTube app by name

{
  "command": "action.devices.commands.appSearch",
  "params": {
    "newApplicationName": "YouTube US"
  }
}

action.devices.commands.appSelect

Select the given application.

Parameters

Parameters Type Description
newApplication String

Key of the application to select.

newApplicationName String

Name of the application to select.

Examples

Select YouTube app by key

{
  "command": "action.devices.commands.appSelect",
  "params": {
    "newApplication": "YouTube"
  }
}

Select YouTube app by name

{
  "command": "action.devices.commands.appSelect",
  "params": {
    "newApplicationName": "YouTube US"
  }
}

Sample utterances

de-DE

  • Öffne Netflix auf dem Fernseher .

en-US

  • begin using YouTube app on the smart TV

es-ES

  • pon netflix en la tele del salón

fr-FR

  • Mets Netflix sur la télé .

hi-IN

  • टीवी पर नेटफ्लिक्स ऍप लॉन्च करो

it-IT

  • Apri Netflix sulla televisione della mia camera .

ja-JP

  • YouTube のアプリを テレビ でスタート

ko-KR

  • TV 에서 유튜브 앱 열어 줘

nl-NL

  • Start Netflix op mijn TV .

pt-BR

  • Abra o Netflix na TV para mim.
  • Abre o Youtube na televisão .

sv-SE

  • Öppna Youtube TV:n

Device ERRORS

See the full list of errors and exceptions.
  • noAvailableApp: The application doesn’t exist or is not available.
  • appLaunchFailed: The application failed to launch.
  • alreadyInstalledApp: The application was already installed.