@@ -22,8 +22,9 @@ class Server(Enum):
2222 DEFAULT = 0
2323 MESSAGINGDEFAULT = 1
2424 TWOFACTORAUTHDEFAULT = 2
25- VOICEDEFAULT = 3
26- WEBRTCDEFAULT = 4
25+ PHONENUMBERLOOKUPDEFAULT = 3
26+ VOICEDEFAULT = 4
27+ WEBRTCDEFAULT = 5
2728
2829
2930class Configuration (object ):
@@ -70,6 +71,14 @@ def two_factor_auth_basic_auth_user_name(self):
7071 def two_factor_auth_basic_auth_password (self ):
7172 return self ._two_factor_auth_basic_auth_password
7273
74+ @property
75+ def phone_number_lookup_basic_auth_user_name (self ):
76+ return self ._phone_number_lookup_basic_auth_user_name
77+
78+ @property
79+ def phone_number_lookup_basic_auth_password (self ):
80+ return self ._phone_number_lookup_basic_auth_password
81+
7382 @property
7483 def voice_basic_auth_user_name (self ):
7584 return self ._voice_basic_auth_user_name
@@ -93,6 +102,8 @@ def __init__(self, timeout=60, max_retries=3, backoff_factor=0,
93102 messaging_basic_auth_password = 'TODO: Replace' ,
94103 two_factor_auth_basic_auth_user_name = 'TODO: Replace' ,
95104 two_factor_auth_basic_auth_password = 'TODO: Replace' ,
105+ phone_number_lookup_basic_auth_user_name = 'TODO: Replace' ,
106+ phone_number_lookup_basic_auth_password = 'TODO: Replace' ,
96107 voice_basic_auth_user_name = 'TODO: Replace' ,
97108 voice_basic_auth_password = 'TODO: Replace' ,
98109 web_rtc_basic_auth_user_name = 'TODO: Replace' ,
@@ -126,6 +137,12 @@ def __init__(self, timeout=60, max_retries=3, backoff_factor=0,
126137 # The password to use with basic authentication
127138 self ._two_factor_auth_basic_auth_password = two_factor_auth_basic_auth_password
128139
140+ # The username to use with basic authentication
141+ self ._phone_number_lookup_basic_auth_user_name = phone_number_lookup_basic_auth_user_name
142+
143+ # The password to use with basic authentication
144+ self ._phone_number_lookup_basic_auth_password = phone_number_lookup_basic_auth_password
145+
129146 # The username to use with basic authentication
130147 self ._voice_basic_auth_user_name = voice_basic_auth_user_name
131148
@@ -147,6 +164,8 @@ def clone_with(self, timeout=None, max_retries=None, backoff_factor=None,
147164 messaging_basic_auth_password = None ,
148165 two_factor_auth_basic_auth_user_name = None ,
149166 two_factor_auth_basic_auth_password = None ,
167+ phone_number_lookup_basic_auth_user_name = None ,
168+ phone_number_lookup_basic_auth_password = None ,
150169 voice_basic_auth_user_name = None ,
151170 voice_basic_auth_password = None ,
152171 web_rtc_basic_auth_user_name = None ,
@@ -160,6 +179,8 @@ def clone_with(self, timeout=None, max_retries=None, backoff_factor=None,
160179 messaging_basic_auth_password = messaging_basic_auth_password or self .messaging_basic_auth_password
161180 two_factor_auth_basic_auth_user_name = two_factor_auth_basic_auth_user_name or self .two_factor_auth_basic_auth_user_name
162181 two_factor_auth_basic_auth_password = two_factor_auth_basic_auth_password or self .two_factor_auth_basic_auth_password
182+ phone_number_lookup_basic_auth_user_name = phone_number_lookup_basic_auth_user_name or self .phone_number_lookup_basic_auth_user_name
183+ phone_number_lookup_basic_auth_password = phone_number_lookup_basic_auth_password or self .phone_number_lookup_basic_auth_password
163184 voice_basic_auth_user_name = voice_basic_auth_user_name or self .voice_basic_auth_user_name
164185 voice_basic_auth_password = voice_basic_auth_password or self .voice_basic_auth_password
165186 web_rtc_basic_auth_user_name = web_rtc_basic_auth_user_name or self .web_rtc_basic_auth_user_name
@@ -172,6 +193,8 @@ def clone_with(self, timeout=None, max_retries=None, backoff_factor=None,
172193 messaging_basic_auth_password = messaging_basic_auth_password ,
173194 two_factor_auth_basic_auth_user_name = two_factor_auth_basic_auth_user_name ,
174195 two_factor_auth_basic_auth_password = two_factor_auth_basic_auth_password ,
196+ phone_number_lookup_basic_auth_user_name = phone_number_lookup_basic_auth_user_name ,
197+ phone_number_lookup_basic_auth_password = phone_number_lookup_basic_auth_password ,
175198 voice_basic_auth_user_name = voice_basic_auth_user_name ,
176199 voice_basic_auth_password = voice_basic_auth_password ,
177200 web_rtc_basic_auth_user_name = web_rtc_basic_auth_user_name ,
@@ -189,13 +212,15 @@ def create_http_client(self):
189212 Server .DEFAULT : 'api.bandwidth.com' ,
190213 Server .MESSAGINGDEFAULT : 'https://messaging.bandwidth.com/api/v2' ,
191214 Server .TWOFACTORAUTHDEFAULT : 'https://mfa.bandwidth.com/api/v1' ,
215+ Server .PHONENUMBERLOOKUPDEFAULT : 'https://numbers.bandwidth.com/api/v1' ,
192216 Server .VOICEDEFAULT : 'https://voice.bandwidth.com' ,
193217 Server .WEBRTCDEFAULT : 'https://api.webrtc.bandwidth.com/v1'
194218 },
195219 Environment .CUSTOM : {
196220 Server .DEFAULT : '{base_url}' ,
197221 Server .MESSAGINGDEFAULT : '{base_url}' ,
198222 Server .TWOFACTORAUTHDEFAULT : '{base_url}' ,
223+ Server .PHONENUMBERLOOKUPDEFAULT : '{base_url}' ,
199224 Server .VOICEDEFAULT : '{base_url}' ,
200225 Server .WEBRTCDEFAULT : '{base_url}'
201226 }
0 commit comments