import voluptuous as vol from homeassistant import config_entries from .const import DOMAIN class ReosConfigFlow(config_entries.ConfigFlow, domain=DOMAIN): VERSION = 1 MINOR_VERSION = 1 async def async_step_user(self, info): if info is not None: return self.async_create_entry(title=info["username"], data=info) return self.async_show_form(step_id="user", data_schema=vol.Schema({ vol.Optional("host", default="feapi.reos.software"): str, vol.Required("client_id"): str, vol.Required("client_secret"): str, vol.Required("username"): str, vol.Required("password"): str, }))