# 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.security.cryptography.core
import winsdk.windows.storage.streams
import winsdk.windows.system

class KeyCredentialAttestationStatus(enum.IntEnum):
    SUCCESS = 0
    UNKNOWN_ERROR = 1
    NOT_SUPPORTED = 2
    TEMPORARY_FAILURE = 3

class KeyCredentialCreationOption(enum.IntEnum):
    REPLACE_EXISTING = 0
    FAIL_IF_EXISTS = 1

class KeyCredentialStatus(enum.IntEnum):
    SUCCESS = 0
    UNKNOWN_ERROR = 1
    NOT_FOUND = 2
    USER_CANCELED = 3
    USER_PREFERS_PASSWORD = 4
    CREDENTIAL_ALREADY_EXISTS = 5
    SECURITY_DEVICE_LOCKED = 6

class WebAccountPictureSize(enum.IntEnum):
    SIZE64X64 = 64
    SIZE208X208 = 208
    SIZE424X424 = 424
    SIZE1080X1080 = 1080

class WebAccountState(enum.IntEnum):
    NONE = 0
    CONNECTED = 1
    ERROR = 2

Self = typing.TypeVar('Self')

class KeyCredential(_winrt.Object):
    name: str
    @staticmethod
    def _from(obj: _winrt.Object) -> KeyCredential: ...
    def get_attestation_async(self) -> winsdk.windows.foundation.IAsyncOperation[KeyCredentialAttestationResult]: ...
    def request_sign_async(self, data: typing.Optional[winsdk.windows.storage.streams.IBuffer]) -> winsdk.windows.foundation.IAsyncOperation[KeyCredentialOperationResult]: ...
    @typing.overload
    def retrieve_public_key(self) -> typing.Optional[winsdk.windows.storage.streams.IBuffer]: ...
    @typing.overload
    def retrieve_public_key(self, blob_type: winsdk.windows.security.cryptography.core.CryptographicPublicKeyBlobType) -> typing.Optional[winsdk.windows.storage.streams.IBuffer]: ...

class KeyCredentialAttestationResult(_winrt.Object):
    attestation_buffer: typing.Optional[winsdk.windows.storage.streams.IBuffer]
    certificate_chain_buffer: typing.Optional[winsdk.windows.storage.streams.IBuffer]
    status: KeyCredentialAttestationStatus
    @staticmethod
    def _from(obj: _winrt.Object) -> KeyCredentialAttestationResult: ...

class KeyCredentialManager(_winrt.Object):
    @staticmethod
    def _from(obj: _winrt.Object) -> KeyCredentialManager: ...
    @staticmethod
    def delete_async(name: str) -> typing.Optional[winsdk.windows.foundation.IAsyncAction]: ...
    @staticmethod
    def is_supported_async() -> winsdk.windows.foundation.IAsyncOperation[_winrt.Boolean]: ...
    @staticmethod
    def open_async(name: str) -> winsdk.windows.foundation.IAsyncOperation[KeyCredentialRetrievalResult]: ...
    @staticmethod
    def renew_attestation_async() -> typing.Optional[winsdk.windows.foundation.IAsyncAction]: ...
    @staticmethod
    def request_create_async(name: str, option: KeyCredentialCreationOption) -> winsdk.windows.foundation.IAsyncOperation[KeyCredentialRetrievalResult]: ...

class KeyCredentialOperationResult(_winrt.Object):
    result: typing.Optional[winsdk.windows.storage.streams.IBuffer]
    status: KeyCredentialStatus
    @staticmethod
    def _from(obj: _winrt.Object) -> KeyCredentialOperationResult: ...

class KeyCredentialRetrievalResult(_winrt.Object):
    credential: typing.Optional[KeyCredential]
    status: KeyCredentialStatus
    @staticmethod
    def _from(obj: _winrt.Object) -> KeyCredentialRetrievalResult: ...

class PasswordCredential(_winrt.Object):
    user_name: str
    resource: str
    password: str
    properties: typing.Optional[winsdk.windows.foundation.collections.IPropertySet]
    @staticmethod
    def _from(obj: _winrt.Object) -> PasswordCredential: ...
    @typing.overload
    def __new__(cls: typing.Type[PasswordCredential], resource: str, user_name: str, password: str) -> PasswordCredential:...
    @typing.overload
    def __new__(cls: typing.Type[PasswordCredential]) -> PasswordCredential:...
    def retrieve_password(self) -> None: ...

class PasswordCredentialPropertyStore(_winrt.Object, typing.MutableMapping[str, _winrt.Object]):
    size: _winrt.UInt32
    def __len__(self) -> int: ...
    def __iter__(self) -> typing.Iterator[str]: ...
    def __contains__(self, key: object) -> bool:...
    def __setitem__(self, key: str, value: _winrt.Object) -> None: ...
    def __getitem__(self, key: str) -> _winrt.Object: ...
    def __delitem__(self, key: str) -> None: ...
    @staticmethod
    def _from(obj: _winrt.Object) -> PasswordCredentialPropertyStore: ...
    def __new__(cls: typing.Type[PasswordCredentialPropertyStore]) -> PasswordCredentialPropertyStore:...
    def clear(self) -> None: ...
    def first(self) -> typing.Optional[winsdk.windows.foundation.collections.IIterator[winsdk.windows.foundation.collections.IKeyValuePair[str, _winrt.Object]]]: ...
    def get_view(self) -> typing.Optional[winsdk.windows.foundation.collections.IMapView[str, _winrt.Object]]: ...
    def has_key(self, key: str) -> _winrt.Boolean: ...
    def insert(self, key: str, value: typing.Optional[_winrt.Object]) -> _winrt.Boolean: ...
    def lookup(self, key: str) -> typing.Optional[_winrt.Object]: ...
    def remove(self, key: str) -> None: ...
    def add_map_changed(self, vhnd: winsdk.windows.foundation.collections.MapChangedEventHandler[str, _winrt.Object]) -> winsdk.windows.foundation.EventRegistrationToken: ...
    def remove_map_changed(self, token: winsdk.windows.foundation.EventRegistrationToken) -> None: ...

class PasswordVault(_winrt.Object):
    @staticmethod
    def _from(obj: _winrt.Object) -> PasswordVault: ...
    def __new__(cls: typing.Type[PasswordVault]) -> PasswordVault:...
    def add(self, credential: typing.Optional[PasswordCredential]) -> None: ...
    def find_all_by_resource(self, resource: str) -> typing.Optional[winsdk.windows.foundation.collections.IVectorView[PasswordCredential]]: ...
    def find_all_by_user_name(self, user_name: str) -> typing.Optional[winsdk.windows.foundation.collections.IVectorView[PasswordCredential]]: ...
    def remove(self, credential: typing.Optional[PasswordCredential]) -> None: ...
    def retrieve(self, resource: str, user_name: str) -> typing.Optional[PasswordCredential]: ...
    def retrieve_all(self) -> typing.Optional[winsdk.windows.foundation.collections.IVectorView[PasswordCredential]]: ...

class WebAccount(_winrt.Object):
    state: WebAccountState
    user_name: str
    web_account_provider: typing.Optional[WebAccountProvider]
    id: str
    properties: typing.Optional[winsdk.windows.foundation.collections.IMapView[str, str]]
    @staticmethod
    def _from(obj: _winrt.Object) -> WebAccount: ...
    def __new__(cls: typing.Type[WebAccount], web_account_provider: typing.Optional[WebAccountProvider], user_name: str, state: WebAccountState) -> WebAccount:...
    def get_picture_async(self, desized_size: WebAccountPictureSize) -> winsdk.windows.foundation.IAsyncOperation[winsdk.windows.storage.streams.IRandomAccessStream]: ...
    @typing.overload
    def sign_out_async(self) -> typing.Optional[winsdk.windows.foundation.IAsyncAction]: ...
    @typing.overload
    def sign_out_async(self, client_id: str) -> typing.Optional[winsdk.windows.foundation.IAsyncAction]: ...

class WebAccountProvider(_winrt.Object):
    display_name: str
    icon_uri: typing.Optional[winsdk.windows.foundation.Uri]
    id: str
    authority: str
    display_purpose: str
    user: typing.Optional[winsdk.windows.system.User]
    is_system_provider: _winrt.Boolean
    @staticmethod
    def _from(obj: _winrt.Object) -> WebAccountProvider: ...
    def __new__(cls: typing.Type[WebAccountProvider], id: str, display_name: str, icon_uri: typing.Optional[winsdk.windows.foundation.Uri]) -> WebAccountProvider:...

class IWebAccount(_winrt.Object):
    state: WebAccountState
    user_name: str
    web_account_provider: typing.Optional[WebAccountProvider]
    @staticmethod
    def _from(obj: _winrt.Object) -> IWebAccount: ...

