Home Assistant Unofficial Reference 2024.12.1
homeassistant.components.ios Namespace Reference

Namespaces

 config_flow
 
 const
 
 notify
 
 sensor
 

Classes

class  iOSConfigView
 
class  iOSIdentifyDeviceView
 
class  iOSPushConfigView
 

Functions

bool async_setup (HomeAssistant hass, ConfigType config)
 
bool async_setup_entry (HomeAssistant hass, config_entries.ConfigEntry entry)
 
str|None device_name_for_push_id (HomeAssistant hass, str push_id)
 
dict[str, dict[str, Any]] devices (HomeAssistant hass)
 
dict[str, str] devices_with_push (HomeAssistant hass)
 
list[str] enabled_push_ids (HomeAssistant hass)
 

Variables

 ACTION_LIST_SCHEMA = vol.All(cv.ensure_list, [ACTION_SCHEMA])
 
 ACTION_SCHEMA
 
list ACTIVATION_MODES = [ATTR_FOREGROUND, ATTR_BACKGROUND]
 
string ATTR_APP = "app"
 
string ATTR_APP_BUILD_NUMBER = "buildNumber"
 
string ATTR_APP_BUNDLE_IDENTIFIER = "bundleIdentifier"
 
string ATTR_APP_VERSION_NUMBER = "versionNumber"
 
string ATTR_BACKGROUND = "background"
 
string ATTR_DEFAULT_BEHAVIOR = "default"
 
string ATTR_DEVICE_LOCALIZED_MODEL = "localizedModel"
 
string ATTR_DEVICE_MODEL = "model"
 
string ATTR_DEVICE_SYSTEM_NAME = "systemName"
 
string ATTR_DEVICES = "devices"
 
string ATTR_FOREGROUND = "foreground"
 
string ATTR_LAST_SEEN_AT = "lastSeenAt"
 
string ATTR_LOCATION_PERMISSION = "location"
 
string ATTR_NOTIFICATIONS_PERMISSION = "notifications"
 
string ATTR_PERMISSIONS = "permissions"
 
string ATTR_PUSH_ID = "pushId"
 
string ATTR_PUSH_SOUNDS = "pushSounds"
 
string ATTR_PUSH_TOKEN = "pushToken"
 
string ATTR_TEXT_INPUT_BEHAVIOR = "textInput"
 
list BEHAVIORS = [ATTR_DEFAULT_BEHAVIOR, ATTR_TEXT_INPUT_BEHAVIOR]
 
string CONF_PUSH = "push"
 
string CONF_PUSH_ACTIONS_ACTIVATION_MODE = "activationMode"
 
string CONF_PUSH_ACTIONS_AUTHENTICATION_REQUIRED = "authenticationRequired"
 
string CONF_PUSH_ACTIONS_BEHAVIOR = "behavior"
 
string CONF_PUSH_ACTIONS_CONTEXT = "context"
 
string CONF_PUSH_ACTIONS_DESTRUCTIVE = "destructive"
 
string CONF_PUSH_ACTIONS_IDENTIFIER = "identifier"
 
string CONF_PUSH_ACTIONS_TEXT_INPUT_BUTTON_TITLE = "textInputButtonTitle"
 
string CONF_PUSH_ACTIONS_TEXT_INPUT_PLACEHOLDER = "textInputPlaceholder"
 
string CONF_PUSH_ACTIONS_TITLE = "title"
 
string CONF_PUSH_CATEGORIES = "categories"
 
string CONF_PUSH_CATEGORIES_ACTIONS = "actions"
 
string CONF_PUSH_CATEGORIES_IDENTIFIER = "identifier"
 
string CONF_PUSH_CATEGORIES_NAME = "name"
 
string CONF_USER = "user"
 
 CONFIG_SCHEMA
 
string CONFIGURATION_FILE = ".ios.conf"
 
 IDENTIFY_APP_SCHEMA
 
 IDENTIFY_APP_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_APP_SCHEMA)
 
 IDENTIFY_BATTERY_SCHEMA
 
 IDENTIFY_BATTERY_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_BATTERY_SCHEMA)
 
 IDENTIFY_DEVICE_SCHEMA
 
 IDENTIFY_DEVICE_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_DEVICE_SCHEMA)
 
 IDENTIFY_SCHEMA
 
list PERMISSIONS = [ATTR_LOCATION_PERMISSION, ATTR_NOTIFICATIONS_PERMISSION]
 
list PLATFORMS = [Platform.SENSOR]
 
 PUSH_ACTION_LIST_SCHEMA = vol.All(cv.ensure_list, [PUSH_ACTION_SCHEMA])
 
 PUSH_ACTION_SCHEMA
 
 PUSH_CATEGORY_LIST_SCHEMA = vol.All(cv.ensure_list, [PUSH_CATEGORY_SCHEMA])
 
 PUSH_CATEGORY_SCHEMA
 

Detailed Description

Native Home Assistant iOS app component.

Function Documentation

◆ async_setup()

bool homeassistant.components.ios.async_setup ( HomeAssistant  hass,
ConfigType  config 
)
Set up the iOS component.

Definition at line 250 of file __init__.py.

◆ async_setup_entry()

bool homeassistant.components.ios.async_setup_entry ( HomeAssistant  hass,
config_entries.ConfigEntry   entry 
)
Set up an iOS entry.

Definition at line 281 of file __init__.py.

◆ device_name_for_push_id()

str | None homeassistant.components.ios.device_name_for_push_id ( HomeAssistant  hass,
str  push_id 
)
Return the device name for the push ID.

Definition at line 242 of file __init__.py.

◆ devices()

dict[str, dict[str, Any]] homeassistant.components.ios.devices ( HomeAssistant  hass)
Return a dictionary of all identified devices.

Definition at line 237 of file __init__.py.

◆ devices_with_push()

dict[str, str] homeassistant.components.ios.devices_with_push ( HomeAssistant  hass)
Return a dictionary of push enabled targets.

Definition at line 219 of file __init__.py.

◆ enabled_push_ids()

list[str] homeassistant.components.ios.enabled_push_ids ( HomeAssistant  hass)
Return a list of push enabled target push IDs.

Definition at line 228 of file __init__.py.

Variable Documentation

◆ ACTION_LIST_SCHEMA

homeassistant.components.ios.ACTION_LIST_SCHEMA = vol.All(cv.ensure_list, [ACTION_SCHEMA])

Definition at line 149 of file __init__.py.

◆ ACTION_SCHEMA

homeassistant.components.ios.ACTION_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(CONF_ACTION_NAME): cv.string,
4  vol.Optional(CONF_ACTION_BACKGROUND_COLOR): cv.string,
5  vol.Optional(CONF_ACTION_LABEL): {
6  vol.Optional(CONF_ACTION_LABEL_TEXT): cv.string,
7  vol.Optional(CONF_ACTION_LABEL_COLOR): cv.string,
8  },
9  vol.Optional(CONF_ACTION_ICON): {
10  vol.Optional(CONF_ACTION_ICON_ICON): cv.string,
11  vol.Optional(CONF_ACTION_ICON_COLOR): cv.string,
12  },
13  vol.Optional(CONF_ACTION_SHOW_IN_CARPLAY): cv.boolean,
14  vol.Optional(CONF_ACTION_SHOW_IN_WATCH): cv.boolean,
15  vol.Optional(CONF_ACTION_USE_CUSTOM_COLORS): cv.boolean,
16  },
17 )

Definition at line 131 of file __init__.py.

◆ ACTIVATION_MODES

list homeassistant.components.ios.ACTIVATION_MODES = [ATTR_FOREGROUND, ATTR_BACKGROUND]

Definition at line 68 of file __init__.py.

◆ ATTR_APP

string homeassistant.components.ios.ATTR_APP = "app"

Definition at line 78 of file __init__.py.

◆ ATTR_APP_BUILD_NUMBER

string homeassistant.components.ios.ATTR_APP_BUILD_NUMBER = "buildNumber"

Definition at line 88 of file __init__.py.

◆ ATTR_APP_BUNDLE_IDENTIFIER

string homeassistant.components.ios.ATTR_APP_BUNDLE_IDENTIFIER = "bundleIdentifier"

Definition at line 87 of file __init__.py.

◆ ATTR_APP_VERSION_NUMBER

string homeassistant.components.ios.ATTR_APP_VERSION_NUMBER = "versionNumber"

Definition at line 89 of file __init__.py.

◆ ATTR_BACKGROUND

string homeassistant.components.ios.ATTR_BACKGROUND = "background"

Definition at line 66 of file __init__.py.

◆ ATTR_DEFAULT_BEHAVIOR

string homeassistant.components.ios.ATTR_DEFAULT_BEHAVIOR = "default"

Definition at line 70 of file __init__.py.

◆ ATTR_DEVICE_LOCALIZED_MODEL

string homeassistant.components.ios.ATTR_DEVICE_LOCALIZED_MODEL = "localizedModel"

Definition at line 83 of file __init__.py.

◆ ATTR_DEVICE_MODEL

string homeassistant.components.ios.ATTR_DEVICE_MODEL = "model"

Definition at line 84 of file __init__.py.

◆ ATTR_DEVICE_SYSTEM_NAME

string homeassistant.components.ios.ATTR_DEVICE_SYSTEM_NAME = "systemName"

Definition at line 85 of file __init__.py.

◆ ATTR_DEVICES

string homeassistant.components.ios.ATTR_DEVICES = "devices"

Definition at line 97 of file __init__.py.

◆ ATTR_FOREGROUND

string homeassistant.components.ios.ATTR_FOREGROUND = "foreground"

Definition at line 65 of file __init__.py.

◆ ATTR_LAST_SEEN_AT

string homeassistant.components.ios.ATTR_LAST_SEEN_AT = "lastSeenAt"

Definition at line 75 of file __init__.py.

◆ ATTR_LOCATION_PERMISSION

string homeassistant.components.ios.ATTR_LOCATION_PERMISSION = "location"

Definition at line 91 of file __init__.py.

◆ ATTR_NOTIFICATIONS_PERMISSION

string homeassistant.components.ios.ATTR_NOTIFICATIONS_PERMISSION = "notifications"

Definition at line 92 of file __init__.py.

◆ ATTR_PERMISSIONS

string homeassistant.components.ios.ATTR_PERMISSIONS = "permissions"

Definition at line 79 of file __init__.py.

◆ ATTR_PUSH_ID

string homeassistant.components.ios.ATTR_PUSH_ID = "pushId"

Definition at line 80 of file __init__.py.

◆ ATTR_PUSH_SOUNDS

string homeassistant.components.ios.ATTR_PUSH_SOUNDS = "pushSounds"

Definition at line 81 of file __init__.py.

◆ ATTR_PUSH_TOKEN

string homeassistant.components.ios.ATTR_PUSH_TOKEN = "pushToken"

Definition at line 77 of file __init__.py.

◆ ATTR_TEXT_INPUT_BEHAVIOR

string homeassistant.components.ios.ATTR_TEXT_INPUT_BEHAVIOR = "textInput"

Definition at line 71 of file __init__.py.

◆ BEHAVIORS

list homeassistant.components.ios.BEHAVIORS = [ATTR_DEFAULT_BEHAVIOR, ATTR_TEXT_INPUT_BEHAVIOR]

Definition at line 73 of file __init__.py.

◆ CONF_PUSH

string homeassistant.components.ios.CONF_PUSH = "push"

Definition at line 47 of file __init__.py.

◆ CONF_PUSH_ACTIONS_ACTIVATION_MODE

string homeassistant.components.ios.CONF_PUSH_ACTIONS_ACTIVATION_MODE = "activationMode"

Definition at line 55 of file __init__.py.

◆ CONF_PUSH_ACTIONS_AUTHENTICATION_REQUIRED

string homeassistant.components.ios.CONF_PUSH_ACTIONS_AUTHENTICATION_REQUIRED = "authenticationRequired"

Definition at line 56 of file __init__.py.

◆ CONF_PUSH_ACTIONS_BEHAVIOR

string homeassistant.components.ios.CONF_PUSH_ACTIONS_BEHAVIOR = "behavior"

Definition at line 58 of file __init__.py.

◆ CONF_PUSH_ACTIONS_CONTEXT

string homeassistant.components.ios.CONF_PUSH_ACTIONS_CONTEXT = "context"

Definition at line 59 of file __init__.py.

◆ CONF_PUSH_ACTIONS_DESTRUCTIVE

string homeassistant.components.ios.CONF_PUSH_ACTIONS_DESTRUCTIVE = "destructive"

Definition at line 57 of file __init__.py.

◆ CONF_PUSH_ACTIONS_IDENTIFIER

string homeassistant.components.ios.CONF_PUSH_ACTIONS_IDENTIFIER = "identifier"

Definition at line 53 of file __init__.py.

◆ CONF_PUSH_ACTIONS_TEXT_INPUT_BUTTON_TITLE

string homeassistant.components.ios.CONF_PUSH_ACTIONS_TEXT_INPUT_BUTTON_TITLE = "textInputButtonTitle"

Definition at line 60 of file __init__.py.

◆ CONF_PUSH_ACTIONS_TEXT_INPUT_PLACEHOLDER

string homeassistant.components.ios.CONF_PUSH_ACTIONS_TEXT_INPUT_PLACEHOLDER = "textInputPlaceholder"

Definition at line 61 of file __init__.py.

◆ CONF_PUSH_ACTIONS_TITLE

string homeassistant.components.ios.CONF_PUSH_ACTIONS_TITLE = "title"

Definition at line 54 of file __init__.py.

◆ CONF_PUSH_CATEGORIES

string homeassistant.components.ios.CONF_PUSH_CATEGORIES = "categories"

Definition at line 48 of file __init__.py.

◆ CONF_PUSH_CATEGORIES_ACTIONS

string homeassistant.components.ios.CONF_PUSH_CATEGORIES_ACTIONS = "actions"

Definition at line 51 of file __init__.py.

◆ CONF_PUSH_CATEGORIES_IDENTIFIER

string homeassistant.components.ios.CONF_PUSH_CATEGORIES_IDENTIFIER = "identifier"

Definition at line 50 of file __init__.py.

◆ CONF_PUSH_CATEGORIES_NAME

string homeassistant.components.ios.CONF_PUSH_CATEGORIES_NAME = "name"

Definition at line 49 of file __init__.py.

◆ CONF_USER

string homeassistant.components.ios.CONF_USER = "user"

Definition at line 63 of file __init__.py.

◆ CONFIG_SCHEMA

homeassistant.components.ios.CONFIG_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  DOMAIN: vol.All(
4  cv.deprecated(CONF_PUSH),
5  {
6  CONF_PUSH: {CONF_PUSH_CATEGORIES: PUSH_CATEGORY_LIST_SCHEMA},
7  CONF_ACTIONS: ACTION_LIST_SCHEMA,
8  },
9  )
10  },
11  extra=vol.ALLOW_EXTRA,
12 )

Definition at line 151 of file __init__.py.

◆ CONFIGURATION_FILE

string homeassistant.components.ios.CONFIGURATION_FILE = ".ios.conf"

Definition at line 214 of file __init__.py.

◆ IDENTIFY_APP_SCHEMA

homeassistant.components.ios.IDENTIFY_APP_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(ATTR_APP_BUNDLE_IDENTIFIER): cv.string,
4  vol.Required(ATTR_APP_BUILD_NUMBER): cv.positive_int,
5  vol.Optional(ATTR_APP_VERSION_NUMBER): cv.string,
6  },
7  extra=vol.ALLOW_EXTRA,
8 )

Definition at line 179 of file __init__.py.

◆ IDENTIFY_APP_SCHEMA_CONTAINER

homeassistant.components.ios.IDENTIFY_APP_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_APP_SCHEMA)

Definition at line 188 of file __init__.py.

◆ IDENTIFY_BATTERY_SCHEMA

homeassistant.components.ios.IDENTIFY_BATTERY_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(ATTR_BATTERY_LEVEL): cv.positive_int,
4  vol.Required(ATTR_BATTERY_STATE): vol.In(BATTERY_STATES),
5  },
6  extra=vol.ALLOW_EXTRA,
7 )

Definition at line 190 of file __init__.py.

◆ IDENTIFY_BATTERY_SCHEMA_CONTAINER

homeassistant.components.ios.IDENTIFY_BATTERY_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_BATTERY_SCHEMA)

Definition at line 198 of file __init__.py.

◆ IDENTIFY_DEVICE_SCHEMA

homeassistant.components.ios.IDENTIFY_DEVICE_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(ATTR_DEVICE_NAME): cv.string,
4  vol.Required(ATTR_DEVICE_LOCALIZED_MODEL): cv.string,
5  vol.Required(ATTR_DEVICE_MODEL): cv.string,
6  vol.Required(ATTR_DEVICE_PERMANENT_ID): cv.string,
7  vol.Required(ATTR_DEVICE_SYSTEM_VERSION): cv.string,
8  vol.Required(ATTR_DEVICE_TYPE): cv.string,
9  vol.Required(ATTR_DEVICE_SYSTEM_NAME): cv.string,
10  },
11  extra=vol.ALLOW_EXTRA,
12 )

Definition at line 164 of file __init__.py.

◆ IDENTIFY_DEVICE_SCHEMA_CONTAINER

homeassistant.components.ios.IDENTIFY_DEVICE_SCHEMA_CONTAINER = vol.All(dict, IDENTIFY_DEVICE_SCHEMA)

Definition at line 177 of file __init__.py.

◆ IDENTIFY_SCHEMA

homeassistant.components.ios.IDENTIFY_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(ATTR_DEVICE): IDENTIFY_DEVICE_SCHEMA_CONTAINER,
4  vol.Required(ATTR_BATTERY): IDENTIFY_BATTERY_SCHEMA_CONTAINER,
5  vol.Required(ATTR_PUSH_TOKEN): cv.string,
6  vol.Required(ATTR_APP): IDENTIFY_APP_SCHEMA_CONTAINER,
7  vol.Required(ATTR_PERMISSIONS): vol.All(cv.ensure_list, [vol.In(PERMISSIONS)]),
8  vol.Required(ATTR_PUSH_ID): cv.string,
9  vol.Required(ATTR_DEVICE_ID): cv.string,
10  vol.Optional(ATTR_PUSH_SOUNDS): list,
11  },
12  extra=vol.ALLOW_EXTRA,
13 )

Definition at line 200 of file __init__.py.

◆ PERMISSIONS

list homeassistant.components.ios.PERMISSIONS = [ATTR_LOCATION_PERMISSION, ATTR_NOTIFICATIONS_PERMISSION]

Definition at line 94 of file __init__.py.

◆ PLATFORMS

list homeassistant.components.ios.PLATFORMS = [Platform.SENSOR]

Definition at line 216 of file __init__.py.

◆ PUSH_ACTION_LIST_SCHEMA

homeassistant.components.ios.PUSH_ACTION_LIST_SCHEMA = vol.All(cv.ensure_list, [PUSH_ACTION_SCHEMA])

Definition at line 119 of file __init__.py.

◆ PUSH_ACTION_SCHEMA

homeassistant.components.ios.PUSH_ACTION_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(CONF_PUSH_ACTIONS_IDENTIFIER): vol.Upper,
4  vol.Required(CONF_PUSH_ACTIONS_TITLE): cv.string,
5  vol.Optional(
6  CONF_PUSH_ACTIONS_ACTIVATION_MODE, default=ATTR_BACKGROUND
7  ): vol.In(ACTIVATION_MODES),
8  vol.Optional(
9  CONF_PUSH_ACTIONS_AUTHENTICATION_REQUIRED, default=False
10  ): cv.boolean,
11  vol.Optional(CONF_PUSH_ACTIONS_DESTRUCTIVE, default=False): cv.boolean,
12  vol.Optional(CONF_PUSH_ACTIONS_BEHAVIOR, default=ATTR_DEFAULT_BEHAVIOR): vol.In(
13  BEHAVIORS
14  ),
15  vol.Optional(CONF_PUSH_ACTIONS_TEXT_INPUT_BUTTON_TITLE): cv.string,
16  vol.Optional(CONF_PUSH_ACTIONS_TEXT_INPUT_PLACEHOLDER): cv.string,
17  },
18  extra=vol.ALLOW_EXTRA,
19 )

Definition at line 99 of file __init__.py.

◆ PUSH_CATEGORY_LIST_SCHEMA

homeassistant.components.ios.PUSH_CATEGORY_LIST_SCHEMA = vol.All(cv.ensure_list, [PUSH_CATEGORY_SCHEMA])

Definition at line 129 of file __init__.py.

◆ PUSH_CATEGORY_SCHEMA

homeassistant.components.ios.PUSH_CATEGORY_SCHEMA
Initial value:
1 = vol.Schema(
2  {
3  vol.Required(CONF_PUSH_CATEGORIES_NAME): cv.string,
4  vol.Required(CONF_PUSH_CATEGORIES_IDENTIFIER): vol.Lower,
5  vol.Required(CONF_PUSH_CATEGORIES_ACTIONS): PUSH_ACTION_LIST_SCHEMA,
6  }
7 )

Definition at line 121 of file __init__.py.