1 """Config flow for xbox."""
9 from .const
import DOMAIN
13 config_entry_oauth2_flow.AbstractOAuth2FlowHandler, domain=DOMAIN
15 """Config flow to handle xbox OAuth2 authentication."""
22 return logging.getLogger(__name__)
26 """Extra data that needs to be appended to the authorize url."""
27 scopes = [
"Xboxlive.signin",
"Xboxlive.offline_access"]
28 return {
"scope":
" ".join(scopes)}
31 self, user_input: dict[str, Any] |
None =
None
32 ) -> ConfigFlowResult:
33 """Handle a flow start."""
34 await self.async_set_unique_id(DOMAIN)
36 if self._async_current_entries():
37 return self.async_abort(reason=
"single_instance_allowed")
logging.Logger logger(self)
ConfigFlowResult async_step_user(self, dict[str, Any]|None user_input=None)
dict extra_authorize_data(self)