# WARNING: Please don't edit this file. It was generated by Python/WinRT v1.0.0-beta.7

import enum
import datetime
import sys
import types
import typing

import winsdk._winrt as _winrt
import winsdk.windows.foundation
import winsdk.windows.foundation.collections
import winsdk.windows.system

class CredentialPromptType(enum.IntEnum):
    PROMPT_IF_NEEDED = 0
    RETYPE_CREDENTIALS = 1
    DO_NOT_PROMPT = 2

class OnlineIdSystemTicketStatus(enum.IntEnum):
    SUCCESS = 0
    ERROR = 1
    SERVICE_CONNECTION_ERROR = 2

Self = typing.TypeVar('Self')

class OnlineIdAuthenticator(_winrt.Object):
    application_id: _winrt.Guid
    authenticated_safe_customer_id: str
    can_sign_out: _winrt.Boolean
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdAuthenticator: ...
    def __new__(cls: typing.Type[OnlineIdAuthenticator]) -> OnlineIdAuthenticator:...
    @typing.overload
    def authenticate_user_async(self, request: typing.Optional[OnlineIdServiceTicketRequest]) -> typing.Optional[UserAuthenticationOperation]: ...
    @typing.overload
    def authenticate_user_async(self, requests: typing.Iterable[OnlineIdServiceTicketRequest], credential_prompt_type: CredentialPromptType) -> typing.Optional[UserAuthenticationOperation]: ...
    def sign_out_user_async(self) -> typing.Optional[SignOutUserOperation]: ...

class OnlineIdServiceTicket(_winrt.Object):
    error_code: _winrt.Int32
    request: typing.Optional[OnlineIdServiceTicketRequest]
    value: str
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdServiceTicket: ...

class OnlineIdServiceTicketRequest(_winrt.Object):
    policy: str
    service: str
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdServiceTicketRequest: ...
    @typing.overload
    def __new__(cls: typing.Type[OnlineIdServiceTicketRequest], service: str, policy: str) -> OnlineIdServiceTicketRequest:...
    @typing.overload
    def __new__(cls: typing.Type[OnlineIdServiceTicketRequest], service: str) -> OnlineIdServiceTicketRequest:...

class OnlineIdSystemAuthenticator(_winrt.Object):
    default: typing.Optional[OnlineIdSystemAuthenticatorForUser]
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdSystemAuthenticator: ...
    @staticmethod
    def get_for_user(user: typing.Optional[winsdk.windows.system.User]) -> typing.Optional[OnlineIdSystemAuthenticatorForUser]: ...

class OnlineIdSystemAuthenticatorForUser(_winrt.Object):
    application_id: _winrt.Guid
    user: typing.Optional[winsdk.windows.system.User]
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdSystemAuthenticatorForUser: ...
    def get_ticket_async(self, request: typing.Optional[OnlineIdServiceTicketRequest]) -> winsdk.windows.foundation.IAsyncOperation[OnlineIdSystemTicketResult]: ...

class OnlineIdSystemIdentity(_winrt.Object):
    id: str
    ticket: typing.Optional[OnlineIdServiceTicket]
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdSystemIdentity: ...

class OnlineIdSystemTicketResult(_winrt.Object):
    extended_error: winsdk.windows.foundation.HResult
    identity: typing.Optional[OnlineIdSystemIdentity]
    status: OnlineIdSystemTicketStatus
    @staticmethod
    def _from(obj: _winrt.Object) -> OnlineIdSystemTicketResult: ...

class SignOutUserOperation(_winrt.Object):
    error_code: winsdk.windows.foundation.HResult
    id: _winrt.UInt32
    status: winsdk.windows.foundation.AsyncStatus
    completed: typing.Optional[winsdk.windows.foundation.AsyncActionCompletedHandler]
    @staticmethod
    def _from(obj: _winrt.Object) -> SignOutUserOperation: ...
    def cancel(self) -> None: ...
    def close(self) -> None: ...
    def get_results(self) -> None: ...

class UserAuthenticationOperation(_winrt.Object):
    error_code: winsdk.windows.foundation.HResult
    id: _winrt.UInt32
    status: winsdk.windows.foundation.AsyncStatus
    completed: typing.Optional[winsdk.windows.foundation.AsyncOperationCompletedHandler[UserIdentity]]
    @staticmethod
    def _from(obj: _winrt.Object) -> UserAuthenticationOperation: ...
    def cancel(self) -> None: ...
    def close(self) -> None: ...
    def get_results(self) -> typing.Optional[UserIdentity]: ...

class UserIdentity(_winrt.Object):
    first_name: str
    id: str
    is_beta_account: _winrt.Boolean
    is_confirmed_p_c: _winrt.Boolean
    last_name: str
    safe_customer_id: str
    sign_in_name: str
    tickets: typing.Optional[winsdk.windows.foundation.collections.IVectorView[OnlineIdServiceTicket]]
    @staticmethod
    def _from(obj: _winrt.Object) -> UserIdentity: ...

