diff --git a/changelog.md b/changelog.md index b6a7e2b..8f7d65c 100644 --- a/changelog.md +++ b/changelog.md @@ -5,6 +5,7 @@ All notable changes to this project will be documented in this file. ### Added - New methods in configuration-api v3.5, v3.6 for bot management: `create_bot_template`, `delete_bot_template`, `update_bot_template`, `list_bot_templates`, `issue_bot_token`, `reset_bot_secret`, `reset_bot_template_secret`. +- New `get_company_details` method in configuration-api v3.6. ### Changed - Updated outdated packages. diff --git a/livechat/configuration/api/v36.py b/livechat/configuration/api/v36.py index 1733ed6..a7d278d 100644 --- a/livechat/configuration/api/v36.py +++ b/livechat/configuration/api/v36.py @@ -1622,6 +1622,26 @@ def update_company_details(self, json=payload, headers=headers) + def get_company_details(self, + payload: dict = None, + headers: dict = None) -> httpx.Response: + ''' Gets company details of the license. + Args: + 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}/get_company_details', + json=payload, + headers=headers) + # Batch requests