teamdbapi 2.37.1__py3-none-any.whl → 3.0.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. teamdbapi/__init__.py +11 -0
  2. teamdbapi/api/__init__.py +39 -34
  3. teamdbapi/api/assembly_api.py +2108 -2108
  4. teamdbapi/api/car_api.py +874 -874
  5. teamdbapi/api/component_api.py +954 -0
  6. teamdbapi/api/config_api.py +118 -118
  7. teamdbapi/api/criteria_api.py +126 -0
  8. teamdbapi/api/edit_api.py +433 -433
  9. teamdbapi/api/event_api.py +878 -878
  10. teamdbapi/api/fixed_field_api.py +320 -320
  11. teamdbapi/api/group_api.py +609 -609
  12. teamdbapi/api/import_export_api.py +828 -743
  13. teamdbapi/api/lap_api.py +708 -708
  14. teamdbapi/api/lap_report_api.py +490 -486
  15. teamdbapi/api/model_field_api.py +708 -708
  16. teamdbapi/api/mounting_api.py +219 -0
  17. teamdbapi/api/notes_authorization_api.py +324 -324
  18. teamdbapi/api/parameter_api.py +1176 -1176
  19. teamdbapi/api/part_api.py +304 -0
  20. teamdbapi/api/report_api.py +142 -142
  21. teamdbapi/api/revision_api.py +1420 -1420
  22. teamdbapi/api/revision_editor_selector_api.py +990 -990
  23. teamdbapi/api/run_api.py +603 -603
  24. teamdbapi/api/script_api.py +490 -490
  25. teamdbapi/api/session_api.py +720 -720
  26. teamdbapi/api/target_api.py +415 -415
  27. teamdbapi/api/team_db_list_api.py +987 -987
  28. teamdbapi/api/team_db_view_api.py +482 -482
  29. teamdbapi/api/tire_api.py +599 -599
  30. teamdbapi/api/tire_set_api.py +514 -514
  31. teamdbapi/api/track_api.py +506 -506
  32. teamdbapi/api/track_layout_api.py +514 -514
  33. teamdbapi/api/update_request_api.py +235 -0
  34. teamdbapi/api/user_api.py +474 -474
  35. teamdbapi/api/value_field_api.py +558 -558
  36. teamdbapi/api/version_api.py +449 -449
  37. teamdbapi/api_client.py +4 -8
  38. teamdbapi/configuration.py +6 -13
  39. teamdbapi/models/__init__.py +6 -0
  40. teamdbapi/models/assembly.py +1 -0
  41. teamdbapi/models/bleed_adjustment.py +1 -0
  42. teamdbapi/models/calibration.py +1 -0
  43. teamdbapi/models/car.py +1 -0
  44. teamdbapi/models/car_parameters_context.py +1 -0
  45. teamdbapi/models/compare_options.py +1 -0
  46. teamdbapi/models/compare_result.py +1 -0
  47. teamdbapi/models/compare_result_detail.py +2 -0
  48. teamdbapi/models/component.py +1217 -0
  49. teamdbapi/models/copy_from_tags_args.py +2 -0
  50. teamdbapi/models/couple_guid_text.py +1 -0
  51. teamdbapi/models/criteria.py +430 -0
  52. teamdbapi/models/criteria_value.py +197 -0
  53. teamdbapi/models/event.py +1 -0
  54. teamdbapi/models/fixed_field.py +2 -1
  55. teamdbapi/models/group.py +1 -0
  56. teamdbapi/models/import_parameters_args.py +1 -0
  57. teamdbapi/models/import_parameters_results.py +2 -0
  58. teamdbapi/models/item_value.py +1 -0
  59. teamdbapi/models/item_value_key.py +1 -0
  60. teamdbapi/models/lap.py +1 -0
  61. teamdbapi/models/lap_report_options.py +1 -0
  62. teamdbapi/models/model_field.py +3 -1
  63. teamdbapi/models/model_field_authorization.py +1 -0
  64. teamdbapi/models/mounting.py +489 -0
  65. teamdbapi/models/notes_authorization.py +1 -0
  66. teamdbapi/models/notes_context.py +1 -0
  67. teamdbapi/models/parameter.py +2 -0
  68. teamdbapi/models/parameter_cross_table.py +1 -0
  69. teamdbapi/models/part.py +963 -0
  70. teamdbapi/models/part_count.py +228 -0
  71. teamdbapi/models/problem_details.py +2 -6
  72. teamdbapi/models/revision.py +88 -3
  73. teamdbapi/models/revision_value.py +1 -0
  74. teamdbapi/models/run.py +1 -0
  75. teamdbapi/models/script.py +1 -0
  76. teamdbapi/models/session.py +1 -0
  77. teamdbapi/models/string_with_font_style.py +1 -0
  78. teamdbapi/models/target.py +64 -7
  79. teamdbapi/models/team_db_list.py +1 -0
  80. teamdbapi/models/team_db_list_item.py +1 -0
  81. teamdbapi/models/tire.py +2 -0
  82. teamdbapi/models/tire_set.py +2 -0
  83. teamdbapi/models/track.py +1 -0
  84. teamdbapi/models/track_layout.py +1 -0
  85. teamdbapi/models/user.py +1 -0
  86. teamdbapi/models/user_group.py +1 -0
  87. teamdbapi/models/value_field.py +1 -0
  88. teamdbapi/models/version.py +1 -0
  89. teamdbapi/rest.py +6 -1
  90. {teamdbapi-2.37.1.dist-info → teamdbapi-3.0.0.dist-info}/METADATA +5 -5
  91. teamdbapi-3.0.0.dist-info/RECORD +93 -0
  92. teamdbapi-2.37.1.dist-info/RECORD +0 -82
  93. {teamdbapi-2.37.1.dist-info → teamdbapi-3.0.0.dist-info}/LICENSE +0 -0
  94. {teamdbapi-2.37.1.dist-info → teamdbapi-3.0.0.dist-info}/WHEEL +0 -0
teamdbapi/api/user_api.py CHANGED
@@ -1,474 +1,474 @@
1
- # coding: utf-8
2
-
3
- """
4
- Trackside Software TeamDB API v2.0
5
-
6
- This API enables you to access TeamDB data # noqa: E501
7
-
8
- OpenAPI spec version: 2.0
9
- Contact: support@trackside.fr
10
- Generated by: https://github.com/swagger-api/swagger-codegen.git
11
- """
12
-
13
- from __future__ import absolute_import
14
-
15
- import re # noqa: F401
16
-
17
- # python 2 and python 3 compatibility library
18
- import six
19
-
20
- from teamdbapi.api_client import ApiClient
21
-
22
-
23
- class UserApi(object):
24
- """NOTE: This class is auto generated by the swagger code generator program.
25
-
26
- Do not edit the class manually.
27
- Ref: https://github.com/swagger-api/swagger-codegen
28
- """
29
-
30
- def __init__(self, api_client=None):
31
- if api_client is None:
32
- api_client = ApiClient()
33
- self.api_client = api_client
34
-
35
- def get_current_user(self, **kwargs): # noqa: E501
36
- """Get the current TeamDB user. # noqa: E501
37
-
38
- This method makes a synchronous HTTP request by default. To make an
39
- asynchronous HTTP request, please pass async_req=True
40
- >>> thread = api.get_current_user(async_req=True)
41
- >>> result = thread.get()
42
-
43
- :param async_req bool
44
- :return: User
45
- If the method is called asynchronously,
46
- returns the request thread.
47
- """
48
- kwargs['_return_http_data_only'] = True
49
- if kwargs.get('async_req'):
50
- return self.get_current_user_with_http_info(**kwargs) # noqa: E501
51
- else:
52
- (data) = self.get_current_user_with_http_info(**kwargs) # noqa: E501
53
- return data
54
-
55
- def get_current_user_with_http_info(self, **kwargs): # noqa: E501
56
- """Get the current TeamDB user. # noqa: E501
57
-
58
- This method makes a synchronous HTTP request by default. To make an
59
- asynchronous HTTP request, please pass async_req=True
60
- >>> thread = api.get_current_user_with_http_info(async_req=True)
61
- >>> result = thread.get()
62
-
63
- :param async_req bool
64
- :return: User
65
- If the method is called asynchronously,
66
- returns the request thread.
67
- """
68
-
69
- all_params = [] # noqa: E501
70
- all_params.append('async_req')
71
- all_params.append('_return_http_data_only')
72
- all_params.append('_preload_content')
73
- all_params.append('_request_timeout')
74
-
75
- params = locals()
76
- for key, val in six.iteritems(params['kwargs']):
77
- if key not in all_params:
78
- raise TypeError(
79
- "Got an unexpected keyword argument '%s'"
80
- " to method get_current_user" % key
81
- )
82
- params[key] = val
83
- del params['kwargs']
84
-
85
- collection_formats = {}
86
-
87
- path_params = {}
88
-
89
- query_params = []
90
-
91
- header_params = {}
92
-
93
- form_params = []
94
- local_var_files = {}
95
-
96
- body_params = None
97
- # HTTP header `Accept`
98
- header_params['Accept'] = self.api_client.select_header_accept(
99
- ['application/json', 'text/json']) # noqa: E501
100
-
101
- # Authentication setting
102
- auth_settings = [] # noqa: E501
103
-
104
- return self.api_client.call_api(
105
- '/teamdbapi/v2.0/user/current', 'GET',
106
- path_params,
107
- query_params,
108
- header_params,
109
- body=body_params,
110
- post_params=form_params,
111
- files=local_var_files,
112
- response_type='User', # noqa: E501
113
- auth_settings=auth_settings,
114
- async_req=params.get('async_req'),
115
- _return_http_data_only=params.get('_return_http_data_only'),
116
- _preload_content=params.get('_preload_content', True),
117
- _request_timeout=params.get('_request_timeout'),
118
- collection_formats=collection_formats)
119
-
120
- def get_user(self, user_id, **kwargs): # noqa: E501
121
- """Get a TeamDB user via a unique id. # noqa: E501
122
-
123
- This method makes a synchronous HTTP request by default. To make an
124
- asynchronous HTTP request, please pass async_req=True
125
- >>> thread = api.get_user(user_id, async_req=True)
126
- >>> result = thread.get()
127
-
128
- :param async_req bool
129
- :param str user_id: The unique TeamDB user id for which you want to get the user (required)
130
- :return: User
131
- If the method is called asynchronously,
132
- returns the request thread.
133
- """
134
- kwargs['_return_http_data_only'] = True
135
- if kwargs.get('async_req'):
136
- return self.get_user_with_http_info(user_id, **kwargs) # noqa: E501
137
- else:
138
- (data) = self.get_user_with_http_info(user_id, **kwargs) # noqa: E501
139
- return data
140
-
141
- def get_user_with_http_info(self, user_id, **kwargs): # noqa: E501
142
- """Get a TeamDB user via a unique id. # noqa: E501
143
-
144
- This method makes a synchronous HTTP request by default. To make an
145
- asynchronous HTTP request, please pass async_req=True
146
- >>> thread = api.get_user_with_http_info(user_id, async_req=True)
147
- >>> result = thread.get()
148
-
149
- :param async_req bool
150
- :param str user_id: The unique TeamDB user id for which you want to get the user (required)
151
- :return: User
152
- If the method is called asynchronously,
153
- returns the request thread.
154
- """
155
-
156
- all_params = ['user_id'] # noqa: E501
157
- all_params.append('async_req')
158
- all_params.append('_return_http_data_only')
159
- all_params.append('_preload_content')
160
- all_params.append('_request_timeout')
161
-
162
- params = locals()
163
- for key, val in six.iteritems(params['kwargs']):
164
- if key not in all_params:
165
- raise TypeError(
166
- "Got an unexpected keyword argument '%s'"
167
- " to method get_user" % key
168
- )
169
- params[key] = val
170
- del params['kwargs']
171
- # verify the required parameter 'user_id' is set
172
- if ('user_id' not in params or
173
- params['user_id'] is None):
174
- raise ValueError("Missing the required parameter `user_id` when calling `get_user`") # noqa: E501
175
-
176
- collection_formats = {}
177
-
178
- path_params = {}
179
- if 'user_id' in params:
180
- path_params['userId'] = params['user_id'] # noqa: E501
181
-
182
- query_params = []
183
-
184
- header_params = {}
185
-
186
- form_params = []
187
- local_var_files = {}
188
-
189
- body_params = None
190
- # HTTP header `Accept`
191
- header_params['Accept'] = self.api_client.select_header_accept(
192
- ['application/json', 'text/json']) # noqa: E501
193
-
194
- # Authentication setting
195
- auth_settings = [] # noqa: E501
196
-
197
- return self.api_client.call_api(
198
- '/teamdbapi/v2.0/user/{userId}', 'GET',
199
- path_params,
200
- query_params,
201
- header_params,
202
- body=body_params,
203
- post_params=form_params,
204
- files=local_var_files,
205
- response_type='User', # noqa: E501
206
- auth_settings=auth_settings,
207
- async_req=params.get('async_req'),
208
- _return_http_data_only=params.get('_return_http_data_only'),
209
- _preload_content=params.get('_preload_content', True),
210
- _request_timeout=params.get('_request_timeout'),
211
- collection_formats=collection_formats)
212
-
213
- def get_user_group(self, user_group_id, **kwargs): # noqa: E501
214
- """Get a TeamDB user group via a unique id. # noqa: E501
215
-
216
- This method makes a synchronous HTTP request by default. To make an
217
- asynchronous HTTP request, please pass async_req=True
218
- >>> thread = api.get_user_group(user_group_id, async_req=True)
219
- >>> result = thread.get()
220
-
221
- :param async_req bool
222
- :param str user_group_id: The unique TeamDB user group id for which you want to get the user group (required)
223
- :return: UserGroup
224
- If the method is called asynchronously,
225
- returns the request thread.
226
- """
227
- kwargs['_return_http_data_only'] = True
228
- if kwargs.get('async_req'):
229
- return self.get_user_group_with_http_info(user_group_id, **kwargs) # noqa: E501
230
- else:
231
- (data) = self.get_user_group_with_http_info(user_group_id, **kwargs) # noqa: E501
232
- return data
233
-
234
- def get_user_group_with_http_info(self, user_group_id, **kwargs): # noqa: E501
235
- """Get a TeamDB user group via a unique id. # noqa: E501
236
-
237
- This method makes a synchronous HTTP request by default. To make an
238
- asynchronous HTTP request, please pass async_req=True
239
- >>> thread = api.get_user_group_with_http_info(user_group_id, async_req=True)
240
- >>> result = thread.get()
241
-
242
- :param async_req bool
243
- :param str user_group_id: The unique TeamDB user group id for which you want to get the user group (required)
244
- :return: UserGroup
245
- If the method is called asynchronously,
246
- returns the request thread.
247
- """
248
-
249
- all_params = ['user_group_id'] # noqa: E501
250
- all_params.append('async_req')
251
- all_params.append('_return_http_data_only')
252
- all_params.append('_preload_content')
253
- all_params.append('_request_timeout')
254
-
255
- params = locals()
256
- for key, val in six.iteritems(params['kwargs']):
257
- if key not in all_params:
258
- raise TypeError(
259
- "Got an unexpected keyword argument '%s'"
260
- " to method get_user_group" % key
261
- )
262
- params[key] = val
263
- del params['kwargs']
264
- # verify the required parameter 'user_group_id' is set
265
- if ('user_group_id' not in params or
266
- params['user_group_id'] is None):
267
- raise ValueError("Missing the required parameter `user_group_id` when calling `get_user_group`") # noqa: E501
268
-
269
- collection_formats = {}
270
-
271
- path_params = {}
272
- if 'user_group_id' in params:
273
- path_params['userGroupId'] = params['user_group_id'] # noqa: E501
274
-
275
- query_params = []
276
-
277
- header_params = {}
278
-
279
- form_params = []
280
- local_var_files = {}
281
-
282
- body_params = None
283
- # HTTP header `Accept`
284
- header_params['Accept'] = self.api_client.select_header_accept(
285
- ['application/json', 'text/json']) # noqa: E501
286
-
287
- # Authentication setting
288
- auth_settings = [] # noqa: E501
289
-
290
- return self.api_client.call_api(
291
- '/teamdbapi/v2.0/usergroup/{userGroupId}', 'GET',
292
- path_params,
293
- query_params,
294
- header_params,
295
- body=body_params,
296
- post_params=form_params,
297
- files=local_var_files,
298
- response_type='UserGroup', # noqa: E501
299
- auth_settings=auth_settings,
300
- async_req=params.get('async_req'),
301
- _return_http_data_only=params.get('_return_http_data_only'),
302
- _preload_content=params.get('_preload_content', True),
303
- _request_timeout=params.get('_request_timeout'),
304
- collection_formats=collection_formats)
305
-
306
- def get_user_groups(self, **kwargs): # noqa: E501
307
- """Get the list of all TeamDB user groups # noqa: E501
308
-
309
- This method makes a synchronous HTTP request by default. To make an
310
- asynchronous HTTP request, please pass async_req=True
311
- >>> thread = api.get_user_groups(async_req=True)
312
- >>> result = thread.get()
313
-
314
- :param async_req bool
315
- :return: list[UserGroup]
316
- If the method is called asynchronously,
317
- returns the request thread.
318
- """
319
- kwargs['_return_http_data_only'] = True
320
- if kwargs.get('async_req'):
321
- return self.get_user_groups_with_http_info(**kwargs) # noqa: E501
322
- else:
323
- (data) = self.get_user_groups_with_http_info(**kwargs) # noqa: E501
324
- return data
325
-
326
- def get_user_groups_with_http_info(self, **kwargs): # noqa: E501
327
- """Get the list of all TeamDB user groups # noqa: E501
328
-
329
- This method makes a synchronous HTTP request by default. To make an
330
- asynchronous HTTP request, please pass async_req=True
331
- >>> thread = api.get_user_groups_with_http_info(async_req=True)
332
- >>> result = thread.get()
333
-
334
- :param async_req bool
335
- :return: list[UserGroup]
336
- If the method is called asynchronously,
337
- returns the request thread.
338
- """
339
-
340
- all_params = [] # noqa: E501
341
- all_params.append('async_req')
342
- all_params.append('_return_http_data_only')
343
- all_params.append('_preload_content')
344
- all_params.append('_request_timeout')
345
-
346
- params = locals()
347
- for key, val in six.iteritems(params['kwargs']):
348
- if key not in all_params:
349
- raise TypeError(
350
- "Got an unexpected keyword argument '%s'"
351
- " to method get_user_groups" % key
352
- )
353
- params[key] = val
354
- del params['kwargs']
355
-
356
- collection_formats = {}
357
-
358
- path_params = {}
359
-
360
- query_params = []
361
-
362
- header_params = {}
363
-
364
- form_params = []
365
- local_var_files = {}
366
-
367
- body_params = None
368
- # HTTP header `Accept`
369
- header_params['Accept'] = self.api_client.select_header_accept(
370
- ['application/json', 'text/json']) # noqa: E501
371
-
372
- # Authentication setting
373
- auth_settings = [] # noqa: E501
374
-
375
- return self.api_client.call_api(
376
- '/teamdbapi/v2.0/usergroups', 'GET',
377
- path_params,
378
- query_params,
379
- header_params,
380
- body=body_params,
381
- post_params=form_params,
382
- files=local_var_files,
383
- response_type='list[UserGroup]', # noqa: E501
384
- auth_settings=auth_settings,
385
- async_req=params.get('async_req'),
386
- _return_http_data_only=params.get('_return_http_data_only'),
387
- _preload_content=params.get('_preload_content', True),
388
- _request_timeout=params.get('_request_timeout'),
389
- collection_formats=collection_formats)
390
-
391
- def get_users(self, **kwargs): # noqa: E501
392
- """Get the list of all TeamDB users # noqa: E501
393
-
394
- This method makes a synchronous HTTP request by default. To make an
395
- asynchronous HTTP request, please pass async_req=True
396
- >>> thread = api.get_users(async_req=True)
397
- >>> result = thread.get()
398
-
399
- :param async_req bool
400
- :return: list[User]
401
- If the method is called asynchronously,
402
- returns the request thread.
403
- """
404
- kwargs['_return_http_data_only'] = True
405
- if kwargs.get('async_req'):
406
- return self.get_users_with_http_info(**kwargs) # noqa: E501
407
- else:
408
- (data) = self.get_users_with_http_info(**kwargs) # noqa: E501
409
- return data
410
-
411
- def get_users_with_http_info(self, **kwargs): # noqa: E501
412
- """Get the list of all TeamDB users # noqa: E501
413
-
414
- This method makes a synchronous HTTP request by default. To make an
415
- asynchronous HTTP request, please pass async_req=True
416
- >>> thread = api.get_users_with_http_info(async_req=True)
417
- >>> result = thread.get()
418
-
419
- :param async_req bool
420
- :return: list[User]
421
- If the method is called asynchronously,
422
- returns the request thread.
423
- """
424
-
425
- all_params = [] # noqa: E501
426
- all_params.append('async_req')
427
- all_params.append('_return_http_data_only')
428
- all_params.append('_preload_content')
429
- all_params.append('_request_timeout')
430
-
431
- params = locals()
432
- for key, val in six.iteritems(params['kwargs']):
433
- if key not in all_params:
434
- raise TypeError(
435
- "Got an unexpected keyword argument '%s'"
436
- " to method get_users" % key
437
- )
438
- params[key] = val
439
- del params['kwargs']
440
-
441
- collection_formats = {}
442
-
443
- path_params = {}
444
-
445
- query_params = []
446
-
447
- header_params = {}
448
-
449
- form_params = []
450
- local_var_files = {}
451
-
452
- body_params = None
453
- # HTTP header `Accept`
454
- header_params['Accept'] = self.api_client.select_header_accept(
455
- ['application/json', 'text/json']) # noqa: E501
456
-
457
- # Authentication setting
458
- auth_settings = [] # noqa: E501
459
-
460
- return self.api_client.call_api(
461
- '/teamdbapi/v2.0/users', 'GET',
462
- path_params,
463
- query_params,
464
- header_params,
465
- body=body_params,
466
- post_params=form_params,
467
- files=local_var_files,
468
- response_type='list[User]', # noqa: E501
469
- auth_settings=auth_settings,
470
- async_req=params.get('async_req'),
471
- _return_http_data_only=params.get('_return_http_data_only'),
472
- _preload_content=params.get('_preload_content', True),
473
- _request_timeout=params.get('_request_timeout'),
474
- collection_formats=collection_formats)
1
+ # coding: utf-8
2
+
3
+ """
4
+ Trackside Software TeamDB API v2.0
5
+
6
+ This API enables you to access TeamDB data # noqa: E501
7
+
8
+ OpenAPI spec version: 2.0
9
+ Contact: support@trackside.fr
10
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
11
+ """
12
+
13
+ from __future__ import absolute_import
14
+
15
+ import re # noqa: F401
16
+
17
+ # python 2 and python 3 compatibility library
18
+ import six
19
+
20
+ from teamdbapi.api_client import ApiClient
21
+
22
+
23
+ class UserApi(object):
24
+ """NOTE: This class is auto generated by the swagger code generator program.
25
+
26
+ Do not edit the class manually.
27
+ Ref: https://github.com/swagger-api/swagger-codegen
28
+ """
29
+
30
+ def __init__(self, api_client=None):
31
+ if api_client is None:
32
+ api_client = ApiClient()
33
+ self.api_client = api_client
34
+
35
+ def get_current_user(self, **kwargs): # noqa: E501
36
+ """Get the current TeamDB user. # noqa: E501
37
+
38
+ This method makes a synchronous HTTP request by default. To make an
39
+ asynchronous HTTP request, please pass async_req=True
40
+ >>> thread = api.get_current_user(async_req=True)
41
+ >>> result = thread.get()
42
+
43
+ :param async_req bool
44
+ :return: User
45
+ If the method is called asynchronously,
46
+ returns the request thread.
47
+ """
48
+ kwargs['_return_http_data_only'] = True
49
+ if kwargs.get('async_req'):
50
+ return self.get_current_user_with_http_info(**kwargs) # noqa: E501
51
+ else:
52
+ (data) = self.get_current_user_with_http_info(**kwargs) # noqa: E501
53
+ return data
54
+
55
+ def get_current_user_with_http_info(self, **kwargs): # noqa: E501
56
+ """Get the current TeamDB user. # noqa: E501
57
+
58
+ This method makes a synchronous HTTP request by default. To make an
59
+ asynchronous HTTP request, please pass async_req=True
60
+ >>> thread = api.get_current_user_with_http_info(async_req=True)
61
+ >>> result = thread.get()
62
+
63
+ :param async_req bool
64
+ :return: User
65
+ If the method is called asynchronously,
66
+ returns the request thread.
67
+ """
68
+
69
+ all_params = [] # noqa: E501
70
+ all_params.append('async_req')
71
+ all_params.append('_return_http_data_only')
72
+ all_params.append('_preload_content')
73
+ all_params.append('_request_timeout')
74
+
75
+ params = locals()
76
+ for key, val in six.iteritems(params['kwargs']):
77
+ if key not in all_params:
78
+ raise TypeError(
79
+ "Got an unexpected keyword argument '%s'"
80
+ " to method get_current_user" % key
81
+ )
82
+ params[key] = val
83
+ del params['kwargs']
84
+
85
+ collection_formats = {}
86
+
87
+ path_params = {}
88
+
89
+ query_params = []
90
+
91
+ header_params = {}
92
+
93
+ form_params = []
94
+ local_var_files = {}
95
+
96
+ body_params = None
97
+ # HTTP header `Accept`
98
+ header_params['Accept'] = self.api_client.select_header_accept(
99
+ ['application/json', 'text/json']) # noqa: E501
100
+
101
+ # Authentication setting
102
+ auth_settings = [] # noqa: E501
103
+
104
+ return self.api_client.call_api(
105
+ '/teamdbapi/v2.0/user/current', 'GET',
106
+ path_params,
107
+ query_params,
108
+ header_params,
109
+ body=body_params,
110
+ post_params=form_params,
111
+ files=local_var_files,
112
+ response_type='User', # noqa: E501
113
+ auth_settings=auth_settings,
114
+ async_req=params.get('async_req'),
115
+ _return_http_data_only=params.get('_return_http_data_only'),
116
+ _preload_content=params.get('_preload_content', True),
117
+ _request_timeout=params.get('_request_timeout'),
118
+ collection_formats=collection_formats)
119
+
120
+ def get_user(self, user_id, **kwargs): # noqa: E501
121
+ """Get a TeamDB user via a unique id. # noqa: E501
122
+
123
+ This method makes a synchronous HTTP request by default. To make an
124
+ asynchronous HTTP request, please pass async_req=True
125
+ >>> thread = api.get_user(user_id, async_req=True)
126
+ >>> result = thread.get()
127
+
128
+ :param async_req bool
129
+ :param str user_id: The unique TeamDB user id for which you want to get the user (required)
130
+ :return: User
131
+ If the method is called asynchronously,
132
+ returns the request thread.
133
+ """
134
+ kwargs['_return_http_data_only'] = True
135
+ if kwargs.get('async_req'):
136
+ return self.get_user_with_http_info(user_id, **kwargs) # noqa: E501
137
+ else:
138
+ (data) = self.get_user_with_http_info(user_id, **kwargs) # noqa: E501
139
+ return data
140
+
141
+ def get_user_with_http_info(self, user_id, **kwargs): # noqa: E501
142
+ """Get a TeamDB user via a unique id. # noqa: E501
143
+
144
+ This method makes a synchronous HTTP request by default. To make an
145
+ asynchronous HTTP request, please pass async_req=True
146
+ >>> thread = api.get_user_with_http_info(user_id, async_req=True)
147
+ >>> result = thread.get()
148
+
149
+ :param async_req bool
150
+ :param str user_id: The unique TeamDB user id for which you want to get the user (required)
151
+ :return: User
152
+ If the method is called asynchronously,
153
+ returns the request thread.
154
+ """
155
+
156
+ all_params = ['user_id'] # noqa: E501
157
+ all_params.append('async_req')
158
+ all_params.append('_return_http_data_only')
159
+ all_params.append('_preload_content')
160
+ all_params.append('_request_timeout')
161
+
162
+ params = locals()
163
+ for key, val in six.iteritems(params['kwargs']):
164
+ if key not in all_params:
165
+ raise TypeError(
166
+ "Got an unexpected keyword argument '%s'"
167
+ " to method get_user" % key
168
+ )
169
+ params[key] = val
170
+ del params['kwargs']
171
+ # verify the required parameter 'user_id' is set
172
+ if ('user_id' not in params or
173
+ params['user_id'] is None):
174
+ raise ValueError("Missing the required parameter `user_id` when calling `get_user`") # noqa: E501
175
+
176
+ collection_formats = {}
177
+
178
+ path_params = {}
179
+ if 'user_id' in params:
180
+ path_params['userId'] = params['user_id'] # noqa: E501
181
+
182
+ query_params = []
183
+
184
+ header_params = {}
185
+
186
+ form_params = []
187
+ local_var_files = {}
188
+
189
+ body_params = None
190
+ # HTTP header `Accept`
191
+ header_params['Accept'] = self.api_client.select_header_accept(
192
+ ['application/json', 'text/json']) # noqa: E501
193
+
194
+ # Authentication setting
195
+ auth_settings = [] # noqa: E501
196
+
197
+ return self.api_client.call_api(
198
+ '/teamdbapi/v2.0/user/{userId}', 'GET',
199
+ path_params,
200
+ query_params,
201
+ header_params,
202
+ body=body_params,
203
+ post_params=form_params,
204
+ files=local_var_files,
205
+ response_type='User', # noqa: E501
206
+ auth_settings=auth_settings,
207
+ async_req=params.get('async_req'),
208
+ _return_http_data_only=params.get('_return_http_data_only'),
209
+ _preload_content=params.get('_preload_content', True),
210
+ _request_timeout=params.get('_request_timeout'),
211
+ collection_formats=collection_formats)
212
+
213
+ def get_user_group(self, user_group_id, **kwargs): # noqa: E501
214
+ """Get a TeamDB user group via a unique id. # noqa: E501
215
+
216
+ This method makes a synchronous HTTP request by default. To make an
217
+ asynchronous HTTP request, please pass async_req=True
218
+ >>> thread = api.get_user_group(user_group_id, async_req=True)
219
+ >>> result = thread.get()
220
+
221
+ :param async_req bool
222
+ :param str user_group_id: The unique TeamDB user group id for which you want to get the user group (required)
223
+ :return: UserGroup
224
+ If the method is called asynchronously,
225
+ returns the request thread.
226
+ """
227
+ kwargs['_return_http_data_only'] = True
228
+ if kwargs.get('async_req'):
229
+ return self.get_user_group_with_http_info(user_group_id, **kwargs) # noqa: E501
230
+ else:
231
+ (data) = self.get_user_group_with_http_info(user_group_id, **kwargs) # noqa: E501
232
+ return data
233
+
234
+ def get_user_group_with_http_info(self, user_group_id, **kwargs): # noqa: E501
235
+ """Get a TeamDB user group via a unique id. # noqa: E501
236
+
237
+ This method makes a synchronous HTTP request by default. To make an
238
+ asynchronous HTTP request, please pass async_req=True
239
+ >>> thread = api.get_user_group_with_http_info(user_group_id, async_req=True)
240
+ >>> result = thread.get()
241
+
242
+ :param async_req bool
243
+ :param str user_group_id: The unique TeamDB user group id for which you want to get the user group (required)
244
+ :return: UserGroup
245
+ If the method is called asynchronously,
246
+ returns the request thread.
247
+ """
248
+
249
+ all_params = ['user_group_id'] # noqa: E501
250
+ all_params.append('async_req')
251
+ all_params.append('_return_http_data_only')
252
+ all_params.append('_preload_content')
253
+ all_params.append('_request_timeout')
254
+
255
+ params = locals()
256
+ for key, val in six.iteritems(params['kwargs']):
257
+ if key not in all_params:
258
+ raise TypeError(
259
+ "Got an unexpected keyword argument '%s'"
260
+ " to method get_user_group" % key
261
+ )
262
+ params[key] = val
263
+ del params['kwargs']
264
+ # verify the required parameter 'user_group_id' is set
265
+ if ('user_group_id' not in params or
266
+ params['user_group_id'] is None):
267
+ raise ValueError("Missing the required parameter `user_group_id` when calling `get_user_group`") # noqa: E501
268
+
269
+ collection_formats = {}
270
+
271
+ path_params = {}
272
+ if 'user_group_id' in params:
273
+ path_params['userGroupId'] = params['user_group_id'] # noqa: E501
274
+
275
+ query_params = []
276
+
277
+ header_params = {}
278
+
279
+ form_params = []
280
+ local_var_files = {}
281
+
282
+ body_params = None
283
+ # HTTP header `Accept`
284
+ header_params['Accept'] = self.api_client.select_header_accept(
285
+ ['application/json', 'text/json']) # noqa: E501
286
+
287
+ # Authentication setting
288
+ auth_settings = [] # noqa: E501
289
+
290
+ return self.api_client.call_api(
291
+ '/teamdbapi/v2.0/usergroup/{userGroupId}', 'GET',
292
+ path_params,
293
+ query_params,
294
+ header_params,
295
+ body=body_params,
296
+ post_params=form_params,
297
+ files=local_var_files,
298
+ response_type='UserGroup', # noqa: E501
299
+ auth_settings=auth_settings,
300
+ async_req=params.get('async_req'),
301
+ _return_http_data_only=params.get('_return_http_data_only'),
302
+ _preload_content=params.get('_preload_content', True),
303
+ _request_timeout=params.get('_request_timeout'),
304
+ collection_formats=collection_formats)
305
+
306
+ def get_user_groups(self, **kwargs): # noqa: E501
307
+ """Get the list of all TeamDB user groups # noqa: E501
308
+
309
+ This method makes a synchronous HTTP request by default. To make an
310
+ asynchronous HTTP request, please pass async_req=True
311
+ >>> thread = api.get_user_groups(async_req=True)
312
+ >>> result = thread.get()
313
+
314
+ :param async_req bool
315
+ :return: list[UserGroup]
316
+ If the method is called asynchronously,
317
+ returns the request thread.
318
+ """
319
+ kwargs['_return_http_data_only'] = True
320
+ if kwargs.get('async_req'):
321
+ return self.get_user_groups_with_http_info(**kwargs) # noqa: E501
322
+ else:
323
+ (data) = self.get_user_groups_with_http_info(**kwargs) # noqa: E501
324
+ return data
325
+
326
+ def get_user_groups_with_http_info(self, **kwargs): # noqa: E501
327
+ """Get the list of all TeamDB user groups # noqa: E501
328
+
329
+ This method makes a synchronous HTTP request by default. To make an
330
+ asynchronous HTTP request, please pass async_req=True
331
+ >>> thread = api.get_user_groups_with_http_info(async_req=True)
332
+ >>> result = thread.get()
333
+
334
+ :param async_req bool
335
+ :return: list[UserGroup]
336
+ If the method is called asynchronously,
337
+ returns the request thread.
338
+ """
339
+
340
+ all_params = [] # noqa: E501
341
+ all_params.append('async_req')
342
+ all_params.append('_return_http_data_only')
343
+ all_params.append('_preload_content')
344
+ all_params.append('_request_timeout')
345
+
346
+ params = locals()
347
+ for key, val in six.iteritems(params['kwargs']):
348
+ if key not in all_params:
349
+ raise TypeError(
350
+ "Got an unexpected keyword argument '%s'"
351
+ " to method get_user_groups" % key
352
+ )
353
+ params[key] = val
354
+ del params['kwargs']
355
+
356
+ collection_formats = {}
357
+
358
+ path_params = {}
359
+
360
+ query_params = []
361
+
362
+ header_params = {}
363
+
364
+ form_params = []
365
+ local_var_files = {}
366
+
367
+ body_params = None
368
+ # HTTP header `Accept`
369
+ header_params['Accept'] = self.api_client.select_header_accept(
370
+ ['application/json', 'text/json']) # noqa: E501
371
+
372
+ # Authentication setting
373
+ auth_settings = [] # noqa: E501
374
+
375
+ return self.api_client.call_api(
376
+ '/teamdbapi/v2.0/usergroups', 'GET',
377
+ path_params,
378
+ query_params,
379
+ header_params,
380
+ body=body_params,
381
+ post_params=form_params,
382
+ files=local_var_files,
383
+ response_type='list[UserGroup]', # noqa: E501
384
+ auth_settings=auth_settings,
385
+ async_req=params.get('async_req'),
386
+ _return_http_data_only=params.get('_return_http_data_only'),
387
+ _preload_content=params.get('_preload_content', True),
388
+ _request_timeout=params.get('_request_timeout'),
389
+ collection_formats=collection_formats)
390
+
391
+ def get_users(self, **kwargs): # noqa: E501
392
+ """Get the list of all TeamDB users # noqa: E501
393
+
394
+ This method makes a synchronous HTTP request by default. To make an
395
+ asynchronous HTTP request, please pass async_req=True
396
+ >>> thread = api.get_users(async_req=True)
397
+ >>> result = thread.get()
398
+
399
+ :param async_req bool
400
+ :return: list[User]
401
+ If the method is called asynchronously,
402
+ returns the request thread.
403
+ """
404
+ kwargs['_return_http_data_only'] = True
405
+ if kwargs.get('async_req'):
406
+ return self.get_users_with_http_info(**kwargs) # noqa: E501
407
+ else:
408
+ (data) = self.get_users_with_http_info(**kwargs) # noqa: E501
409
+ return data
410
+
411
+ def get_users_with_http_info(self, **kwargs): # noqa: E501
412
+ """Get the list of all TeamDB users # noqa: E501
413
+
414
+ This method makes a synchronous HTTP request by default. To make an
415
+ asynchronous HTTP request, please pass async_req=True
416
+ >>> thread = api.get_users_with_http_info(async_req=True)
417
+ >>> result = thread.get()
418
+
419
+ :param async_req bool
420
+ :return: list[User]
421
+ If the method is called asynchronously,
422
+ returns the request thread.
423
+ """
424
+
425
+ all_params = [] # noqa: E501
426
+ all_params.append('async_req')
427
+ all_params.append('_return_http_data_only')
428
+ all_params.append('_preload_content')
429
+ all_params.append('_request_timeout')
430
+
431
+ params = locals()
432
+ for key, val in six.iteritems(params['kwargs']):
433
+ if key not in all_params:
434
+ raise TypeError(
435
+ "Got an unexpected keyword argument '%s'"
436
+ " to method get_users" % key
437
+ )
438
+ params[key] = val
439
+ del params['kwargs']
440
+
441
+ collection_formats = {}
442
+
443
+ path_params = {}
444
+
445
+ query_params = []
446
+
447
+ header_params = {}
448
+
449
+ form_params = []
450
+ local_var_files = {}
451
+
452
+ body_params = None
453
+ # HTTP header `Accept`
454
+ header_params['Accept'] = self.api_client.select_header_accept(
455
+ ['application/json', 'text/json']) # noqa: E501
456
+
457
+ # Authentication setting
458
+ auth_settings = [] # noqa: E501
459
+
460
+ return self.api_client.call_api(
461
+ '/teamdbapi/v2.0/users', 'GET',
462
+ path_params,
463
+ query_params,
464
+ header_params,
465
+ body=body_params,
466
+ post_params=form_params,
467
+ files=local_var_files,
468
+ response_type='list[User]', # noqa: E501
469
+ auth_settings=auth_settings,
470
+ async_req=params.get('async_req'),
471
+ _return_http_data_only=params.get('_return_http_data_only'),
472
+ _preload_content=params.get('_preload_content', True),
473
+ _request_timeout=params.get('_request_timeout'),
474
+ collection_formats=collection_formats)