Device Settings Reference

Alexa customers can set their timezone, distance measuring unit, and temperature measurement unit in the Alexa app. The Alexa Settings APIs allow developers to retrieve customer preferences for these settings in a unified view.

DeviceSettings.constructor(alexaEvent)

Constructor

Arguments:
  • alexaEvent – Alexa Event object.
DeviceSettings.getDistanceUnits()

Gets distance units

Returns Object:A string with the distance units
DeviceSettings.getTemperatureUnits()

Gets temperature units

Returns Object:A string with the temperature units
DeviceSettings.getTimezone()

Gets timezone

Returns Object:A string with the timezone value
DeviceSettings.getSettings()

Gets all settings details

Returns Object:A JSON object with device’s info with the following structure
{
  "distanceUnits": "string",
  "temperatureUnits": "string",
  "timezone": "string"
}

With Voxa, you can ask for the full device’s address like this:

const skill = new Voxa({ variables, views });

skill.onIntent('FullSettingsIntent', async (alexaEvent) => {
  const info = await alexaEvent.deviceSettings.getSettings();

  alexaEvent.model.settingsInfo = `${info.distanceUnits}, ${info.temperatureUnits}, ${info.timezone}`;
  return { reply: 'DeviceSettings.FullSettings' };
});

You don’t need to request to the user the permission to access the device settings info.