trustcomponent 0.0.1b0__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.
- trustcomponent/__init__.py +7 -0
- trustcomponent/_client.py +54 -0
- trustcomponent/_generated/__init__.py +186 -0
- trustcomponent/_generated/api/__init__.py +12 -0
- trustcomponent/_generated/api/analytics_server_events_api.py +330 -0
- trustcomponent/_generated/api/analytics_websites_api.py +2006 -0
- trustcomponent/_generated/api/captcha_verifications_api.py +335 -0
- trustcomponent/_generated/api/monitoring_heartbeats_api.py +315 -0
- trustcomponent/_generated/api/platform_events_api.py +381 -0
- trustcomponent/_generated/api/tax_validation_schedules_api.py +579 -0
- trustcomponent/_generated/api/tax_validation_validation_results_api.py +305 -0
- trustcomponent/_generated/api/tax_validation_validations_api.py +609 -0
- trustcomponent/_generated/api_client.py +819 -0
- trustcomponent/_generated/api_response.py +21 -0
- trustcomponent/_generated/configuration.py +630 -0
- trustcomponent/_generated/exceptions.py +218 -0
- trustcomponent/_generated/models/__init__.py +78 -0
- trustcomponent/_generated/models/analytics_event_category_enum.py +49 -0
- trustcomponent/_generated/models/analytics_realtime.py +110 -0
- trustcomponent/_generated/models/analytics_realtime_page.py +90 -0
- trustcomponent/_generated/models/analytics_realtime_point.py +90 -0
- trustcomponent/_generated/models/analytics_server_event_batch_create_params.py +106 -0
- trustcomponent/_generated/models/analytics_server_event_batch_event_commerce_create_params.py +113 -0
- trustcomponent/_generated/models/analytics_server_event_batch_event_commerce_product_create_params.py +97 -0
- trustcomponent/_generated/models/analytics_server_event_batch_event_create_params.py +131 -0
- trustcomponent/_generated/models/analytics_server_event_batch_event_error_create_params.py +95 -0
- trustcomponent/_generated/models/analytics_server_event_batch_event_refund_create_params.py +91 -0
- trustcomponent/_generated/models/analytics_server_event_batch_result.py +98 -0
- trustcomponent/_generated/models/analytics_server_event_batch_result_drop_reason_enum.py +49 -0
- trustcomponent/_generated/models/analytics_server_event_batch_result_dropped.py +91 -0
- trustcomponent/_generated/models/analytics_stats_breakdown.py +109 -0
- trustcomponent/_generated/models/analytics_stats_breakdown_row.py +100 -0
- trustcomponent/_generated/models/analytics_stats_breakdown_row_page.py +111 -0
- trustcomponent/_generated/models/analytics_stats_conversions.py +102 -0
- trustcomponent/_generated/models/analytics_stats_conversions_goal.py +110 -0
- trustcomponent/_generated/models/analytics_stats_conversions_goal_revenue.py +90 -0
- trustcomponent/_generated/models/analytics_stats_dimension_enum.py +66 -0
- trustcomponent/_generated/models/analytics_stats_filter_match_mode_enum.py +37 -0
- trustcomponent/_generated/models/analytics_stats_filter_operator_enum.py +42 -0
- trustcomponent/_generated/models/analytics_stats_granularity_enum.py +37 -0
- trustcomponent/_generated/models/analytics_stats_overview.py +105 -0
- trustcomponent/_generated/models/analytics_stats_timeseries.py +103 -0
- trustcomponent/_generated/models/analytics_stats_timeseries_point.py +94 -0
- trustcomponent/_generated/models/analytics_stats_totals.py +117 -0
- trustcomponent/_generated/models/analytics_website.py +95 -0
- trustcomponent/_generated/models/analytics_websites_page.py +102 -0
- trustcomponent/_generated/models/captcha_verification_result.py +128 -0
- trustcomponent/_generated/models/platform_event.py +136 -0
- trustcomponent/_generated/models/platform_event_actor.py +110 -0
- trustcomponent/_generated/models/platform_event_actor_automation.py +91 -0
- trustcomponent/_generated/models/platform_event_actor_automation_kind_enum.py +38 -0
- trustcomponent/_generated/models/platform_event_actor_type_enum.py +40 -0
- trustcomponent/_generated/models/platform_event_change.py +107 -0
- trustcomponent/_generated/models/platform_event_change_operation_enum.py +40 -0
- trustcomponent/_generated/models/platform_event_origin.py +107 -0
- trustcomponent/_generated/models/platform_event_ref.py +98 -0
- trustcomponent/_generated/models/platform_event_source_enum.py +41 -0
- trustcomponent/_generated/models/platform_events_page.py +113 -0
- trustcomponent/_generated/models/tax_validation_match_status_enum.py +41 -0
- trustcomponent/_generated/models/tax_validation_provider_enum.py +43 -0
- trustcomponent/_generated/models/tax_validation_provider_status_enum.py +48 -0
- trustcomponent/_generated/models/tax_validation_schedule.py +124 -0
- trustcomponent/_generated/models/tax_validation_schedule_create_params.py +135 -0
- trustcomponent/_generated/models/tax_validation_tax_address.py +121 -0
- trustcomponent/_generated/models/tax_validation_tax_identifier_scheme_enum.py +46 -0
- trustcomponent/_generated/models/tax_validation_validation.py +163 -0
- trustcomponent/_generated/models/tax_validation_validation_address_match.py +97 -0
- trustcomponent/_generated/models/tax_validation_validation_batch_create_params.py +97 -0
- trustcomponent/_generated/models/tax_validation_validation_create_params.py +135 -0
- trustcomponent/_generated/models/tax_validation_validation_frequency_enum.py +38 -0
- trustcomponent/_generated/models/tax_validation_validation_input.py +117 -0
- trustcomponent/_generated/models/tax_validation_validation_match.py +97 -0
- trustcomponent/_generated/models/tax_validation_validation_mode_enum.py +37 -0
- trustcomponent/_generated/models/tax_validation_validation_outcome_enum.py +41 -0
- trustcomponent/_generated/models/tax_validation_validation_request_status_enum.py +41 -0
- trustcomponent/_generated/models/tax_validation_validation_response_data.py +113 -0
- trustcomponent/_generated/models/tax_validation_validation_result.py +146 -0
- trustcomponent/_generated/models/tax_validation_validation_schedule_attach_params.py +109 -0
- trustcomponent/_generated/models/tax_validation_verification_method_enum.py +37 -0
- trustcomponent/_generated/modules.py +42 -0
- trustcomponent/_generated/py.typed +0 -0
- trustcomponent/_generated/rest.py +313 -0
- trustcomponent/_http.py +90 -0
- trustcomponent/captcha.py +33 -0
- trustcomponent/errors.py +51 -0
- trustcomponent-0.0.1b0.dist-info/METADATA +98 -0
- trustcomponent-0.0.1b0.dist-info/RECORD +89 -0
- trustcomponent-0.0.1b0.dist-info/WHEEL +4 -0
- trustcomponent-0.0.1b0.dist-info/licenses/LICENSE.md +21 -0
|
@@ -0,0 +1,609 @@
|
|
|
1
|
+
"""
|
|
2
|
+
TrustComponent API
|
|
3
|
+
|
|
4
|
+
The public API of every TrustComponent module, authenticated with an API key (`ak_…`). Each operation carries its own version in its path.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 0.0.1-beta.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
|
|
19
|
+
from typing import List
|
|
20
|
+
from typing_extensions import Annotated
|
|
21
|
+
from trustcomponent._generated.models.tax_validation_validation import TaxValidationValidation
|
|
22
|
+
from trustcomponent._generated.models.tax_validation_validation_batch_create_params import TaxValidationValidationBatchCreateParams
|
|
23
|
+
from trustcomponent._generated.models.tax_validation_validation_create_params import TaxValidationValidationCreateParams
|
|
24
|
+
|
|
25
|
+
from trustcomponent._generated.api_client import ApiClient, RequestSerialized
|
|
26
|
+
from trustcomponent._generated.api_response import ApiResponse
|
|
27
|
+
from trustcomponent._generated.rest import RESTResponseType
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
class TaxValidationValidationsApi:
|
|
31
|
+
"""NOTE: This class is auto generated by OpenAPI Generator
|
|
32
|
+
Ref: https://openapi-generator.tech
|
|
33
|
+
|
|
34
|
+
Do not edit the class manually.
|
|
35
|
+
"""
|
|
36
|
+
|
|
37
|
+
def __init__(self, api_client=None) -> None:
|
|
38
|
+
if api_client is None:
|
|
39
|
+
api_client = ApiClient.get_default()
|
|
40
|
+
self.api_client = api_client
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
@validate_call
|
|
44
|
+
def create_validation(
|
|
45
|
+
self,
|
|
46
|
+
tax_validation_validation_create_params: Annotated[TaxValidationValidationCreateParams, Field(description="Validation input")],
|
|
47
|
+
_request_timeout: Union[
|
|
48
|
+
None,
|
|
49
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
50
|
+
Tuple[
|
|
51
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
52
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
53
|
+
]
|
|
54
|
+
] = None,
|
|
55
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
56
|
+
_content_type: Optional[StrictStr] = None,
|
|
57
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
58
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
59
|
+
) -> TaxValidationValidation:
|
|
60
|
+
"""Submits a validation request via API key (programmatic integration)
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
:param tax_validation_validation_create_params: Validation input (required)
|
|
64
|
+
:type tax_validation_validation_create_params: TaxValidationValidationCreateParams
|
|
65
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
66
|
+
number provided, it will be total request
|
|
67
|
+
timeout. It can also be a pair (tuple) of
|
|
68
|
+
(connection, read) timeouts.
|
|
69
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
70
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
71
|
+
request; this effectively ignores the
|
|
72
|
+
authentication in the spec for a single request.
|
|
73
|
+
:type _request_auth: dict, optional
|
|
74
|
+
:param _content_type: force content-type for the request.
|
|
75
|
+
:type _content_type: str, Optional
|
|
76
|
+
:param _headers: set to override the headers for a single
|
|
77
|
+
request; this effectively ignores the headers
|
|
78
|
+
in the spec for a single request.
|
|
79
|
+
:type _headers: dict, optional
|
|
80
|
+
:param _host_index: set to override the host_index for a single
|
|
81
|
+
request; this effectively ignores the host_index
|
|
82
|
+
in the spec for a single request.
|
|
83
|
+
:type _host_index: int, optional
|
|
84
|
+
:return: Returns the result object.
|
|
85
|
+
""" # noqa: E501
|
|
86
|
+
|
|
87
|
+
_param = self._create_validation_serialize(
|
|
88
|
+
tax_validation_validation_create_params=tax_validation_validation_create_params,
|
|
89
|
+
_request_auth=_request_auth,
|
|
90
|
+
_content_type=_content_type,
|
|
91
|
+
_headers=_headers,
|
|
92
|
+
_host_index=_host_index
|
|
93
|
+
)
|
|
94
|
+
|
|
95
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
96
|
+
'201': "TaxValidationValidation",
|
|
97
|
+
'202': "TaxValidationValidation",
|
|
98
|
+
'401': None,
|
|
99
|
+
'403': None,
|
|
100
|
+
'422': None,
|
|
101
|
+
}
|
|
102
|
+
response_data = self.api_client.call_api(
|
|
103
|
+
*_param,
|
|
104
|
+
_request_timeout=_request_timeout
|
|
105
|
+
)
|
|
106
|
+
response_data.read()
|
|
107
|
+
return self.api_client.response_deserialize(
|
|
108
|
+
response_data=response_data,
|
|
109
|
+
response_types_map=_response_types_map,
|
|
110
|
+
).data
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
@validate_call
|
|
114
|
+
def create_validation_with_http_info(
|
|
115
|
+
self,
|
|
116
|
+
tax_validation_validation_create_params: Annotated[TaxValidationValidationCreateParams, Field(description="Validation input")],
|
|
117
|
+
_request_timeout: Union[
|
|
118
|
+
None,
|
|
119
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
120
|
+
Tuple[
|
|
121
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
122
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
123
|
+
]
|
|
124
|
+
] = None,
|
|
125
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
126
|
+
_content_type: Optional[StrictStr] = None,
|
|
127
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
128
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
129
|
+
) -> ApiResponse[TaxValidationValidation]:
|
|
130
|
+
"""Submits a validation request via API key (programmatic integration)
|
|
131
|
+
|
|
132
|
+
|
|
133
|
+
:param tax_validation_validation_create_params: Validation input (required)
|
|
134
|
+
:type tax_validation_validation_create_params: TaxValidationValidationCreateParams
|
|
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_validation_serialize(
|
|
158
|
+
tax_validation_validation_create_params=tax_validation_validation_create_params,
|
|
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': "TaxValidationValidation",
|
|
167
|
+
'202': "TaxValidationValidation",
|
|
168
|
+
'401': None,
|
|
169
|
+
'403': None,
|
|
170
|
+
'422': None,
|
|
171
|
+
}
|
|
172
|
+
response_data = self.api_client.call_api(
|
|
173
|
+
*_param,
|
|
174
|
+
_request_timeout=_request_timeout
|
|
175
|
+
)
|
|
176
|
+
response_data.read()
|
|
177
|
+
return self.api_client.response_deserialize(
|
|
178
|
+
response_data=response_data,
|
|
179
|
+
response_types_map=_response_types_map,
|
|
180
|
+
)
|
|
181
|
+
|
|
182
|
+
|
|
183
|
+
@validate_call
|
|
184
|
+
def create_validation_without_preload_content(
|
|
185
|
+
self,
|
|
186
|
+
tax_validation_validation_create_params: Annotated[TaxValidationValidationCreateParams, Field(description="Validation input")],
|
|
187
|
+
_request_timeout: Union[
|
|
188
|
+
None,
|
|
189
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
190
|
+
Tuple[
|
|
191
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
192
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
193
|
+
]
|
|
194
|
+
] = None,
|
|
195
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
196
|
+
_content_type: Optional[StrictStr] = None,
|
|
197
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
198
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
199
|
+
) -> RESTResponseType:
|
|
200
|
+
"""Submits a validation request via API key (programmatic integration)
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
:param tax_validation_validation_create_params: Validation input (required)
|
|
204
|
+
:type tax_validation_validation_create_params: TaxValidationValidationCreateParams
|
|
205
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
206
|
+
number provided, it will be total request
|
|
207
|
+
timeout. It can also be a pair (tuple) of
|
|
208
|
+
(connection, read) timeouts.
|
|
209
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
210
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
211
|
+
request; this effectively ignores the
|
|
212
|
+
authentication in the spec for a single request.
|
|
213
|
+
:type _request_auth: dict, optional
|
|
214
|
+
:param _content_type: force content-type for the request.
|
|
215
|
+
:type _content_type: str, Optional
|
|
216
|
+
:param _headers: set to override the headers for a single
|
|
217
|
+
request; this effectively ignores the headers
|
|
218
|
+
in the spec for a single request.
|
|
219
|
+
:type _headers: dict, optional
|
|
220
|
+
:param _host_index: set to override the host_index for a single
|
|
221
|
+
request; this effectively ignores the host_index
|
|
222
|
+
in the spec for a single request.
|
|
223
|
+
:type _host_index: int, optional
|
|
224
|
+
:return: Returns the result object.
|
|
225
|
+
""" # noqa: E501
|
|
226
|
+
|
|
227
|
+
_param = self._create_validation_serialize(
|
|
228
|
+
tax_validation_validation_create_params=tax_validation_validation_create_params,
|
|
229
|
+
_request_auth=_request_auth,
|
|
230
|
+
_content_type=_content_type,
|
|
231
|
+
_headers=_headers,
|
|
232
|
+
_host_index=_host_index
|
|
233
|
+
)
|
|
234
|
+
|
|
235
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
236
|
+
'201': "TaxValidationValidation",
|
|
237
|
+
'202': "TaxValidationValidation",
|
|
238
|
+
'401': None,
|
|
239
|
+
'403': None,
|
|
240
|
+
'422': None,
|
|
241
|
+
}
|
|
242
|
+
response_data = self.api_client.call_api(
|
|
243
|
+
*_param,
|
|
244
|
+
_request_timeout=_request_timeout
|
|
245
|
+
)
|
|
246
|
+
return response_data.response
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
def _create_validation_serialize(
|
|
250
|
+
self,
|
|
251
|
+
tax_validation_validation_create_params,
|
|
252
|
+
_request_auth,
|
|
253
|
+
_content_type,
|
|
254
|
+
_headers,
|
|
255
|
+
_host_index,
|
|
256
|
+
) -> RequestSerialized:
|
|
257
|
+
|
|
258
|
+
_host = None
|
|
259
|
+
|
|
260
|
+
_collection_formats: Dict[str, str] = {
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
_path_params: Dict[str, str] = {}
|
|
264
|
+
_query_params: List[Tuple[str, str]] = []
|
|
265
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
266
|
+
_form_params: List[Tuple[str, str]] = []
|
|
267
|
+
_files: Dict[
|
|
268
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
269
|
+
] = {}
|
|
270
|
+
_body_params: Optional[bytes] = None
|
|
271
|
+
|
|
272
|
+
# process the path parameters
|
|
273
|
+
# process the query parameters
|
|
274
|
+
# process the header parameters
|
|
275
|
+
# process the form parameters
|
|
276
|
+
# process the body parameter
|
|
277
|
+
if tax_validation_validation_create_params is not None:
|
|
278
|
+
_body_params = tax_validation_validation_create_params
|
|
279
|
+
|
|
280
|
+
|
|
281
|
+
# set the HTTP header `Accept`
|
|
282
|
+
if 'Accept' not in _header_params:
|
|
283
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
284
|
+
[
|
|
285
|
+
'application/json'
|
|
286
|
+
]
|
|
287
|
+
)
|
|
288
|
+
|
|
289
|
+
# set the HTTP header `Content-Type`
|
|
290
|
+
if _content_type:
|
|
291
|
+
_header_params['Content-Type'] = _content_type
|
|
292
|
+
else:
|
|
293
|
+
_default_content_type = (
|
|
294
|
+
self.api_client.select_header_content_type(
|
|
295
|
+
[
|
|
296
|
+
'application/json'
|
|
297
|
+
]
|
|
298
|
+
)
|
|
299
|
+
)
|
|
300
|
+
if _default_content_type is not None:
|
|
301
|
+
_header_params['Content-Type'] = _default_content_type
|
|
302
|
+
|
|
303
|
+
# authentication setting
|
|
304
|
+
_auth_settings: List[str] = [
|
|
305
|
+
'bearerApiKey'
|
|
306
|
+
]
|
|
307
|
+
|
|
308
|
+
return self.api_client.param_serialize(
|
|
309
|
+
method='POST',
|
|
310
|
+
resource_path='/taxvalidation/v1/validations',
|
|
311
|
+
path_params=_path_params,
|
|
312
|
+
query_params=_query_params,
|
|
313
|
+
header_params=_header_params,
|
|
314
|
+
body=_body_params,
|
|
315
|
+
post_params=_form_params,
|
|
316
|
+
files=_files,
|
|
317
|
+
auth_settings=_auth_settings,
|
|
318
|
+
collection_formats=_collection_formats,
|
|
319
|
+
_host=_host,
|
|
320
|
+
_request_auth=_request_auth
|
|
321
|
+
)
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
|
|
326
|
+
@validate_call
|
|
327
|
+
def create_validation_batch(
|
|
328
|
+
self,
|
|
329
|
+
tax_validation_validation_batch_create_params: Annotated[TaxValidationValidationBatchCreateParams, Field(description="Batch of validation inputs")],
|
|
330
|
+
_request_timeout: Union[
|
|
331
|
+
None,
|
|
332
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
333
|
+
Tuple[
|
|
334
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
335
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
336
|
+
]
|
|
337
|
+
] = None,
|
|
338
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
339
|
+
_content_type: Optional[StrictStr] = None,
|
|
340
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
341
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
342
|
+
) -> List[TaxValidationValidation]:
|
|
343
|
+
"""Submits multiple validation requests in one call via API key
|
|
344
|
+
|
|
345
|
+
Every item is accepted as a PENDING validation request and processed asynchronously; the per-item result is delivered via webhook (or can be polled). The response carries the created requests in input order, each without an outcome yet. A batch is always accepted or rejected as a whole.
|
|
346
|
+
|
|
347
|
+
:param tax_validation_validation_batch_create_params: Batch of validation inputs (required)
|
|
348
|
+
:type tax_validation_validation_batch_create_params: TaxValidationValidationBatchCreateParams
|
|
349
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
350
|
+
number provided, it will be total request
|
|
351
|
+
timeout. It can also be a pair (tuple) of
|
|
352
|
+
(connection, read) timeouts.
|
|
353
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
354
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
355
|
+
request; this effectively ignores the
|
|
356
|
+
authentication in the spec for a single request.
|
|
357
|
+
:type _request_auth: dict, optional
|
|
358
|
+
:param _content_type: force content-type for the request.
|
|
359
|
+
:type _content_type: str, Optional
|
|
360
|
+
:param _headers: set to override the headers for a single
|
|
361
|
+
request; this effectively ignores the headers
|
|
362
|
+
in the spec for a single request.
|
|
363
|
+
:type _headers: dict, optional
|
|
364
|
+
:param _host_index: set to override the host_index for a single
|
|
365
|
+
request; this effectively ignores the host_index
|
|
366
|
+
in the spec for a single request.
|
|
367
|
+
:type _host_index: int, optional
|
|
368
|
+
:return: Returns the result object.
|
|
369
|
+
""" # noqa: E501
|
|
370
|
+
|
|
371
|
+
_param = self._create_validation_batch_serialize(
|
|
372
|
+
tax_validation_validation_batch_create_params=tax_validation_validation_batch_create_params,
|
|
373
|
+
_request_auth=_request_auth,
|
|
374
|
+
_content_type=_content_type,
|
|
375
|
+
_headers=_headers,
|
|
376
|
+
_host_index=_host_index
|
|
377
|
+
)
|
|
378
|
+
|
|
379
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
380
|
+
'202': "List[TaxValidationValidation]",
|
|
381
|
+
'401': None,
|
|
382
|
+
'402': None,
|
|
383
|
+
'403': None,
|
|
384
|
+
'422': None,
|
|
385
|
+
}
|
|
386
|
+
response_data = self.api_client.call_api(
|
|
387
|
+
*_param,
|
|
388
|
+
_request_timeout=_request_timeout
|
|
389
|
+
)
|
|
390
|
+
response_data.read()
|
|
391
|
+
return self.api_client.response_deserialize(
|
|
392
|
+
response_data=response_data,
|
|
393
|
+
response_types_map=_response_types_map,
|
|
394
|
+
).data
|
|
395
|
+
|
|
396
|
+
|
|
397
|
+
@validate_call
|
|
398
|
+
def create_validation_batch_with_http_info(
|
|
399
|
+
self,
|
|
400
|
+
tax_validation_validation_batch_create_params: Annotated[TaxValidationValidationBatchCreateParams, Field(description="Batch of validation inputs")],
|
|
401
|
+
_request_timeout: Union[
|
|
402
|
+
None,
|
|
403
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
404
|
+
Tuple[
|
|
405
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
406
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
407
|
+
]
|
|
408
|
+
] = None,
|
|
409
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
410
|
+
_content_type: Optional[StrictStr] = None,
|
|
411
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
412
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
413
|
+
) -> ApiResponse[List[TaxValidationValidation]]:
|
|
414
|
+
"""Submits multiple validation requests in one call via API key
|
|
415
|
+
|
|
416
|
+
Every item is accepted as a PENDING validation request and processed asynchronously; the per-item result is delivered via webhook (or can be polled). The response carries the created requests in input order, each without an outcome yet. A batch is always accepted or rejected as a whole.
|
|
417
|
+
|
|
418
|
+
:param tax_validation_validation_batch_create_params: Batch of validation inputs (required)
|
|
419
|
+
:type tax_validation_validation_batch_create_params: TaxValidationValidationBatchCreateParams
|
|
420
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
421
|
+
number provided, it will be total request
|
|
422
|
+
timeout. It can also be a pair (tuple) of
|
|
423
|
+
(connection, read) timeouts.
|
|
424
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
425
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
426
|
+
request; this effectively ignores the
|
|
427
|
+
authentication in the spec for a single request.
|
|
428
|
+
:type _request_auth: dict, optional
|
|
429
|
+
:param _content_type: force content-type for the request.
|
|
430
|
+
:type _content_type: str, Optional
|
|
431
|
+
:param _headers: set to override the headers for a single
|
|
432
|
+
request; this effectively ignores the headers
|
|
433
|
+
in the spec for a single request.
|
|
434
|
+
:type _headers: dict, optional
|
|
435
|
+
:param _host_index: set to override the host_index for a single
|
|
436
|
+
request; this effectively ignores the host_index
|
|
437
|
+
in the spec for a single request.
|
|
438
|
+
:type _host_index: int, optional
|
|
439
|
+
:return: Returns the result object.
|
|
440
|
+
""" # noqa: E501
|
|
441
|
+
|
|
442
|
+
_param = self._create_validation_batch_serialize(
|
|
443
|
+
tax_validation_validation_batch_create_params=tax_validation_validation_batch_create_params,
|
|
444
|
+
_request_auth=_request_auth,
|
|
445
|
+
_content_type=_content_type,
|
|
446
|
+
_headers=_headers,
|
|
447
|
+
_host_index=_host_index
|
|
448
|
+
)
|
|
449
|
+
|
|
450
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
451
|
+
'202': "List[TaxValidationValidation]",
|
|
452
|
+
'401': None,
|
|
453
|
+
'402': None,
|
|
454
|
+
'403': None,
|
|
455
|
+
'422': None,
|
|
456
|
+
}
|
|
457
|
+
response_data = self.api_client.call_api(
|
|
458
|
+
*_param,
|
|
459
|
+
_request_timeout=_request_timeout
|
|
460
|
+
)
|
|
461
|
+
response_data.read()
|
|
462
|
+
return self.api_client.response_deserialize(
|
|
463
|
+
response_data=response_data,
|
|
464
|
+
response_types_map=_response_types_map,
|
|
465
|
+
)
|
|
466
|
+
|
|
467
|
+
|
|
468
|
+
@validate_call
|
|
469
|
+
def create_validation_batch_without_preload_content(
|
|
470
|
+
self,
|
|
471
|
+
tax_validation_validation_batch_create_params: Annotated[TaxValidationValidationBatchCreateParams, Field(description="Batch of validation inputs")],
|
|
472
|
+
_request_timeout: Union[
|
|
473
|
+
None,
|
|
474
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
475
|
+
Tuple[
|
|
476
|
+
Annotated[StrictFloat, Field(gt=0)],
|
|
477
|
+
Annotated[StrictFloat, Field(gt=0)]
|
|
478
|
+
]
|
|
479
|
+
] = None,
|
|
480
|
+
_request_auth: Optional[Dict[StrictStr, Any]] = None,
|
|
481
|
+
_content_type: Optional[StrictStr] = None,
|
|
482
|
+
_headers: Optional[Dict[StrictStr, Any]] = None,
|
|
483
|
+
_host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
|
|
484
|
+
) -> RESTResponseType:
|
|
485
|
+
"""Submits multiple validation requests in one call via API key
|
|
486
|
+
|
|
487
|
+
Every item is accepted as a PENDING validation request and processed asynchronously; the per-item result is delivered via webhook (or can be polled). The response carries the created requests in input order, each without an outcome yet. A batch is always accepted or rejected as a whole.
|
|
488
|
+
|
|
489
|
+
:param tax_validation_validation_batch_create_params: Batch of validation inputs (required)
|
|
490
|
+
:type tax_validation_validation_batch_create_params: TaxValidationValidationBatchCreateParams
|
|
491
|
+
:param _request_timeout: timeout setting for this request. If one
|
|
492
|
+
number provided, it will be total request
|
|
493
|
+
timeout. It can also be a pair (tuple) of
|
|
494
|
+
(connection, read) timeouts.
|
|
495
|
+
:type _request_timeout: int, tuple(int, int), optional
|
|
496
|
+
:param _request_auth: set to override the auth_settings for an a single
|
|
497
|
+
request; this effectively ignores the
|
|
498
|
+
authentication in the spec for a single request.
|
|
499
|
+
:type _request_auth: dict, optional
|
|
500
|
+
:param _content_type: force content-type for the request.
|
|
501
|
+
:type _content_type: str, Optional
|
|
502
|
+
:param _headers: set to override the headers for a single
|
|
503
|
+
request; this effectively ignores the headers
|
|
504
|
+
in the spec for a single request.
|
|
505
|
+
:type _headers: dict, optional
|
|
506
|
+
:param _host_index: set to override the host_index for a single
|
|
507
|
+
request; this effectively ignores the host_index
|
|
508
|
+
in the spec for a single request.
|
|
509
|
+
:type _host_index: int, optional
|
|
510
|
+
:return: Returns the result object.
|
|
511
|
+
""" # noqa: E501
|
|
512
|
+
|
|
513
|
+
_param = self._create_validation_batch_serialize(
|
|
514
|
+
tax_validation_validation_batch_create_params=tax_validation_validation_batch_create_params,
|
|
515
|
+
_request_auth=_request_auth,
|
|
516
|
+
_content_type=_content_type,
|
|
517
|
+
_headers=_headers,
|
|
518
|
+
_host_index=_host_index
|
|
519
|
+
)
|
|
520
|
+
|
|
521
|
+
_response_types_map: Dict[str, Optional[str]] = {
|
|
522
|
+
'202': "List[TaxValidationValidation]",
|
|
523
|
+
'401': None,
|
|
524
|
+
'402': None,
|
|
525
|
+
'403': None,
|
|
526
|
+
'422': None,
|
|
527
|
+
}
|
|
528
|
+
response_data = self.api_client.call_api(
|
|
529
|
+
*_param,
|
|
530
|
+
_request_timeout=_request_timeout
|
|
531
|
+
)
|
|
532
|
+
return response_data.response
|
|
533
|
+
|
|
534
|
+
|
|
535
|
+
def _create_validation_batch_serialize(
|
|
536
|
+
self,
|
|
537
|
+
tax_validation_validation_batch_create_params,
|
|
538
|
+
_request_auth,
|
|
539
|
+
_content_type,
|
|
540
|
+
_headers,
|
|
541
|
+
_host_index,
|
|
542
|
+
) -> RequestSerialized:
|
|
543
|
+
|
|
544
|
+
_host = None
|
|
545
|
+
|
|
546
|
+
_collection_formats: Dict[str, str] = {
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
_path_params: Dict[str, str] = {}
|
|
550
|
+
_query_params: List[Tuple[str, str]] = []
|
|
551
|
+
_header_params: Dict[str, Optional[str]] = _headers or {}
|
|
552
|
+
_form_params: List[Tuple[str, str]] = []
|
|
553
|
+
_files: Dict[
|
|
554
|
+
str, Union[str, bytes, List[str], List[bytes], List[Tuple[str, bytes]]]
|
|
555
|
+
] = {}
|
|
556
|
+
_body_params: Optional[bytes] = None
|
|
557
|
+
|
|
558
|
+
# process the path parameters
|
|
559
|
+
# process the query parameters
|
|
560
|
+
# process the header parameters
|
|
561
|
+
# process the form parameters
|
|
562
|
+
# process the body parameter
|
|
563
|
+
if tax_validation_validation_batch_create_params is not None:
|
|
564
|
+
_body_params = tax_validation_validation_batch_create_params
|
|
565
|
+
|
|
566
|
+
|
|
567
|
+
# set the HTTP header `Accept`
|
|
568
|
+
if 'Accept' not in _header_params:
|
|
569
|
+
_header_params['Accept'] = self.api_client.select_header_accept(
|
|
570
|
+
[
|
|
571
|
+
'application/json'
|
|
572
|
+
]
|
|
573
|
+
)
|
|
574
|
+
|
|
575
|
+
# set the HTTP header `Content-Type`
|
|
576
|
+
if _content_type:
|
|
577
|
+
_header_params['Content-Type'] = _content_type
|
|
578
|
+
else:
|
|
579
|
+
_default_content_type = (
|
|
580
|
+
self.api_client.select_header_content_type(
|
|
581
|
+
[
|
|
582
|
+
'application/json'
|
|
583
|
+
]
|
|
584
|
+
)
|
|
585
|
+
)
|
|
586
|
+
if _default_content_type is not None:
|
|
587
|
+
_header_params['Content-Type'] = _default_content_type
|
|
588
|
+
|
|
589
|
+
# authentication setting
|
|
590
|
+
_auth_settings: List[str] = [
|
|
591
|
+
'bearerApiKey'
|
|
592
|
+
]
|
|
593
|
+
|
|
594
|
+
return self.api_client.param_serialize(
|
|
595
|
+
method='POST',
|
|
596
|
+
resource_path='/taxvalidation/v1/validations/batch',
|
|
597
|
+
path_params=_path_params,
|
|
598
|
+
query_params=_query_params,
|
|
599
|
+
header_params=_header_params,
|
|
600
|
+
body=_body_params,
|
|
601
|
+
post_params=_form_params,
|
|
602
|
+
files=_files,
|
|
603
|
+
auth_settings=_auth_settings,
|
|
604
|
+
collection_formats=_collection_formats,
|
|
605
|
+
_host=_host,
|
|
606
|
+
_request_auth=_request_auth
|
|
607
|
+
)
|
|
608
|
+
|
|
609
|
+
|