Skip to content

Commit b6d1656

Browse files
author
PureCloud Jenkins
committed
79.1.0
1 parent 81a4ef9 commit b6d1656

9 files changed

Lines changed: 44 additions & 11 deletions

File tree

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ If connecting to a proxy server, set the the address of your proxy server as fol
7272
PureCloudPlatformClientV2.configuration.proxy = 'YOUR_PROXY_URL'
7373
```
7474

75+
If your proxy server requires authentication, set the username and password as follows:
76+
77+
```{"language":"python"}
78+
PureCloudPlatformClientV2.configuration.proxy_username = 'YOUR_PROXY_USERNAME'
79+
PureCloudPlatformClientV2.configuration.proxy_password = 'YOUR_PROXY_PASSWORD'
80+
```
81+
7582
The Python SDK uses `urllib3.ProxyManager` to make requests when `proxy` is given.
7683

7784
### Making Requests

build/PureCloudPlatformClientV2/api_client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ def __call_api(self, resource_path, method,
185185
header_params['Cookie'] = self.cookie
186186
if header_params:
187187
header_params = self.sanitize_for_serialization(header_params)
188-
header_params['purecloud-sdk'] = '79.0.1'
188+
header_params['purecloud-sdk'] = '79.1.0'
189189

190190
# path parameters
191191
if path_params:

build/PureCloudPlatformClientV2/configuration.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,12 @@ def __init__(self):
104104
# proxy
105105
self.proxy = None
106106

107+
# proxy username
108+
self.proxy_username = None
109+
110+
# proxy password
111+
self.proxy_password = None
112+
107113
@property
108114
def logger_file(self):
109115
"""
@@ -249,5 +255,5 @@ def to_debug_report(self):
249255
"OS: {env}\n"\
250256
"Python Version: {pyversion}\n"\
251257
"Version of the API: v2\n"\
252-
"SDK Package Version: 79.0.1".\
258+
"SDK Package Version: 79.1.0".\
253259
format(env=sys.platform, pyversion=sys.version)

build/PureCloudPlatformClientV2/rest.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,18 +97,24 @@ def __init__(self, pools_size=4):
9797
# key file
9898
key_file = Configuration().key_file
9999

100-
# proxy
100+
# proxy
101101
proxy = Configuration().proxy
102+
proxy_username = Configuration().proxy_username
103+
proxy_password = Configuration().proxy_password
102104

103105
# https pool manager
104106
if proxy:
107+
headers = None
108+
if proxy_username and proxy_password:
109+
headers = urllib3.make_headers(proxy_basic_auth=proxy_username + ':' + proxy_password)
105110
self.pool_manager = urllib3.ProxyManager(
106111
num_pools=pools_size,
107112
cert_reqs=cert_reqs,
108113
ca_certs=ca_certs,
109114
cert_file=cert_file,
110115
key_file=key_file,
111-
proxy_url=proxy
116+
proxy_url=proxy,
117+
proxy_headers=headers
112118
)
113119
else:
114120
self.pool_manager = urllib3.PoolManager(

build/README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ If connecting to a proxy server, set the the address of your proxy server as fol
7272
PureCloudPlatformClientV2.configuration.proxy = 'YOUR_PROXY_URL'
7373
```
7474

75+
If your proxy server requires authentication, set the username and password as follows:
76+
77+
```{"language":"python"}
78+
PureCloudPlatformClientV2.configuration.proxy_username = 'YOUR_PROXY_USERNAME'
79+
PureCloudPlatformClientV2.configuration.proxy_password = 'YOUR_PROXY_PASSWORD'
80+
```
81+
7582
The Python SDK uses `urllib3.ProxyManager` to make requests when `proxy` is given.
7683

7784
### Making Requests

build/docs/index.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,13 @@ If connecting to a proxy server, set the the address of your proxy server as fol
7272
PureCloudPlatformClientV2.configuration.proxy = 'YOUR_PROXY_URL'
7373
```
7474

75+
If your proxy server requires authentication, set the username and password as follows:
76+
77+
```{"language":"python"}
78+
PureCloudPlatformClientV2.configuration.proxy_username = 'YOUR_PROXY_USERNAME'
79+
PureCloudPlatformClientV2.configuration.proxy_password = 'YOUR_PROXY_PASSWORD'
80+
```
81+
7582
The Python SDK uses `urllib3.ProxyManager` to make requests when `proxy` is given.
7683

7784
### Making Requests

build/setup.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from setuptools import setup, find_packages
55

66
NAME = "PureCloudPlatformClientV2"
7-
VERSION = "79.0.1"
7+
VERSION = "79.1.0"
88

99

1010

@@ -19,7 +19,7 @@
1919

2020
setup(
2121
name="PureCloudPlatformClientV2",
22-
version="79.0.1",
22+
version="79.1.0",
2323
description="PureCloud Platform API SDK",
2424
author="Genesys Developer Evangelists",
2525
author_email="DeveloperEvangelists@Genesys.com",

releaseNotes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Platform API version: 3829
33

44
# SDK Changes
55

6-
* Fixed region host enums for new regions
6+
* API-4992 Add authenticated proxy support
77

88
# Major Changes (0 changes)
99

version.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
22
"major": 79,
3-
"minor": 0,
4-
"point": 1,
3+
"minor": 1,
4+
"point": 0,
55
"prerelease": "",
66
"apiVersion": 0,
7-
"display": "79.0.1",
8-
"displayFull": "79.0.1"
7+
"display": "79.1.0",
8+
"displayFull": "79.1.0"
99
}

0 commit comments

Comments
 (0)