diff --git a/sinch/core/clients/sinch_client_async.py b/sinch/core/clients/sinch_client_async.py index a32a223..aab97e5 100644 --- a/sinch/core/clients/sinch_client_async.py +++ b/sinch/core/clients/sinch_client_async.py @@ -1,3 +1,4 @@ +from logging import Logger from sinch.core.clients.sinch_client_base import ClientBase from sinch.core.clients.sinch_client_configuration import Configuration from sinch.core.token_manager import TokenManagerAsync @@ -17,11 +18,11 @@ class ClientAsync(ClientBase): """ def __init__( self, - key_id, - key_secret, - project_id, - logger_name=None, - logger=None, + key_id: str = None, + key_secret: str = None, + project_id: str = None, + logger_name: str = None, + logger: Logger = None, application_key: str = None, application_secret: str = None ): diff --git a/sinch/core/clients/sinch_client_base.py b/sinch/core/clients/sinch_client_base.py index 7f53fd0..45d6754 100644 --- a/sinch/core/clients/sinch_client_base.py +++ b/sinch/core/clients/sinch_client_base.py @@ -1,3 +1,4 @@ +from logging import Logger from abc import ABC, abstractmethod from sinch.core.clients.sinch_client_configuration import Configuration from sinch.domains.authentication import AuthenticationBase @@ -21,15 +22,15 @@ class ClientBase(ABC): @abstractmethod def __init__( self, - key_id, - key_secret, - project_id, - logger_name=None, - logger=None, + key_id: str = None, + key_secret: str = None, + project_id: str = None, + logger_name: str = None, + logger: Logger = None, application_key: str = None, application_secret: str = None ): pass def __repr__(self): - return f"Sinch SDK client for project_id: {self.configuration.project_id}" + return "Sinch SDK client" diff --git a/sinch/core/clients/sinch_client_configuration.py b/sinch/core/clients/sinch_client_configuration.py index 74f0931..b087898 100644 --- a/sinch/core/clients/sinch_client_configuration.py +++ b/sinch/core/clients/sinch_client_configuration.py @@ -1,4 +1,5 @@ import logging +from logging import Logger from typing import Union from sinch.core.ports.http_transport import HTTPTransport @@ -16,7 +17,7 @@ def __init__( project_id: str, transport: HTTPTransport, token_manager: Union[TokenManager, TokenManagerAsync], - logger=None, + logger: Logger = None, logger_name: str = None, disable_https=False, connection_timeout=10, diff --git a/sinch/core/clients/sinch_client_sync.py b/sinch/core/clients/sinch_client_sync.py index 0ec939c..5e81b78 100644 --- a/sinch/core/clients/sinch_client_sync.py +++ b/sinch/core/clients/sinch_client_sync.py @@ -1,3 +1,4 @@ +from logging import Logger from sinch.core.clients.sinch_client_base import ClientBase from sinch.core.clients.sinch_client_configuration import Configuration from sinch.core.token_manager import TokenManager @@ -17,11 +18,11 @@ class Client(ClientBase): """ def __init__( self, - key_id, - key_secret, - project_id, - logger_name=None, - logger=None, + key_id: str = None, + key_secret: str = None, + project_id: str = None, + logger_name: str = None, + logger: Logger = None, application_key: str = None, application_secret: str = None ):