Skip to content

Commit

Permalink
Define teslafi config schema
Browse files Browse the repository at this point in the history
  • Loading branch information
jhansche committed Jan 5, 2025
1 parent 5f142e1 commit 1e42053
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions custom_components/teslafi/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@

from __future__ import annotations

import voluptuous as vol

from homeassistant.config_entries import ConfigEntry
from homeassistant.const import CONF_API_KEY, Platform
from homeassistant.core import HomeAssistant
from homeassistant.helpers import device_registry as dr
import homeassistant.helpers.config_validation as cv
from homeassistant.helpers.device_registry import DeviceEntry
from homeassistant.helpers.httpx_client import create_async_httpx_client
from homeassistant.helpers.typing import ConfigType
Expand All @@ -29,6 +32,16 @@
Platform.UPDATE,
]

CONFIG_SCHEMA = vol.Schema(
{
DOMAIN: vol.Schema(
{
vol.Required(CONF_API_KEY): cv.string,
}
)
}
)


async def async_setup(hass: HomeAssistant, config: ConfigType) -> bool:
"""Set up the integration."""
Expand Down

0 comments on commit 1e42053

Please sign in to comment.