pluggy-sdk 1.0.0.post14__py3-none-any.whl → 1.0.0.post16__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 (39) hide show
  1. pluggy_sdk/__init__.py +4 -1
  2. pluggy_sdk/api/__init__.py +3 -0
  3. pluggy_sdk/api/account_api.py +12 -10
  4. pluggy_sdk/api/acquirer_anticipation_api.py +12 -10
  5. pluggy_sdk/api/acquirer_receivable_api.py +12 -10
  6. pluggy_sdk/api/acquirer_sale_api.py +12 -10
  7. pluggy_sdk/api/auth_api.py +12 -10
  8. pluggy_sdk/api/benefit_api.py +12 -10
  9. pluggy_sdk/api/bill_api.py +12 -10
  10. pluggy_sdk/api/bulk_payment_api.py +18 -15
  11. pluggy_sdk/api/category_api.py +24 -20
  12. pluggy_sdk/api/connector_api.py +18 -15
  13. pluggy_sdk/api/consent_api.py +12 -10
  14. pluggy_sdk/api/identity_api.py +12 -10
  15. pluggy_sdk/api/income_report_api.py +6 -5
  16. pluggy_sdk/api/investment_api.py +18 -15
  17. pluggy_sdk/api/items_api.py +30 -25
  18. pluggy_sdk/api/loan_api.py +12 -10
  19. pluggy_sdk/api/payment_customer_api.py +30 -25
  20. pluggy_sdk/api/payment_intent_api.py +18 -15
  21. pluggy_sdk/api/payment_receipts_api.py +842 -0
  22. pluggy_sdk/api/payment_recipient_api.py +42 -35
  23. pluggy_sdk/api/payment_request_api.py +134 -1187
  24. pluggy_sdk/api/payment_schedule_api.py +817 -0
  25. pluggy_sdk/api/portfolio_yield_api.py +12 -10
  26. pluggy_sdk/api/smart_account_api.py +24 -590
  27. pluggy_sdk/api/smart_account_transfer_api.py +610 -0
  28. pluggy_sdk/api/transaction_api.py +18 -15
  29. pluggy_sdk/api/webhook_api.py +30 -25
  30. pluggy_sdk/api_client.py +2 -2
  31. pluggy_sdk/configuration.py +17 -3
  32. pluggy_sdk/models/benefit_loan.py +6 -6
  33. pluggy_sdk/models/benefit_loan_client.py +3 -3
  34. pluggy_sdk/models/connector.py +6 -2
  35. pluggy_sdk/models/item.py +3 -1
  36. {pluggy_sdk-1.0.0.post14.dist-info → pluggy_sdk-1.0.0.post16.dist-info}/METADATA +11 -9
  37. {pluggy_sdk-1.0.0.post14.dist-info → pluggy_sdk-1.0.0.post16.dist-info}/RECORD +39 -36
  38. {pluggy_sdk-1.0.0.post14.dist-info → pluggy_sdk-1.0.0.post16.dist-info}/WHEEL +1 -1
  39. {pluggy_sdk-1.0.0.post14.dist-info → pluggy_sdk-1.0.0.post16.dist-info}/top_level.txt +0 -0
@@ -277,11 +277,12 @@ class PortfolioYieldApi:
277
277
 
278
278
 
279
279
  # set the HTTP header `Accept`
280
- _header_params['Accept'] = self.api_client.select_header_accept(
281
- [
282
- 'application/json'
283
- ]
284
- )
280
+ if 'Accept' not in _header_params:
281
+ _header_params['Accept'] = self.api_client.select_header_accept(
282
+ [
283
+ 'application/json'
284
+ ]
285
+ )
285
286
 
286
287
 
287
288
  # authentication setting
@@ -544,11 +545,12 @@ class PortfolioYieldApi:
544
545
 
545
546
 
546
547
  # set the HTTP header `Accept`
547
- _header_params['Accept'] = self.api_client.select_header_accept(
548
- [
549
- 'application/json'
550
- ]
551
- )
548
+ if 'Accept' not in _header_params:
549
+ _header_params['Accept'] = self.api_client.select_header_accept(
550
+ [
551
+ 'application/json'
552
+ ]
553
+ )
552
554
 
553
555
 
554
556
  # authentication setting
@@ -21,10 +21,8 @@ from pydantic import Field, StrictFloat, StrictInt, StrictStr
21
21
  from typing import Optional, Union
22
22
  from typing_extensions import Annotated
23
23
  from pluggy_sdk.models.create_smart_account_request import CreateSmartAccountRequest
24
- from pluggy_sdk.models.create_smart_account_transfer_request import CreateSmartAccountTransferRequest
25
24
  from pluggy_sdk.models.smart_account import SmartAccount
26
25
  from pluggy_sdk.models.smart_account_balance import SmartAccountBalance
27
- from pluggy_sdk.models.smart_account_transfer import SmartAccountTransfer
28
26
  from pluggy_sdk.models.smart_accounts_list200_response import SmartAccountsList200Response
29
27
 
30
28
  from pluggy_sdk.api_client import ApiClient, RequestSerialized
@@ -276,11 +274,12 @@ class SmartAccountApi:
276
274
 
277
275
 
278
276
  # set the HTTP header `Accept`
279
- _header_params['Accept'] = self.api_client.select_header_accept(
280
- [
281
- 'application/json'
282
- ]
283
- )
277
+ if 'Accept' not in _header_params:
278
+ _header_params['Accept'] = self.api_client.select_header_accept(
279
+ [
280
+ 'application/json'
281
+ ]
282
+ )
284
283
 
285
284
 
286
285
  # authentication setting
@@ -537,11 +536,12 @@ class SmartAccountApi:
537
536
 
538
537
 
539
538
  # set the HTTP header `Accept`
540
- _header_params['Accept'] = self.api_client.select_header_accept(
541
- [
542
- 'application/json'
543
- ]
544
- )
539
+ if 'Accept' not in _header_params:
540
+ _header_params['Accept'] = self.api_client.select_header_accept(
541
+ [
542
+ 'application/json'
543
+ ]
544
+ )
545
545
 
546
546
  # set the HTTP header `Content-Type`
547
547
  if _content_type:
@@ -811,11 +811,12 @@ class SmartAccountApi:
811
811
 
812
812
 
813
813
  # set the HTTP header `Accept`
814
- _header_params['Accept'] = self.api_client.select_header_accept(
815
- [
816
- 'application/json'
817
- ]
818
- )
814
+ if 'Accept' not in _header_params:
815
+ _header_params['Accept'] = self.api_client.select_header_accept(
816
+ [
817
+ 'application/json'
818
+ ]
819
+ )
819
820
 
820
821
 
821
822
  # authentication setting
@@ -841,574 +842,6 @@ class SmartAccountApi:
841
842
 
842
843
 
843
844
 
844
- @validate_call
845
- def smart_account_transfer(
846
- self,
847
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
848
- transfer_id: Annotated[StrictStr, Field(description="Transfer primary identifier")],
849
- _request_timeout: Union[
850
- None,
851
- Annotated[StrictFloat, Field(gt=0)],
852
- Tuple[
853
- Annotated[StrictFloat, Field(gt=0)],
854
- Annotated[StrictFloat, Field(gt=0)]
855
- ]
856
- ] = None,
857
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
858
- _content_type: Optional[StrictStr] = None,
859
- _headers: Optional[Dict[StrictStr, Any]] = None,
860
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
861
- ) -> SmartAccountTransfer:
862
- """Retrieve Transfer
863
-
864
- Get a transfer from the smart account
865
-
866
- :param id: Smart account primary identifier (required)
867
- :type id: str
868
- :param transfer_id: Transfer primary identifier (required)
869
- :type transfer_id: str
870
- :param _request_timeout: timeout setting for this request. If one
871
- number provided, it will be total request
872
- timeout. It can also be a pair (tuple) of
873
- (connection, read) timeouts.
874
- :type _request_timeout: int, tuple(int, int), optional
875
- :param _request_auth: set to override the auth_settings for an a single
876
- request; this effectively ignores the
877
- authentication in the spec for a single request.
878
- :type _request_auth: dict, optional
879
- :param _content_type: force content-type for the request.
880
- :type _content_type: str, Optional
881
- :param _headers: set to override the headers for a single
882
- request; this effectively ignores the headers
883
- in the spec for a single request.
884
- :type _headers: dict, optional
885
- :param _host_index: set to override the host_index for a single
886
- request; this effectively ignores the host_index
887
- in the spec for a single request.
888
- :type _host_index: int, optional
889
- :return: Returns the result object.
890
- """ # noqa: E501
891
-
892
- _param = self._smart_account_transfer_serialize(
893
- id=id,
894
- transfer_id=transfer_id,
895
- _request_auth=_request_auth,
896
- _content_type=_content_type,
897
- _headers=_headers,
898
- _host_index=_host_index
899
- )
900
-
901
- _response_types_map: Dict[str, Optional[str]] = {
902
- '200': "SmartAccountTransfer",
903
- '404': "GlobalErrorResponse",
904
- '400': "GlobalErrorResponse",
905
- }
906
- response_data = self.api_client.call_api(
907
- *_param,
908
- _request_timeout=_request_timeout
909
- )
910
- response_data.read()
911
- return self.api_client.response_deserialize(
912
- response_data=response_data,
913
- response_types_map=_response_types_map,
914
- ).data
915
-
916
-
917
- @validate_call
918
- def smart_account_transfer_with_http_info(
919
- self,
920
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
921
- transfer_id: Annotated[StrictStr, Field(description="Transfer primary identifier")],
922
- _request_timeout: Union[
923
- None,
924
- Annotated[StrictFloat, Field(gt=0)],
925
- Tuple[
926
- Annotated[StrictFloat, Field(gt=0)],
927
- Annotated[StrictFloat, Field(gt=0)]
928
- ]
929
- ] = None,
930
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
931
- _content_type: Optional[StrictStr] = None,
932
- _headers: Optional[Dict[StrictStr, Any]] = None,
933
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
934
- ) -> ApiResponse[SmartAccountTransfer]:
935
- """Retrieve Transfer
936
-
937
- Get a transfer from the smart account
938
-
939
- :param id: Smart account primary identifier (required)
940
- :type id: str
941
- :param transfer_id: Transfer primary identifier (required)
942
- :type transfer_id: str
943
- :param _request_timeout: timeout setting for this request. If one
944
- number provided, it will be total request
945
- timeout. It can also be a pair (tuple) of
946
- (connection, read) timeouts.
947
- :type _request_timeout: int, tuple(int, int), optional
948
- :param _request_auth: set to override the auth_settings for an a single
949
- request; this effectively ignores the
950
- authentication in the spec for a single request.
951
- :type _request_auth: dict, optional
952
- :param _content_type: force content-type for the request.
953
- :type _content_type: str, Optional
954
- :param _headers: set to override the headers for a single
955
- request; this effectively ignores the headers
956
- in the spec for a single request.
957
- :type _headers: dict, optional
958
- :param _host_index: set to override the host_index for a single
959
- request; this effectively ignores the host_index
960
- in the spec for a single request.
961
- :type _host_index: int, optional
962
- :return: Returns the result object.
963
- """ # noqa: E501
964
-
965
- _param = self._smart_account_transfer_serialize(
966
- id=id,
967
- transfer_id=transfer_id,
968
- _request_auth=_request_auth,
969
- _content_type=_content_type,
970
- _headers=_headers,
971
- _host_index=_host_index
972
- )
973
-
974
- _response_types_map: Dict[str, Optional[str]] = {
975
- '200': "SmartAccountTransfer",
976
- '404': "GlobalErrorResponse",
977
- '400': "GlobalErrorResponse",
978
- }
979
- response_data = self.api_client.call_api(
980
- *_param,
981
- _request_timeout=_request_timeout
982
- )
983
- response_data.read()
984
- return self.api_client.response_deserialize(
985
- response_data=response_data,
986
- response_types_map=_response_types_map,
987
- )
988
-
989
-
990
- @validate_call
991
- def smart_account_transfer_without_preload_content(
992
- self,
993
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
994
- transfer_id: Annotated[StrictStr, Field(description="Transfer primary identifier")],
995
- _request_timeout: Union[
996
- None,
997
- Annotated[StrictFloat, Field(gt=0)],
998
- Tuple[
999
- Annotated[StrictFloat, Field(gt=0)],
1000
- Annotated[StrictFloat, Field(gt=0)]
1001
- ]
1002
- ] = None,
1003
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
1004
- _content_type: Optional[StrictStr] = None,
1005
- _headers: Optional[Dict[StrictStr, Any]] = None,
1006
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1007
- ) -> RESTResponseType:
1008
- """Retrieve Transfer
1009
-
1010
- Get a transfer from the smart account
1011
-
1012
- :param id: Smart account primary identifier (required)
1013
- :type id: str
1014
- :param transfer_id: Transfer primary identifier (required)
1015
- :type transfer_id: str
1016
- :param _request_timeout: timeout setting for this request. If one
1017
- number provided, it will be total request
1018
- timeout. It can also be a pair (tuple) of
1019
- (connection, read) timeouts.
1020
- :type _request_timeout: int, tuple(int, int), optional
1021
- :param _request_auth: set to override the auth_settings for an a single
1022
- request; this effectively ignores the
1023
- authentication in the spec for a single request.
1024
- :type _request_auth: dict, optional
1025
- :param _content_type: force content-type for the request.
1026
- :type _content_type: str, Optional
1027
- :param _headers: set to override the headers for a single
1028
- request; this effectively ignores the headers
1029
- in the spec for a single request.
1030
- :type _headers: dict, optional
1031
- :param _host_index: set to override the host_index for a single
1032
- request; this effectively ignores the host_index
1033
- in the spec for a single request.
1034
- :type _host_index: int, optional
1035
- :return: Returns the result object.
1036
- """ # noqa: E501
1037
-
1038
- _param = self._smart_account_transfer_serialize(
1039
- id=id,
1040
- transfer_id=transfer_id,
1041
- _request_auth=_request_auth,
1042
- _content_type=_content_type,
1043
- _headers=_headers,
1044
- _host_index=_host_index
1045
- )
1046
-
1047
- _response_types_map: Dict[str, Optional[str]] = {
1048
- '200': "SmartAccountTransfer",
1049
- '404': "GlobalErrorResponse",
1050
- '400': "GlobalErrorResponse",
1051
- }
1052
- response_data = self.api_client.call_api(
1053
- *_param,
1054
- _request_timeout=_request_timeout
1055
- )
1056
- return response_data.response
1057
-
1058
-
1059
- def _smart_account_transfer_serialize(
1060
- self,
1061
- id,
1062
- transfer_id,
1063
- _request_auth,
1064
- _content_type,
1065
- _headers,
1066
- _host_index,
1067
- ) -> RequestSerialized:
1068
-
1069
- _host = None
1070
-
1071
- _collection_formats: Dict[str, str] = {
1072
- }
1073
-
1074
- _path_params: Dict[str, str] = {}
1075
- _query_params: List[Tuple[str, str]] = []
1076
- _header_params: Dict[str, Optional[str]] = _headers or {}
1077
- _form_params: List[Tuple[str, str]] = []
1078
- _files: Dict[str, Union[str, bytes]] = {}
1079
- _body_params: Optional[bytes] = None
1080
-
1081
- # process the path parameters
1082
- if id is not None:
1083
- _path_params['id'] = id
1084
- if transfer_id is not None:
1085
- _path_params['transfer_id'] = transfer_id
1086
- # process the query parameters
1087
- # process the header parameters
1088
- # process the form parameters
1089
- # process the body parameter
1090
-
1091
-
1092
- # set the HTTP header `Accept`
1093
- _header_params['Accept'] = self.api_client.select_header_accept(
1094
- [
1095
- 'application/json'
1096
- ]
1097
- )
1098
-
1099
-
1100
- # authentication setting
1101
- _auth_settings: List[str] = [
1102
- 'default'
1103
- ]
1104
-
1105
- return self.api_client.param_serialize(
1106
- method='GET',
1107
- resource_path='/payments/smart-accounts/{id}/transfers/{transfer_id}',
1108
- path_params=_path_params,
1109
- query_params=_query_params,
1110
- header_params=_header_params,
1111
- body=_body_params,
1112
- post_params=_form_params,
1113
- files=_files,
1114
- auth_settings=_auth_settings,
1115
- collection_formats=_collection_formats,
1116
- _host=_host,
1117
- _request_auth=_request_auth
1118
- )
1119
-
1120
-
1121
-
1122
-
1123
- @validate_call
1124
- def smart_account_transfer_create(
1125
- self,
1126
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
1127
- create_smart_account_transfer_request: CreateSmartAccountTransferRequest,
1128
- _request_timeout: Union[
1129
- None,
1130
- Annotated[StrictFloat, Field(gt=0)],
1131
- Tuple[
1132
- Annotated[StrictFloat, Field(gt=0)],
1133
- Annotated[StrictFloat, Field(gt=0)]
1134
- ]
1135
- ] = None,
1136
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
1137
- _content_type: Optional[StrictStr] = None,
1138
- _headers: Optional[Dict[StrictStr, Any]] = None,
1139
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1140
- ) -> SmartAccountTransfer:
1141
- """Create Transfer
1142
-
1143
- Creates the smart account transfer resource
1144
-
1145
- :param id: Smart account primary identifier (required)
1146
- :type id: str
1147
- :param create_smart_account_transfer_request: (required)
1148
- :type create_smart_account_transfer_request: CreateSmartAccountTransferRequest
1149
- :param _request_timeout: timeout setting for this request. If one
1150
- number provided, it will be total request
1151
- timeout. It can also be a pair (tuple) of
1152
- (connection, read) timeouts.
1153
- :type _request_timeout: int, tuple(int, int), optional
1154
- :param _request_auth: set to override the auth_settings for an a single
1155
- request; this effectively ignores the
1156
- authentication in the spec for a single request.
1157
- :type _request_auth: dict, optional
1158
- :param _content_type: force content-type for the request.
1159
- :type _content_type: str, Optional
1160
- :param _headers: set to override the headers for a single
1161
- request; this effectively ignores the headers
1162
- in the spec for a single request.
1163
- :type _headers: dict, optional
1164
- :param _host_index: set to override the host_index for a single
1165
- request; this effectively ignores the host_index
1166
- in the spec for a single request.
1167
- :type _host_index: int, optional
1168
- :return: Returns the result object.
1169
- """ # noqa: E501
1170
-
1171
- _param = self._smart_account_transfer_create_serialize(
1172
- id=id,
1173
- create_smart_account_transfer_request=create_smart_account_transfer_request,
1174
- _request_auth=_request_auth,
1175
- _content_type=_content_type,
1176
- _headers=_headers,
1177
- _host_index=_host_index
1178
- )
1179
-
1180
- _response_types_map: Dict[str, Optional[str]] = {
1181
- '200': "SmartAccountTransfer",
1182
- '400': "GlobalErrorResponse",
1183
- }
1184
- response_data = self.api_client.call_api(
1185
- *_param,
1186
- _request_timeout=_request_timeout
1187
- )
1188
- response_data.read()
1189
- return self.api_client.response_deserialize(
1190
- response_data=response_data,
1191
- response_types_map=_response_types_map,
1192
- ).data
1193
-
1194
-
1195
- @validate_call
1196
- def smart_account_transfer_create_with_http_info(
1197
- self,
1198
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
1199
- create_smart_account_transfer_request: CreateSmartAccountTransferRequest,
1200
- _request_timeout: Union[
1201
- None,
1202
- Annotated[StrictFloat, Field(gt=0)],
1203
- Tuple[
1204
- Annotated[StrictFloat, Field(gt=0)],
1205
- Annotated[StrictFloat, Field(gt=0)]
1206
- ]
1207
- ] = None,
1208
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
1209
- _content_type: Optional[StrictStr] = None,
1210
- _headers: Optional[Dict[StrictStr, Any]] = None,
1211
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1212
- ) -> ApiResponse[SmartAccountTransfer]:
1213
- """Create Transfer
1214
-
1215
- Creates the smart account transfer resource
1216
-
1217
- :param id: Smart account primary identifier (required)
1218
- :type id: str
1219
- :param create_smart_account_transfer_request: (required)
1220
- :type create_smart_account_transfer_request: CreateSmartAccountTransferRequest
1221
- :param _request_timeout: timeout setting for this request. If one
1222
- number provided, it will be total request
1223
- timeout. It can also be a pair (tuple) of
1224
- (connection, read) timeouts.
1225
- :type _request_timeout: int, tuple(int, int), optional
1226
- :param _request_auth: set to override the auth_settings for an a single
1227
- request; this effectively ignores the
1228
- authentication in the spec for a single request.
1229
- :type _request_auth: dict, optional
1230
- :param _content_type: force content-type for the request.
1231
- :type _content_type: str, Optional
1232
- :param _headers: set to override the headers for a single
1233
- request; this effectively ignores the headers
1234
- in the spec for a single request.
1235
- :type _headers: dict, optional
1236
- :param _host_index: set to override the host_index for a single
1237
- request; this effectively ignores the host_index
1238
- in the spec for a single request.
1239
- :type _host_index: int, optional
1240
- :return: Returns the result object.
1241
- """ # noqa: E501
1242
-
1243
- _param = self._smart_account_transfer_create_serialize(
1244
- id=id,
1245
- create_smart_account_transfer_request=create_smart_account_transfer_request,
1246
- _request_auth=_request_auth,
1247
- _content_type=_content_type,
1248
- _headers=_headers,
1249
- _host_index=_host_index
1250
- )
1251
-
1252
- _response_types_map: Dict[str, Optional[str]] = {
1253
- '200': "SmartAccountTransfer",
1254
- '400': "GlobalErrorResponse",
1255
- }
1256
- response_data = self.api_client.call_api(
1257
- *_param,
1258
- _request_timeout=_request_timeout
1259
- )
1260
- response_data.read()
1261
- return self.api_client.response_deserialize(
1262
- response_data=response_data,
1263
- response_types_map=_response_types_map,
1264
- )
1265
-
1266
-
1267
- @validate_call
1268
- def smart_account_transfer_create_without_preload_content(
1269
- self,
1270
- id: Annotated[StrictStr, Field(description="Smart account primary identifier")],
1271
- create_smart_account_transfer_request: CreateSmartAccountTransferRequest,
1272
- _request_timeout: Union[
1273
- None,
1274
- Annotated[StrictFloat, Field(gt=0)],
1275
- Tuple[
1276
- Annotated[StrictFloat, Field(gt=0)],
1277
- Annotated[StrictFloat, Field(gt=0)]
1278
- ]
1279
- ] = None,
1280
- _request_auth: Optional[Dict[StrictStr, Any]] = None,
1281
- _content_type: Optional[StrictStr] = None,
1282
- _headers: Optional[Dict[StrictStr, Any]] = None,
1283
- _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0,
1284
- ) -> RESTResponseType:
1285
- """Create Transfer
1286
-
1287
- Creates the smart account transfer resource
1288
-
1289
- :param id: Smart account primary identifier (required)
1290
- :type id: str
1291
- :param create_smart_account_transfer_request: (required)
1292
- :type create_smart_account_transfer_request: CreateSmartAccountTransferRequest
1293
- :param _request_timeout: timeout setting for this request. If one
1294
- number provided, it will be total request
1295
- timeout. It can also be a pair (tuple) of
1296
- (connection, read) timeouts.
1297
- :type _request_timeout: int, tuple(int, int), optional
1298
- :param _request_auth: set to override the auth_settings for an a single
1299
- request; this effectively ignores the
1300
- authentication in the spec for a single request.
1301
- :type _request_auth: dict, optional
1302
- :param _content_type: force content-type for the request.
1303
- :type _content_type: str, Optional
1304
- :param _headers: set to override the headers for a single
1305
- request; this effectively ignores the headers
1306
- in the spec for a single request.
1307
- :type _headers: dict, optional
1308
- :param _host_index: set to override the host_index for a single
1309
- request; this effectively ignores the host_index
1310
- in the spec for a single request.
1311
- :type _host_index: int, optional
1312
- :return: Returns the result object.
1313
- """ # noqa: E501
1314
-
1315
- _param = self._smart_account_transfer_create_serialize(
1316
- id=id,
1317
- create_smart_account_transfer_request=create_smart_account_transfer_request,
1318
- _request_auth=_request_auth,
1319
- _content_type=_content_type,
1320
- _headers=_headers,
1321
- _host_index=_host_index
1322
- )
1323
-
1324
- _response_types_map: Dict[str, Optional[str]] = {
1325
- '200': "SmartAccountTransfer",
1326
- '400': "GlobalErrorResponse",
1327
- }
1328
- response_data = self.api_client.call_api(
1329
- *_param,
1330
- _request_timeout=_request_timeout
1331
- )
1332
- return response_data.response
1333
-
1334
-
1335
- def _smart_account_transfer_create_serialize(
1336
- self,
1337
- id,
1338
- create_smart_account_transfer_request,
1339
- _request_auth,
1340
- _content_type,
1341
- _headers,
1342
- _host_index,
1343
- ) -> RequestSerialized:
1344
-
1345
- _host = None
1346
-
1347
- _collection_formats: Dict[str, str] = {
1348
- }
1349
-
1350
- _path_params: Dict[str, str] = {}
1351
- _query_params: List[Tuple[str, str]] = []
1352
- _header_params: Dict[str, Optional[str]] = _headers or {}
1353
- _form_params: List[Tuple[str, str]] = []
1354
- _files: Dict[str, Union[str, bytes]] = {}
1355
- _body_params: Optional[bytes] = None
1356
-
1357
- # process the path parameters
1358
- if id is not None:
1359
- _path_params['id'] = id
1360
- # process the query parameters
1361
- # process the header parameters
1362
- # process the form parameters
1363
- # process the body parameter
1364
- if create_smart_account_transfer_request is not None:
1365
- _body_params = create_smart_account_transfer_request
1366
-
1367
-
1368
- # set the HTTP header `Accept`
1369
- _header_params['Accept'] = self.api_client.select_header_accept(
1370
- [
1371
- 'application/json'
1372
- ]
1373
- )
1374
-
1375
- # set the HTTP header `Content-Type`
1376
- if _content_type:
1377
- _header_params['Content-Type'] = _content_type
1378
- else:
1379
- _default_content_type = (
1380
- self.api_client.select_header_content_type(
1381
- [
1382
- 'application/json'
1383
- ]
1384
- )
1385
- )
1386
- if _default_content_type is not None:
1387
- _header_params['Content-Type'] = _default_content_type
1388
-
1389
- # authentication setting
1390
- _auth_settings: List[str] = [
1391
- 'default'
1392
- ]
1393
-
1394
- return self.api_client.param_serialize(
1395
- method='POST',
1396
- resource_path='/payments/smart-accounts/{id}/transfers',
1397
- path_params=_path_params,
1398
- query_params=_query_params,
1399
- header_params=_header_params,
1400
- body=_body_params,
1401
- post_params=_form_params,
1402
- files=_files,
1403
- auth_settings=_auth_settings,
1404
- collection_formats=_collection_formats,
1405
- _host=_host,
1406
- _request_auth=_request_auth
1407
- )
1408
-
1409
-
1410
-
1411
-
1412
845
  @validate_call
1413
846
  def smart_accounts_list(
1414
847
  self,
@@ -1656,11 +1089,12 @@ class SmartAccountApi:
1656
1089
 
1657
1090
 
1658
1091
  # set the HTTP header `Accept`
1659
- _header_params['Accept'] = self.api_client.select_header_accept(
1660
- [
1661
- 'application/json'
1662
- ]
1663
- )
1092
+ if 'Accept' not in _header_params:
1093
+ _header_params['Accept'] = self.api_client.select_header_accept(
1094
+ [
1095
+ 'application/json'
1096
+ ]
1097
+ )
1664
1098
 
1665
1099
 
1666
1100
  # authentication setting