Skip to content

Release lc-sdk-python v0.3.4 #91

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Change Log
All notable changes to this project will be documented in this file.

## [0.3.4] - TBA
## [0.3.4] - 2022-10-26

### Added
- New methods in configuration-api v3.5: `list_groups_properties`, `get_product_source`.
Expand All @@ -11,14 +11,12 @@ All notable changes to this project will be documented in this file.

### Changed
- Renamed method `tag_chat_usage` to `chat_usage` in reports-api v3.5.
- Internal documentation main page and structure.

### Bugfixes
- Fix paths for `response_time` and `first_response_time` methods in reports-api v3.4/v3.5 classes.
- Fix `upload_file` method in agent-api v3.4/v3.5 classes.

### Changed
- Internal documentation main page and structure.

### Removed
- Support for `list_group_properties`, `get_license_id` and `get_organization_id` method in configuration-api v3.5 class.
- Support for `webhook` parameter in `create_bot` and `update_bot` methods in configuration-api v3.3/v3.4/v3.5 classes.
Expand Down
6 changes: 3 additions & 3 deletions docs/agent/web/api/v34.html
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ <h1 class="title">Module <code>livechat.agent.web.api.v34</code></h1>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)

def send_rich_message_postback(self,
Expand Down Expand Up @@ -1551,7 +1551,7 @@ <h2 class="section-title" id="header-classes">Classes</h2>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)

def send_rich_message_postback(self,
Expand Down Expand Up @@ -4384,7 +4384,7 @@ <h2 id="returns">Returns</h2>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)</code></pre>
</details>
</dd>
Expand Down
6 changes: 3 additions & 3 deletions docs/agent/web/api/v35.html
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ <h1 class="title">Module <code>livechat.agent.web.api.v35</code></h1>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)

def send_rich_message_postback(self,
Expand Down Expand Up @@ -1551,7 +1551,7 @@ <h2 class="section-title" id="header-classes">Classes</h2>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)

def send_rich_message_postback(self,
Expand Down Expand Up @@ -4384,7 +4384,7 @@ <h2 id="returns">Returns</h2>
httpx.Response: The Response object from `httpx` library,
which contains a server’s response to an HTTP request. &#39;&#39;&#39;
return self.session.post(f&#39;{self.api_url}/upload_file&#39;,
content=file.read(),
file=file,
headers=headers)</code></pre>
</details>
</dd>
Expand Down
54 changes: 41 additions & 13 deletions docs/agent/web/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,9 @@ <h1 class="title">Module <code>livechat.agent.web.base</code></h1>
access_token: str,
version: str = stable_version,
base_url: str = api_url,
http2: bool = False
http2: bool = False,
proxies: dict = None,
verify: bool = True
) -&gt; Union[AgentWebV33, AgentWebV34, AgentWebV35]:
&#39;&#39;&#39; Returns client for specific API version.

Expand All @@ -62,6 +64,11 @@ <h1 class="title">Module <code>livechat.agent.web.base</code></h1>
base_url (str): API&#39;s base url. Defaults to API&#39;s production URL.
http2 (bool): A boolean indicating if HTTP/2 support should be
enabled. Defaults to `False`.
proxies (dict): A dictionary mapping proxy keys to proxy URLs.
verify (bool): SSL certificates (a.k.a CA bundle) used to
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`.

Returns:
API client object for specified version.
Expand All @@ -70,9 +77,9 @@ <h1 class="title">Module <code>livechat.agent.web.base</code></h1>
ValueError: If the specified version does not exist.
&#39;&#39;&#39;
client = {
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2),
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2, proxies, verify),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2, proxies, verify),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2, proxies, verify),
}.get(version)
if not client:
raise ValueError(&#39;Provided version does not exist.&#39;)
Expand Down Expand Up @@ -106,7 +113,9 @@ <h2 class="section-title" id="header-classes">Classes</h2>
access_token: str,
version: str = stable_version,
base_url: str = api_url,
http2: bool = False
http2: bool = False,
proxies: dict = None,
verify: bool = True
) -&gt; Union[AgentWebV33, AgentWebV34, AgentWebV35]:
&#39;&#39;&#39; Returns client for specific API version.

Expand All @@ -117,6 +126,11 @@ <h2 class="section-title" id="header-classes">Classes</h2>
base_url (str): API&#39;s base url. Defaults to API&#39;s production URL.
http2 (bool): A boolean indicating if HTTP/2 support should be
enabled. Defaults to `False`.
proxies (dict): A dictionary mapping proxy keys to proxy URLs.
verify (bool): SSL certificates (a.k.a CA bundle) used to
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`.

Returns:
API client object for specified version.
Expand All @@ -125,9 +139,9 @@ <h2 class="section-title" id="header-classes">Classes</h2>
ValueError: If the specified version does not exist.
&#39;&#39;&#39;
client = {
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2),
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2, proxies, verify),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2, proxies, verify),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2, proxies, verify),
}.get(version)
if not client:
raise ValueError(&#39;Provided version does not exist.&#39;)
Expand All @@ -136,7 +150,7 @@ <h2 class="section-title" id="header-classes">Classes</h2>
<h3>Static methods</h3>
<dl>
<dt id="livechat.agent.web.base.AgentWeb.get_client"><code class="name flex">
<span>def <span class="ident">get_client</span></span>(<span>access_token: str, version: str = '3.4', base_url: str = 'api.livechatinc.com', http2: bool = False) ‑> Union[<a title="livechat.agent.web.api.v33.AgentWebV33" href="api/v33.html#livechat.agent.web.api.v33.AgentWebV33">AgentWebV33</a>, <a title="livechat.agent.web.api.v34.AgentWebV34" href="api/v34.html#livechat.agent.web.api.v34.AgentWebV34">AgentWebV34</a>, <a title="livechat.agent.web.api.v35.AgentWebV35" href="api/v35.html#livechat.agent.web.api.v35.AgentWebV35">AgentWebV35</a>]</span>
<span>def <span class="ident">get_client</span></span>(<span>access_token: str, version: str = '3.4', base_url: str = 'api.livechatinc.com', http2: bool = False, proxies: dict = None, verify: bool = True) ‑> Union[<a title="livechat.agent.web.api.v33.AgentWebV33" href="api/v33.html#livechat.agent.web.api.v33.AgentWebV33">AgentWebV33</a>, <a title="livechat.agent.web.api.v34.AgentWebV34" href="api/v34.html#livechat.agent.web.api.v34.AgentWebV34">AgentWebV34</a>, <a title="livechat.agent.web.api.v35.AgentWebV35" href="api/v35.html#livechat.agent.web.api.v35.AgentWebV35">AgentWebV35</a>]</span>
</code></dt>
<dd>
<div class="desc"><p>Returns client for specific API version.</p>
Expand All @@ -152,6 +166,13 @@ <h2 id="args">Args</h2>
<dt><strong><code>http2</code></strong> :&ensp;<code>bool</code></dt>
<dd>A boolean indicating if HTTP/2 support should be
enabled. Defaults to <code>False</code>.</dd>
<dt><strong><code>proxies</code></strong> :&ensp;<code>dict</code></dt>
<dd>A dictionary mapping proxy keys to proxy URLs.</dd>
<dt><strong><code>verify</code></strong> :&ensp;<code>bool</code></dt>
<dd>SSL certificates (a.k.a CA bundle) used to
verify the identity of requested hosts. Either <code>True</code> (default CA bundle),
a path to an SSL certificate file, an <code>ssl.SSLContext</code>, or <code>False</code>
(which will disable verification). Defaults to <code>True</code>.</dd>
</dl>
<h2 id="returns">Returns</h2>
<p>API client object for specified version.</p>
Expand All @@ -169,7 +190,9 @@ <h2 id="raises">Raises</h2>
access_token: str,
version: str = stable_version,
base_url: str = api_url,
http2: bool = False
http2: bool = False,
proxies: dict = None,
verify: bool = True
) -&gt; Union[AgentWebV33, AgentWebV34, AgentWebV35]:
&#39;&#39;&#39; Returns client for specific API version.

Expand All @@ -180,6 +203,11 @@ <h2 id="raises">Raises</h2>
base_url (str): API&#39;s base url. Defaults to API&#39;s production URL.
http2 (bool): A boolean indicating if HTTP/2 support should be
enabled. Defaults to `False`.
proxies (dict): A dictionary mapping proxy keys to proxy URLs.
verify (bool): SSL certificates (a.k.a CA bundle) used to
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`.

Returns:
API client object for specified version.
Expand All @@ -188,9 +216,9 @@ <h2 id="raises">Raises</h2>
ValueError: If the specified version does not exist.
&#39;&#39;&#39;
client = {
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2),
&#39;3.3&#39;: AgentWebV33(access_token, base_url, http2, proxies, verify),
&#39;3.4&#39;: AgentWebV34(access_token, base_url, http2, proxies, verify),
&#39;3.5&#39;: AgentWebV35(access_token, base_url, http2, proxies, verify),
}.get(version)
if not client:
raise ValueError(&#39;Provided version does not exist.&#39;)
Expand Down
Loading