Skip to content

Commit 3fb9198

Browse files
authored
Merge pull request #28 from alipay/feature-250410
update 250410
2 parents fe92ddc + 4b75acc commit 3fb9198

13 files changed

+132
-9
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
# Changelog
22

3+
## 1.4.4 - 2024-04-10
4+
* [#28](https://github.com/alipay/global-open-sdk-python/pull/28) feature-250410
5+
- Antom 印度渠道接入AMS拒付相关接口的标准变更
6+
- Antom印度渠道接入(UPI/CARD/NETBAKING)相关接口标准变更
7+
- CKP二期支持商户传入支付方式地区和支付方式要素
8+
9+
310
## 1.4.3 - 2024-02-05
411
* [#27](https://github.com/alipay/global-open-sdk-python/pull/27) feature-250205
512
- 支付、查询、支付结果通知新增卡相关信息字段

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
```
22
Language:Python
33
Python version:2.7+
4-
Releass ^1.4.3
4+
Releass ^1.4.4
55
Copyright:Ant financial services group
66
```
77

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
from enum import Enum, unique
2+
3+
4+
@unique
5+
class DisputeJudgedResult(Enum):
6+
ACCEPT_BY_CUSTOMER = "ACCEPT_BY_CUSTOMER"
7+
ACCEPT_BY_MERCHANT = "ACCEPT_BY_MERCHANT"
8+
VALIDATE_SUCCESS = "VALIDATE_SUCCESS"
9+
VALIDATE_FAIL = "VALIDATE_FAIL"
10+
def to_ams_dict(self):
11+
return self.name
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
from enum import Enum, unique
2+
3+
4+
@unique
5+
class DisputeJudgedResult(Enum):
6+
CHARGEBACK = "CHARGEBACK"
7+
RETRIEVAL_REQUEST = "RETRIEVAL_REQUEST"
8+
COMPLIANCE_REQUEST = "COMPLIANCE_REQUEST"
9+
def to_ams_dict(self):
10+
return self.name

com/alipay/ams/api/model/available_payment_method.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,14 @@ class AvailablePaymentMethod:
55

66
def __init__(self):
77
self.__payment_method_type_list = None #type: list[PaymentMethodTypeItem]
8+
self.__payment_method_meta_data = None #type: map[string,object]
89

910

1011
@property
1112
def payment_method_type_list(self):
1213
return self.__payment_method_type_list
1314

15+
1416
@payment_method_type_list.setter
1517
def payment_method_type_list(self, payment_method_type_list):
1618
if not isinstance(payment_method_type_list, list):
@@ -23,9 +25,18 @@ def payment_method_type_list(self, payment_method_type_list):
2325
self.__payment_method_type_list = payment_method_type_list
2426

2527

28+
@property
29+
def payment_method_meta_data(self):
30+
return self.__payment_method_meta_data
31+
@payment_method_meta_data.setter
32+
def payment_method_meta_data(self, payment_method_meta_data):
33+
self.__payment_method_meta_data = payment_method_meta_data
34+
35+
2636
def to_ams_dict(self):
2737
params = dict()
2838
if self.__payment_method_type_list is not None:
2939
params['paymentMethodTypeList'] = [item.to_ams_dict() for item in self.__payment_method_type_list]
30-
40+
if self.__payment_method_meta_data is not None:
41+
params['paymentMethodMetaData'] = self.__payment_method_meta_data
3142
return params

com/alipay/ams/api/model/dispute_evidence_format_type.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
class DisputeEvidenceFormatType(Enum):
66
PDF = "PDF"
77
WORD = "WORD"
8+
ZIP = "ZIP"
9+
JPG = "JPG"
810

911
def to_ams_dict(self):
1012
return self.name

com/alipay/ams/api/model/payment_method_type.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,8 @@ class PaymentMethodType(Enum):
99
BALANCE_ACCOUNT = "BALANCE_ACCOUNT"
1010
SETTLEMENT_CARD = "SETTLEMENT_CARD"
1111
APPLEPAY = "APPLEPAY"
12+
UPI = "UPI"
13+
ONLINEBANKING_NETBANKING = "ONLINEBANKING_NETBANKING"
14+
1215
def to_ams_dict(self):
1316
return self.name

com/alipay/ams/api/request/notify/alipay_dispute_notify.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,6 @@
22
from com.alipay.ams.api.model.dispute_notification_type import DisputeNotificationType
33
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
44

5-
6-
class DisputeJudgedResult:
7-
pass
8-
9-
105
class AlipayDisputeNotify(AlipayNotify):
116

127
def __init__(self, notify_body):

com/alipay/ams/api/request/pay/alipay_create_session_request.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ def __init__(self):
3535
self.__saved_payment_methods = None # type: list[PaymentMethod]
3636
self.__locale = None
3737
self.__available_payment_method = None # type: list[AvailablePaymentMethod]
38+
self.__allowed_payment_method_regions = None # type: list[str]
3839

3940
@property
4041
def product_code(self):
Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
import json
2+
3+
from com.alipay.ams.api.request.alipay_request import AlipayRequest
4+
5+
6+
class AlipayUploadInvoiceShippingFileRequest(AlipayRequest):
7+
8+
def __init__(self):
9+
super(AlipayUploadInvoiceShippingFileRequest, self).__init__("/ams/api/v1/payments/uploadInvoiceShippingFile")
10+
self.__payment_request_id = None
11+
self.__file_id = None
12+
self.__upload_file = None
13+
self.__file_type = None
14+
self.__file_name = None
15+
16+
17+
@property
18+
def payment_request_id(self):
19+
return self.__payment_request_id
20+
21+
@payment_request_id.setter
22+
def payment_request_id(self, value):
23+
self.__payment_request_id = value
24+
25+
@property
26+
def file_id(self):
27+
return self.__file_id
28+
29+
@file_id.setter
30+
def file_id(self, value):
31+
self.__file_id = value
32+
33+
@property
34+
def upload_file(self):
35+
return self.__upload_file
36+
37+
@upload_file.setter
38+
def upload_file(self, value):
39+
self.__upload_file = value
40+
41+
@property
42+
def file_type(self):
43+
return self.__file_type
44+
45+
@file_type.setter
46+
def file_type(self, value):
47+
self.__file_type = value
48+
49+
@property
50+
def file_name(self):
51+
return self.__file_name
52+
53+
@file_name.setter
54+
def file_name(self, value):
55+
self.__file_name = value
56+
57+
def to_ams_json(self):
58+
json_str = json.dumps(obj=self.__to_ams_dict(), default=lambda o: o.to_ams_dict(), indent=3)
59+
return json_str
60+
61+
def __to_ams_dict(self):
62+
params = dict()
63+
if hasattr(self, "payment_request_id") and self.payment_request_id:
64+
params['paymentRequestId'] = self.payment_request_id
65+
if hasattr(self, "file_id") and self.file_id:
66+
params['fileId'] = self.file_id
67+
if hasattr(self, "upload_file") and self.upload_file:
68+
params['uploadFile'] = self.upload_file
69+
if hasattr(self, "file_type") and self.file_type:
70+
params['fileType'] = self.file_type
71+
if hasattr(self, "file_name") and self.file_name:
72+
params['fileName'] = self.file_name
73+
return params

0 commit comments

Comments
 (0)