dockflow-sdk 0.3.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 (52) hide show
  1. dockflow_sdk/__init__.py +124 -0
  2. dockflow_sdk/api/__init__.py +8 -0
  3. dockflow_sdk/api/documents_api.py +1382 -0
  4. dockflow_sdk/api/tradeflows_api.py +615 -0
  5. dockflow_sdk/api/upstream_api.py +471 -0
  6. dockflow_sdk/api/widget_api.py +303 -0
  7. dockflow_sdk/api_client.py +865 -0
  8. dockflow_sdk/api_response.py +21 -0
  9. dockflow_sdk/configuration.py +658 -0
  10. dockflow_sdk/exceptions.py +218 -0
  11. dockflow_sdk/models/__init__.py +51 -0
  12. dockflow_sdk/models/container_reference.py +90 -0
  13. dockflow_sdk/models/create_tradeflows202_response.py +104 -0
  14. dockflow_sdk/models/create_tradeflows202_response_tradeflows_inner.py +90 -0
  15. dockflow_sdk/models/document_update.py +92 -0
  16. dockflow_sdk/models/document_upload.py +105 -0
  17. dockflow_sdk/models/downstream_tradeflow.py +189 -0
  18. dockflow_sdk/models/downstream_tradeflow_bill_of_lading_reference.py +138 -0
  19. dockflow_sdk/models/downstream_tradeflow_booking_reference.py +138 -0
  20. dockflow_sdk/models/downstream_tradeflow_events_inner.py +97 -0
  21. dockflow_sdk/models/downstream_tradeflow_free_time_overrides_inner.py +101 -0
  22. dockflow_sdk/models/downstream_tradeflow_mock_tracking.py +88 -0
  23. dockflow_sdk/models/downstream_tradeflow_partners_inner.py +94 -0
  24. dockflow_sdk/models/downstream_tradeflow_references.py +92 -0
  25. dockflow_sdk/models/get_document200_response.py +100 -0
  26. dockflow_sdk/models/get_document200_response_data_inner.py +133 -0
  27. dockflow_sdk/models/get_document200_response_data_inner_document_type.py +90 -0
  28. dockflow_sdk/models/get_upstream200_response.py +102 -0
  29. dockflow_sdk/models/get_upstream400_response.py +172 -0
  30. dockflow_sdk/models/inline_object.py +90 -0
  31. dockflow_sdk/models/list_document_types200_response_inner.py +90 -0
  32. dockflow_sdk/models/upload_document202_response.py +120 -0
  33. dockflow_sdk/models/upload_document400_response.py +155 -0
  34. dockflow_sdk/models/upstream_record.py +132 -0
  35. dockflow_sdk/models/upstream_record_additional_references.py +90 -0
  36. dockflow_sdk/models/upstream_record_data_quality.py +96 -0
  37. dockflow_sdk/models/upstream_record_metadata.py +105 -0
  38. dockflow_sdk/models/widget_container.py +120 -0
  39. dockflow_sdk/models/widget_country.py +100 -0
  40. dockflow_sdk/models/widget_leg.py +113 -0
  41. dockflow_sdk/models/widget_location.py +129 -0
  42. dockflow_sdk/models/widget_milestone.py +118 -0
  43. dockflow_sdk/models/widget_point.py +90 -0
  44. dockflow_sdk/models/widget_search_result.py +155 -0
  45. dockflow_sdk/models/widget_track.py +102 -0
  46. dockflow_sdk/models/widget_track_reading.py +92 -0
  47. dockflow_sdk/py.typed +0 -0
  48. dockflow_sdk/rest.py +334 -0
  49. dockflow_sdk-0.3.0.dist-info/METADATA +212 -0
  50. dockflow_sdk-0.3.0.dist-info/RECORD +52 -0
  51. dockflow_sdk-0.3.0.dist-info/WHEEL +5 -0
  52. dockflow_sdk-0.3.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,471 @@
1
+ """
2
+ Dockflow v3 API
3
+
4
+ No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
+
6
+ The version of the OpenAPI document: 3.0.0
7
+ Generated by OpenAPI Generator (https://openapi-generator.tech)
8
+
9
+ Do not edit the class manually.
10
+ """ # noqa: E501
11
+
12
+
13
+ import warnings
14
+ from pydantic import validate_call, Field, StrictFloat, StrictStr, StrictInt
15
+ from typing import Any, Dict, List, Optional, Tuple, Union
16
+ from typing_extensions import Annotated
17
+
18
+ from pydantic import Field, StrictInt, StrictStr, field_validator
19
+ from typing import Optional
20
+ from typing_extensions import Annotated
21
+ from dockflow_sdk.models.get_upstream200_response import GetUpstream200Response
22
+
23
+ from dockflow_sdk.api_client import ApiClient, RequestSerialized
24
+ from dockflow_sdk.api_response import ApiResponse
25
+ from dockflow_sdk.rest import RESTResponseType
26
+
27
+
28
+ class UpstreamApi:
29
+ """NOTE: This class is auto generated by OpenAPI Generator
30
+ Ref: https://openapi-generator.tech
31
+
32
+ Do not edit the class manually.
33
+ """
34
+
35
+ def __init__(self, api_client=None) -> None:
36
+ if api_client is None:
37
+ api_client = ApiClient.get_default()
38
+ self.api_client = api_client
39
+
40
+
41
+ @validate_call
42
+ def get_upstream(
43
+ self,
44
+ since: Annotated[Optional[StrictStr], Field(description="Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.")] = None,
45
+ tradeflow: Annotated[Optional[StrictStr], Field(description="Your tradeflow reference. Returns that tradeflow regardless of when it changed.")] = None,
46
+ container: Annotated[Optional[StrictStr], Field(description="A container number. Returns its tradeflows regardless of when they changed.")] = None,
47
+ category: Annotated[Optional[StrictStr], Field(description="Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.")] = None,
48
+ code: Annotated[Optional[StrictStr], Field(description="Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.")] = None,
49
+ cursor: Annotated[Optional[StrictStr], Field(description="next_cursor from the previous page. Keep since identical across the pages of one cycle.")] = None,
50
+ active: Annotated[Optional[StrictStr], Field(description="true (active only), false, or both. Default: active plus recently deactivated.")] = None,
51
+ fields: Annotated[Optional[StrictStr], Field(description="Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.")] = None,
52
+ format: Annotated[Optional[StrictStr], Field(description="Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.")] = None,
53
+ per_page: Annotated[Optional[StrictInt], Field(description="Tradeflows per page, 1 to 1000. Default 50.")] = None,
54
+ failsafe: Annotated[Optional[StrictStr], Field(description="Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.")] = None,
55
+ _request_timeout: Union[
56
+ None,
57
+ Annotated[StrictFloat, Field(gt=0)],
58
+ Tuple[
59
+ Annotated[StrictFloat, Field(gt=0)],
60
+ Annotated[StrictFloat, Field(gt=0)]
61
+ ]
62
+ ] = None,
63
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
64
+ _content_type: Optional[StrictStr] = None,
65
+ _headers: Optional[Dict[StrictStr, Any]] = None,
66
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
67
+ ) -> GetUpstream200Response:
68
+ """Poll upstream events
69
+
70
+
71
+ :param since: Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.
72
+ :type since: str
73
+ :param tradeflow: Your tradeflow reference. Returns that tradeflow regardless of when it changed.
74
+ :type tradeflow: str
75
+ :param container: A container number. Returns its tradeflows regardless of when they changed.
76
+ :type container: str
77
+ :param category: Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.
78
+ :type category: str
79
+ :param code: Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.
80
+ :type code: str
81
+ :param cursor: next_cursor from the previous page. Keep since identical across the pages of one cycle.
82
+ :type cursor: str
83
+ :param active: true (active only), false, or both. Default: active plus recently deactivated.
84
+ :type active: str
85
+ :param fields: Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.
86
+ :type fields: str
87
+ :param format: Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.
88
+ :type format: str
89
+ :param per_page: Tradeflows per page, 1 to 1000. Default 50.
90
+ :type per_page: int
91
+ :param failsafe: Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.
92
+ :type failsafe: str
93
+ :param _request_timeout: timeout setting for this request. If one
94
+ number provided, it will be total request
95
+ timeout. It can also be a pair (tuple) of
96
+ (connection, read) timeouts.
97
+ :type _request_timeout: int, tuple(int, int), optional
98
+ :param _request_auth: set to override the auth_settings for an a single
99
+ request; this effectively ignores the
100
+ authentication in the spec for a single request.
101
+ :type _request_auth: dict, optional
102
+ :param _content_type: force content-type for the request.
103
+ :type _content_type: str, Optional
104
+ :param _headers: set to override the headers for a single
105
+ request; this effectively ignores the headers
106
+ in the spec for a single request.
107
+ :type _headers: dict, optional
108
+ :param _host_index: set to override the host_index for a single
109
+ request; this effectively ignores the host_index
110
+ in the spec for a single request.
111
+ :type _host_index: int, optional
112
+ :return: Returns the result object.
113
+ """ # noqa: E501
114
+
115
+ _param = self._get_upstream_serialize(
116
+ since=since,
117
+ tradeflow=tradeflow,
118
+ container=container,
119
+ category=category,
120
+ code=code,
121
+ cursor=cursor,
122
+ active=active,
123
+ fields=fields,
124
+ format=format,
125
+ per_page=per_page,
126
+ failsafe=failsafe,
127
+ _request_auth=_request_auth,
128
+ _content_type=_content_type,
129
+ _headers=_headers,
130
+ _host_index=_host_index
131
+ )
132
+
133
+ _response_types_map: Dict[str, Optional[str]] = {
134
+ '200': "GetUpstream200Response",
135
+ '400': "GetUpstream400Response",
136
+ }
137
+ response_data = self.api_client.call_api(
138
+ *_param,
139
+ _request_timeout=_request_timeout
140
+ )
141
+ response_data.read()
142
+ return self.api_client.response_deserialize(
143
+ response_data=response_data,
144
+ response_types_map=_response_types_map,
145
+ ).data
146
+
147
+
148
+ @validate_call
149
+ def get_upstream_with_http_info(
150
+ self,
151
+ since: Annotated[Optional[StrictStr], Field(description="Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.")] = None,
152
+ tradeflow: Annotated[Optional[StrictStr], Field(description="Your tradeflow reference. Returns that tradeflow regardless of when it changed.")] = None,
153
+ container: Annotated[Optional[StrictStr], Field(description="A container number. Returns its tradeflows regardless of when they changed.")] = None,
154
+ category: Annotated[Optional[StrictStr], Field(description="Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.")] = None,
155
+ code: Annotated[Optional[StrictStr], Field(description="Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.")] = None,
156
+ cursor: Annotated[Optional[StrictStr], Field(description="next_cursor from the previous page. Keep since identical across the pages of one cycle.")] = None,
157
+ active: Annotated[Optional[StrictStr], Field(description="true (active only), false, or both. Default: active plus recently deactivated.")] = None,
158
+ fields: Annotated[Optional[StrictStr], Field(description="Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.")] = None,
159
+ format: Annotated[Optional[StrictStr], Field(description="Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.")] = None,
160
+ per_page: Annotated[Optional[StrictInt], Field(description="Tradeflows per page, 1 to 1000. Default 50.")] = None,
161
+ failsafe: Annotated[Optional[StrictStr], Field(description="Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.")] = None,
162
+ _request_timeout: Union[
163
+ None,
164
+ Annotated[StrictFloat, Field(gt=0)],
165
+ Tuple[
166
+ Annotated[StrictFloat, Field(gt=0)],
167
+ Annotated[StrictFloat, Field(gt=0)]
168
+ ]
169
+ ] = None,
170
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
171
+ _content_type: Optional[StrictStr] = None,
172
+ _headers: Optional[Dict[StrictStr, Any]] = None,
173
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
174
+ ) -> ApiResponse[GetUpstream200Response]:
175
+ """Poll upstream events
176
+
177
+
178
+ :param since: Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.
179
+ :type since: str
180
+ :param tradeflow: Your tradeflow reference. Returns that tradeflow regardless of when it changed.
181
+ :type tradeflow: str
182
+ :param container: A container number. Returns its tradeflows regardless of when they changed.
183
+ :type container: str
184
+ :param category: Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.
185
+ :type category: str
186
+ :param code: Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.
187
+ :type code: str
188
+ :param cursor: next_cursor from the previous page. Keep since identical across the pages of one cycle.
189
+ :type cursor: str
190
+ :param active: true (active only), false, or both. Default: active plus recently deactivated.
191
+ :type active: str
192
+ :param fields: Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.
193
+ :type fields: str
194
+ :param format: Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.
195
+ :type format: str
196
+ :param per_page: Tradeflows per page, 1 to 1000. Default 50.
197
+ :type per_page: int
198
+ :param failsafe: Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.
199
+ :type failsafe: str
200
+ :param _request_timeout: timeout setting for this request. If one
201
+ number provided, it will be total request
202
+ timeout. It can also be a pair (tuple) of
203
+ (connection, read) timeouts.
204
+ :type _request_timeout: int, tuple(int, int), optional
205
+ :param _request_auth: set to override the auth_settings for an a single
206
+ request; this effectively ignores the
207
+ authentication in the spec for a single request.
208
+ :type _request_auth: dict, optional
209
+ :param _content_type: force content-type for the request.
210
+ :type _content_type: str, Optional
211
+ :param _headers: set to override the headers for a single
212
+ request; this effectively ignores the headers
213
+ in the spec for a single request.
214
+ :type _headers: dict, optional
215
+ :param _host_index: set to override the host_index for a single
216
+ request; this effectively ignores the host_index
217
+ in the spec for a single request.
218
+ :type _host_index: int, optional
219
+ :return: Returns the result object.
220
+ """ # noqa: E501
221
+
222
+ _param = self._get_upstream_serialize(
223
+ since=since,
224
+ tradeflow=tradeflow,
225
+ container=container,
226
+ category=category,
227
+ code=code,
228
+ cursor=cursor,
229
+ active=active,
230
+ fields=fields,
231
+ format=format,
232
+ per_page=per_page,
233
+ failsafe=failsafe,
234
+ _request_auth=_request_auth,
235
+ _content_type=_content_type,
236
+ _headers=_headers,
237
+ _host_index=_host_index
238
+ )
239
+
240
+ _response_types_map: Dict[str, Optional[str]] = {
241
+ '200': "GetUpstream200Response",
242
+ '400': "GetUpstream400Response",
243
+ }
244
+ response_data = self.api_client.call_api(
245
+ *_param,
246
+ _request_timeout=_request_timeout
247
+ )
248
+ response_data.read()
249
+ return self.api_client.response_deserialize(
250
+ response_data=response_data,
251
+ response_types_map=_response_types_map,
252
+ )
253
+
254
+
255
+ @validate_call
256
+ def get_upstream_without_preload_content(
257
+ self,
258
+ since: Annotated[Optional[StrictStr], Field(description="Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.")] = None,
259
+ tradeflow: Annotated[Optional[StrictStr], Field(description="Your tradeflow reference. Returns that tradeflow regardless of when it changed.")] = None,
260
+ container: Annotated[Optional[StrictStr], Field(description="A container number. Returns its tradeflows regardless of when they changed.")] = None,
261
+ category: Annotated[Optional[StrictStr], Field(description="Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.")] = None,
262
+ code: Annotated[Optional[StrictStr], Field(description="Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.")] = None,
263
+ cursor: Annotated[Optional[StrictStr], Field(description="next_cursor from the previous page. Keep since identical across the pages of one cycle.")] = None,
264
+ active: Annotated[Optional[StrictStr], Field(description="true (active only), false, or both. Default: active plus recently deactivated.")] = None,
265
+ fields: Annotated[Optional[StrictStr], Field(description="Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.")] = None,
266
+ format: Annotated[Optional[StrictStr], Field(description="Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.")] = None,
267
+ per_page: Annotated[Optional[StrictInt], Field(description="Tradeflows per page, 1 to 1000. Default 50.")] = None,
268
+ failsafe: Annotated[Optional[StrictStr], Field(description="Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.")] = None,
269
+ _request_timeout: Union[
270
+ None,
271
+ Annotated[StrictFloat, Field(gt=0)],
272
+ Tuple[
273
+ Annotated[StrictFloat, Field(gt=0)],
274
+ Annotated[StrictFloat, Field(gt=0)]
275
+ ]
276
+ ] = None,
277
+ _request_auth: Optional[Dict[StrictStr, Any]] = None,
278
+ _content_type: Optional[StrictStr] = None,
279
+ _headers: Optional[Dict[StrictStr, Any]] = None,
280
+ _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
281
+ ) -> RESTResponseType:
282
+ """Poll upstream events
283
+
284
+
285
+ :param since: Only tradeflows changed after this ISO 8601 timestamp (exclusive), with an offset. Without since, cursor, tradeflow or container: the last 15 minutes.
286
+ :type since: str
287
+ :param tradeflow: Your tradeflow reference. Returns that tradeflow regardless of when it changed.
288
+ :type tradeflow: str
289
+ :param container: A container number. Returns its tradeflows regardless of when they changed.
290
+ :type container: str
291
+ :param category: Keep only events of this category: MILESTONE, SHIPMENT or LOCATION.
292
+ :type category: str
293
+ :param code: Keep only events whose code starts with this value. One of: GE, GN, AE, VD, VA, UV, GT, GD, GR, POS, A-BKD, A-RCS, A-DEP, A-ARR, A-RCF, A-NFD, A-DLV. Any other value returns 400.
294
+ :type code: str
295
+ :param cursor: next_cursor from the previous page. Keep since identical across the pages of one cycle.
296
+ :type cursor: str
297
+ :param active: true (active only), false, or both. Default: active plus recently deactivated.
298
+ :type active: str
299
+ :param fields: Comma-separated blocks: events, locations, containers, shipment, vessels. Default: all but vessels.
300
+ :type fields: str
301
+ :param format: Shape of `events`: `v3` (Dockflow milestones) or `dcsa-tnt-2.2` (DCSA Track & Trace 2.2). The rest of the record is identical.
302
+ :type format: str
303
+ :param per_page: Tradeflows per page, 1 to 1000. Default 50.
304
+ :type per_page: int
305
+ :param failsafe: Set to 1 and Dockflow keeps your position per API key and filter set, so repeated identical polls skip nothing.
306
+ :type failsafe: str
307
+ :param _request_timeout: timeout setting for this request. If one
308
+ number provided, it will be total request
309
+ timeout. It can also be a pair (tuple) of
310
+ (connection, read) timeouts.
311
+ :type _request_timeout: int, tuple(int, int), optional
312
+ :param _request_auth: set to override the auth_settings for an a single
313
+ request; this effectively ignores the
314
+ authentication in the spec for a single request.
315
+ :type _request_auth: dict, optional
316
+ :param _content_type: force content-type for the request.
317
+ :type _content_type: str, Optional
318
+ :param _headers: set to override the headers for a single
319
+ request; this effectively ignores the headers
320
+ in the spec for a single request.
321
+ :type _headers: dict, optional
322
+ :param _host_index: set to override the host_index for a single
323
+ request; this effectively ignores the host_index
324
+ in the spec for a single request.
325
+ :type _host_index: int, optional
326
+ :return: Returns the result object.
327
+ """ # noqa: E501
328
+
329
+ _param = self._get_upstream_serialize(
330
+ since=since,
331
+ tradeflow=tradeflow,
332
+ container=container,
333
+ category=category,
334
+ code=code,
335
+ cursor=cursor,
336
+ active=active,
337
+ fields=fields,
338
+ format=format,
339
+ per_page=per_page,
340
+ failsafe=failsafe,
341
+ _request_auth=_request_auth,
342
+ _content_type=_content_type,
343
+ _headers=_headers,
344
+ _host_index=_host_index
345
+ )
346
+
347
+ _response_types_map: Dict[str, Optional[str]] = {
348
+ '200': "GetUpstream200Response",
349
+ '400': "GetUpstream400Response",
350
+ }
351
+ response_data = self.api_client.call_api(
352
+ *_param,
353
+ _request_timeout=_request_timeout
354
+ )
355
+ return response_data.response
356
+
357
+
358
+ def _get_upstream_serialize(
359
+ self,
360
+ since,
361
+ tradeflow,
362
+ container,
363
+ category,
364
+ code,
365
+ cursor,
366
+ active,
367
+ fields,
368
+ format,
369
+ per_page,
370
+ failsafe,
371
+ _request_auth,
372
+ _content_type,
373
+ _headers,
374
+ _host_index,
375
+ ) -> RequestSerialized:
376
+
377
+ _host = None
378
+
379
+ _collection_formats: Dict[str, str] = {
380
+ }
381
+
382
+ _path_params: Dict[str, str] = {}
383
+ _query_params: List[Tuple[str, str]] = []
384
+ _header_params: Dict[str, Any] = self.api_client._merge_headers(_headers)
385
+ _form_params: List[Tuple[str, str]] = []
386
+ _files: Dict[
387
+ str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
388
+ ] = {}
389
+ _body_params: Optional[bytes] = None
390
+
391
+ # process the path parameters
392
+ # process the query parameters
393
+ if since is not None:
394
+
395
+ _query_params.append(('since', since))
396
+
397
+ if tradeflow is not None:
398
+
399
+ _query_params.append(('tradeflow', tradeflow))
400
+
401
+ if container is not None:
402
+
403
+ _query_params.append(('container', container))
404
+
405
+ if category is not None:
406
+
407
+ _query_params.append(('category', category))
408
+
409
+ if code is not None:
410
+
411
+ _query_params.append(('code', code))
412
+
413
+ if cursor is not None:
414
+
415
+ _query_params.append(('cursor', cursor))
416
+
417
+ if active is not None:
418
+
419
+ _query_params.append(('active', active))
420
+
421
+ if fields is not None:
422
+
423
+ _query_params.append(('fields', fields))
424
+
425
+ if format is not None:
426
+
427
+ _query_params.append(('format', format))
428
+
429
+ if per_page is not None:
430
+
431
+ _query_params.append(('per_page', per_page))
432
+
433
+ if failsafe is not None:
434
+
435
+ _query_params.append(('failsafe', failsafe))
436
+
437
+ # process the header parameters
438
+ # process the form parameters
439
+ # process the body parameter
440
+
441
+
442
+ # set the HTTP header `Accept`
443
+ if not any(key.lower() == 'accept' for key in _header_params):
444
+ _header_params['Accept'] = self.api_client.select_header_accept(
445
+ [
446
+ 'application/json'
447
+ ]
448
+ )
449
+
450
+
451
+ # authentication setting
452
+ _auth_settings: List[str] = [
453
+ 'ApiKey'
454
+ ]
455
+
456
+ return self.api_client.param_serialize(
457
+ method='GET',
458
+ resource_path='/v3/upstream',
459
+ path_params=_path_params,
460
+ query_params=_query_params,
461
+ header_params=_header_params,
462
+ body=_body_params,
463
+ post_params=_form_params,
464
+ files=_files,
465
+ auth_settings=_auth_settings,
466
+ collection_formats=_collection_formats,
467
+ _host=_host,
468
+ _request_auth=_request_auth
469
+ )
470
+
471
+