Skip to content

Commit 13c27b4

Browse files
committed
Refactor future-proofing request_parameters
Use common `request_parameters` name for future-proofing keyword arguments.
1 parent b5e7776 commit 13c27b4

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

ciscosparkapi/api/people.py

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ def __init__(self, session):
157157

158158
@generator_container
159159
def list(self, email=None, displayName=None, id=None, orgId=None, max=None,
160-
**query_params):
160+
**request_parameters):
161161
"""List people
162162
163163
This method supports Cisco Spark's implementation of RFC5988 Web
@@ -179,8 +179,8 @@ def list(self, email=None, displayName=None, id=None, orgId=None, max=None,
179179
orgId(basestring): The organization id.
180180
max(int): Limits the maximum number of people returned from the
181181
Spark service per request.
182-
**query_params: Additional query parameters (provides support for
183-
query parameters that may be added in the future).
182+
**request_parameters: Additional request parameters (provides
183+
support for parameters that may be added in the future).
184184
185185
Returns:
186186
GeneratorContainer: A GeneratorContainer which, when iterated,
@@ -198,7 +198,7 @@ def list(self, email=None, displayName=None, id=None, orgId=None, max=None,
198198
check_type(max, int)
199199

200200
params = dict_from_items_with_values(
201-
query_params,
201+
request_parameters,
202202
id=id,
203203
email=email,
204204
displayName=displayName,
@@ -215,7 +215,7 @@ def list(self, email=None, displayName=None, id=None, orgId=None, max=None,
215215

216216
def create(self, emails, displayName=None, firstName=None, lastName=None,
217217
avatar=None, orgId=None, roles=None, licenses=None,
218-
**person_attributes):
218+
**request_parameters):
219219
"""Create a new user account for a given organization
220220
221221
Only an admin can create a new user account.
@@ -233,8 +233,8 @@ def create(self, emails, displayName=None, firstName=None, lastName=None,
233233
licenses(list): Licenses allocated to the person (list of
234234
strings - containing the license IDs to be allocated to the
235235
person).
236-
**person_attributes: Additional person attributes (provides support
237-
for attributes that may be added in the future).
236+
**request_parameters: Additional request parameters (provides
237+
support for parameters that may be added in the future).
238238
239239
Returns:
240240
Person: A Person object with the details of the created person.
@@ -254,7 +254,7 @@ def create(self, emails, displayName=None, firstName=None, lastName=None,
254254
check_type(licenses, list)
255255

256256
post_data = dict_from_items_with_values(
257-
person_attributes,
257+
request_parameters,
258258
emails=emails,
259259
displayName=displayName,
260260
firstName=firstName,
@@ -273,7 +273,7 @@ def create(self, emails, displayName=None, firstName=None, lastName=None,
273273

274274
def update(self, personId, emails=None, displayName=None, firstName=None,
275275
lastName=None, avatar=None, orgId=None, roles=None,
276-
licenses=None, **person_attributes):
276+
licenses=None, **request_parameters):
277277
"""Update details for a person, by ID.
278278
279279
Only an admin can update a person's details.
@@ -299,8 +299,8 @@ def update(self, personId, emails=None, displayName=None, firstName=None,
299299
licenses(list): Licenses allocated to the person (list of
300300
strings - containing the license IDs to be allocated to the
301301
person).
302-
**person_attributes: Additional person attributes (provides support
303-
for attributes that may be added in the future).
302+
**request_parameters: Additional request parameters (provides
303+
support for parameters that may be added in the future).
304304
305305
Returns:
306306
Person: A Person object with the updated details.
@@ -320,7 +320,7 @@ def update(self, personId, emails=None, displayName=None, firstName=None,
320320
check_type(licenses, list)
321321

322322
put_data = dict_from_items_with_values(
323-
person_attributes,
323+
request_parameters,
324324
emails=emails,
325325
displayName=displayName,
326326
firstName=firstName,

0 commit comments

Comments
 (0)