diff --git a/changelog.md b/changelog.md index 1ba7663..71f1dcb 100644 --- a/changelog.md +++ b/changelog.md @@ -1,7 +1,7 @@ # Change Log All notable changes to this project will be documented in this file. -## [0.3.7] - TBA +## [0.3.7] - 2023-09-26 ### Added diff --git a/docs/agent/web/api/v33.html b/docs/agent/web/api/v33.html index 0f9bc69..c27749c 100644 --- a/docs/agent/web/api/v33.html +++ b/docs/agent/web/api/v33.html @@ -47,8 +47,10 @@

Module livechat.agent.web.api.v33

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/agent/action' # Chats @@ -1147,7 +1149,7 @@

Classes

class AgentWebV33 -(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Agent Web API Class containing methods in version 3.3.

@@ -1162,8 +1164,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/agent/action' # Chats @@ -4624,4 +4628,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/agent/web/api/v34.html b/docs/agent/web/api/v34.html index 1a81244..faa8df8 100644 --- a/docs/agent/web/api/v34.html +++ b/docs/agent/web/api/v34.html @@ -49,8 +49,10 @@

Module livechat.agent.web.api.v34

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/agent/action' # Chats @@ -1109,7 +1111,7 @@

Classes

class AgentWebV34 -(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Agent Web API Class containing methods in version 3.4.

@@ -1124,8 +1126,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/agent/action' # Chats @@ -4456,4 +4460,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/agent/web/api/v35.html b/docs/agent/web/api/v35.html index 1bb5f49..eac725b 100644 --- a/docs/agent/web/api/v35.html +++ b/docs/agent/web/api/v35.html @@ -49,8 +49,10 @@

Module livechat.agent.web.api.v35

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/agent/action' # Chats @@ -1109,7 +1111,7 @@

Classes

class AgentWebV35 -(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Agent Web API Class containing methods in version 3.5.

@@ -1124,8 +1126,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/agent/action' # Chats @@ -4456,4 +4460,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/agent/web/api/v36.html b/docs/agent/web/api/v36.html index 3d44072..273458e 100644 --- a/docs/agent/web/api/v36.html +++ b/docs/agent/web/api/v36.html @@ -49,8 +49,10 @@

Module livechat.agent.web.api.v36

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/agent/action' # Chats @@ -1074,7 +1076,7 @@

Classes

class AgentWebV36 -(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Agent Web API Class containing methods in version 3.6.

@@ -1089,8 +1091,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(access_token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/agent/action' # Chats @@ -4311,4 +4315,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/agent/web/base.html b/docs/agent/web/base.html index d855f88..3a60bbb 100644 --- a/docs/agent/web/base.html +++ b/docs/agent/web/base.html @@ -49,12 +49,13 @@

Module livechat.agent.web.base

API version. ''' @staticmethod def get_client( - access_token: str, - version: str = stable_version, - base_url: str = api_url, - http2: bool = False, - proxies: dict = None, - verify: bool = True + access_token: str, + version: str = stable_version, + base_url: str = api_url, + http2: bool = False, + proxies: dict = None, + verify: bool = True, + disable_logging: bool = False, ) -> Union[AgentWebV33, AgentWebV34, AgentWebV35]: ''' Returns client for specific API version. @@ -70,6 +71,7 @@

Module livechat.agent.web.base

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version. @@ -78,10 +80,18 @@

Module livechat.agent.web.base

ValueError: If the specified version does not exist. ''' client = { - '3.3': AgentWebV33(access_token, base_url, http2, proxies, verify), - '3.4': AgentWebV34(access_token, base_url, http2, proxies, verify), - '3.5': AgentWebV35(access_token, base_url, http2, proxies, verify), - '3.6': AgentWebV36(access_token, base_url, http2, proxies, verify), + '3.3': + AgentWebV33(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + AgentWebV34(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + AgentWebV35(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + AgentWebV36(access_token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -112,12 +122,13 @@

Classes

API version. ''' @staticmethod def get_client( - access_token: str, - version: str = stable_version, - base_url: str = api_url, - http2: bool = False, - proxies: dict = None, - verify: bool = True + access_token: str, + version: str = stable_version, + base_url: str = api_url, + http2: bool = False, + proxies: dict = None, + verify: bool = True, + disable_logging: bool = False, ) -> Union[AgentWebV33, AgentWebV34, AgentWebV35]: ''' Returns client for specific API version. @@ -133,6 +144,7 @@

Classes

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version. @@ -141,10 +153,18 @@

Classes

ValueError: If the specified version does not exist. ''' client = { - '3.3': AgentWebV33(access_token, base_url, http2, proxies, verify), - '3.4': AgentWebV34(access_token, base_url, http2, proxies, verify), - '3.5': AgentWebV35(access_token, base_url, http2, proxies, verify), - '3.6': AgentWebV36(access_token, base_url, http2, proxies, verify), + '3.3': + AgentWebV33(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + AgentWebV34(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + AgentWebV35(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + AgentWebV36(access_token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -153,7 +173,7 @@

Classes

Static methods

-def get_client(access_token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True) ‑> Union[AgentWebV33AgentWebV34AgentWebV35] +def get_client(access_token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, disable_logging: bool = False) ‑> Union[AgentWebV33AgentWebV34AgentWebV35]

Returns client for specific API version.

@@ -176,6 +196,8 @@

Args

verify the identity of requested hosts. Either True (default CA bundle), a path to an SSL certificate file, an ssl.SSLContext, or False (which will disable verification). Defaults to True.
+
disable_logging : bool
+
indicates if logging should be disabled.

Returns

API client object for specified version.

@@ -190,12 +212,13 @@

Raises

@staticmethod
 def get_client(
-        access_token: str,
-        version: str = stable_version,
-        base_url: str = api_url,
-        http2: bool = False,
-        proxies: dict = None,
-        verify: bool = True
+    access_token: str,
+    version: str = stable_version,
+    base_url: str = api_url,
+    http2: bool = False,
+    proxies: dict = None,
+    verify: bool = True,
+    disable_logging: bool = False,
 ) -> Union[AgentWebV33, AgentWebV34, AgentWebV35]:
     ''' Returns client for specific API version.
 
@@ -211,6 +234,7 @@ 

Raises

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version. @@ -219,10 +243,18 @@

Raises

ValueError: If the specified version does not exist. ''' client = { - '3.3': AgentWebV33(access_token, base_url, http2, proxies, verify), - '3.4': AgentWebV34(access_token, base_url, http2, proxies, verify), - '3.5': AgentWebV35(access_token, base_url, http2, proxies, verify), - '3.6': AgentWebV36(access_token, base_url, http2, proxies, verify), + '3.3': + AgentWebV33(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + AgentWebV34(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + AgentWebV35(access_token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + AgentWebV36(access_token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -262,4 +294,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/billing/api/v1.html b/docs/billing/api/v1.html index 628fa67..f0835c1 100644 --- a/docs/billing/api/v1.html +++ b/docs/billing/api/v1.html @@ -42,8 +42,10 @@

Module livechat.billing.api.v1

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v1' # direct_charge @@ -391,7 +393,7 @@

Classes

class BillingApiV1 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Billing API client class in version 1.

@@ -406,8 +408,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v1' # direct_charge @@ -1512,4 +1516,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/billing/base.html b/docs/billing/base.html index ef154fe..4cb60ef 100644 --- a/docs/billing/base.html +++ b/docs/billing/base.html @@ -48,12 +48,15 @@

Module livechat.billing.base

''' Base class that allows retrieval of client for specific Billing API version. ''' @staticmethod - def get_client(token: str, - version: str = billing_version, - base_url: str = billing_url, - http2: bool = False, - proxies: dict = None, - verify: bool = True) -> BillingApiV1: + def get_client( + token: str, + version: str = billing_version, + base_url: str = billing_url, + http2: bool = False, + proxies: dict = None, + verify: bool = True, + disable_logging: bool = False, + ) -> BillingApiV1: ''' Returns client for specific Billing API version. Args: @@ -68,6 +71,7 @@

Module livechat.billing.base

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: BillingApi: API client object for specified version. @@ -76,7 +80,9 @@

Module livechat.billing.base

ValueError: If the specified version does not exist. ''' client = { - '1': BillingApiV1(token, base_url, http2, proxies, verify), + '1': + BillingApiV1(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -106,12 +112,15 @@

Classes

''' Base class that allows retrieval of client for specific Billing API version. ''' @staticmethod - def get_client(token: str, - version: str = billing_version, - base_url: str = billing_url, - http2: bool = False, - proxies: dict = None, - verify: bool = True) -> BillingApiV1: + def get_client( + token: str, + version: str = billing_version, + base_url: str = billing_url, + http2: bool = False, + proxies: dict = None, + verify: bool = True, + disable_logging: bool = False, + ) -> BillingApiV1: ''' Returns client for specific Billing API version. Args: @@ -126,6 +135,7 @@

Classes

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: BillingApi: API client object for specified version. @@ -134,7 +144,9 @@

Classes

ValueError: If the specified version does not exist. ''' client = { - '1': BillingApiV1(token, base_url, http2, proxies, verify), + '1': + BillingApiV1(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -143,7 +155,7 @@

Classes

Static methods

-def get_client(token: str, version: str = '1', base_url: str = 'billing.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True) ‑> BillingApiV1 +def get_client(token: str, version: str = '1', base_url: str = 'billing.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, disable_logging: bool = False) ‑> BillingApiV1

Returns client for specific Billing API version.

@@ -166,6 +178,8 @@

Args

verify the identity of requested hosts. Either True (default CA bundle), a path to an SSL certificate file, an ssl.SSLContext, or False (which will disable verification). Defaults to True.
+
disable_logging : bool
+
indicates if logging should be disabled.

Returns

@@ -182,12 +196,15 @@

Raises

Expand source code
@staticmethod
-def get_client(token: str,
-               version: str = billing_version,
-               base_url: str = billing_url,
-               http2: bool = False,
-               proxies: dict = None,
-               verify: bool = True) -> BillingApiV1:
+def get_client(
+    token: str,
+    version: str = billing_version,
+    base_url: str = billing_url,
+    http2: bool = False,
+    proxies: dict = None,
+    verify: bool = True,
+    disable_logging: bool = False,
+) -> BillingApiV1:
     ''' Returns client for specific Billing API version.
 
         Args:
@@ -202,6 +219,7 @@ 

Raises

verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: BillingApi: API client object for specified version. @@ -210,7 +228,9 @@

Raises

ValueError: If the specified version does not exist. ''' client = { - '1': BillingApiV1(token, base_url, http2, proxies, verify), + '1': + BillingApiV1(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -250,4 +270,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/configuration/api/v33.html b/docs/configuration/api/v33.html index 58e579e..08eba41 100644 --- a/docs/configuration/api/v33.html +++ b/docs/configuration/api/v33.html @@ -42,8 +42,10 @@

Module livechat.configuration.api.v33

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/configuration/action' # Agents @@ -1237,7 +1239,7 @@

Classes

class ConfigurationApiV33 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Configuration API client class in version 3.3.

@@ -1252,8 +1254,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/configuration/action' # Agents @@ -5011,4 +5015,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/configuration/api/v34.html b/docs/configuration/api/v34.html index ca0d02d..bbab5e8 100644 --- a/docs/configuration/api/v34.html +++ b/docs/configuration/api/v34.html @@ -42,8 +42,10 @@

Module livechat.configuration.api.v34

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/configuration/action' # Agents @@ -1238,7 +1240,7 @@

Classes

class ConfigurationApiV34 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Configuration API client class in version 3.4.

@@ -1253,8 +1255,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/configuration/action' # Agents @@ -5014,4 +5018,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/configuration/api/v35.html b/docs/configuration/api/v35.html index dcd9627..b6704fc 100644 --- a/docs/configuration/api/v35.html +++ b/docs/configuration/api/v35.html @@ -44,8 +44,10 @@

Module livechat.configuration.api.v35

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/configuration/action' # Agents @@ -1335,9 +1337,9 @@

Module livechat.configuration.api.v35

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers) + return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers) # Batch requests @@ -1457,9 +1459,9 @@

Module livechat.configuration.api.v35

headers=headers) def batch_create_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `create_bot`. Args: @@ -1476,9 +1478,9 @@

Module livechat.configuration.api.v35

headers=headers) def batch_delete_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `delete_bot`. Args: @@ -1495,9 +1497,9 @@

Module livechat.configuration.api.v35

headers=headers) def batch_update_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `update_bot`. Args: @@ -1525,7 +1527,7 @@

Classes

class ConfigurationApiV35 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Configuration API client class in version 3.5.

@@ -1540,8 +1542,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/configuration/action' # Agents @@ -2831,9 +2835,9 @@

Classes

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers) + return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers) # Batch requests @@ -2953,9 +2957,9 @@

Classes

headers=headers) def batch_create_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `create_bot`. Args: @@ -2972,9 +2976,9 @@

Classes

headers=headers) def batch_delete_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `delete_bot`. Args: @@ -2991,9 +2995,9 @@

Classes

headers=headers) def batch_update_bots(self, - requests: list = None, - payload: dict = None, - headers: dict = None) -> httpx.Response: + requests: list = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: ''' Batch method for `update_bot`. Args: @@ -3234,9 +3238,9 @@

Returns

Expand source code
def batch_create_bots(self,
-                        requests: list = None,
-                        payload: dict = None,
-                        headers: dict = None) -> httpx.Response:
+                      requests: list = None,
+                      payload: dict = None,
+                      headers: dict = None) -> httpx.Response:
     ''' Batch method for `create_bot`.
 
         Args:
@@ -3314,9 +3318,9 @@ 

Returns

Expand source code
def batch_delete_bots(self,
-                        requests: list = None,
-                        payload: dict = None,
-                        headers: dict = None) -> httpx.Response:
+                      requests: list = None,
+                      payload: dict = None,
+                      headers: dict = None) -> httpx.Response:
     ''' Batch method for `delete_bot`.
 
         Args:
@@ -3474,9 +3478,9 @@ 

Returns

Expand source code
def batch_update_bots(self,
-                        requests: list = None,
-                        payload: dict = None,
-                        headers: dict = None) -> httpx.Response:
+                      requests: list = None,
+                      payload: dict = None,
+                      headers: dict = None) -> httpx.Response:
     ''' Batch method for `update_bot`.
 
         Args:
@@ -4581,9 +4585,9 @@ 

Returns

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers)
+ return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers)
@@ -6204,4 +6208,4 @@

pdoc 0.10.0.

- \ No newline at end of file + diff --git a/docs/configuration/api/v36.html b/docs/configuration/api/v36.html index a973d6a..60a1a48 100644 --- a/docs/configuration/api/v36.html +++ b/docs/configuration/api/v36.html @@ -36,6 +36,8 @@

Module livechat.configuration.api.v36

from livechat.utils.helpers import prepare_payload from livechat.utils.http_client import HttpClient +# pylint: disable=unused-argument,too-many-arguments,redefined-builtin,invalid-name + class ConfigurationApiV36(HttpClient): ''' Configuration API client class in version 3.6. ''' @@ -44,8 +46,10 @@

Module livechat.configuration.api.v36

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/configuration/action' # Agents @@ -1335,9 +1339,84 @@

Module livechat.configuration.api.v36

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers) + return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers) + + def reactivate_email(self, + agent_id: str = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: + ''' Reactivates email if it has been bounced. + Args: + agent_id (str): Agent ID. + payload (dict): Custom payload to be used as request's data. + It overrides all other parameters provided for the method. + headers (dict): Custom headers to be used with session headers. + They will be merged with session-level values that are set, + however, these method-level parameters will not be persisted across requests. + Returns: + httpx.Response: The Response object from `httpx` library, + which contains a server's response to an HTTP request. + ''' + if payload is None: + payload = prepare_payload(locals()) + return self.session.post(f'{self.api_url}/reactivate_email', + json=payload, + headers=headers) + + def update_company_details(self, + enrich: bool = None, + audience: str = None, + chat_purpose: str = None, + city: str = None, + company: str = None, + company_size: str = None, + country: str = None, + invoice_email: str = None, + invoice_name: str = None, + nip: str = None, + postal_code: str = None, + state: str = None, + street: str = None, + phone: str = None, + province: str = None, + url: str = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: + ''' Updates company details of the license. + Args: + enrich (bool): Whether the system should attempt to automatically + fill empty fields by searching for company's domain. + audience (str): Audience + chat_purpose (str): Chat purpose + city (str): City + company (str): Company + company_size (str): Company size + country (str): Country + invoice_email (str): Invoice email + invoice_name (str): Invoice name + nip (str): Employer Identification Number + postal_code (str): Postal code + state (str): State + street (str): Street + phone (str): Phone + province (str): Province + url (str): URL + payload (dict): Custom payload to be used as request's data. + It overrides all other parameters provided for the method. + headers (dict): Custom headers to be used with session headers. + They will be merged with session-level values that are set, + however, these method-level parameters will not be persisted across requests. + Returns: + httpx.Response: The Response object from `httpx` library, + which contains a server's response to an HTTP request. + ''' + if payload is None: + payload = prepare_payload(locals()) + return self.session.post(f'{self.api_url}/update_company_details', + json=payload, + headers=headers) # Batch requests @@ -1525,7 +1604,7 @@

Classes

class ConfigurationApiV36 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

Configuration API client class in version 3.6.

@@ -1540,8 +1619,10 @@

Classes

base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/configuration/action' # Agents @@ -2831,9 +2912,84 @@

Classes

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers) + return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers) + + def reactivate_email(self, + agent_id: str = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: + ''' Reactivates email if it has been bounced. + Args: + agent_id (str): Agent ID. + payload (dict): Custom payload to be used as request's data. + It overrides all other parameters provided for the method. + headers (dict): Custom headers to be used with session headers. + They will be merged with session-level values that are set, + however, these method-level parameters will not be persisted across requests. + Returns: + httpx.Response: The Response object from `httpx` library, + which contains a server's response to an HTTP request. + ''' + if payload is None: + payload = prepare_payload(locals()) + return self.session.post(f'{self.api_url}/reactivate_email', + json=payload, + headers=headers) + + def update_company_details(self, + enrich: bool = None, + audience: str = None, + chat_purpose: str = None, + city: str = None, + company: str = None, + company_size: str = None, + country: str = None, + invoice_email: str = None, + invoice_name: str = None, + nip: str = None, + postal_code: str = None, + state: str = None, + street: str = None, + phone: str = None, + province: str = None, + url: str = None, + payload: dict = None, + headers: dict = None) -> httpx.Response: + ''' Updates company details of the license. + Args: + enrich (bool): Whether the system should attempt to automatically + fill empty fields by searching for company's domain. + audience (str): Audience + chat_purpose (str): Chat purpose + city (str): City + company (str): Company + company_size (str): Company size + country (str): Country + invoice_email (str): Invoice email + invoice_name (str): Invoice name + nip (str): Employer Identification Number + postal_code (str): Postal code + state (str): State + street (str): Street + phone (str): Phone + province (str): Province + url (str): URL + payload (dict): Custom payload to be used as request's data. + It overrides all other parameters provided for the method. + headers (dict): Custom headers to be used with session headers. + They will be merged with session-level values that are set, + however, these method-level parameters will not be persisted across requests. + Returns: + httpx.Response: The Response object from `httpx` library, + which contains a server's response to an HTTP request. + ''' + if payload is None: + payload = prepare_payload(locals()) + return self.session.post(f'{self.api_url}/update_company_details', + json=payload, + headers=headers) # Batch requests @@ -4581,9 +4737,9 @@

Returns

''' if payload is None: payload = prepare_payload(locals()) - return self.session.get(f'{self.api_url}/get_product_source', - json=payload, - headers=headers)

+ return self.session.post(f'{self.api_url}/get_product_source', + json=payload, + headers=headers)

@@ -5222,6 +5378,56 @@

Returns

headers=headers)

+
+def reactivate_email(self, agent_id: str = None, payload: dict = None, headers: dict = None) ‑> httpx.Response +
+
+

Reactivates email if it has been bounced.

+

Args

+
+
agent_id : str
+
Agent ID.
+
payload : dict
+
Custom payload to be used as request's data. +It overrides all other parameters provided for the method.
+
headers : dict
+
Custom headers to be used with session headers. +They will be merged with session-level values that are set, +however, these method-level parameters will not be persisted across requests.
+
+

Returns

+
+
httpx.Response
+
The Response object from httpx library, +which contains a server's response to an HTTP request.
+
+
+ +Expand source code + +
def reactivate_email(self,
+                     agent_id: str = None,
+                     payload: dict = None,
+                     headers: dict = None) -> httpx.Response:
+    ''' Reactivates email if it has been bounced.
+        Args:
+            agent_id (str): Agent ID.
+            payload (dict): Custom payload to be used as request's data.
+                            It overrides all other parameters provided for the method.
+            headers (dict): Custom headers to be used with session headers.
+                            They will be merged with session-level values that are set,
+                            however, these method-level parameters will not be persisted across requests.
+        Returns:
+            httpx.Response: The Response object from `httpx` library,
+                            which contains a server's response to an HTTP request.
+    '''
+    if payload is None:
+        payload = prepare_payload(locals())
+    return self.session.post(f'{self.api_url}/reactivate_email',
+                             json=payload,
+                             headers=headers)
+
+
def register_property(self, name: str = None, owner_client_id: str = None, type: str = None, access: dict = None, description: str = None, domain: list = None, range: dict = None, default_value: str = None, payload: dict = None, headers: dict = None) ‑> httpx.Response
@@ -5884,6 +6090,118 @@

Returns

headers=headers)

+
+def update_company_details(self, enrich: bool = None, audience: str = None, chat_purpose: str = None, city: str = None, company: str = None, company_size: str = None, country: str = None, invoice_email: str = None, invoice_name: str = None, nip: str = None, postal_code: str = None, state: str = None, street: str = None, phone: str = None, province: str = None, url: str = None, payload: dict = None, headers: dict = None) ‑> httpx.Response +
+
+

Updates company details of the license.

+

Args

+
+
enrich : bool
+
Whether the system should attempt to automatically +fill empty fields by searching for company's domain.
+
audience : str
+
Audience
+
chat_purpose : str
+
Chat purpose
+
city : str
+
City
+
company : str
+
Company
+
company_size : str
+
Company size
+
country : str
+
Country
+
invoice_email : str
+
Invoice email
+
invoice_name : str
+
Invoice name
+
nip : str
+
Employer Identification Number
+
postal_code : str
+
Postal code
+
state : str
+
State
+
street : str
+
Street
+
phone : str
+
Phone
+
province : str
+
Province
+
url : str
+
URL
+
payload : dict
+
Custom payload to be used as request's data. +It overrides all other parameters provided for the method.
+
headers : dict
+
Custom headers to be used with session headers. +They will be merged with session-level values that are set, +however, these method-level parameters will not be persisted across requests.
+
+

Returns

+
+
httpx.Response
+
The Response object from httpx library, +which contains a server's response to an HTTP request.
+
+
+ +Expand source code + +
def update_company_details(self,
+                           enrich: bool = None,
+                           audience: str = None,
+                           chat_purpose: str = None,
+                           city: str = None,
+                           company: str = None,
+                           company_size: str = None,
+                           country: str = None,
+                           invoice_email: str = None,
+                           invoice_name: str = None,
+                           nip: str = None,
+                           postal_code: str = None,
+                           state: str = None,
+                           street: str = None,
+                           phone: str = None,
+                           province: str = None,
+                           url: str = None,
+                           payload: dict = None,
+                           headers: dict = None) -> httpx.Response:
+    ''' Updates company details of the license.
+        Args:
+            enrich (bool): Whether the system should attempt to automatically
+                           fill empty fields by searching for company's domain.
+            audience (str): Audience
+            chat_purpose (str): Chat purpose
+            city (str): City
+            company (str): Company
+            company_size (str): Company size
+            country (str): Country
+            invoice_email (str): Invoice email
+            invoice_name (str): Invoice name
+            nip (str): Employer Identification Number
+            postal_code (str): Postal code
+            state (str): State
+            street (str): Street
+            phone (str): Phone
+            province (str): Province
+            url (str): URL
+            payload (dict): Custom payload to be used as request's data.
+                            It overrides all other parameters provided for the method.
+            headers (dict): Custom headers to be used with session headers.
+                            They will be merged with session-level values that are set,
+                            however, these method-level parameters will not be persisted across requests.
+        Returns:
+            httpx.Response: The Response object from `httpx` library,
+                            which contains a server's response to an HTTP request.
+    '''
+    if payload is None:
+        payload = prepare_payload(locals())
+    return self.session.post(f'{self.api_url}/update_company_details',
+                             json=payload,
+                             headers=headers)
+
+
def update_group(self, id: int = None, name: str = None, language_code: str = None, agent_priorities: dict = None, payload: dict = None, headers: dict = None) ‑> httpx.Response
@@ -6179,6 +6497,7 @@

list_webhook_names
  • list_webhooks
  • publish_property
  • +
  • reactivate_email
  • register_property
  • register_webhook
  • request_agent_unsuspension
  • @@ -6189,6 +6508,7 @@

    update_agent
  • update_auto_access
  • update_bot
  • +
  • update_company_details
  • update_group
  • update_group_properties
  • update_license_properties
  • @@ -6204,4 +6524,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/configuration/base.html b/docs/configuration/base.html index 104abce..bbd3368 100644 --- a/docs/configuration/base.html +++ b/docs/configuration/base.html @@ -57,7 +57,8 @@

    Module livechat.configuration.base

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ConfigurationApiV33, ConfigurationApiV34, ConfigurationApiV35]: ''' Returns client for specific Configuration API version. @@ -73,6 +74,7 @@

    Module livechat.configuration.base

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ConfigurationApi: API client object for specified version. @@ -81,14 +83,18 @@

    Module livechat.configuration.base

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ConfigurationApiV33(token, base_url, http2, proxies, - verify), - '3.4': ConfigurationApiV34(token, base_url, http2, proxies, - verify), - '3.5': ConfigurationApiV35(token, base_url, http2, proxies, - verify), - '3.6': ConfigurationApiV36(token, base_url, http2, proxies, - verify), + '3.3': + ConfigurationApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ConfigurationApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ConfigurationApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ConfigurationApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -124,7 +130,8 @@

    Classes

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ConfigurationApiV33, ConfigurationApiV34, ConfigurationApiV35]: ''' Returns client for specific Configuration API version. @@ -140,6 +147,7 @@

    Classes

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ConfigurationApi: API client object for specified version. @@ -148,14 +156,18 @@

    Classes

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ConfigurationApiV33(token, base_url, http2, proxies, - verify), - '3.4': ConfigurationApiV34(token, base_url, http2, proxies, - verify), - '3.5': ConfigurationApiV35(token, base_url, http2, proxies, - verify), - '3.6': ConfigurationApiV36(token, base_url, http2, proxies, - verify), + '3.3': + ConfigurationApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ConfigurationApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ConfigurationApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ConfigurationApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -164,7 +176,7 @@

    Classes

    Static methods

    -def get_client(token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True) ‑> Union[ConfigurationApiV33ConfigurationApiV34ConfigurationApiV35] +def get_client(token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, disable_logging: bool = False) ‑> Union[ConfigurationApiV33ConfigurationApiV34ConfigurationApiV35]

    Returns client for specific Configuration API version.

    @@ -187,6 +199,8 @@

    Args

    verify the identity of requested hosts. Either True (default CA bundle), a path to an SSL certificate file, an ssl.SSLContext, or False (which will disable verification). Defaults to True.
    +
    disable_logging : bool
    +
    indicates if logging should be disabled.

    Returns

    @@ -209,7 +223,8 @@

    Raises

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ConfigurationApiV33, ConfigurationApiV34, ConfigurationApiV35]: ''' Returns client for specific Configuration API version. @@ -225,6 +240,7 @@

    Raises

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ConfigurationApi: API client object for specified version. @@ -233,14 +249,18 @@

    Raises

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ConfigurationApiV33(token, base_url, http2, proxies, - verify), - '3.4': ConfigurationApiV34(token, base_url, http2, proxies, - verify), - '3.5': ConfigurationApiV35(token, base_url, http2, proxies, - verify), - '3.6': ConfigurationApiV36(token, base_url, http2, proxies, - verify), + '3.3': + ConfigurationApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ConfigurationApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ConfigurationApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ConfigurationApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -280,4 +300,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/customer/web/api/v33.html b/docs/customer/web/api/v33.html index 5a5ef3b..90f3091 100644 --- a/docs/customer/web/api/v33.html +++ b/docs/customer/web/api/v33.html @@ -46,9 +46,11 @@

    Module livechat.customer.web.api.v33

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -639,8 +641,8 @@

    Module livechat.customer.web.api.v33

    params['name'] = name params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -668,8 +670,8 @@

    Module livechat.customer.web.api.v33

    params['id'] = str(group_id) params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -1002,7 +1004,7 @@

    Classes

    class CustomerWebV33 -(license_id: int, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(license_id: int, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Customer Web API Class containing methods in version 3.3.

    @@ -1018,9 +1020,11 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -1611,8 +1615,8 @@

    Classes

    params['name'] = name params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -1640,8 +1644,8 @@

    Classes

    params['id'] = str(group_id) params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -2944,8 +2948,8 @@

    Returns

    params['id'] = str(group_id) params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)
    @@ -3056,8 +3060,8 @@

    Returns

    params['name'] = name params['license_id'] = self.license_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)

    @@ -3970,4 +3974,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/customer/web/api/v34.html b/docs/customer/web/api/v34.html index 0d00d55..af68cb1 100644 --- a/docs/customer/web/api/v34.html +++ b/docs/customer/web/api/v34.html @@ -46,9 +46,11 @@

    Module livechat.customer.web.api.v34

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -639,8 +641,8 @@

    Module livechat.customer.web.api.v34

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -668,8 +670,8 @@

    Module livechat.customer.web.api.v34

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -1002,7 +1004,7 @@

    Classes

    class CustomerWebV34 -(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Customer Web API Class containing methods in version 3.4.

    @@ -1018,9 +1020,11 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -1611,8 +1615,8 @@

    Classes

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -1640,8 +1644,8 @@

    Classes

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -2944,8 +2948,8 @@

    Returns

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)
    @@ -3056,8 +3060,8 @@

    Returns

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)
    @@ -3970,4 +3974,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/customer/web/api/v35.html b/docs/customer/web/api/v35.html index b65821a..bf56dca 100644 --- a/docs/customer/web/api/v35.html +++ b/docs/customer/web/api/v35.html @@ -46,9 +46,11 @@

    Module livechat.customer.web.api.v35

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -639,8 +641,8 @@

    Module livechat.customer.web.api.v35

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -668,8 +670,8 @@

    Module livechat.customer.web.api.v35

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -1002,7 +1004,7 @@

    Classes

    class CustomerWebV35 -(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Customer Web API Class containing methods in version 3.5.

    @@ -1018,9 +1020,11 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -1611,8 +1615,8 @@

    Classes

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers) + params=params, + headers=headers) def list_group_properties(self, group_id: int = None, @@ -1640,8 +1644,8 @@

    Classes

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers) + params=params, + headers=headers) # Customers @@ -2944,8 +2948,8 @@

    Returns

    params['id'] = str(group_id) params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_group_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)
    @@ -3056,8 +3060,8 @@

    Returns

    params['name'] = name params['organization_id'] = self.organization_id return self.session.get(f'{self.api_url}/list_license_properties', - params=params, - headers=headers)
    + params=params, + headers=headers)
    @@ -3970,4 +3974,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/customer/web/api/v36.html b/docs/customer/web/api/v36.html index 1ef0084..6763f9e 100644 --- a/docs/customer/web/api/v36.html +++ b/docs/customer/web/api/v36.html @@ -46,9 +46,11 @@

    Module livechat.customer.web.api.v36

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -1002,7 +1004,7 @@

    Classes

    class CustomerWebV36 -(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(organization_id: str, access_token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Customer Web API Class containing methods in version 3.6.

    @@ -1018,9 +1020,11 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): + verify: bool = True, + disable_logging: bool = False): if all([access_token, isinstance(access_token, str)]): - super().__init__(access_token, base_url, http2, proxies, verify) + super().__init__(access_token, base_url, http2, proxies, verify, + disable_logging) else: raise ValueError( 'Incorrect or missing `access_token` argument (should be of type str.)' @@ -3970,4 +3974,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/customer/web/base.html b/docs/customer/web/base.html index 1842b8b..c41b7dd 100644 --- a/docs/customer/web/base.html +++ b/docs/customer/web/base.html @@ -57,7 +57,8 @@

    Module livechat.customer.web.base

    http2: bool = False, proxies: dict = None, verify: bool = True, - organization_id: str = None + organization_id: str = None, + disable_logging: bool = False, ) -> Union[CustomerWebV33, CustomerWebV34, CustomerWebV35]: ''' Returns client for specific API version. @@ -75,6 +76,7 @@

    Module livechat.customer.web.base

    a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. organization_id (str): Organization ID, replaced license ID in v3.4. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version based on @@ -96,7 +98,8 @@

    Module livechat.customer.web.base

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.4': { 'organization_id': organization_id, @@ -104,7 +107,8 @@

    Module livechat.customer.web.base

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.5': { 'organization_id': organization_id, @@ -112,7 +116,8 @@

    Module livechat.customer.web.base

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.6': { 'organization_id': organization_id, @@ -120,7 +125,8 @@

    Module livechat.customer.web.base

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, }.get(version) if client: @@ -159,7 +165,8 @@

    Classes

    http2: bool = False, proxies: dict = None, verify: bool = True, - organization_id: str = None + organization_id: str = None, + disable_logging: bool = False, ) -> Union[CustomerWebV33, CustomerWebV34, CustomerWebV35]: ''' Returns client for specific API version. @@ -177,6 +184,7 @@

    Classes

    a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. organization_id (str): Organization ID, replaced license ID in v3.4. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version based on @@ -198,7 +206,8 @@

    Classes

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.4': { 'organization_id': organization_id, @@ -206,7 +215,8 @@

    Classes

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.5': { 'organization_id': organization_id, @@ -214,7 +224,8 @@

    Classes

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.6': { 'organization_id': organization_id, @@ -222,7 +233,8 @@

    Classes

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, }.get(version) if client: @@ -232,7 +244,7 @@

    Classes

    Static methods

    -def get_client(license_id: int = None, access_token: str = None, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, organization_id: str = None) ‑> Union[CustomerWebV33CustomerWebV34CustomerWebV35] +def get_client(license_id: int = None, access_token: str = None, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, organization_id: str = None, disable_logging: bool = False) ‑> Union[CustomerWebV33CustomerWebV34CustomerWebV35]

    Returns client for specific API version.

    @@ -259,6 +271,8 @@

    Args

    (which will disable verification). Defaults to True.
    organization_id : str
    Organization ID, replaced license ID in v3.4.
    +
    disable_logging : bool
    +
    indicates if logging should be disabled.

    Returns

    API client object for specified version based on @@ -281,7 +295,8 @@

    Raises

    http2: bool = False, proxies: dict = None, verify: bool = True, - organization_id: str = None + organization_id: str = None, + disable_logging: bool = False, ) -> Union[CustomerWebV33, CustomerWebV34, CustomerWebV35]: ''' Returns client for specific API version. @@ -299,6 +314,7 @@

    Raises

    a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. organization_id (str): Organization ID, replaced license ID in v3.4. + disable_logging (bool): indicates if logging should be disabled. Returns: API client object for specified version based on @@ -320,7 +336,8 @@

    Raises

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.4': { 'organization_id': organization_id, @@ -328,7 +345,8 @@

    Raises

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.5': { 'organization_id': organization_id, @@ -336,7 +354,8 @@

    Raises

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, '3.6': { 'organization_id': organization_id, @@ -344,7 +363,8 @@

    Raises

    'base_url': base_url, 'http2': http2, 'proxies': proxies, - 'verify': verify + 'verify': verify, + 'disable_logging': disable_logging }, }.get(version) if client: @@ -385,4 +405,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/reports/api/v33.html b/docs/reports/api/v33.html index a25787c..8bbee29 100644 --- a/docs/reports/api/v33.html +++ b/docs/reports/api/v33.html @@ -42,8 +42,10 @@

    Module livechat.reports.api.v33

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/reports' # Chats @@ -170,7 +172,7 @@

    Classes

    class ReportsApiV33 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Reports API client class in version 3.3.

    @@ -185,8 +187,10 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.3/reports' # Chats @@ -569,4 +573,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/reports/api/v34.html b/docs/reports/api/v34.html index c0ad3e7..916d4bd 100644 --- a/docs/reports/api/v34.html +++ b/docs/reports/api/v34.html @@ -42,8 +42,10 @@

    Module livechat.reports.api.v34

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/reports' # Chats @@ -420,7 +422,7 @@

    Classes

    class ReportsApiV34 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Reports API client class in version 3.4.

    @@ -435,8 +437,10 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.4/reports' # Chats @@ -1615,4 +1619,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/reports/api/v35.html b/docs/reports/api/v35.html index 4ce33bd..1c7d79e 100644 --- a/docs/reports/api/v35.html +++ b/docs/reports/api/v35.html @@ -42,8 +42,10 @@

    Module livechat.reports.api.v35

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/reports' # Chats @@ -451,7 +453,7 @@

    Classes

    class ReportsApiV35 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Reports API client class in version 3.5.

    @@ -466,8 +468,10 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.5/reports' # Chats @@ -1738,4 +1742,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/reports/api/v36.html b/docs/reports/api/v36.html index dc5408b..d4dbf10 100644 --- a/docs/reports/api/v36.html +++ b/docs/reports/api/v36.html @@ -42,8 +42,10 @@

    Module livechat.reports.api.v36

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/reports' # Chats @@ -451,7 +453,7 @@

    Classes

    class ReportsApiV36 -(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True) +(token: str, base_url: str, http2: bool, proxies=None, verify: bool = True, disable_logging: bool = False)

    Reports API client class in version 3.6.

    @@ -466,8 +468,10 @@

    Classes

    base_url: str, http2: bool, proxies=None, - verify: bool = True): - super().__init__(token, base_url, http2, proxies, verify) + verify: bool = True, + disable_logging: bool = False): + super().__init__(token, base_url, http2, proxies, verify, + disable_logging) self.api_url = f'https://{base_url}/v3.6/reports' # Chats @@ -1738,4 +1742,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/docs/reports/base.html b/docs/reports/base.html index 0af9dfb..981ffe8 100644 --- a/docs/reports/base.html +++ b/docs/reports/base.html @@ -58,7 +58,8 @@

    Module livechat.reports.base

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ReportsApiV33, ReportsApiV34, ReportsApiV35]: ''' Returns client for specific Reports API version. @@ -74,6 +75,7 @@

    Module livechat.reports.base

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ReportsApi: API client object for specified version. @@ -82,10 +84,18 @@

    Module livechat.reports.base

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ReportsApiV33(token, base_url, http2, proxies, verify), - '3.4': ReportsApiV34(token, base_url, http2, proxies, verify), - '3.5': ReportsApiV35(token, base_url, http2, proxies, verify), - '3.6': ReportsApiV36(token, base_url, http2, proxies, verify), + '3.3': + ReportsApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ReportsApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ReportsApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ReportsApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -121,7 +131,8 @@

    Classes

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ReportsApiV33, ReportsApiV34, ReportsApiV35]: ''' Returns client for specific Reports API version. @@ -137,6 +148,7 @@

    Classes

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ReportsApi: API client object for specified version. @@ -145,10 +157,18 @@

    Classes

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ReportsApiV33(token, base_url, http2, proxies, verify), - '3.4': ReportsApiV34(token, base_url, http2, proxies, verify), - '3.5': ReportsApiV35(token, base_url, http2, proxies, verify), - '3.6': ReportsApiV36(token, base_url, http2, proxies, verify), + '3.3': + ReportsApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ReportsApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ReportsApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ReportsApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -157,7 +177,7 @@

    Classes

    Static methods

    -def get_client(token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True) ‑> Union[ReportsApiV33ReportsApiV34ReportsApiV35] +def get_client(token: str, version: str = '3.5', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True, disable_logging: bool = False) ‑> Union[ReportsApiV33ReportsApiV34ReportsApiV35]

    Returns client for specific Reports API version.

    @@ -180,6 +200,8 @@

    Args

    verify the identity of requested hosts. Either True (default CA bundle), a path to an SSL certificate file, an ssl.SSLContext, or False (which will disable verification). Defaults to True.
    +
    disable_logging : bool
    +
    indicates if logging should be disabled.

    Returns

    @@ -202,7 +224,8 @@

    Raises

    base_url: str = api_url, http2: bool = False, proxies: dict = None, - verify: bool = True + verify: bool = True, + disable_logging: bool = False, ) -> Union[ReportsApiV33, ReportsApiV34, ReportsApiV35]: ''' Returns client for specific Reports API version. @@ -218,6 +241,7 @@

    Raises

    verify the identity of requested hosts. Either `True` (default CA bundle), a path to an SSL certificate file, an `ssl.SSLContext`, or `False` (which will disable verification). Defaults to `True`. + disable_logging (bool): indicates if logging should be disabled. Returns: ReportsApi: API client object for specified version. @@ -226,10 +250,18 @@

    Raises

    ValueError: If the specified version does not exist. ''' client = { - '3.3': ReportsApiV33(token, base_url, http2, proxies, verify), - '3.4': ReportsApiV34(token, base_url, http2, proxies, verify), - '3.5': ReportsApiV35(token, base_url, http2, proxies, verify), - '3.6': ReportsApiV36(token, base_url, http2, proxies, verify), + '3.3': + ReportsApiV33(token, base_url, http2, proxies, verify, + disable_logging), + '3.4': + ReportsApiV34(token, base_url, http2, proxies, verify, + disable_logging), + '3.5': + ReportsApiV35(token, base_url, http2, proxies, verify, + disable_logging), + '3.6': + ReportsApiV36(token, base_url, http2, proxies, verify, + disable_logging), }.get(version) if not client: raise ValueError('Provided version does not exist.') @@ -269,4 +301,4 @@

    pdoc 0.10.0.

    - \ No newline at end of file + diff --git a/setup.cfg b/setup.cfg index 44906c0..272db4e 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,6 +1,6 @@ [metadata] name = lc-sdk-python -version = 0.3.6 +version = 0.3.7 description = Package which lets to work with LiveChat API. long_description = file: README.md long_description_content_type = text/markdown