Skip to content

Commit ad624bb

Browse files
committed
feat(compare comply): Basic auth support for compare and comply
1 parent 9d9a85a commit ad624bb

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

ibm_watson/compare_comply_v1.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ def __init__(
4848
icp4d_access_token=None,
4949
icp4d_url=None,
5050
authentication_type=None,
51+
username=None,
52+
password=None,
5153
):
5254
"""
5355
Construct a new client for the Compare Comply service.
@@ -67,6 +69,18 @@ def __init__(
6769
"https://gateway.watsonplatform.net/compare-comply/api/compare-comply/api").
6870
The base url may differ between IBM Cloud regions.
6971
72+
:param str username: The username used to authenticate with the service.
73+
Username and password credentials are only required to run your
74+
application locally or outside of IBM Cloud. When running on
75+
IBM Cloud, the credentials will be automatically loaded from the
76+
`VCAP_SERVICES` environment variable.
77+
78+
:param str password: The password used to authenticate with the service.
79+
Username and password credentials are only required to run your
80+
application locally or outside of IBM Cloud. When running on
81+
IBM Cloud, the credentials will be automatically loaded from the
82+
`VCAP_SERVICES` environment variable.
83+
7084
:param str iam_apikey: An API key that can be used to request IAM tokens. If
7185
this API key is provided, the SDK will manage the token and handle the
7286
refreshing.
@@ -99,6 +113,8 @@ def __init__(
99113
self,
100114
vcap_services_name='compare-comply',
101115
url=url,
116+
username=username,
117+
password=password,
102118
iam_apikey=iam_apikey,
103119
iam_access_token=iam_access_token,
104120
iam_url=iam_url,

0 commit comments

Comments
 (0)