crc-pulpcore-client 20250821.3__py3-none-any.whl → 20250825.1__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.

Potentially problematic release.


This version of crc-pulpcore-client might be problematic. Click here for more details.

Files changed (86) hide show
  1. crc-pulpcore-client/api/__init__.py +1 -0
  2. crc-pulpcore-client/api/content_api.py +12 -12
  3. crc-pulpcore-client/api/distributions_api.py +12 -12
  4. crc-pulpcore-client/api/remotes_api.py +12 -12
  5. crc-pulpcore-client/api/repositories_api.py +12 -12
  6. crc-pulpcore-client/api/vuln_report_api.py +977 -0
  7. crc-pulpcore-client/api_client.py +1 -1
  8. crc-pulpcore-client/configuration.py +3 -3
  9. crc-pulpcore-client/models/__init__.py +2 -0
  10. crc-pulpcore-client/models/artifact_distribution_response.py +16 -16
  11. crc-pulpcore-client/models/filesystem_export_response.py +0 -2
  12. crc-pulpcore-client/models/generic_remote_response.py +1 -3
  13. crc-pulpcore-client/models/group_role_response.py +0 -2
  14. crc-pulpcore-client/models/multiple_artifact_content_response.py +5 -1
  15. crc-pulpcore-client/models/nested_open_pgp_public_subkey_response.py +0 -2
  16. crc-pulpcore-client/models/nested_open_pgp_signature.py +1 -1
  17. crc-pulpcore-client/models/nested_open_pgp_signature_response.py +2 -3
  18. crc-pulpcore-client/models/nested_open_pgp_user_attribute_response.py +0 -2
  19. crc-pulpcore-client/models/nested_open_pgp_user_id_response.py +0 -2
  20. crc-pulpcore-client/models/open_pgp_keyring.py +2 -2
  21. crc-pulpcore-client/models/open_pgp_keyring_response.py +2 -3
  22. crc-pulpcore-client/models/open_pgp_public_key_response.py +4 -6
  23. crc-pulpcore-client/models/open_pgp_public_subkey_response.py +4 -2
  24. crc-pulpcore-client/models/open_pgp_signature_response.py +6 -3
  25. crc-pulpcore-client/models/open_pgp_user_attribute_response.py +4 -2
  26. crc-pulpcore-client/models/open_pgp_user_id_response.py +4 -2
  27. crc-pulpcore-client/models/orphans_cleanup.py +2 -3
  28. crc-pulpcore-client/models/paginated_access_policy_response_list.py +0 -10
  29. crc-pulpcore-client/models/paginated_artifact_distribution_response_list.py +0 -10
  30. crc-pulpcore-client/models/paginated_artifact_response_list.py +0 -10
  31. crc-pulpcore-client/models/paginated_composite_content_guard_response_list.py +0 -10
  32. crc-pulpcore-client/models/paginated_content_guard_response_list.py +0 -10
  33. crc-pulpcore-client/models/paginated_content_redirect_content_guard_response_list.py +0 -10
  34. crc-pulpcore-client/models/paginated_distribution_response_list.py +0 -10
  35. crc-pulpcore-client/models/paginated_domain_response_list.py +0 -10
  36. crc-pulpcore-client/models/paginated_filesystem_export_response_list.py +0 -10
  37. crc-pulpcore-client/models/paginated_filesystem_exporter_response_list.py +0 -10
  38. crc-pulpcore-client/models/paginated_generic_remote_response_list.py +0 -10
  39. crc-pulpcore-client/models/paginated_group_response_list.py +0 -10
  40. crc-pulpcore-client/models/paginated_group_role_response_list.py +0 -10
  41. crc-pulpcore-client/models/paginated_group_user_response_list.py +0 -10
  42. crc-pulpcore-client/models/paginated_header_content_guard_response_list.py +0 -10
  43. crc-pulpcore-client/models/paginated_import_response_list.py +0 -10
  44. crc-pulpcore-client/models/paginated_multiple_artifact_content_response_list.py +0 -10
  45. crc-pulpcore-client/models/paginated_open_pgp_distribution_response_list.py +0 -10
  46. crc-pulpcore-client/models/paginated_open_pgp_keyring_response_list.py +0 -10
  47. crc-pulpcore-client/models/paginated_open_pgp_public_key_response_list.py +0 -10
  48. crc-pulpcore-client/models/paginated_open_pgp_public_subkey_response_list.py +0 -10
  49. crc-pulpcore-client/models/paginated_open_pgp_signature_response_list.py +0 -10
  50. crc-pulpcore-client/models/paginated_open_pgp_user_attribute_response_list.py +0 -10
  51. crc-pulpcore-client/models/paginated_open_pgp_user_id_response_list.py +0 -10
  52. crc-pulpcore-client/models/paginated_publication_response_list.py +0 -10
  53. crc-pulpcore-client/models/paginated_pulp_export_response_list.py +0 -10
  54. crc-pulpcore-client/models/paginated_pulp_exporter_response_list.py +0 -10
  55. crc-pulpcore-client/models/paginated_pulp_importer_response_list.py +0 -10
  56. crc-pulpcore-client/models/paginated_rbac_content_guard_response_list.py +0 -10
  57. crc-pulpcore-client/models/paginated_repository_response_list.py +0 -10
  58. crc-pulpcore-client/models/paginated_repository_version_response_list.py +0 -10
  59. crc-pulpcore-client/models/paginated_role_response_list.py +0 -10
  60. crc-pulpcore-client/models/paginated_signing_service_response_list.py +0 -10
  61. crc-pulpcore-client/models/paginated_task_group_response_list.py +0 -10
  62. crc-pulpcore-client/models/paginated_task_response_list.py +0 -10
  63. crc-pulpcore-client/models/paginated_task_schedule_response_list.py +0 -10
  64. crc-pulpcore-client/models/paginated_upload_response_list.py +0 -10
  65. crc-pulpcore-client/models/paginated_upstream_pulp_response_list.py +0 -10
  66. crc-pulpcore-client/models/paginated_user_response_list.py +0 -10
  67. crc-pulpcore-client/models/paginated_user_role_response_list.py +0 -10
  68. crc-pulpcore-client/models/paginated_vulnerability_report_response_list.py +102 -0
  69. crc-pulpcore-client/models/paginated_worker_response_list.py +0 -10
  70. crc-pulpcore-client/models/patched_open_pgp_keyring.py +2 -2
  71. crc-pulpcore-client/models/pulp_export_response.py +0 -2
  72. crc-pulpcore-client/models/rbac_content_guard_response.py +0 -4
  73. crc-pulpcore-client/models/repository_response.py +2 -3
  74. crc-pulpcore-client/models/repository_version_response.py +6 -2
  75. crc-pulpcore-client/models/storage_response.py +4 -5
  76. crc-pulpcore-client/models/task_group_response.py +0 -4
  77. crc-pulpcore-client/models/task_response.py +0 -8
  78. crc-pulpcore-client/models/upload_detail_response.py +0 -2
  79. crc-pulpcore-client/models/upstream_pulp_response.py +0 -2
  80. crc-pulpcore-client/models/user_response.py +0 -4
  81. crc-pulpcore-client/models/user_role_response.py +0 -2
  82. crc-pulpcore-client/models/vulnerability_report_response.py +116 -0
  83. {crc_pulpcore_client-20250821.3.dist-info → crc_pulpcore_client-20250825.1.dist-info}/METADATA +1 -1
  84. {crc_pulpcore_client-20250821.3.dist-info → crc_pulpcore_client-20250825.1.dist-info}/RECORD +86 -83
  85. {crc_pulpcore_client-20250821.3.dist-info → crc_pulpcore_client-20250825.1.dist-info}/WHEEL +0 -0
  86. {crc_pulpcore_client-20250821.3.dist-info → crc_pulpcore_client-20250825.1.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,977 @@
1
+ # coding: utf-8
2
+
3
+ """
4
+ Pulp 3 API
5
+
6
+ Fetch, Upload, Organize, and Distribute Software Packages
7
+
8
+ The version of the OpenAPI document: v3
9
+ Contact: pulp-list@redhat.com
10
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
11
+
12
+ Do not edit the class manually.
13
+ """ # noqa: E501
14
+
15
+ import warnings
16
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
17
+ from typing import Any, Dict, List, Optional, Tuple, Union
18
+ from typing_extensions import Annotated
19
+
20
+ from pydantic import Field, StrictInt, StrictStr
21
+ from typing import List, Optional
22
+ from typing_extensions import Annotated
23
+ from crc-pulpcore-client.models.paginated_vulnerability_report_response_list import PaginatedVulnerabilityReportResponseList
24
+ from crc-pulpcore-client.models.vulnerability_report_response import VulnerabilityReportResponse
25
+
26
+ from crc-pulpcore-client.api_client import ApiClient, RequestSerialized
27
+ from crc-pulpcore-client.api_response import ApiResponse
28
+ from crc-pulpcore-client.rest import RESTResponseType
29
+
30
+
31
+ class VulnReportApi:
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
+ def delete(
46
+ self,
47
+ vulnerability_report_href: StrictStr,
48
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
49
+ _request_timeout: Union[
50
+ None,
51
+ Annotated[StrictFloat, Field(gt=0)],
52
+ Tuple[
53
+ Annotated[StrictFloat, Field(gt=0)],
54
+ Annotated[StrictFloat, Field(gt=0)]
55
+ ]
56
+ ] = None,
57
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
58
+ _content_type: Optional[StrictStr] = None,
59
+ _headers: Optional[Dict[StrictStr, Any]] = None,
60
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
61
+ ) -> None:
62
+ """Delete a vulnerability report
63
+
64
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
65
+
66
+ :param vulnerability_report_href: (required)
67
+ :type vulnerability_report_href: str
68
+ :param x_task_diagnostics: List of profilers to use on tasks.
69
+ :type x_task_diagnostics: List[str]
70
+ :param _request_timeout: timeout setting for this request. If one
71
+ number provided, it will be total request
72
+ timeout. It can also be a pair (tuple) of
73
+ (connection, read) timeouts.
74
+ :type _request_timeout: int, tuple(int, int), optional
75
+ :param _request_auth: set to override the auth_settings for an a single
76
+ request; this effectively ignores the
77
+ authentication in the spec for a single request.
78
+ :type _request_auth: dict, optional
79
+ :param _content_type: force content-type for the request.
80
+ :type _content_type: str, Optional
81
+ :param _headers: set to override the headers for a single
82
+ request; this effectively ignores the headers
83
+ in the spec for a single request.
84
+ :type _headers: dict, optional
85
+ :param _host_index: set to override the host_index for a single
86
+ request; this effectively ignores the host_index
87
+ in the spec for a single request.
88
+ :type _host_index: int, optional
89
+ :return: Returns the result object.
90
+ """ # noqa: E501
91
+
92
+ _param = self._delete_serialize(
93
+ vulnerability_report_href=vulnerability_report_href,
94
+ x_task_diagnostics=x_task_diagnostics,
95
+ _request_auth=_request_auth,
96
+ _content_type=_content_type,
97
+ _headers=_headers,
98
+ _host_index=_host_index
99
+ )
100
+
101
+ _response_types_map: Dict[str, Optional[str]] = {
102
+ '204': None,
103
+ }
104
+ response_data = self.api_client.call_api(
105
+ *_param,
106
+ _request_timeout=_request_timeout
107
+ )
108
+ response_data.read()
109
+ return self.api_client.response_deserialize(
110
+ response_data=response_data,
111
+ response_types_map=_response_types_map,
112
+ ).data
113
+
114
+
115
+ @validate_call
116
+ def delete_with_http_info(
117
+ self,
118
+ vulnerability_report_href: StrictStr,
119
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
120
+ _request_timeout: Union[
121
+ None,
122
+ Annotated[StrictFloat, Field(gt=0)],
123
+ Tuple[
124
+ Annotated[StrictFloat, Field(gt=0)],
125
+ Annotated[StrictFloat, Field(gt=0)]
126
+ ]
127
+ ] = None,
128
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
129
+ _content_type: Optional[StrictStr] = None,
130
+ _headers: Optional[Dict[StrictStr, Any]] = None,
131
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
132
+ ) -> ApiResponse[None]:
133
+ """Delete a vulnerability report
134
+
135
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
136
+
137
+ :param vulnerability_report_href: (required)
138
+ :type vulnerability_report_href: str
139
+ :param x_task_diagnostics: List of profilers to use on tasks.
140
+ :type x_task_diagnostics: List[str]
141
+ :param _request_timeout: timeout setting for this request. If one
142
+ number provided, it will be total request
143
+ timeout. It can also be a pair (tuple) of
144
+ (connection, read) timeouts.
145
+ :type _request_timeout: int, tuple(int, int), optional
146
+ :param _request_auth: set to override the auth_settings for an a single
147
+ request; this effectively ignores the
148
+ authentication in the spec for a single request.
149
+ :type _request_auth: dict, optional
150
+ :param _content_type: force content-type for the request.
151
+ :type _content_type: str, Optional
152
+ :param _headers: set to override the headers for a single
153
+ request; this effectively ignores the headers
154
+ in the spec for a single request.
155
+ :type _headers: dict, optional
156
+ :param _host_index: set to override the host_index for a single
157
+ request; this effectively ignores the host_index
158
+ in the spec for a single request.
159
+ :type _host_index: int, optional
160
+ :return: Returns the result object.
161
+ """ # noqa: E501
162
+
163
+ _param = self._delete_serialize(
164
+ vulnerability_report_href=vulnerability_report_href,
165
+ x_task_diagnostics=x_task_diagnostics,
166
+ _request_auth=_request_auth,
167
+ _content_type=_content_type,
168
+ _headers=_headers,
169
+ _host_index=_host_index
170
+ )
171
+
172
+ _response_types_map: Dict[str, Optional[str]] = {
173
+ '204': None,
174
+ }
175
+ response_data = self.api_client.call_api(
176
+ *_param,
177
+ _request_timeout=_request_timeout
178
+ )
179
+ response_data.read()
180
+ return self.api_client.response_deserialize(
181
+ response_data=response_data,
182
+ response_types_map=_response_types_map,
183
+ )
184
+
185
+
186
+ @validate_call
187
+ def delete_without_preload_content(
188
+ self,
189
+ vulnerability_report_href: StrictStr,
190
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
191
+ _request_timeout: Union[
192
+ None,
193
+ Annotated[StrictFloat, Field(gt=0)],
194
+ Tuple[
195
+ Annotated[StrictFloat, Field(gt=0)],
196
+ Annotated[StrictFloat, Field(gt=0)]
197
+ ]
198
+ ] = None,
199
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
200
+ _content_type: Optional[StrictStr] = None,
201
+ _headers: Optional[Dict[StrictStr, Any]] = None,
202
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
203
+ ) -> RESTResponseType:
204
+ """Delete a vulnerability report
205
+
206
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
207
+
208
+ :param vulnerability_report_href: (required)
209
+ :type vulnerability_report_href: str
210
+ :param x_task_diagnostics: List of profilers to use on tasks.
211
+ :type x_task_diagnostics: List[str]
212
+ :param _request_timeout: timeout setting for this request. If one
213
+ number provided, it will be total request
214
+ timeout. It can also be a pair (tuple) of
215
+ (connection, read) timeouts.
216
+ :type _request_timeout: int, tuple(int, int), optional
217
+ :param _request_auth: set to override the auth_settings for an a single
218
+ request; this effectively ignores the
219
+ authentication in the spec for a single request.
220
+ :type _request_auth: dict, optional
221
+ :param _content_type: force content-type for the request.
222
+ :type _content_type: str, Optional
223
+ :param _headers: set to override the headers for a single
224
+ request; this effectively ignores the headers
225
+ in the spec for a single request.
226
+ :type _headers: dict, optional
227
+ :param _host_index: set to override the host_index for a single
228
+ request; this effectively ignores the host_index
229
+ in the spec for a single request.
230
+ :type _host_index: int, optional
231
+ :return: Returns the result object.
232
+ """ # noqa: E501
233
+
234
+ _param = self._delete_serialize(
235
+ vulnerability_report_href=vulnerability_report_href,
236
+ x_task_diagnostics=x_task_diagnostics,
237
+ _request_auth=_request_auth,
238
+ _content_type=_content_type,
239
+ _headers=_headers,
240
+ _host_index=_host_index
241
+ )
242
+
243
+ _response_types_map: Dict[str, Optional[str]] = {
244
+ '204': None,
245
+ }
246
+ response_data = self.api_client.call_api(
247
+ *_param,
248
+ _request_timeout=_request_timeout
249
+ )
250
+ return response_data.response
251
+
252
+
253
+ def _delete_serialize(
254
+ self,
255
+ vulnerability_report_href,
256
+ x_task_diagnostics,
257
+ _request_auth,
258
+ _content_type,
259
+ _headers,
260
+ _host_index,
261
+ ) -> RequestSerialized:
262
+
263
+ _host = None
264
+
265
+ _collection_formats: Dict[str, str] = {
266
+ 'X-Task-Diagnostics': 'csv',
267
+ }
268
+
269
+ _path_params: Dict[str, str] = {}
270
+ _query_params: List[Tuple[str, str]] = []
271
+ _header_params: Dict[str, Optional[str]] = _headers or {}
272
+ _form_params: List[Tuple[str, str]] = []
273
+ _files: Dict[
274
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
275
+ ] = {}
276
+ _body_params: Optional[bytes] = None
277
+
278
+ # process the path parameters
279
+ if vulnerability_report_href is not None:
280
+ _path_params['vulnerability_report_href'] = vulnerability_report_href
281
+ # process the query parameters
282
+ # process the header parameters
283
+ if x_task_diagnostics is not None:
284
+ _header_params['X-Task-Diagnostics'] = x_task_diagnostics
285
+ # process the form parameters
286
+ # process the body parameter
287
+
288
+
289
+
290
+
291
+ # authentication setting
292
+ _auth_settings: List[str] = [
293
+ 'json_header_remote_authentication',
294
+ 'basicAuth',
295
+ 'cookieAuth'
296
+ ]
297
+
298
+ return self.api_client.param_serialize(
299
+ method='DELETE',
300
+ resource_path='{vulnerability_report_href}',
301
+ path_params=_path_params,
302
+ query_params=_query_params,
303
+ header_params=_header_params,
304
+ body=_body_params,
305
+ post_params=_form_params,
306
+ files=_files,
307
+ auth_settings=_auth_settings,
308
+ collection_formats=_collection_formats,
309
+ _host=_host,
310
+ _request_auth=_request_auth
311
+ )
312
+
313
+
314
+
315
+
316
+ @validate_call
317
+ def list(
318
+ self,
319
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
320
+ limit: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None,
321
+ offset: Annotated[Optional[StrictInt], Field(description="The initial index from which to return the results.")] = None,
322
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
323
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
324
+ pulp_domain: StrictStr = "default",
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
+ ) -> PaginatedVulnerabilityReportResponseList:
338
+ """List vulnerability reports
339
+
340
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
341
+
342
+ :param pulp_domain: (required)
343
+ :type pulp_domain: str
344
+ :param x_task_diagnostics: List of profilers to use on tasks.
345
+ :type x_task_diagnostics: List[str]
346
+ :param limit: Number of results to return per page.
347
+ :type limit: int
348
+ :param offset: The initial index from which to return the results.
349
+ :type offset: int
350
+ :param fields: A list of fields to include in the response.
351
+ :type fields: List[str]
352
+ :param exclude_fields: A list of fields to exclude from the response.
353
+ :type exclude_fields: List[str]
354
+ :param _request_timeout: timeout setting for this request. If one
355
+ number provided, it will be total request
356
+ timeout. It can also be a pair (tuple) of
357
+ (connection, read) timeouts.
358
+ :type _request_timeout: int, tuple(int, int), optional
359
+ :param _request_auth: set to override the auth_settings for an a single
360
+ request; this effectively ignores the
361
+ authentication in the spec for a single request.
362
+ :type _request_auth: dict, optional
363
+ :param _content_type: force content-type for the request.
364
+ :type _content_type: str, Optional
365
+ :param _headers: set to override the headers for a single
366
+ request; this effectively ignores the headers
367
+ in the spec for a single request.
368
+ :type _headers: dict, optional
369
+ :param _host_index: set to override the host_index for a single
370
+ request; this effectively ignores the host_index
371
+ in the spec for a single request.
372
+ :type _host_index: int, optional
373
+ :return: Returns the result object.
374
+ """ # noqa: E501
375
+
376
+ _param = self._list_serialize(
377
+ pulp_domain=pulp_domain,
378
+ x_task_diagnostics=x_task_diagnostics,
379
+ limit=limit,
380
+ offset=offset,
381
+ fields=fields,
382
+ exclude_fields=exclude_fields,
383
+ _request_auth=_request_auth,
384
+ _content_type=_content_type,
385
+ _headers=_headers,
386
+ _host_index=_host_index
387
+ )
388
+
389
+ _response_types_map: Dict[str, Optional[str]] = {
390
+ '200': "PaginatedVulnerabilityReportResponseList",
391
+ }
392
+ response_data = self.api_client.call_api(
393
+ *_param,
394
+ _request_timeout=_request_timeout
395
+ )
396
+ response_data.read()
397
+ return self.api_client.response_deserialize(
398
+ response_data=response_data,
399
+ response_types_map=_response_types_map,
400
+ ).data
401
+
402
+
403
+ @validate_call
404
+ def list_with_http_info(
405
+ self,
406
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
407
+ limit: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None,
408
+ offset: Annotated[Optional[StrictInt], Field(description="The initial index from which to return the results.")] = None,
409
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
410
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
411
+ pulp_domain: StrictStr = "default",
412
+ _request_timeout: Union[
413
+ None,
414
+ Annotated[StrictFloat, Field(gt=0)],
415
+ Tuple[
416
+ Annotated[StrictFloat, Field(gt=0)],
417
+ Annotated[StrictFloat, Field(gt=0)]
418
+ ]
419
+ ] = None,
420
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
421
+ _content_type: Optional[StrictStr] = None,
422
+ _headers: Optional[Dict[StrictStr, Any]] = None,
423
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
424
+ ) -> ApiResponse[PaginatedVulnerabilityReportResponseList]:
425
+ """List vulnerability reports
426
+
427
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
428
+
429
+ :param pulp_domain: (required)
430
+ :type pulp_domain: str
431
+ :param x_task_diagnostics: List of profilers to use on tasks.
432
+ :type x_task_diagnostics: List[str]
433
+ :param limit: Number of results to return per page.
434
+ :type limit: int
435
+ :param offset: The initial index from which to return the results.
436
+ :type offset: int
437
+ :param fields: A list of fields to include in the response.
438
+ :type fields: List[str]
439
+ :param exclude_fields: A list of fields to exclude from the response.
440
+ :type exclude_fields: List[str]
441
+ :param _request_timeout: timeout setting for this request. If one
442
+ number provided, it will be total request
443
+ timeout. It can also be a pair (tuple) of
444
+ (connection, read) timeouts.
445
+ :type _request_timeout: int, tuple(int, int), optional
446
+ :param _request_auth: set to override the auth_settings for an a single
447
+ request; this effectively ignores the
448
+ authentication in the spec for a single request.
449
+ :type _request_auth: dict, optional
450
+ :param _content_type: force content-type for the request.
451
+ :type _content_type: str, Optional
452
+ :param _headers: set to override the headers for a single
453
+ request; this effectively ignores the headers
454
+ in the spec for a single request.
455
+ :type _headers: dict, optional
456
+ :param _host_index: set to override the host_index for a single
457
+ request; this effectively ignores the host_index
458
+ in the spec for a single request.
459
+ :type _host_index: int, optional
460
+ :return: Returns the result object.
461
+ """ # noqa: E501
462
+
463
+ _param = self._list_serialize(
464
+ pulp_domain=pulp_domain,
465
+ x_task_diagnostics=x_task_diagnostics,
466
+ limit=limit,
467
+ offset=offset,
468
+ fields=fields,
469
+ exclude_fields=exclude_fields,
470
+ _request_auth=_request_auth,
471
+ _content_type=_content_type,
472
+ _headers=_headers,
473
+ _host_index=_host_index
474
+ )
475
+
476
+ _response_types_map: Dict[str, Optional[str]] = {
477
+ '200': "PaginatedVulnerabilityReportResponseList",
478
+ }
479
+ response_data = self.api_client.call_api(
480
+ *_param,
481
+ _request_timeout=_request_timeout
482
+ )
483
+ response_data.read()
484
+ return self.api_client.response_deserialize(
485
+ response_data=response_data,
486
+ response_types_map=_response_types_map,
487
+ )
488
+
489
+
490
+ @validate_call
491
+ def list_without_preload_content(
492
+ self,
493
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
494
+ limit: Annotated[Optional[StrictInt], Field(description="Number of results to return per page.")] = None,
495
+ offset: Annotated[Optional[StrictInt], Field(description="The initial index from which to return the results.")] = None,
496
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
497
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
498
+ pulp_domain: StrictStr = "default",
499
+ _request_timeout: Union[
500
+ None,
501
+ Annotated[StrictFloat, Field(gt=0)],
502
+ Tuple[
503
+ Annotated[StrictFloat, Field(gt=0)],
504
+ Annotated[StrictFloat, Field(gt=0)]
505
+ ]
506
+ ] = None,
507
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
508
+ _content_type: Optional[StrictStr] = None,
509
+ _headers: Optional[Dict[StrictStr, Any]] = None,
510
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
511
+ ) -> RESTResponseType:
512
+ """List vulnerability reports
513
+
514
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
515
+
516
+ :param pulp_domain: (required)
517
+ :type pulp_domain: str
518
+ :param x_task_diagnostics: List of profilers to use on tasks.
519
+ :type x_task_diagnostics: List[str]
520
+ :param limit: Number of results to return per page.
521
+ :type limit: int
522
+ :param offset: The initial index from which to return the results.
523
+ :type offset: int
524
+ :param fields: A list of fields to include in the response.
525
+ :type fields: List[str]
526
+ :param exclude_fields: A list of fields to exclude from the response.
527
+ :type exclude_fields: List[str]
528
+ :param _request_timeout: timeout setting for this request. If one
529
+ number provided, it will be total request
530
+ timeout. It can also be a pair (tuple) of
531
+ (connection, read) timeouts.
532
+ :type _request_timeout: int, tuple(int, int), optional
533
+ :param _request_auth: set to override the auth_settings for an a single
534
+ request; this effectively ignores the
535
+ authentication in the spec for a single request.
536
+ :type _request_auth: dict, optional
537
+ :param _content_type: force content-type for the request.
538
+ :type _content_type: str, Optional
539
+ :param _headers: set to override the headers for a single
540
+ request; this effectively ignores the headers
541
+ in the spec for a single request.
542
+ :type _headers: dict, optional
543
+ :param _host_index: set to override the host_index for a single
544
+ request; this effectively ignores the host_index
545
+ in the spec for a single request.
546
+ :type _host_index: int, optional
547
+ :return: Returns the result object.
548
+ """ # noqa: E501
549
+
550
+ _param = self._list_serialize(
551
+ pulp_domain=pulp_domain,
552
+ x_task_diagnostics=x_task_diagnostics,
553
+ limit=limit,
554
+ offset=offset,
555
+ fields=fields,
556
+ exclude_fields=exclude_fields,
557
+ _request_auth=_request_auth,
558
+ _content_type=_content_type,
559
+ _headers=_headers,
560
+ _host_index=_host_index
561
+ )
562
+
563
+ _response_types_map: Dict[str, Optional[str]] = {
564
+ '200': "PaginatedVulnerabilityReportResponseList",
565
+ }
566
+ response_data = self.api_client.call_api(
567
+ *_param,
568
+ _request_timeout=_request_timeout
569
+ )
570
+ return response_data.response
571
+
572
+
573
+ def _list_serialize(
574
+ self,
575
+ pulp_domain,
576
+ x_task_diagnostics,
577
+ limit,
578
+ offset,
579
+ fields,
580
+ exclude_fields,
581
+ _request_auth,
582
+ _content_type,
583
+ _headers,
584
+ _host_index,
585
+ ) -> RequestSerialized:
586
+
587
+ _host = None
588
+
589
+ _collection_formats: Dict[str, str] = {
590
+ 'X-Task-Diagnostics': 'csv',
591
+ 'fields': 'multi',
592
+ 'exclude_fields': 'multi',
593
+ }
594
+
595
+ _path_params: Dict[str, str] = {}
596
+ _query_params: List[Tuple[str, str]] = []
597
+ _header_params: Dict[str, Optional[str]] = _headers or {}
598
+ _form_params: List[Tuple[str, str]] = []
599
+ _files: Dict[
600
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
601
+ ] = {}
602
+ _body_params: Optional[bytes] = None
603
+
604
+ # process the path parameters
605
+ if pulp_domain is not None:
606
+ _path_params['pulp_domain'] = pulp_domain
607
+ # process the query parameters
608
+ if limit is not None:
609
+
610
+ _query_params.append(('limit', limit))
611
+
612
+ if offset is not None:
613
+
614
+ _query_params.append(('offset', offset))
615
+
616
+ if fields is not None:
617
+
618
+ _query_params.append(('fields', fields))
619
+
620
+ if exclude_fields is not None:
621
+
622
+ _query_params.append(('exclude_fields', exclude_fields))
623
+
624
+ # process the header parameters
625
+ if x_task_diagnostics is not None:
626
+ _header_params['X-Task-Diagnostics'] = x_task_diagnostics
627
+ # process the form parameters
628
+ # process the body parameter
629
+
630
+
631
+ # set the HTTP header `Accept`
632
+ if 'Accept' not in _header_params:
633
+ _header_params['Accept'] = self.api_client.select_header_accept(
634
+ [
635
+ 'application/json'
636
+ ]
637
+ )
638
+
639
+
640
+ # authentication setting
641
+ _auth_settings: List[str] = [
642
+ 'json_header_remote_authentication',
643
+ 'basicAuth',
644
+ 'cookieAuth'
645
+ ]
646
+
647
+ return self.api_client.param_serialize(
648
+ method='GET',
649
+ resource_path='/api/pulp/{pulp_domain}/api/v3/vuln_report/',
650
+ path_params=_path_params,
651
+ query_params=_query_params,
652
+ header_params=_header_params,
653
+ body=_body_params,
654
+ post_params=_form_params,
655
+ files=_files,
656
+ auth_settings=_auth_settings,
657
+ collection_formats=_collection_formats,
658
+ _host=_host,
659
+ _request_auth=_request_auth
660
+ )
661
+
662
+
663
+
664
+
665
+ @validate_call
666
+ def read(
667
+ self,
668
+ vulnerability_report_href: StrictStr,
669
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
670
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
671
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
672
+ _request_timeout: Union[
673
+ None,
674
+ Annotated[StrictFloat, Field(gt=0)],
675
+ Tuple[
676
+ Annotated[StrictFloat, Field(gt=0)],
677
+ Annotated[StrictFloat, Field(gt=0)]
678
+ ]
679
+ ] = None,
680
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
681
+ _content_type: Optional[StrictStr] = None,
682
+ _headers: Optional[Dict[StrictStr, Any]] = None,
683
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
684
+ ) -> VulnerabilityReportResponse:
685
+ """Inspect a vulnerability report
686
+
687
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
688
+
689
+ :param vulnerability_report_href: (required)
690
+ :type vulnerability_report_href: str
691
+ :param x_task_diagnostics: List of profilers to use on tasks.
692
+ :type x_task_diagnostics: List[str]
693
+ :param fields: A list of fields to include in the response.
694
+ :type fields: List[str]
695
+ :param exclude_fields: A list of fields to exclude from the response.
696
+ :type exclude_fields: List[str]
697
+ :param _request_timeout: timeout setting for this request. If one
698
+ number provided, it will be total request
699
+ timeout. It can also be a pair (tuple) of
700
+ (connection, read) timeouts.
701
+ :type _request_timeout: int, tuple(int, int), optional
702
+ :param _request_auth: set to override the auth_settings for an a single
703
+ request; this effectively ignores the
704
+ authentication in the spec for a single request.
705
+ :type _request_auth: dict, optional
706
+ :param _content_type: force content-type for the request.
707
+ :type _content_type: str, Optional
708
+ :param _headers: set to override the headers for a single
709
+ request; this effectively ignores the headers
710
+ in the spec for a single request.
711
+ :type _headers: dict, optional
712
+ :param _host_index: set to override the host_index for a single
713
+ request; this effectively ignores the host_index
714
+ in the spec for a single request.
715
+ :type _host_index: int, optional
716
+ :return: Returns the result object.
717
+ """ # noqa: E501
718
+
719
+ _param = self._read_serialize(
720
+ vulnerability_report_href=vulnerability_report_href,
721
+ x_task_diagnostics=x_task_diagnostics,
722
+ fields=fields,
723
+ exclude_fields=exclude_fields,
724
+ _request_auth=_request_auth,
725
+ _content_type=_content_type,
726
+ _headers=_headers,
727
+ _host_index=_host_index
728
+ )
729
+
730
+ _response_types_map: Dict[str, Optional[str]] = {
731
+ '200': "VulnerabilityReportResponse",
732
+ }
733
+ response_data = self.api_client.call_api(
734
+ *_param,
735
+ _request_timeout=_request_timeout
736
+ )
737
+ response_data.read()
738
+ return self.api_client.response_deserialize(
739
+ response_data=response_data,
740
+ response_types_map=_response_types_map,
741
+ ).data
742
+
743
+
744
+ @validate_call
745
+ def read_with_http_info(
746
+ self,
747
+ vulnerability_report_href: StrictStr,
748
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
749
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
750
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
751
+ _request_timeout: Union[
752
+ None,
753
+ Annotated[StrictFloat, Field(gt=0)],
754
+ Tuple[
755
+ Annotated[StrictFloat, Field(gt=0)],
756
+ Annotated[StrictFloat, Field(gt=0)]
757
+ ]
758
+ ] = None,
759
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
760
+ _content_type: Optional[StrictStr] = None,
761
+ _headers: Optional[Dict[StrictStr, Any]] = None,
762
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
763
+ ) -> ApiResponse[VulnerabilityReportResponse]:
764
+ """Inspect a vulnerability report
765
+
766
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
767
+
768
+ :param vulnerability_report_href: (required)
769
+ :type vulnerability_report_href: str
770
+ :param x_task_diagnostics: List of profilers to use on tasks.
771
+ :type x_task_diagnostics: List[str]
772
+ :param fields: A list of fields to include in the response.
773
+ :type fields: List[str]
774
+ :param exclude_fields: A list of fields to exclude from the response.
775
+ :type exclude_fields: List[str]
776
+ :param _request_timeout: timeout setting for this request. If one
777
+ number provided, it will be total request
778
+ timeout. It can also be a pair (tuple) of
779
+ (connection, read) timeouts.
780
+ :type _request_timeout: int, tuple(int, int), optional
781
+ :param _request_auth: set to override the auth_settings for an a single
782
+ request; this effectively ignores the
783
+ authentication in the spec for a single request.
784
+ :type _request_auth: dict, optional
785
+ :param _content_type: force content-type for the request.
786
+ :type _content_type: str, Optional
787
+ :param _headers: set to override the headers for a single
788
+ request; this effectively ignores the headers
789
+ in the spec for a single request.
790
+ :type _headers: dict, optional
791
+ :param _host_index: set to override the host_index for a single
792
+ request; this effectively ignores the host_index
793
+ in the spec for a single request.
794
+ :type _host_index: int, optional
795
+ :return: Returns the result object.
796
+ """ # noqa: E501
797
+
798
+ _param = self._read_serialize(
799
+ vulnerability_report_href=vulnerability_report_href,
800
+ x_task_diagnostics=x_task_diagnostics,
801
+ fields=fields,
802
+ exclude_fields=exclude_fields,
803
+ _request_auth=_request_auth,
804
+ _content_type=_content_type,
805
+ _headers=_headers,
806
+ _host_index=_host_index
807
+ )
808
+
809
+ _response_types_map: Dict[str, Optional[str]] = {
810
+ '200': "VulnerabilityReportResponse",
811
+ }
812
+ response_data = self.api_client.call_api(
813
+ *_param,
814
+ _request_timeout=_request_timeout
815
+ )
816
+ response_data.read()
817
+ return self.api_client.response_deserialize(
818
+ response_data=response_data,
819
+ response_types_map=_response_types_map,
820
+ )
821
+
822
+
823
+ @validate_call
824
+ def read_without_preload_content(
825
+ self,
826
+ vulnerability_report_href: StrictStr,
827
+ x_task_diagnostics: Annotated[Optional[List[StrictStr]], Field(description="List of profilers to use on tasks.")] = None,
828
+ fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to include in the response.")] = None,
829
+ exclude_fields: Annotated[Optional[List[StrictStr]], Field(description="A list of fields to exclude from the response.")] = None,
830
+ _request_timeout: Union[
831
+ None,
832
+ Annotated[StrictFloat, Field(gt=0)],
833
+ Tuple[
834
+ Annotated[StrictFloat, Field(gt=0)],
835
+ Annotated[StrictFloat, Field(gt=0)]
836
+ ]
837
+ ] = None,
838
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
839
+ _content_type: Optional[StrictStr] = None,
840
+ _headers: Optional[Dict[StrictStr, Any]] = None,
841
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
842
+ ) -> RESTResponseType:
843
+ """Inspect a vulnerability report
844
+
845
+ A customized named ModelViewSet that knows how to register itself with the Pulp API router. This viewset is discoverable by its name. \"Normal\" Django Models and Master/Detail models are supported by the ``register_with`` method. Attributes: lookup_field (str): The name of the field by which an object should be looked up, in addition to any parent lookups if this ViewSet is nested. Defaults to 'pk' endpoint_name (str): The name of the final path segment that should identify the ViewSet's collection endpoint. nest_prefix (str): Optional prefix under which this ViewSet should be nested. This must correspond to the \"parent_prefix\" of a router with rest_framework_nested.NestedMixin. None indicates this ViewSet should not be nested. parent_lookup_kwargs (dict): Optional mapping of key names that would appear in self.kwargs to django model filter expressions that can be used with the corresponding value from self.kwargs, used only by a nested ViewSet to filter based on the parent object's identity. schema (DefaultSchema): The schema class to use by default in a viewset.
846
+
847
+ :param vulnerability_report_href: (required)
848
+ :type vulnerability_report_href: str
849
+ :param x_task_diagnostics: List of profilers to use on tasks.
850
+ :type x_task_diagnostics: List[str]
851
+ :param fields: A list of fields to include in the response.
852
+ :type fields: List[str]
853
+ :param exclude_fields: A list of fields to exclude from the response.
854
+ :type exclude_fields: List[str]
855
+ :param _request_timeout: timeout setting for this request. If one
856
+ number provided, it will be total request
857
+ timeout. It can also be a pair (tuple) of
858
+ (connection, read) timeouts.
859
+ :type _request_timeout: int, tuple(int, int), optional
860
+ :param _request_auth: set to override the auth_settings for an a single
861
+ request; this effectively ignores the
862
+ authentication in the spec for a single request.
863
+ :type _request_auth: dict, optional
864
+ :param _content_type: force content-type for the request.
865
+ :type _content_type: str, Optional
866
+ :param _headers: set to override the headers for a single
867
+ request; this effectively ignores the headers
868
+ in the spec for a single request.
869
+ :type _headers: dict, optional
870
+ :param _host_index: set to override the host_index for a single
871
+ request; this effectively ignores the host_index
872
+ in the spec for a single request.
873
+ :type _host_index: int, optional
874
+ :return: Returns the result object.
875
+ """ # noqa: E501
876
+
877
+ _param = self._read_serialize(
878
+ vulnerability_report_href=vulnerability_report_href,
879
+ x_task_diagnostics=x_task_diagnostics,
880
+ fields=fields,
881
+ exclude_fields=exclude_fields,
882
+ _request_auth=_request_auth,
883
+ _content_type=_content_type,
884
+ _headers=_headers,
885
+ _host_index=_host_index
886
+ )
887
+
888
+ _response_types_map: Dict[str, Optional[str]] = {
889
+ '200': "VulnerabilityReportResponse",
890
+ }
891
+ response_data = self.api_client.call_api(
892
+ *_param,
893
+ _request_timeout=_request_timeout
894
+ )
895
+ return response_data.response
896
+
897
+
898
+ def _read_serialize(
899
+ self,
900
+ vulnerability_report_href,
901
+ x_task_diagnostics,
902
+ fields,
903
+ exclude_fields,
904
+ _request_auth,
905
+ _content_type,
906
+ _headers,
907
+ _host_index,
908
+ ) -> RequestSerialized:
909
+
910
+ _host = None
911
+
912
+ _collection_formats: Dict[str, str] = {
913
+ 'X-Task-Diagnostics': 'csv',
914
+ 'fields': 'multi',
915
+ 'exclude_fields': 'multi',
916
+ }
917
+
918
+ _path_params: Dict[str, str] = {}
919
+ _query_params: List[Tuple[str, str]] = []
920
+ _header_params: Dict[str, Optional[str]] = _headers or {}
921
+ _form_params: List[Tuple[str, str]] = []
922
+ _files: Dict[
923
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
924
+ ] = {}
925
+ _body_params: Optional[bytes] = None
926
+
927
+ # process the path parameters
928
+ if vulnerability_report_href is not None:
929
+ _path_params['vulnerability_report_href'] = vulnerability_report_href
930
+ # process the query parameters
931
+ if fields is not None:
932
+
933
+ _query_params.append(('fields', fields))
934
+
935
+ if exclude_fields is not None:
936
+
937
+ _query_params.append(('exclude_fields', exclude_fields))
938
+
939
+ # process the header parameters
940
+ if x_task_diagnostics is not None:
941
+ _header_params['X-Task-Diagnostics'] = x_task_diagnostics
942
+ # process the form parameters
943
+ # process the body parameter
944
+
945
+
946
+ # set the HTTP header `Accept`
947
+ if 'Accept' not in _header_params:
948
+ _header_params['Accept'] = self.api_client.select_header_accept(
949
+ [
950
+ 'application/json'
951
+ ]
952
+ )
953
+
954
+
955
+ # authentication setting
956
+ _auth_settings: List[str] = [
957
+ 'json_header_remote_authentication',
958
+ 'basicAuth',
959
+ 'cookieAuth'
960
+ ]
961
+
962
+ return self.api_client.param_serialize(
963
+ method='GET',
964
+ resource_path='{vulnerability_report_href}',
965
+ path_params=_path_params,
966
+ query_params=_query_params,
967
+ header_params=_header_params,
968
+ body=_body_params,
969
+ post_params=_form_params,
970
+ files=_files,
971
+ auth_settings=_auth_settings,
972
+ collection_formats=_collection_formats,
973
+ _host=_host,
974
+ _request_auth=_request_auth
975
+ )
976
+
977
+