qi-compute-api-client 0.56.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 (205) hide show
  1. compute_api_client/__init__.py +219 -0
  2. compute_api_client/api/__init__.py +23 -0
  3. compute_api_client/api/algorithms_api.py +1603 -0
  4. compute_api_client/api/auth_config_api.py +278 -0
  5. compute_api_client/api/backend_api.py +1540 -0
  6. compute_api_client/api/backend_types_api.py +1178 -0
  7. compute_api_client/api/batch_jobs_api.py +2224 -0
  8. compute_api_client/api/commits_api.py +1565 -0
  9. compute_api_client/api/files_api.py +1307 -0
  10. compute_api_client/api/final_results_api.py +847 -0
  11. compute_api_client/api/health_api.py +281 -0
  12. compute_api_client/api/jobs_api.py +1787 -0
  13. compute_api_client/api/languages_api.py +692 -0
  14. compute_api_client/api/members_api.py +1238 -0
  15. compute_api_client/api/metadata_api.py +930 -0
  16. compute_api_client/api/permissions_api.py +1295 -0
  17. compute_api_client/api/projects_api.py +1889 -0
  18. compute_api_client/api/reservations_api.py +1324 -0
  19. compute_api_client/api/results_api.py +1702 -0
  20. compute_api_client/api/teams_api.py +692 -0
  21. compute_api_client/api/transactions_api.py +805 -0
  22. compute_api_client/api/users_api.py +1305 -0
  23. compute_api_client/api_client.py +804 -0
  24. compute_api_client/api_response.py +21 -0
  25. compute_api_client/configuration.py +606 -0
  26. compute_api_client/docs/Algorithm.md +34 -0
  27. compute_api_client/docs/AlgorithmIn.md +33 -0
  28. compute_api_client/docs/AlgorithmType.md +12 -0
  29. compute_api_client/docs/AlgorithmsApi.md +428 -0
  30. compute_api_client/docs/AuthConfig.md +31 -0
  31. compute_api_client/docs/AuthConfigApi.md +71 -0
  32. compute_api_client/docs/Backend.md +35 -0
  33. compute_api_client/docs/BackendApi.md +418 -0
  34. compute_api_client/docs/BackendIn.md +34 -0
  35. compute_api_client/docs/BackendMessage.md +29 -0
  36. compute_api_client/docs/BackendPatch.md +31 -0
  37. compute_api_client/docs/BackendStatus.md +16 -0
  38. compute_api_client/docs/BackendType.md +48 -0
  39. compute_api_client/docs/BackendTypePatch.md +45 -0
  40. compute_api_client/docs/BackendTypesApi.md +289 -0
  41. compute_api_client/docs/BackendWithAuthentication.md +36 -0
  42. compute_api_client/docs/BatchJob.md +39 -0
  43. compute_api_client/docs/BatchJobIn.md +29 -0
  44. compute_api_client/docs/BatchJobStatus.md +18 -0
  45. compute_api_client/docs/BatchJobsApi.md +600 -0
  46. compute_api_client/docs/Commit.md +33 -0
  47. compute_api_client/docs/CommitIn.md +30 -0
  48. compute_api_client/docs/CommitsApi.md +425 -0
  49. compute_api_client/docs/CompilePayload.md +30 -0
  50. compute_api_client/docs/CompileStage.md +18 -0
  51. compute_api_client/docs/Domain.md +14 -0
  52. compute_api_client/docs/File.md +36 -0
  53. compute_api_client/docs/FileIn.md +35 -0
  54. compute_api_client/docs/FilesApi.md +346 -0
  55. compute_api_client/docs/FinalResult.md +32 -0
  56. compute_api_client/docs/FinalResultIn.md +30 -0
  57. compute_api_client/docs/FinalResultsApi.md +248 -0
  58. compute_api_client/docs/HTTPBadRequestError.md +29 -0
  59. compute_api_client/docs/HTTPNotFoundError.md +29 -0
  60. compute_api_client/docs/HTTPValidationError.md +29 -0
  61. compute_api_client/docs/HealthApi.md +72 -0
  62. compute_api_client/docs/Job.md +42 -0
  63. compute_api_client/docs/JobIn.md +32 -0
  64. compute_api_client/docs/JobPatch.md +34 -0
  65. compute_api_client/docs/JobStatus.md +18 -0
  66. compute_api_client/docs/JobsApi.md +460 -0
  67. compute_api_client/docs/Language.md +31 -0
  68. compute_api_client/docs/LanguagesApi.md +177 -0
  69. compute_api_client/docs/LocationInner.md +27 -0
  70. compute_api_client/docs/Member.md +33 -0
  71. compute_api_client/docs/MemberId.md +28 -0
  72. compute_api_client/docs/MemberIn.md +32 -0
  73. compute_api_client/docs/MembersApi.md +331 -0
  74. compute_api_client/docs/PageAlgorithm.md +33 -0
  75. compute_api_client/docs/PageBackend.md +33 -0
  76. compute_api_client/docs/PageBackendType.md +33 -0
  77. compute_api_client/docs/PageBatchJob.md +33 -0
  78. compute_api_client/docs/PageCommit.md +33 -0
  79. compute_api_client/docs/PageFile.md +33 -0
  80. compute_api_client/docs/PageJob.md +33 -0
  81. compute_api_client/docs/PageLanguage.md +33 -0
  82. compute_api_client/docs/PageMember.md +33 -0
  83. compute_api_client/docs/PageMetadata.md +32 -0
  84. compute_api_client/docs/PagePermission.md +33 -0
  85. compute_api_client/docs/PagePermissionGroup.md +33 -0
  86. compute_api_client/docs/PageProject.md +33 -0
  87. compute_api_client/docs/PageReservation.md +33 -0
  88. compute_api_client/docs/PageResult.md +33 -0
  89. compute_api_client/docs/PageTeam.md +33 -0
  90. compute_api_client/docs/PageTransaction.md +33 -0
  91. compute_api_client/docs/PageUser.md +33 -0
  92. compute_api_client/docs/Permission.md +31 -0
  93. compute_api_client/docs/PermissionGroup.md +30 -0
  94. compute_api_client/docs/PermissionsApi.md +340 -0
  95. compute_api_client/docs/Project.md +34 -0
  96. compute_api_client/docs/ProjectIn.md +32 -0
  97. compute_api_client/docs/ProjectPatch.md +32 -0
  98. compute_api_client/docs/ProjectsApi.md +502 -0
  99. compute_api_client/docs/Reservation.md +35 -0
  100. compute_api_client/docs/ReservationIn.md +32 -0
  101. compute_api_client/docs/ReservationsApi.md +341 -0
  102. compute_api_client/docs/Result.md +36 -0
  103. compute_api_client/docs/ResultIn.md +34 -0
  104. compute_api_client/docs/ResultsApi.md +439 -0
  105. compute_api_client/docs/Role.md +12 -0
  106. compute_api_client/docs/ShareType.md +14 -0
  107. compute_api_client/docs/Team.md +32 -0
  108. compute_api_client/docs/TeamsApi.md +177 -0
  109. compute_api_client/docs/Transaction.md +35 -0
  110. compute_api_client/docs/TransactionDomain.md +28 -0
  111. compute_api_client/docs/TransactionsApi.md +190 -0
  112. compute_api_client/docs/User.md +36 -0
  113. compute_api_client/docs/UserIn.md +35 -0
  114. compute_api_client/docs/UsersApi.md +338 -0
  115. compute_api_client/docs/ValidationError.md +31 -0
  116. compute_api_client/docs/ValidationErrorLocInner.md +28 -0
  117. compute_api_client/exceptions.py +216 -0
  118. compute_api_client/models/__init__.py +84 -0
  119. compute_api_client/models/algorithm.py +105 -0
  120. compute_api_client/models/algorithm_in.py +103 -0
  121. compute_api_client/models/algorithm_type.py +37 -0
  122. compute_api_client/models/auth_config.py +91 -0
  123. compute_api_client/models/backend.py +106 -0
  124. compute_api_client/models/backend_in.py +104 -0
  125. compute_api_client/models/backend_message.py +87 -0
  126. compute_api_client/models/backend_patch.py +112 -0
  127. compute_api_client/models/backend_status.py +39 -0
  128. compute_api_client/models/backend_type.py +145 -0
  129. compute_api_client/models/backend_type_patch.py +205 -0
  130. compute_api_client/models/backend_with_authentication.py +108 -0
  131. compute_api_client/models/batch_job.py +130 -0
  132. compute_api_client/models/batch_job_in.py +87 -0
  133. compute_api_client/models/batch_job_status.py +40 -0
  134. compute_api_client/models/commit.py +97 -0
  135. compute_api_client/models/commit_in.py +89 -0
  136. compute_api_client/models/compile_payload.py +95 -0
  137. compute_api_client/models/compile_stage.py +40 -0
  138. compute_api_client/models/domain.py +38 -0
  139. compute_api_client/models/file.py +108 -0
  140. compute_api_client/models/file_in.py +106 -0
  141. compute_api_client/models/final_result.py +94 -0
  142. compute_api_client/models/final_result_in.py +89 -0
  143. compute_api_client/models/http_bad_request_error.py +87 -0
  144. compute_api_client/models/http_not_found_error.py +87 -0
  145. compute_api_client/models/http_validation_error.py +95 -0
  146. compute_api_client/models/job.py +131 -0
  147. compute_api_client/models/job_in.py +98 -0
  148. compute_api_client/models/job_patch.py +99 -0
  149. compute_api_client/models/job_status.py +40 -0
  150. compute_api_client/models/language.py +92 -0
  151. compute_api_client/models/location_inner.py +144 -0
  152. compute_api_client/models/member.py +96 -0
  153. compute_api_client/models/member_id.py +144 -0
  154. compute_api_client/models/member_in.py +94 -0
  155. compute_api_client/models/metadata.py +93 -0
  156. compute_api_client/models/metadata_in.py +94 -0
  157. compute_api_client/models/page_algorithm.py +104 -0
  158. compute_api_client/models/page_backend.py +104 -0
  159. compute_api_client/models/page_backend_type.py +104 -0
  160. compute_api_client/models/page_batch_job.py +104 -0
  161. compute_api_client/models/page_commit.py +104 -0
  162. compute_api_client/models/page_file.py +104 -0
  163. compute_api_client/models/page_job.py +104 -0
  164. compute_api_client/models/page_language.py +104 -0
  165. compute_api_client/models/page_member.py +104 -0
  166. compute_api_client/models/page_metadata.py +125 -0
  167. compute_api_client/models/page_permission.py +104 -0
  168. compute_api_client/models/page_permission_group.py +104 -0
  169. compute_api_client/models/page_project.py +104 -0
  170. compute_api_client/models/page_reservation.py +104 -0
  171. compute_api_client/models/page_result.py +104 -0
  172. compute_api_client/models/page_team.py +104 -0
  173. compute_api_client/models/page_transaction.py +104 -0
  174. compute_api_client/models/page_user.py +104 -0
  175. compute_api_client/models/permission.py +92 -0
  176. compute_api_client/models/permission_group.py +90 -0
  177. compute_api_client/models/project.py +99 -0
  178. compute_api_client/models/project_in.py +94 -0
  179. compute_api_client/models/project_patch.py +114 -0
  180. compute_api_client/models/reservation.py +105 -0
  181. compute_api_client/models/reservation_in.py +94 -0
  182. compute_api_client/models/result.py +122 -0
  183. compute_api_client/models/result_in.py +117 -0
  184. compute_api_client/models/role.py +37 -0
  185. compute_api_client/models/share_type.py +38 -0
  186. compute_api_client/models/team.py +94 -0
  187. compute_api_client/models/transaction.py +117 -0
  188. compute_api_client/models/transaction_domain.py +142 -0
  189. compute_api_client/models/user.py +102 -0
  190. compute_api_client/models/user_in.py +100 -0
  191. compute_api_client/models/validation_error.py +99 -0
  192. compute_api_client/models/validation_error_loc_inner.py +138 -0
  193. compute_api_client/rest.py +213 -0
  194. qi2_shared/__init__.py +0 -0
  195. qi2_shared/authentication.py +66 -0
  196. qi2_shared/client.py +52 -0
  197. qi2_shared/hybrid/__init__.py +0 -0
  198. qi2_shared/hybrid/quantum_interface.py +45 -0
  199. qi2_shared/pagination.py +44 -0
  200. qi2_shared/settings.py +68 -0
  201. qi2_shared/utils.py +13 -0
  202. qi_compute_api_client-0.56.0.dist-info/METADATA +266 -0
  203. qi_compute_api_client-0.56.0.dist-info/RECORD +205 -0
  204. qi_compute_api_client-0.56.0.dist-info/WHEEL +4 -0
  205. qi_compute_api_client-0.56.0.dist-info/licenses/LICENSE.md +142 -0
@@ -0,0 +1,1305 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Quantum Inspire 2
5
+
6
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+
8
+ The version of the OpenAPI document: 0.1.0
9
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
10
+
11
+ Do not edit the class manually.
12
+ """ # noqa: E501
13
+
14
+ import warnings
15
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
16
+ from typing import Any, Dict, List, Optional, Tuple, Union
17
+ from typing_extensions import Annotated
18
+
19
+ from pydantic import Field, StrictBool, StrictInt, StrictStr
20
+ from typing import Optional
21
+ from typing_extensions import Annotated
22
+ from compute_api_client.models.page_user import PageUser
23
+ from compute_api_client.models.user import User
24
+ from compute_api_client.models.user_in import UserIn
25
+
26
+ from compute_api_client.api_client import ApiClient, RequestSerialized
27
+ from compute_api_client.api_response import ApiResponse
28
+ from compute_api_client.rest import RESTResponseType
29
+
30
+
31
+ class UsersApi:
32
+ """NOTE: This class is auto generated by OpenAPI Generator
33
+ Ref: https://openapi-generator.tech
34
+
35
+ Do not edit the class manually.
36
+ """
37
+
38
+ def __init__(self, api_client=None) -> None:
39
+ if api_client is None:
40
+ api_client = ApiClient.get_default()
41
+ self.api_client = api_client
42
+
43
+
44
+ @validate_call
45
+ async def create_user_users_post(
46
+ self,
47
+ user_in: UserIn,
48
+ _request_timeout: Union[
49
+ None,
50
+ Annotated[StrictFloat, Field(gt=0)],
51
+ Tuple[
52
+ Annotated[StrictFloat, Field(gt=0)],
53
+ Annotated[StrictFloat, Field(gt=0)]
54
+ ]
55
+ ] = None,
56
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
57
+ _content_type: Optional[StrictStr] = None,
58
+ _headers: Optional[Dict[StrictStr, Any]] = None,
59
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
60
+ ) -> User:
61
+ """Create user
62
+
63
+ Create new user.
64
+
65
+ :param user_in: (required)
66
+ :type user_in: UserIn
67
+ :param _request_timeout: timeout setting for this request. If one
68
+ number provided, it will be total request
69
+ timeout. It can also be a pair (tuple) of
70
+ (connection, read) timeouts.
71
+ :type _request_timeout: int, tuple(int, int), optional
72
+ :param _request_auth: set to override the auth_settings for an a single
73
+ request; this effectively ignores the
74
+ authentication in the spec for a single request.
75
+ :type _request_auth: dict, optional
76
+ :param _content_type: force content-type for the request.
77
+ :type _content_type: str, Optional
78
+ :param _headers: set to override the headers for a single
79
+ request; this effectively ignores the headers
80
+ in the spec for a single request.
81
+ :type _headers: dict, optional
82
+ :param _host_index: set to override the host_index for a single
83
+ request; this effectively ignores the host_index
84
+ in the spec for a single request.
85
+ :type _host_index: int, optional
86
+ :return: Returns the result object.
87
+ """ # noqa: E501
88
+
89
+ _param = self._create_user_users_post_serialize(
90
+ user_in=user_in,
91
+ _request_auth=_request_auth,
92
+ _content_type=_content_type,
93
+ _headers=_headers,
94
+ _host_index=_host_index
95
+ )
96
+
97
+ _response_types_map: Dict[str, Optional[str]] = {
98
+ '201': "User",
99
+ '422': "HTTPValidationError",
100
+ }
101
+ response_data = await self.api_client.call_api(
102
+ *_param,
103
+ _request_timeout=_request_timeout
104
+ )
105
+ await response_data.read()
106
+ return self.api_client.response_deserialize(
107
+ response_data=response_data,
108
+ response_types_map=_response_types_map,
109
+ ).data
110
+
111
+
112
+ @validate_call
113
+ async def create_user_users_post_with_http_info(
114
+ self,
115
+ user_in: UserIn,
116
+ _request_timeout: Union[
117
+ None,
118
+ Annotated[StrictFloat, Field(gt=0)],
119
+ Tuple[
120
+ Annotated[StrictFloat, Field(gt=0)],
121
+ Annotated[StrictFloat, Field(gt=0)]
122
+ ]
123
+ ] = None,
124
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
125
+ _content_type: Optional[StrictStr] = None,
126
+ _headers: Optional[Dict[StrictStr, Any]] = None,
127
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
128
+ ) -> ApiResponse[User]:
129
+ """Create user
130
+
131
+ Create new user.
132
+
133
+ :param user_in: (required)
134
+ :type user_in: UserIn
135
+ :param _request_timeout: timeout setting for this request. If one
136
+ number provided, it will be total request
137
+ timeout. It can also be a pair (tuple) of
138
+ (connection, read) timeouts.
139
+ :type _request_timeout: int, tuple(int, int), optional
140
+ :param _request_auth: set to override the auth_settings for an a single
141
+ request; this effectively ignores the
142
+ authentication in the spec for a single request.
143
+ :type _request_auth: dict, optional
144
+ :param _content_type: force content-type for the request.
145
+ :type _content_type: str, Optional
146
+ :param _headers: set to override the headers for a single
147
+ request; this effectively ignores the headers
148
+ in the spec for a single request.
149
+ :type _headers: dict, optional
150
+ :param _host_index: set to override the host_index for a single
151
+ request; this effectively ignores the host_index
152
+ in the spec for a single request.
153
+ :type _host_index: int, optional
154
+ :return: Returns the result object.
155
+ """ # noqa: E501
156
+
157
+ _param = self._create_user_users_post_serialize(
158
+ user_in=user_in,
159
+ _request_auth=_request_auth,
160
+ _content_type=_content_type,
161
+ _headers=_headers,
162
+ _host_index=_host_index
163
+ )
164
+
165
+ _response_types_map: Dict[str, Optional[str]] = {
166
+ '201': "User",
167
+ '422': "HTTPValidationError",
168
+ }
169
+ response_data = await self.api_client.call_api(
170
+ *_param,
171
+ _request_timeout=_request_timeout
172
+ )
173
+ await response_data.read()
174
+ return self.api_client.response_deserialize(
175
+ response_data=response_data,
176
+ response_types_map=_response_types_map,
177
+ )
178
+
179
+
180
+ @validate_call
181
+ async def create_user_users_post_without_preload_content(
182
+ self,
183
+ user_in: UserIn,
184
+ _request_timeout: Union[
185
+ None,
186
+ Annotated[StrictFloat, Field(gt=0)],
187
+ Tuple[
188
+ Annotated[StrictFloat, Field(gt=0)],
189
+ Annotated[StrictFloat, Field(gt=0)]
190
+ ]
191
+ ] = None,
192
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
193
+ _content_type: Optional[StrictStr] = None,
194
+ _headers: Optional[Dict[StrictStr, Any]] = None,
195
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
196
+ ) -> RESTResponseType:
197
+ """Create user
198
+
199
+ Create new user.
200
+
201
+ :param user_in: (required)
202
+ :type user_in: UserIn
203
+ :param _request_timeout: timeout setting for this request. If one
204
+ number provided, it will be total request
205
+ timeout. It can also be a pair (tuple) of
206
+ (connection, read) timeouts.
207
+ :type _request_timeout: int, tuple(int, int), optional
208
+ :param _request_auth: set to override the auth_settings for an a single
209
+ request; this effectively ignores the
210
+ authentication in the spec for a single request.
211
+ :type _request_auth: dict, optional
212
+ :param _content_type: force content-type for the request.
213
+ :type _content_type: str, Optional
214
+ :param _headers: set to override the headers for a single
215
+ request; this effectively ignores the headers
216
+ in the spec for a single request.
217
+ :type _headers: dict, optional
218
+ :param _host_index: set to override the host_index for a single
219
+ request; this effectively ignores the host_index
220
+ in the spec for a single request.
221
+ :type _host_index: int, optional
222
+ :return: Returns the result object.
223
+ """ # noqa: E501
224
+
225
+ _param = self._create_user_users_post_serialize(
226
+ user_in=user_in,
227
+ _request_auth=_request_auth,
228
+ _content_type=_content_type,
229
+ _headers=_headers,
230
+ _host_index=_host_index
231
+ )
232
+
233
+ _response_types_map: Dict[str, Optional[str]] = {
234
+ '201': "User",
235
+ '422': "HTTPValidationError",
236
+ }
237
+ response_data = await self.api_client.call_api(
238
+ *_param,
239
+ _request_timeout=_request_timeout
240
+ )
241
+ return response_data.response
242
+
243
+
244
+ def _create_user_users_post_serialize(
245
+ self,
246
+ user_in,
247
+ _request_auth,
248
+ _content_type,
249
+ _headers,
250
+ _host_index,
251
+ ) -> RequestSerialized:
252
+
253
+ _host = None
254
+
255
+ _collection_formats: Dict[str, str] = {
256
+ }
257
+
258
+ _path_params: Dict[str, str] = {}
259
+ _query_params: List[Tuple[str, str]] = []
260
+ _header_params: Dict[str, Optional[str]] = _headers or {}
261
+ _form_params: List[Tuple[str, str]] = []
262
+ _files: Dict[
263
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
264
+ ] = {}
265
+ _body_params: Optional[bytes] = None
266
+
267
+ # process the path parameters
268
+ # process the query parameters
269
+ # process the header parameters
270
+ # process the form parameters
271
+ # process the body parameter
272
+ if user_in is not None:
273
+ _body_params = user_in
274
+
275
+
276
+ # set the HTTP header `Accept`
277
+ if 'Accept' not in _header_params:
278
+ _header_params['Accept'] = self.api_client.select_header_accept(
279
+ [
280
+ 'application/json'
281
+ ]
282
+ )
283
+
284
+ # set the HTTP header `Content-Type`
285
+ if _content_type:
286
+ _header_params['Content-Type'] = _content_type
287
+ else:
288
+ _default_content_type = (
289
+ self.api_client.select_header_content_type(
290
+ [
291
+ 'application/json'
292
+ ]
293
+ )
294
+ )
295
+ if _default_content_type is not None:
296
+ _header_params['Content-Type'] = _default_content_type
297
+
298
+ # authentication setting
299
+ _auth_settings: List[str] = [
300
+ 'user_bearer'
301
+ ]
302
+
303
+ return self.api_client.param_serialize(
304
+ method='POST',
305
+ resource_path='/users',
306
+ path_params=_path_params,
307
+ query_params=_query_params,
308
+ header_params=_header_params,
309
+ body=_body_params,
310
+ post_params=_form_params,
311
+ files=_files,
312
+ auth_settings=_auth_settings,
313
+ collection_formats=_collection_formats,
314
+ _host=_host,
315
+ _request_auth=_request_auth
316
+ )
317
+
318
+
319
+
320
+
321
+ @validate_call
322
+ async def delete_user_users_id_delete(
323
+ self,
324
+ id: StrictInt,
325
+ _request_timeout: Union[
326
+ None,
327
+ Annotated[StrictFloat, Field(gt=0)],
328
+ Tuple[
329
+ Annotated[StrictFloat, Field(gt=0)],
330
+ Annotated[StrictFloat, Field(gt=0)]
331
+ ]
332
+ ] = None,
333
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
334
+ _content_type: Optional[StrictStr] = None,
335
+ _headers: Optional[Dict[StrictStr, Any]] = None,
336
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
337
+ ) -> None:
338
+ """Destroy user
339
+
340
+ Delete a user.
341
+
342
+ :param id: (required)
343
+ :type id: int
344
+ :param _request_timeout: timeout setting for this request. If one
345
+ number provided, it will be total request
346
+ timeout. It can also be a pair (tuple) of
347
+ (connection, read) timeouts.
348
+ :type _request_timeout: int, tuple(int, int), optional
349
+ :param _request_auth: set to override the auth_settings for an a single
350
+ request; this effectively ignores the
351
+ authentication in the spec for a single request.
352
+ :type _request_auth: dict, optional
353
+ :param _content_type: force content-type for the request.
354
+ :type _content_type: str, Optional
355
+ :param _headers: set to override the headers for a single
356
+ request; this effectively ignores the headers
357
+ in the spec for a single request.
358
+ :type _headers: dict, optional
359
+ :param _host_index: set to override the host_index for a single
360
+ request; this effectively ignores the host_index
361
+ in the spec for a single request.
362
+ :type _host_index: int, optional
363
+ :return: Returns the result object.
364
+ """ # noqa: E501
365
+
366
+ _param = self._delete_user_users_id_delete_serialize(
367
+ id=id,
368
+ _request_auth=_request_auth,
369
+ _content_type=_content_type,
370
+ _headers=_headers,
371
+ _host_index=_host_index
372
+ )
373
+
374
+ _response_types_map: Dict[str, Optional[str]] = {
375
+ '204': None,
376
+ '404': "HTTPNotFoundError",
377
+ '422': "HTTPValidationError",
378
+ }
379
+ response_data = await self.api_client.call_api(
380
+ *_param,
381
+ _request_timeout=_request_timeout
382
+ )
383
+ await response_data.read()
384
+ return self.api_client.response_deserialize(
385
+ response_data=response_data,
386
+ response_types_map=_response_types_map,
387
+ ).data
388
+
389
+
390
+ @validate_call
391
+ async def delete_user_users_id_delete_with_http_info(
392
+ self,
393
+ id: StrictInt,
394
+ _request_timeout: Union[
395
+ None,
396
+ Annotated[StrictFloat, Field(gt=0)],
397
+ Tuple[
398
+ Annotated[StrictFloat, Field(gt=0)],
399
+ Annotated[StrictFloat, Field(gt=0)]
400
+ ]
401
+ ] = None,
402
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
403
+ _content_type: Optional[StrictStr] = None,
404
+ _headers: Optional[Dict[StrictStr, Any]] = None,
405
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
406
+ ) -> ApiResponse[None]:
407
+ """Destroy user
408
+
409
+ Delete a user.
410
+
411
+ :param id: (required)
412
+ :type id: int
413
+ :param _request_timeout: timeout setting for this request. If one
414
+ number provided, it will be total request
415
+ timeout. It can also be a pair (tuple) of
416
+ (connection, read) timeouts.
417
+ :type _request_timeout: int, tuple(int, int), optional
418
+ :param _request_auth: set to override the auth_settings for an a single
419
+ request; this effectively ignores the
420
+ authentication in the spec for a single request.
421
+ :type _request_auth: dict, optional
422
+ :param _content_type: force content-type for the request.
423
+ :type _content_type: str, Optional
424
+ :param _headers: set to override the headers for a single
425
+ request; this effectively ignores the headers
426
+ in the spec for a single request.
427
+ :type _headers: dict, optional
428
+ :param _host_index: set to override the host_index for a single
429
+ request; this effectively ignores the host_index
430
+ in the spec for a single request.
431
+ :type _host_index: int, optional
432
+ :return: Returns the result object.
433
+ """ # noqa: E501
434
+
435
+ _param = self._delete_user_users_id_delete_serialize(
436
+ id=id,
437
+ _request_auth=_request_auth,
438
+ _content_type=_content_type,
439
+ _headers=_headers,
440
+ _host_index=_host_index
441
+ )
442
+
443
+ _response_types_map: Dict[str, Optional[str]] = {
444
+ '204': None,
445
+ '404': "HTTPNotFoundError",
446
+ '422': "HTTPValidationError",
447
+ }
448
+ response_data = await self.api_client.call_api(
449
+ *_param,
450
+ _request_timeout=_request_timeout
451
+ )
452
+ await response_data.read()
453
+ return self.api_client.response_deserialize(
454
+ response_data=response_data,
455
+ response_types_map=_response_types_map,
456
+ )
457
+
458
+
459
+ @validate_call
460
+ async def delete_user_users_id_delete_without_preload_content(
461
+ self,
462
+ id: StrictInt,
463
+ _request_timeout: Union[
464
+ None,
465
+ Annotated[StrictFloat, Field(gt=0)],
466
+ Tuple[
467
+ Annotated[StrictFloat, Field(gt=0)],
468
+ Annotated[StrictFloat, Field(gt=0)]
469
+ ]
470
+ ] = None,
471
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
472
+ _content_type: Optional[StrictStr] = None,
473
+ _headers: Optional[Dict[StrictStr, Any]] = None,
474
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
475
+ ) -> RESTResponseType:
476
+ """Destroy user
477
+
478
+ Delete a user.
479
+
480
+ :param id: (required)
481
+ :type id: int
482
+ :param _request_timeout: timeout setting for this request. If one
483
+ number provided, it will be total request
484
+ timeout. It can also be a pair (tuple) of
485
+ (connection, read) timeouts.
486
+ :type _request_timeout: int, tuple(int, int), optional
487
+ :param _request_auth: set to override the auth_settings for an a single
488
+ request; this effectively ignores the
489
+ authentication in the spec for a single request.
490
+ :type _request_auth: dict, optional
491
+ :param _content_type: force content-type for the request.
492
+ :type _content_type: str, Optional
493
+ :param _headers: set to override the headers for a single
494
+ request; this effectively ignores the headers
495
+ in the spec for a single request.
496
+ :type _headers: dict, optional
497
+ :param _host_index: set to override the host_index for a single
498
+ request; this effectively ignores the host_index
499
+ in the spec for a single request.
500
+ :type _host_index: int, optional
501
+ :return: Returns the result object.
502
+ """ # noqa: E501
503
+
504
+ _param = self._delete_user_users_id_delete_serialize(
505
+ id=id,
506
+ _request_auth=_request_auth,
507
+ _content_type=_content_type,
508
+ _headers=_headers,
509
+ _host_index=_host_index
510
+ )
511
+
512
+ _response_types_map: Dict[str, Optional[str]] = {
513
+ '204': None,
514
+ '404': "HTTPNotFoundError",
515
+ '422': "HTTPValidationError",
516
+ }
517
+ response_data = await self.api_client.call_api(
518
+ *_param,
519
+ _request_timeout=_request_timeout
520
+ )
521
+ return response_data.response
522
+
523
+
524
+ def _delete_user_users_id_delete_serialize(
525
+ self,
526
+ id,
527
+ _request_auth,
528
+ _content_type,
529
+ _headers,
530
+ _host_index,
531
+ ) -> RequestSerialized:
532
+
533
+ _host = None
534
+
535
+ _collection_formats: Dict[str, str] = {
536
+ }
537
+
538
+ _path_params: Dict[str, str] = {}
539
+ _query_params: List[Tuple[str, str]] = []
540
+ _header_params: Dict[str, Optional[str]] = _headers or {}
541
+ _form_params: List[Tuple[str, str]] = []
542
+ _files: Dict[
543
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
544
+ ] = {}
545
+ _body_params: Optional[bytes] = None
546
+
547
+ # process the path parameters
548
+ if id is not None:
549
+ _path_params['id'] = id
550
+ # process the query parameters
551
+ # process the header parameters
552
+ # process the form parameters
553
+ # process the body parameter
554
+
555
+
556
+ # set the HTTP header `Accept`
557
+ if 'Accept' not in _header_params:
558
+ _header_params['Accept'] = self.api_client.select_header_accept(
559
+ [
560
+ 'application/json'
561
+ ]
562
+ )
563
+
564
+
565
+ # authentication setting
566
+ _auth_settings: List[str] = [
567
+ 'user_bearer'
568
+ ]
569
+
570
+ return self.api_client.param_serialize(
571
+ method='DELETE',
572
+ resource_path='/users/{id}',
573
+ path_params=_path_params,
574
+ query_params=_query_params,
575
+ header_params=_header_params,
576
+ body=_body_params,
577
+ post_params=_form_params,
578
+ files=_files,
579
+ auth_settings=_auth_settings,
580
+ collection_formats=_collection_formats,
581
+ _host=_host,
582
+ _request_auth=_request_auth
583
+ )
584
+
585
+
586
+
587
+
588
+ @validate_call
589
+ async def read_user_users_id_get(
590
+ self,
591
+ id: StrictInt,
592
+ _request_timeout: Union[
593
+ None,
594
+ Annotated[StrictFloat, Field(gt=0)],
595
+ Tuple[
596
+ Annotated[StrictFloat, Field(gt=0)],
597
+ Annotated[StrictFloat, Field(gt=0)]
598
+ ]
599
+ ] = None,
600
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
601
+ _content_type: Optional[StrictStr] = None,
602
+ _headers: Optional[Dict[StrictStr, Any]] = None,
603
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
604
+ ) -> User:
605
+ """Retrieve user
606
+
607
+ Get user by ID.
608
+
609
+ :param id: (required)
610
+ :type id: int
611
+ :param _request_timeout: timeout setting for this request. If one
612
+ number provided, it will be total request
613
+ timeout. It can also be a pair (tuple) of
614
+ (connection, read) timeouts.
615
+ :type _request_timeout: int, tuple(int, int), optional
616
+ :param _request_auth: set to override the auth_settings for an a single
617
+ request; this effectively ignores the
618
+ authentication in the spec for a single request.
619
+ :type _request_auth: dict, optional
620
+ :param _content_type: force content-type for the request.
621
+ :type _content_type: str, Optional
622
+ :param _headers: set to override the headers for a single
623
+ request; this effectively ignores the headers
624
+ in the spec for a single request.
625
+ :type _headers: dict, optional
626
+ :param _host_index: set to override the host_index for a single
627
+ request; this effectively ignores the host_index
628
+ in the spec for a single request.
629
+ :type _host_index: int, optional
630
+ :return: Returns the result object.
631
+ """ # noqa: E501
632
+
633
+ _param = self._read_user_users_id_get_serialize(
634
+ id=id,
635
+ _request_auth=_request_auth,
636
+ _content_type=_content_type,
637
+ _headers=_headers,
638
+ _host_index=_host_index
639
+ )
640
+
641
+ _response_types_map: Dict[str, Optional[str]] = {
642
+ '200': "User",
643
+ '404': "HTTPNotFoundError",
644
+ '422': "HTTPValidationError",
645
+ }
646
+ response_data = await self.api_client.call_api(
647
+ *_param,
648
+ _request_timeout=_request_timeout
649
+ )
650
+ await response_data.read()
651
+ return self.api_client.response_deserialize(
652
+ response_data=response_data,
653
+ response_types_map=_response_types_map,
654
+ ).data
655
+
656
+
657
+ @validate_call
658
+ async def read_user_users_id_get_with_http_info(
659
+ self,
660
+ id: StrictInt,
661
+ _request_timeout: Union[
662
+ None,
663
+ Annotated[StrictFloat, Field(gt=0)],
664
+ Tuple[
665
+ Annotated[StrictFloat, Field(gt=0)],
666
+ Annotated[StrictFloat, Field(gt=0)]
667
+ ]
668
+ ] = None,
669
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
670
+ _content_type: Optional[StrictStr] = None,
671
+ _headers: Optional[Dict[StrictStr, Any]] = None,
672
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
673
+ ) -> ApiResponse[User]:
674
+ """Retrieve user
675
+
676
+ Get user by ID.
677
+
678
+ :param id: (required)
679
+ :type id: int
680
+ :param _request_timeout: timeout setting for this request. If one
681
+ number provided, it will be total request
682
+ timeout. It can also be a pair (tuple) of
683
+ (connection, read) timeouts.
684
+ :type _request_timeout: int, tuple(int, int), optional
685
+ :param _request_auth: set to override the auth_settings for an a single
686
+ request; this effectively ignores the
687
+ authentication in the spec for a single request.
688
+ :type _request_auth: dict, optional
689
+ :param _content_type: force content-type for the request.
690
+ :type _content_type: str, Optional
691
+ :param _headers: set to override the headers for a single
692
+ request; this effectively ignores the headers
693
+ in the spec for a single request.
694
+ :type _headers: dict, optional
695
+ :param _host_index: set to override the host_index for a single
696
+ request; this effectively ignores the host_index
697
+ in the spec for a single request.
698
+ :type _host_index: int, optional
699
+ :return: Returns the result object.
700
+ """ # noqa: E501
701
+
702
+ _param = self._read_user_users_id_get_serialize(
703
+ id=id,
704
+ _request_auth=_request_auth,
705
+ _content_type=_content_type,
706
+ _headers=_headers,
707
+ _host_index=_host_index
708
+ )
709
+
710
+ _response_types_map: Dict[str, Optional[str]] = {
711
+ '200': "User",
712
+ '404': "HTTPNotFoundError",
713
+ '422': "HTTPValidationError",
714
+ }
715
+ response_data = await self.api_client.call_api(
716
+ *_param,
717
+ _request_timeout=_request_timeout
718
+ )
719
+ await response_data.read()
720
+ return self.api_client.response_deserialize(
721
+ response_data=response_data,
722
+ response_types_map=_response_types_map,
723
+ )
724
+
725
+
726
+ @validate_call
727
+ async def read_user_users_id_get_without_preload_content(
728
+ self,
729
+ id: StrictInt,
730
+ _request_timeout: Union[
731
+ None,
732
+ Annotated[StrictFloat, Field(gt=0)],
733
+ Tuple[
734
+ Annotated[StrictFloat, Field(gt=0)],
735
+ Annotated[StrictFloat, Field(gt=0)]
736
+ ]
737
+ ] = None,
738
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
739
+ _content_type: Optional[StrictStr] = None,
740
+ _headers: Optional[Dict[StrictStr, Any]] = None,
741
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
742
+ ) -> RESTResponseType:
743
+ """Retrieve user
744
+
745
+ Get user by ID.
746
+
747
+ :param id: (required)
748
+ :type id: int
749
+ :param _request_timeout: timeout setting for this request. If one
750
+ number provided, it will be total request
751
+ timeout. It can also be a pair (tuple) of
752
+ (connection, read) timeouts.
753
+ :type _request_timeout: int, tuple(int, int), optional
754
+ :param _request_auth: set to override the auth_settings for an a single
755
+ request; this effectively ignores the
756
+ authentication in the spec for a single request.
757
+ :type _request_auth: dict, optional
758
+ :param _content_type: force content-type for the request.
759
+ :type _content_type: str, Optional
760
+ :param _headers: set to override the headers for a single
761
+ request; this effectively ignores the headers
762
+ in the spec for a single request.
763
+ :type _headers: dict, optional
764
+ :param _host_index: set to override the host_index for a single
765
+ request; this effectively ignores the host_index
766
+ in the spec for a single request.
767
+ :type _host_index: int, optional
768
+ :return: Returns the result object.
769
+ """ # noqa: E501
770
+
771
+ _param = self._read_user_users_id_get_serialize(
772
+ id=id,
773
+ _request_auth=_request_auth,
774
+ _content_type=_content_type,
775
+ _headers=_headers,
776
+ _host_index=_host_index
777
+ )
778
+
779
+ _response_types_map: Dict[str, Optional[str]] = {
780
+ '200': "User",
781
+ '404': "HTTPNotFoundError",
782
+ '422': "HTTPValidationError",
783
+ }
784
+ response_data = await self.api_client.call_api(
785
+ *_param,
786
+ _request_timeout=_request_timeout
787
+ )
788
+ return response_data.response
789
+
790
+
791
+ def _read_user_users_id_get_serialize(
792
+ self,
793
+ id,
794
+ _request_auth,
795
+ _content_type,
796
+ _headers,
797
+ _host_index,
798
+ ) -> RequestSerialized:
799
+
800
+ _host = None
801
+
802
+ _collection_formats: Dict[str, str] = {
803
+ }
804
+
805
+ _path_params: Dict[str, str] = {}
806
+ _query_params: List[Tuple[str, str]] = []
807
+ _header_params: Dict[str, Optional[str]] = _headers or {}
808
+ _form_params: List[Tuple[str, str]] = []
809
+ _files: Dict[
810
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
811
+ ] = {}
812
+ _body_params: Optional[bytes] = None
813
+
814
+ # process the path parameters
815
+ if id is not None:
816
+ _path_params['id'] = id
817
+ # process the query parameters
818
+ # process the header parameters
819
+ # process the form parameters
820
+ # process the body parameter
821
+
822
+
823
+ # set the HTTP header `Accept`
824
+ if 'Accept' not in _header_params:
825
+ _header_params['Accept'] = self.api_client.select_header_accept(
826
+ [
827
+ 'application/json'
828
+ ]
829
+ )
830
+
831
+
832
+ # authentication setting
833
+ _auth_settings: List[str] = [
834
+ 'user_bearer'
835
+ ]
836
+
837
+ return self.api_client.param_serialize(
838
+ method='GET',
839
+ resource_path='/users/{id}',
840
+ path_params=_path_params,
841
+ query_params=_query_params,
842
+ header_params=_header_params,
843
+ body=_body_params,
844
+ post_params=_form_params,
845
+ files=_files,
846
+ auth_settings=_auth_settings,
847
+ collection_formats=_collection_formats,
848
+ _host=_host,
849
+ _request_auth=_request_auth
850
+ )
851
+
852
+
853
+
854
+
855
+ @validate_call
856
+ async def read_users_users_get(
857
+ self,
858
+ id: Optional[StrictInt] = None,
859
+ full_name: Optional[StrictStr] = None,
860
+ email: Optional[StrictStr] = None,
861
+ is_superuser: Optional[StrictBool] = None,
862
+ is_staff: Optional[StrictBool] = None,
863
+ is_active: Optional[StrictBool] = None,
864
+ is_confirmed: Optional[StrictBool] = None,
865
+ oidc_sub: Optional[StrictStr] = None,
866
+ sort_by: Annotated[Optional[StrictStr], Field(description="The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.")] = None,
867
+ latest: Annotated[Optional[StrictBool], Field(description="If True gets the most recently created object.")] = None,
868
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number")] = None,
869
+ size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Page size")] = None,
870
+ _request_timeout: Union[
871
+ None,
872
+ Annotated[StrictFloat, Field(gt=0)],
873
+ Tuple[
874
+ Annotated[StrictFloat, Field(gt=0)],
875
+ Annotated[StrictFloat, Field(gt=0)]
876
+ ]
877
+ ] = None,
878
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
879
+ _content_type: Optional[StrictStr] = None,
880
+ _headers: Optional[Dict[StrictStr, Any]] = None,
881
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
882
+ ) -> PageUser:
883
+ """List users
884
+
885
+ Read users.
886
+
887
+ :param id:
888
+ :type id: int
889
+ :param full_name:
890
+ :type full_name: str
891
+ :param email:
892
+ :type email: str
893
+ :param is_superuser:
894
+ :type is_superuser: bool
895
+ :param is_staff:
896
+ :type is_staff: bool
897
+ :param is_active:
898
+ :type is_active: bool
899
+ :param is_confirmed:
900
+ :type is_confirmed: bool
901
+ :param oidc_sub:
902
+ :type oidc_sub: str
903
+ :param sort_by: The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.
904
+ :type sort_by: str
905
+ :param latest: If True gets the most recently created object.
906
+ :type latest: bool
907
+ :param page: Page number
908
+ :type page: int
909
+ :param size: Page size
910
+ :type size: int
911
+ :param _request_timeout: timeout setting for this request. If one
912
+ number provided, it will be total request
913
+ timeout. It can also be a pair (tuple) of
914
+ (connection, read) timeouts.
915
+ :type _request_timeout: int, tuple(int, int), optional
916
+ :param _request_auth: set to override the auth_settings for an a single
917
+ request; this effectively ignores the
918
+ authentication in the spec for a single request.
919
+ :type _request_auth: dict, optional
920
+ :param _content_type: force content-type for the request.
921
+ :type _content_type: str, Optional
922
+ :param _headers: set to override the headers for a single
923
+ request; this effectively ignores the headers
924
+ in the spec for a single request.
925
+ :type _headers: dict, optional
926
+ :param _host_index: set to override the host_index for a single
927
+ request; this effectively ignores the host_index
928
+ in the spec for a single request.
929
+ :type _host_index: int, optional
930
+ :return: Returns the result object.
931
+ """ # noqa: E501
932
+
933
+ _param = self._read_users_users_get_serialize(
934
+ id=id,
935
+ full_name=full_name,
936
+ email=email,
937
+ is_superuser=is_superuser,
938
+ is_staff=is_staff,
939
+ is_active=is_active,
940
+ is_confirmed=is_confirmed,
941
+ oidc_sub=oidc_sub,
942
+ sort_by=sort_by,
943
+ latest=latest,
944
+ page=page,
945
+ size=size,
946
+ _request_auth=_request_auth,
947
+ _content_type=_content_type,
948
+ _headers=_headers,
949
+ _host_index=_host_index
950
+ )
951
+
952
+ _response_types_map: Dict[str, Optional[str]] = {
953
+ '200': "PageUser",
954
+ '422': "HTTPValidationError",
955
+ }
956
+ response_data = await self.api_client.call_api(
957
+ *_param,
958
+ _request_timeout=_request_timeout
959
+ )
960
+ await response_data.read()
961
+ return self.api_client.response_deserialize(
962
+ response_data=response_data,
963
+ response_types_map=_response_types_map,
964
+ ).data
965
+
966
+
967
+ @validate_call
968
+ async def read_users_users_get_with_http_info(
969
+ self,
970
+ id: Optional[StrictInt] = None,
971
+ full_name: Optional[StrictStr] = None,
972
+ email: Optional[StrictStr] = None,
973
+ is_superuser: Optional[StrictBool] = None,
974
+ is_staff: Optional[StrictBool] = None,
975
+ is_active: Optional[StrictBool] = None,
976
+ is_confirmed: Optional[StrictBool] = None,
977
+ oidc_sub: Optional[StrictStr] = None,
978
+ sort_by: Annotated[Optional[StrictStr], Field(description="The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.")] = None,
979
+ latest: Annotated[Optional[StrictBool], Field(description="If True gets the most recently created object.")] = None,
980
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number")] = None,
981
+ size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Page size")] = None,
982
+ _request_timeout: Union[
983
+ None,
984
+ Annotated[StrictFloat, Field(gt=0)],
985
+ Tuple[
986
+ Annotated[StrictFloat, Field(gt=0)],
987
+ Annotated[StrictFloat, Field(gt=0)]
988
+ ]
989
+ ] = None,
990
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
991
+ _content_type: Optional[StrictStr] = None,
992
+ _headers: Optional[Dict[StrictStr, Any]] = None,
993
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
994
+ ) -> ApiResponse[PageUser]:
995
+ """List users
996
+
997
+ Read users.
998
+
999
+ :param id:
1000
+ :type id: int
1001
+ :param full_name:
1002
+ :type full_name: str
1003
+ :param email:
1004
+ :type email: str
1005
+ :param is_superuser:
1006
+ :type is_superuser: bool
1007
+ :param is_staff:
1008
+ :type is_staff: bool
1009
+ :param is_active:
1010
+ :type is_active: bool
1011
+ :param is_confirmed:
1012
+ :type is_confirmed: bool
1013
+ :param oidc_sub:
1014
+ :type oidc_sub: str
1015
+ :param sort_by: The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.
1016
+ :type sort_by: str
1017
+ :param latest: If True gets the most recently created object.
1018
+ :type latest: bool
1019
+ :param page: Page number
1020
+ :type page: int
1021
+ :param size: Page size
1022
+ :type size: int
1023
+ :param _request_timeout: timeout setting for this request. If one
1024
+ number provided, it will be total request
1025
+ timeout. It can also be a pair (tuple) of
1026
+ (connection, read) timeouts.
1027
+ :type _request_timeout: int, tuple(int, int), optional
1028
+ :param _request_auth: set to override the auth_settings for an a single
1029
+ request; this effectively ignores the
1030
+ authentication in the spec for a single request.
1031
+ :type _request_auth: dict, optional
1032
+ :param _content_type: force content-type for the request.
1033
+ :type _content_type: str, Optional
1034
+ :param _headers: set to override the headers for a single
1035
+ request; this effectively ignores the headers
1036
+ in the spec for a single request.
1037
+ :type _headers: dict, optional
1038
+ :param _host_index: set to override the host_index for a single
1039
+ request; this effectively ignores the host_index
1040
+ in the spec for a single request.
1041
+ :type _host_index: int, optional
1042
+ :return: Returns the result object.
1043
+ """ # noqa: E501
1044
+
1045
+ _param = self._read_users_users_get_serialize(
1046
+ id=id,
1047
+ full_name=full_name,
1048
+ email=email,
1049
+ is_superuser=is_superuser,
1050
+ is_staff=is_staff,
1051
+ is_active=is_active,
1052
+ is_confirmed=is_confirmed,
1053
+ oidc_sub=oidc_sub,
1054
+ sort_by=sort_by,
1055
+ latest=latest,
1056
+ page=page,
1057
+ size=size,
1058
+ _request_auth=_request_auth,
1059
+ _content_type=_content_type,
1060
+ _headers=_headers,
1061
+ _host_index=_host_index
1062
+ )
1063
+
1064
+ _response_types_map: Dict[str, Optional[str]] = {
1065
+ '200': "PageUser",
1066
+ '422': "HTTPValidationError",
1067
+ }
1068
+ response_data = await self.api_client.call_api(
1069
+ *_param,
1070
+ _request_timeout=_request_timeout
1071
+ )
1072
+ await response_data.read()
1073
+ return self.api_client.response_deserialize(
1074
+ response_data=response_data,
1075
+ response_types_map=_response_types_map,
1076
+ )
1077
+
1078
+
1079
+ @validate_call
1080
+ async def read_users_users_get_without_preload_content(
1081
+ self,
1082
+ id: Optional[StrictInt] = None,
1083
+ full_name: Optional[StrictStr] = None,
1084
+ email: Optional[StrictStr] = None,
1085
+ is_superuser: Optional[StrictBool] = None,
1086
+ is_staff: Optional[StrictBool] = None,
1087
+ is_active: Optional[StrictBool] = None,
1088
+ is_confirmed: Optional[StrictBool] = None,
1089
+ oidc_sub: Optional[StrictStr] = None,
1090
+ sort_by: Annotated[Optional[StrictStr], Field(description="The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.")] = None,
1091
+ latest: Annotated[Optional[StrictBool], Field(description="If True gets the most recently created object.")] = None,
1092
+ page: Annotated[Optional[Annotated[int, Field(strict=True, ge=1)]], Field(description="Page number")] = None,
1093
+ size: Annotated[Optional[Annotated[int, Field(le=100, strict=True, ge=1)]], Field(description="Page size")] = None,
1094
+ _request_timeout: Union[
1095
+ None,
1096
+ Annotated[StrictFloat, Field(gt=0)],
1097
+ Tuple[
1098
+ Annotated[StrictFloat, Field(gt=0)],
1099
+ Annotated[StrictFloat, Field(gt=0)]
1100
+ ]
1101
+ ] = None,
1102
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
1103
+ _content_type: Optional[StrictStr] = None,
1104
+ _headers: Optional[Dict[StrictStr, Any]] = None,
1105
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1106
+ ) -> RESTResponseType:
1107
+ """List users
1108
+
1109
+ Read users.
1110
+
1111
+ :param id:
1112
+ :type id: int
1113
+ :param full_name:
1114
+ :type full_name: str
1115
+ :param email:
1116
+ :type email: str
1117
+ :param is_superuser:
1118
+ :type is_superuser: bool
1119
+ :param is_staff:
1120
+ :type is_staff: bool
1121
+ :param is_active:
1122
+ :type is_active: bool
1123
+ :param is_confirmed:
1124
+ :type is_confirmed: bool
1125
+ :param oidc_sub:
1126
+ :type oidc_sub: str
1127
+ :param sort_by: The field name to sort on. Prefix with '-' for descending order. E.g., '-created_on'.
1128
+ :type sort_by: str
1129
+ :param latest: If True gets the most recently created object.
1130
+ :type latest: bool
1131
+ :param page: Page number
1132
+ :type page: int
1133
+ :param size: Page size
1134
+ :type size: int
1135
+ :param _request_timeout: timeout setting for this request. If one
1136
+ number provided, it will be total request
1137
+ timeout. It can also be a pair (tuple) of
1138
+ (connection, read) timeouts.
1139
+ :type _request_timeout: int, tuple(int, int), optional
1140
+ :param _request_auth: set to override the auth_settings for an a single
1141
+ request; this effectively ignores the
1142
+ authentication in the spec for a single request.
1143
+ :type _request_auth: dict, optional
1144
+ :param _content_type: force content-type for the request.
1145
+ :type _content_type: str, Optional
1146
+ :param _headers: set to override the headers for a single
1147
+ request; this effectively ignores the headers
1148
+ in the spec for a single request.
1149
+ :type _headers: dict, optional
1150
+ :param _host_index: set to override the host_index for a single
1151
+ request; this effectively ignores the host_index
1152
+ in the spec for a single request.
1153
+ :type _host_index: int, optional
1154
+ :return: Returns the result object.
1155
+ """ # noqa: E501
1156
+
1157
+ _param = self._read_users_users_get_serialize(
1158
+ id=id,
1159
+ full_name=full_name,
1160
+ email=email,
1161
+ is_superuser=is_superuser,
1162
+ is_staff=is_staff,
1163
+ is_active=is_active,
1164
+ is_confirmed=is_confirmed,
1165
+ oidc_sub=oidc_sub,
1166
+ sort_by=sort_by,
1167
+ latest=latest,
1168
+ page=page,
1169
+ size=size,
1170
+ _request_auth=_request_auth,
1171
+ _content_type=_content_type,
1172
+ _headers=_headers,
1173
+ _host_index=_host_index
1174
+ )
1175
+
1176
+ _response_types_map: Dict[str, Optional[str]] = {
1177
+ '200': "PageUser",
1178
+ '422': "HTTPValidationError",
1179
+ }
1180
+ response_data = await self.api_client.call_api(
1181
+ *_param,
1182
+ _request_timeout=_request_timeout
1183
+ )
1184
+ return response_data.response
1185
+
1186
+
1187
+ def _read_users_users_get_serialize(
1188
+ self,
1189
+ id,
1190
+ full_name,
1191
+ email,
1192
+ is_superuser,
1193
+ is_staff,
1194
+ is_active,
1195
+ is_confirmed,
1196
+ oidc_sub,
1197
+ sort_by,
1198
+ latest,
1199
+ page,
1200
+ size,
1201
+ _request_auth,
1202
+ _content_type,
1203
+ _headers,
1204
+ _host_index,
1205
+ ) -> RequestSerialized:
1206
+
1207
+ _host = None
1208
+
1209
+ _collection_formats: Dict[str, str] = {
1210
+ }
1211
+
1212
+ _path_params: Dict[str, str] = {}
1213
+ _query_params: List[Tuple[str, str]] = []
1214
+ _header_params: Dict[str, Optional[str]] = _headers or {}
1215
+ _form_params: List[Tuple[str, str]] = []
1216
+ _files: Dict[
1217
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
1218
+ ] = {}
1219
+ _body_params: Optional[bytes] = None
1220
+
1221
+ # process the path parameters
1222
+ # process the query parameters
1223
+ if id is not None:
1224
+
1225
+ _query_params.append(('id', id))
1226
+
1227
+ if full_name is not None:
1228
+
1229
+ _query_params.append(('full_name', full_name))
1230
+
1231
+ if email is not None:
1232
+
1233
+ _query_params.append(('email', email))
1234
+
1235
+ if is_superuser is not None:
1236
+
1237
+ _query_params.append(('is_superuser', is_superuser))
1238
+
1239
+ if is_staff is not None:
1240
+
1241
+ _query_params.append(('is_staff', is_staff))
1242
+
1243
+ if is_active is not None:
1244
+
1245
+ _query_params.append(('is_active', is_active))
1246
+
1247
+ if is_confirmed is not None:
1248
+
1249
+ _query_params.append(('is_confirmed', is_confirmed))
1250
+
1251
+ if oidc_sub is not None:
1252
+
1253
+ _query_params.append(('oidc_sub', oidc_sub))
1254
+
1255
+ if sort_by is not None:
1256
+
1257
+ _query_params.append(('sort_by', sort_by))
1258
+
1259
+ if latest is not None:
1260
+
1261
+ _query_params.append(('latest', latest))
1262
+
1263
+ if page is not None:
1264
+
1265
+ _query_params.append(('page', page))
1266
+
1267
+ if size is not None:
1268
+
1269
+ _query_params.append(('size', size))
1270
+
1271
+ # process the header parameters
1272
+ # process the form parameters
1273
+ # process the body parameter
1274
+
1275
+
1276
+ # set the HTTP header `Accept`
1277
+ if 'Accept' not in _header_params:
1278
+ _header_params['Accept'] = self.api_client.select_header_accept(
1279
+ [
1280
+ 'application/json'
1281
+ ]
1282
+ )
1283
+
1284
+
1285
+ # authentication setting
1286
+ _auth_settings: List[str] = [
1287
+ 'user_bearer'
1288
+ ]
1289
+
1290
+ return self.api_client.param_serialize(
1291
+ method='GET',
1292
+ resource_path='/users',
1293
+ path_params=_path_params,
1294
+ query_params=_query_params,
1295
+ header_params=_header_params,
1296
+ body=_body_params,
1297
+ post_params=_form_params,
1298
+ files=_files,
1299
+ auth_settings=_auth_settings,
1300
+ collection_formats=_collection_formats,
1301
+ _host=_host,
1302
+ _request_auth=_request_auth
1303
+ )
1304
+
1305
+