sinch.core.clients.sinch_client_configuration module
- class sinch.core.clients.sinch_client_configuration.Configuration(
- transport: HTTPTransport,
- token_manager: TokenManager,
- connection_timeout=10,
- key_id: str = None,
- key_secret: str = None,
- project_id: str = None,
- logger: Logger = None,
- logger_name: str = None,
- service_plan_id: str = None,
- sms_api_token: str = None,
- sms_region: str = None,
- conversation_region: str = None,
Bases:
objectSinch client configuration object.
- Parameters:
transport (HTTPTransport)
token_manager (TokenManager)
key_id (str)
key_secret (str)
project_id (str)
logger (Logger)
logger_name (str)
service_plan_id (str)
sms_api_token (str)
sms_region (str)
conversation_region (str)
- property sms_region_with_service_plan_id
SMS Region for service plan id version of the SMS API
- property sms_domain_with_service_plan_id
SMS Domain for service plan id version of the SMS API
- property sms_region
SMS Region
- property sms_domain
SMS Domain
- property conversation_region
ConversationAPI Region
- property conversation_domain
ConversationAPI Domain
- property authentication_method
Returns the determined authentication method
- validate_authentication_parameters()[source]
Validates that sufficient authentication parameters are provided. Recalculates the authentication method based on current credentials before validating. This should be called before making actual API requests.
- get_sms_origin_for_auth()[source]
Returns the appropriate SMS origin based on the authentication method. - SMS auth (service_plan_id + sms_api_token): uses sms_origin_with_service_plan_id - Project auth (project_id): uses regular sms_origin
- Raises:
ValueError: If the SMS origin is None (sms_region not set)