global-open-sdk-python 1.4.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- com/__init__.py +1 -0
- com/alipay/__init__.py +0 -0
- com/alipay/ams/__init__.py +0 -0
- com/alipay/ams/api/__init__.py +0 -0
- com/alipay/ams/api/default_alipay_client.py +114 -0
- com/alipay/ams/api/exception/__init__.py +0 -0
- com/alipay/ams/api/exception/exception.py +6 -0
- com/alipay/ams/api/model/__init__.py +0 -0
- com/alipay/ams/api/model/account_balance.py +49 -0
- com/alipay/ams/api/model/account_holder_type.py +10 -0
- com/alipay/ams/api/model/account_type.py +11 -0
- com/alipay/ams/api/model/acquirer_info.py +86 -0
- com/alipay/ams/api/model/address.py +121 -0
- com/alipay/ams/api/model/agreement_info.py +35 -0
- com/alipay/ams/api/model/amount.py +39 -0
- com/alipay/ams/api/model/amount_limit.py +44 -0
- com/alipay/ams/api/model/amount_limit_info.py +44 -0
- com/alipay/ams/api/model/antom_path_constants.py +56 -0
- com/alipay/ams/api/model/apple_pay_configuration.py +56 -0
- com/alipay/ams/api/model/association_type.py +15 -0
- com/alipay/ams/api/model/attachment.py +54 -0
- com/alipay/ams/api/model/attachment_type.py +26 -0
- com/alipay/ams/api/model/auth_code_form.py +20 -0
- com/alipay/ams/api/model/auth_meta_data.py +32 -0
- com/alipay/ams/api/model/authentication_channel_type.py +12 -0
- com/alipay/ams/api/model/authentication_type.py +11 -0
- com/alipay/ams/api/model/authorization_error.py +27 -0
- com/alipay/ams/api/model/authorization_phase.py +10 -0
- com/alipay/ams/api/model/available_payment_method.py +31 -0
- com/alipay/ams/api/model/browser_info.py +65 -0
- com/alipay/ams/api/model/business_info.py +89 -0
- com/alipay/ams/api/model/business_type.py +13 -0
- com/alipay/ams/api/model/buyer.py +59 -0
- com/alipay/ams/api/model/cancellation_type.py +9 -0
- com/alipay/ams/api/model/capture_mode.py +10 -0
- com/alipay/ams/api/model/card_brand.py +54 -0
- com/alipay/ams/api/model/card_brand_type.py +13 -0
- com/alipay/ams/api/model/card_payment_method_detail.py +457 -0
- com/alipay/ams/api/model/card_verification_result.py +76 -0
- com/alipay/ams/api/model/certificate.py +65 -0
- com/alipay/ams/api/model/certificate_type.py +15 -0
- com/alipay/ams/api/model/challenge_action_form.py +63 -0
- com/alipay/ams/api/model/challenge_trigger_source_type.py +13 -0
- com/alipay/ams/api/model/challenge_type.py +14 -0
- com/alipay/ams/api/model/china_extra_trans_info.py +130 -0
- com/alipay/ams/api/model/class_type.py +11 -0
- com/alipay/ams/api/model/clearing_channel.py +7 -0
- com/alipay/ams/api/model/code_detail.py +53 -0
- com/alipay/ams/api/model/code_value_type.py +24 -0
- com/alipay/ams/api/model/company.py +141 -0
- com/alipay/ams/api/model/companyType.py +20 -0
- com/alipay/ams/api/model/company_unit_type.py +10 -0
- com/alipay/ams/api/model/contact.py +27 -0
- com/alipay/ams/api/model/contact_info.py +30 -0
- com/alipay/ams/api/model/coupon_payment_method_detail.py +107 -0
- com/alipay/ams/api/model/credit_pay_fee_type.py +9 -0
- com/alipay/ams/api/model/credit_pay_plan.py +41 -0
- com/alipay/ams/api/model/customer_belongs_to.py +47 -0
- com/alipay/ams/api/model/customer_id_type.py +14 -0
- com/alipay/ams/api/model/customs_info.py +28 -0
- com/alipay/ams/api/model/declaration_record.py +178 -0
- com/alipay/ams/api/model/delivery_method_type.py +10 -0
- com/alipay/ams/api/model/disable_reason_type.py +17 -0
- com/alipay/ams/api/model/discount.py +76 -0
- com/alipay/ams/api/model/discount_payment_method_detail.py +94 -0
- com/alipay/ams/api/model/display_type.py +33 -0
- com/alipay/ams/api/model/dispute_accept_reason_type.py +11 -0
- com/alipay/ams/api/model/dispute_evidence_format_type.py +10 -0
- com/alipay/ams/api/model/dispute_evidence_type.py +10 -0
- com/alipay/ams/api/model/dispute_judged_result.py +10 -0
- com/alipay/ams/api/model/dispute_notification_type.py +15 -0
- com/alipay/ams/api/model/entity_associations.py +67 -0
- com/alipay/ams/api/model/env.py +229 -0
- com/alipay/ams/api/model/extend_info.py +21 -0
- com/alipay/ams/api/model/external_payment_method_detail.py +76 -0
- com/alipay/ams/api/model/funding_type.py +16 -0
- com/alipay/ams/api/model/gaming.py +55 -0
- com/alipay/ams/api/model/goods.py +108 -0
- com/alipay/ams/api/model/grant_type.py +12 -0
- com/alipay/ams/api/model/http_method.py +9 -0
- com/alipay/ams/api/model/identity_check_result.py +9 -0
- com/alipay/ams/api/model/in_store_payment_scenario.py +14 -0
- com/alipay/ams/api/model/individual.py +97 -0
- com/alipay/ams/api/model/installment.py +41 -0
- com/alipay/ams/api/model/interest_free.py +85 -0
- com/alipay/ams/api/model/leg.py +116 -0
- com/alipay/ams/api/model/legal_entity_type.py +10 -0
- com/alipay/ams/api/model/lodging.py +95 -0
- com/alipay/ams/api/model/logo.py +31 -0
- com/alipay/ams/api/model/merchant.py +107 -0
- com/alipay/ams/api/model/merchant_customs_info.py +28 -0
- com/alipay/ams/api/model/merchant_info.py +79 -0
- com/alipay/ams/api/model/merchant_registration_info.py +96 -0
- com/alipay/ams/api/model/merchant_type.py +10 -0
- com/alipay/ams/api/model/method_type.py +13 -0
- com/alipay/ams/api/model/order.py +186 -0
- com/alipay/ams/api/model/order_code_form.py +66 -0
- com/alipay/ams/api/model/order_info.py +22 -0
- com/alipay/ams/api/model/os_type.py +12 -0
- com/alipay/ams/api/model/passengers.py +39 -0
- com/alipay/ams/api/model/paymentOptionDetail.py +43 -0
- com/alipay/ams/api/model/payment_detail.py +32 -0
- com/alipay/ams/api/model/payment_factor.py +73 -0
- com/alipay/ams/api/model/payment_method.py +86 -0
- com/alipay/ams/api/model/payment_method_category_type.py +29 -0
- com/alipay/ams/api/model/payment_method_detail.py +129 -0
- com/alipay/ams/api/model/payment_method_detail_type.py +30 -0
- com/alipay/ams/api/model/payment_method_info.py +53 -0
- com/alipay/ams/api/model/payment_method_type.py +13 -0
- com/alipay/ams/api/model/payment_method_type_item.py +40 -0
- com/alipay/ams/api/model/payment_option.py +137 -0
- com/alipay/ams/api/model/payment_result_info.py +159 -0
- com/alipay/ams/api/model/payment_verification_data.py +34 -0
- com/alipay/ams/api/model/period_rule.py +48 -0
- com/alipay/ams/api/model/period_type.py +12 -0
- com/alipay/ams/api/model/plan.py +106 -0
- com/alipay/ams/api/model/presentment_mode.py +11 -0
- com/alipay/ams/api/model/product_code_type.py +13 -0
- com/alipay/ams/api/model/promotion_info.py +66 -0
- com/alipay/ams/api/model/promotion_result.py +49 -0
- com/alipay/ams/api/model/promotion_type.py +10 -0
- com/alipay/ams/api/model/psp_customer_info.py +78 -0
- com/alipay/ams/api/model/quote.py +84 -0
- com/alipay/ams/api/model/redirect_action_form.py +63 -0
- com/alipay/ams/api/model/refund_detail.py +35 -0
- com/alipay/ams/api/model/refund_from_type.py +11 -0
- com/alipay/ams/api/model/refund_record.py +66 -0
- com/alipay/ams/api/model/registration_detail.py +119 -0
- com/alipay/ams/api/model/result.py +39 -0
- com/alipay/ams/api/model/result_status_type.py +27 -0
- com/alipay/ams/api/model/risk_score_detail.py +37 -0
- com/alipay/ams/api/model/risk_score_result.py +57 -0
- com/alipay/ams/api/model/risk_score_type.py +24 -0
- com/alipay/ams/api/model/scope_type.py +17 -0
- com/alipay/ams/api/model/settle_to_type.py +10 -0
- com/alipay/ams/api/model/settlement_bank_account.py +143 -0
- com/alipay/ams/api/model/settlement_detail.py +32 -0
- com/alipay/ams/api/model/settlement_info.py +31 -0
- com/alipay/ams/api/model/settlement_strategy.py +22 -0
- com/alipay/ams/api/model/shipping.py +61 -0
- com/alipay/ams/api/model/stock_info.py +26 -0
- com/alipay/ams/api/model/store.py +107 -0
- com/alipay/ams/api/model/subscription_notification_type.py +14 -0
- com/alipay/ams/api/model/subscription_status.py +12 -0
- com/alipay/ams/api/model/support_bank.py +49 -0
- com/alipay/ams/api/model/support_card_brand.py +39 -0
- com/alipay/ams/api/model/terminal_type.py +13 -0
- com/alipay/ams/api/model/three_ds_result.py +78 -0
- com/alipay/ams/api/model/transaction.py +80 -0
- com/alipay/ams/api/model/transaction_status_type.py +33 -0
- com/alipay/ams/api/model/transaction_type.py +36 -0
- com/alipay/ams/api/model/transfer_from_detail.py +44 -0
- com/alipay/ams/api/model/transfer_to_detail.py +108 -0
- com/alipay/ams/api/model/transit.py +46 -0
- com/alipay/ams/api/model/transit_type.py +12 -0
- com/alipay/ams/api/model/trial.py +47 -0
- com/alipay/ams/api/model/user_identity_type.py +11 -0
- com/alipay/ams/api/model/user_name.py +77 -0
- com/alipay/ams/api/model/wallet_payment_method_type.py +20 -0
- com/alipay/ams/api/model/web_site.py +54 -0
- com/alipay/ams/api/net/__init__.py +0 -0
- com/alipay/ams/api/net/default_http_rpc.py +58 -0
- com/alipay/ams/api/request/__init__.py +0 -0
- com/alipay/ams/api/request/alipay_request.py +41 -0
- com/alipay/ams/api/request/auth/__init__.py +0 -0
- com/alipay/ams/api/request/auth/alipay_auth_apply_token_request.py +88 -0
- com/alipay/ams/api/request/auth/alipay_auth_consult_request.py +160 -0
- com/alipay/ams/api/request/auth/alipay_auth_create_session_request.py +84 -0
- com/alipay/ams/api/request/auth/alipay_auth_query_token_request.py +32 -0
- com/alipay/ams/api/request/auth/alipay_auth_revoke_token_request.py +43 -0
- com/alipay/ams/api/request/declare/__init__.py +0 -0
- com/alipay/ams/api/request/declare/alipay_customs_declare_request.py +109 -0
- com/alipay/ams/api/request/declare/alipay_customs_query_request.py +28 -0
- com/alipay/ams/api/request/dispute/__init__.py +0 -0
- com/alipay/ams/api/request/dispute/alipay_accept_dispute_request.py +29 -0
- com/alipay/ams/api/request/dispute/alipay_download_dispute_evidence_request.py +40 -0
- com/alipay/ams/api/request/dispute/alipay_supply_defense_document_request.py +39 -0
- com/alipay/ams/api/request/marketplace/__init__.py +0 -0
- com/alipay/ams/api/request/marketplace/alipay_create_payout_request.py +53 -0
- com/alipay/ams/api/request/marketplace/alipay_create_transfer_request.py +53 -0
- com/alipay/ams/api/request/marketplace/alipay_inquire_balance_request.py +29 -0
- com/alipay/ams/api/request/marketplace/alipay_register_request.py +65 -0
- com/alipay/ams/api/request/marketplace/alipay_settle_request.py +51 -0
- com/alipay/ams/api/request/marketplace/alipay_settlement_info_update_request.py +62 -0
- com/alipay/ams/api/request/marketplace/alipay_submit_attachment_request.py +51 -0
- com/alipay/ams/api/request/merchant/__init__.py +0 -0
- com/alipay/ams/api/request/merchant/alipay_merchant_registration_info_query_request.py +30 -0
- com/alipay/ams/api/request/merchant/alipay_merchant_registration_request.py +78 -0
- com/alipay/ams/api/request/merchant/alipay_merchant_registration_status_query_request.py +42 -0
- com/alipay/ams/api/request/notify/__init__.py +0 -0
- com/alipay/ams/api/request/notify/alipay_auth_notify.py +67 -0
- com/alipay/ams/api/request/notify/alipay_capture_result_notify.py +64 -0
- com/alipay/ams/api/request/notify/alipay_dispute_notify.py +144 -0
- com/alipay/ams/api/request/notify/alipay_notify.py +28 -0
- com/alipay/ams/api/request/notify/alipay_pay_result_notify.py +111 -0
- com/alipay/ams/api/request/notify/alipay_refund_notify.py +67 -0
- com/alipay/ams/api/request/notify/alipay_subscription_notify.py +94 -0
- com/alipay/ams/api/request/notify/alipay_subscription_pay_notify.py +50 -0
- com/alipay/ams/api/request/notify/alipay_vaulting_notify.py +47 -0
- com/alipay/ams/api/request/pay/__init__.py +0 -0
- com/alipay/ams/api/request/pay/alipay_capture_request.py +70 -0
- com/alipay/ams/api/request/pay/alipay_create_order_request.py +94 -0
- com/alipay/ams/api/request/pay/alipay_create_session_request.py +225 -0
- com/alipay/ams/api/request/pay/alipay_pay_cancel_request.py +57 -0
- com/alipay/ams/api/request/pay/alipay_pay_consult_request.py +244 -0
- com/alipay/ams/api/request/pay/alipay_pay_query_request.py +60 -0
- com/alipay/ams/api/request/pay/alipay_pay_request.py +269 -0
- com/alipay/ams/api/request/pay/alipay_refund_query_request.py +51 -0
- com/alipay/ams/api/request/pay/alipay_refund_request.py +118 -0
- com/alipay/ams/api/request/pay/entry_code_payment_request.py +49 -0
- com/alipay/ams/api/request/pay/order_code_payment_request.py +46 -0
- com/alipay/ams/api/request/pay/user_presented_code_payment_request.py +50 -0
- com/alipay/ams/api/request/risks/__init__.py +0 -0
- com/alipay/ams/api/request/risks/inquiry_risk_score_request.py +68 -0
- com/alipay/ams/api/request/risks/risk_decide_request.py +121 -0
- com/alipay/ams/api/request/risks/risk_report_request.py +65 -0
- com/alipay/ams/api/request/risks/send_payment_result_request.py +73 -0
- com/alipay/ams/api/request/risks/send_refund_result_request.py +61 -0
- com/alipay/ams/api/request/subscription/__init__.py +0 -0
- com/alipay/ams/api/request/subscription/alipay_subscription_cancel_request.py +52 -0
- com/alipay/ams/api/request/subscription/alipay_subscription_change_request.py +140 -0
- com/alipay/ams/api/request/subscription/alipay_subscription_create_request.py +205 -0
- com/alipay/ams/api/request/subscription/alipay_subscription_update_request.py +104 -0
- com/alipay/ams/api/request/users/__init__.py +0 -0
- com/alipay/ams/api/request/users/alipay_init_authentication_request.py +79 -0
- com/alipay/ams/api/request/users/alipay_user_query_info_request.py +32 -0
- com/alipay/ams/api/request/users/alipay_verify_authentication_request.py +56 -0
- com/alipay/ams/api/request/vaulting/__init__.py +0 -0
- com/alipay/ams/api/request/vaulting/alipay_vaulting_payment_method_request.py +84 -0
- com/alipay/ams/api/request/vaulting/alipay_vaulting_query_request.py +29 -0
- com/alipay/ams/api/request/vaulting/alipay_vaulting_session_request.py +84 -0
- com/alipay/ams/api/response/__init__.py +0 -0
- com/alipay/ams/api/response/alipay_response.py +22 -0
- com/alipay/ams/api/response/auth/__init__.py +0 -0
- com/alipay/ams/api/response/auth/alipay_auth_apply_token_response.py +57 -0
- com/alipay/ams/api/response/auth/alipay_auth_consult_response.py +68 -0
- com/alipay/ams/api/response/auth/alipay_auth_create_session_response.py +34 -0
- com/alipay/ams/api/response/auth/alipay_auth_query_token_response.py +49 -0
- com/alipay/ams/api/response/auth/alipay_auth_revoke_token_response.py +21 -0
- com/alipay/ams/api/response/declare/__init__.py +0 -0
- com/alipay/ams/api/response/declare/alipay_customs_declare_response.py +54 -0
- com/alipay/ams/api/response/declare/alipay_customs_query_response.py +32 -0
- com/alipay/ams/api/response/dispute/__init__.py +0 -0
- com/alipay/ams/api/response/dispute/alipay_accept_dispute_response.py +24 -0
- com/alipay/ams/api/response/dispute/alipay_download_dispute_evidence_response.py +26 -0
- com/alipay/ams/api/response/dispute/alipay_supply_defense_document_response.py +24 -0
- com/alipay/ams/api/response/marketplace/__init__.py +0 -0
- com/alipay/ams/api/response/marketplace/alipay_create_payout_response.py +43 -0
- com/alipay/ams/api/response/marketplace/alipay_create_transfer_response.py +43 -0
- com/alipay/ams/api/response/marketplace/alipay_inquire_balance_response.py +26 -0
- com/alipay/ams/api/response/marketplace/alipay_register_response.py +18 -0
- com/alipay/ams/api/response/marketplace/alipay_settle_response.py +25 -0
- com/alipay/ams/api/response/marketplace/alipay_settlement_info_update_response.py +17 -0
- com/alipay/ams/api/response/marketplace/alipay_submit_attachment_response.py +26 -0
- com/alipay/ams/api/response/merchant/__init__.py +0 -0
- com/alipay/ams/api/response/merchant/alipay_merchant_registration_info_query_response.py +25 -0
- com/alipay/ams/api/response/merchant/alipay_merchant_registration_response.py +20 -0
- com/alipay/ams/api/response/merchant/alipay_merchant_registration_status_query_response.py +25 -0
- com/alipay/ams/api/response/pay/__init__.py +0 -0
- com/alipay/ams/api/response/pay/alipay_capture_response.py +59 -0
- com/alipay/ams/api/response/pay/alipay_create_order_response.py +55 -0
- com/alipay/ams/api/response/pay/alipay_create_session_response.py +32 -0
- com/alipay/ams/api/response/pay/alipay_pay_cancel_response.py +34 -0
- com/alipay/ams/api/response/pay/alipay_pay_consult_response.py +41 -0
- com/alipay/ams/api/response/pay/alipay_pay_query_response.py +245 -0
- com/alipay/ams/api/response/pay/alipay_pay_response.py +218 -0
- com/alipay/ams/api/response/pay/alipay_refund_query_response.py +68 -0
- com/alipay/ams/api/response/pay/alipay_refund_response.py +111 -0
- com/alipay/ams/api/response/risks/__init__.py +0 -0
- com/alipay/ams/api/response/risks/inquiry_risk_score_response.py +42 -0
- com/alipay/ams/api/response/risks/risk_decide_response.py +34 -0
- com/alipay/ams/api/response/risks/risk_report_response.py +11 -0
- com/alipay/ams/api/response/risks/send_payment_result_response.py +11 -0
- com/alipay/ams/api/response/risks/send_refund_result_response.py +11 -0
- com/alipay/ams/api/response/subscription/__init__.py +0 -0
- com/alipay/ams/api/response/subscription/alipay_subscription_cancel_response.py +12 -0
- com/alipay/ams/api/response/subscription/alipay_subscription_change_response.py +11 -0
- com/alipay/ams/api/response/subscription/alipay_subscription_create_response.py +40 -0
- com/alipay/ams/api/response/subscription/alipay_subscription_update_response.py +11 -0
- com/alipay/ams/api/response/users/__init__.py +0 -0
- com/alipay/ams/api/response/users/alipay_init_authentication_response.py +21 -0
- com/alipay/ams/api/response/users/alipay_user_query_info_response.py +37 -0
- com/alipay/ams/api/response/users/alipay_verify_authentication_response.py +21 -0
- com/alipay/ams/api/response/vaulting/__init__.py +0 -0
- com/alipay/ams/api/response/vaulting/alipay_vaulting_payment_method_response.py +50 -0
- com/alipay/ams/api/response/vaulting/alipay_vaulting_query_response.py +53 -0
- com/alipay/ams/api/response/vaulting/alipay_vaulting_session_response.py +31 -0
- com/alipay/ams/api/tools/__init__.py +0 -0
- com/alipay/ams/api/tools/constants.py +17 -0
- com/alipay/ams/api/tools/date_tools.py +30 -0
- com/alipay/ams/api/tools/signature_tool.py +96 -0
- com/alipay/ams/api/tools/webhook_tool.py +10 -0
- global_open_sdk_python-1.4.1.dist-info/LICENSE +21 -0
- global_open_sdk_python-1.4.1.dist-info/METADATA +32 -0
- global_open_sdk_python-1.4.1.dist-info/RECORD +297 -0
- global_open_sdk_python-1.4.1.dist-info/WHEEL +5 -0
- global_open_sdk_python-1.4.1.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import json
|
|
2
|
+
|
|
3
|
+
from com.alipay.ams.api.model.antom_path_constants import AntomPathConstants
|
|
4
|
+
from com.alipay.ams.api.request.alipay_request import AlipayRequest
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class AlipayMerchantRegistrationInfoQueryRequest(AlipayRequest):
|
|
8
|
+
|
|
9
|
+
def __init__(self):
|
|
10
|
+
super(AlipayMerchantRegistrationInfoQueryRequest, self).__init__(AntomPathConstants.MERCHANTS_INQUIRY_REGISTRATION_PATH)
|
|
11
|
+
self.__reference_merchant_id = None
|
|
12
|
+
|
|
13
|
+
@property
|
|
14
|
+
def reference_merchant_id(self):
|
|
15
|
+
return self.__reference_merchant_id
|
|
16
|
+
|
|
17
|
+
@reference_merchant_id.setter
|
|
18
|
+
def reference_merchant_id(self, value):
|
|
19
|
+
self.__reference_merchant_id = value
|
|
20
|
+
|
|
21
|
+
def to_ams_json(self):
|
|
22
|
+
json_str = json.dumps(obj=self.__to_ams_dict(), default=lambda o: o.to_ams_dict(), indent=3)
|
|
23
|
+
return json_str
|
|
24
|
+
|
|
25
|
+
def __to_ams_dict(self):
|
|
26
|
+
params = dict()
|
|
27
|
+
if hasattr(self, "reference_merchant_id") and self.reference_merchant_id:
|
|
28
|
+
params['referenceMerchantId'] = self.reference_merchant_id
|
|
29
|
+
|
|
30
|
+
return params
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import json
|
|
2
|
+
|
|
3
|
+
from com.alipay.ams.api.model.antom_path_constants import AntomPathConstants
|
|
4
|
+
from com.alipay.ams.api.request.alipay_request import AlipayRequest
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class AlipayMerchantRegistrationRequest(AlipayRequest):
|
|
8
|
+
|
|
9
|
+
def __init__(self):
|
|
10
|
+
super(AlipayMerchantRegistrationRequest, self).__init__(AntomPathConstants.MERCHANTS_REGISTRATION_PATH)
|
|
11
|
+
self.__product_codes = None
|
|
12
|
+
self.__registration_request_id = None
|
|
13
|
+
self.__registration_notify_url = None
|
|
14
|
+
self.__merchant_info = None
|
|
15
|
+
self.__pass_through_info = None
|
|
16
|
+
|
|
17
|
+
@property
|
|
18
|
+
def product_codes(self):
|
|
19
|
+
return self.__product_codes
|
|
20
|
+
|
|
21
|
+
@product_codes.setter
|
|
22
|
+
def product_codes(self, value):
|
|
23
|
+
self.__product_codes = value
|
|
24
|
+
|
|
25
|
+
@property
|
|
26
|
+
def registration_request_id(self):
|
|
27
|
+
return self.__registration_request_id
|
|
28
|
+
|
|
29
|
+
@registration_request_id.setter
|
|
30
|
+
def registration_request_id(self, value):
|
|
31
|
+
self.__registration_request_id = value
|
|
32
|
+
|
|
33
|
+
@property
|
|
34
|
+
def registration_notify_url(self):
|
|
35
|
+
return self.__registration_notify_url
|
|
36
|
+
|
|
37
|
+
@registration_notify_url.setter
|
|
38
|
+
def registration_notify_url(self, value):
|
|
39
|
+
self.__registration_notify_url = value
|
|
40
|
+
|
|
41
|
+
@property
|
|
42
|
+
def merchant_info(self):
|
|
43
|
+
return self.__merchant_info
|
|
44
|
+
|
|
45
|
+
@merchant_info.setter
|
|
46
|
+
def merchant_info(self, value):
|
|
47
|
+
self.__merchant_info = value
|
|
48
|
+
|
|
49
|
+
@property
|
|
50
|
+
def pass_through_info(self):
|
|
51
|
+
return self.__pass_through_info
|
|
52
|
+
|
|
53
|
+
@pass_through_info.setter
|
|
54
|
+
def pass_through_info(self, value):
|
|
55
|
+
self.__pass_through_info = 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=10)
|
|
59
|
+
return json_str
|
|
60
|
+
|
|
61
|
+
def __to_ams_dict(self):
|
|
62
|
+
params = dict()
|
|
63
|
+
if hasattr(self, "product_codes") and self.product_codes:
|
|
64
|
+
params['productCodes'] = self.product_codes
|
|
65
|
+
|
|
66
|
+
if hasattr(self, "registration_request_id") and self.registration_request_id:
|
|
67
|
+
params['registrationRequestId'] = self.registration_request_id
|
|
68
|
+
|
|
69
|
+
if hasattr(self, "registration_notify_url") and self.registration_notify_url:
|
|
70
|
+
params['registrationNotifyURL'] = self.registration_notify_url
|
|
71
|
+
|
|
72
|
+
if hasattr(self, "merchant_info") and self.merchant_info:
|
|
73
|
+
params['merchantInfo'] = self.merchant_info
|
|
74
|
+
|
|
75
|
+
if hasattr(self, "pass_through_info") and self.pass_through_info:
|
|
76
|
+
params['passThroughInfo'] = self.pass_through_info
|
|
77
|
+
|
|
78
|
+
return params
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import json
|
|
2
|
+
|
|
3
|
+
from com.alipay.ams.api.model.antom_path_constants import AntomPathConstants
|
|
4
|
+
from com.alipay.ams.api.request.alipay_request import AlipayRequest
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class AlipayMerchantRegistrationStatusQueryRequest(AlipayRequest):
|
|
8
|
+
|
|
9
|
+
def __init__(self):
|
|
10
|
+
super(AlipayMerchantRegistrationStatusQueryRequest, self).__init__(AntomPathConstants.MERCHANTS_INQUIRY_REGISTRATION_STATUS_PATH)
|
|
11
|
+
self.__registration_request_id = None
|
|
12
|
+
self.__reference_merchant_id = None
|
|
13
|
+
|
|
14
|
+
@property
|
|
15
|
+
def registration_request_id(self):
|
|
16
|
+
return self.__registration_request_id
|
|
17
|
+
|
|
18
|
+
@registration_request_id.setter
|
|
19
|
+
def registration_request_id(self, value):
|
|
20
|
+
self.__registration_request_id = value
|
|
21
|
+
|
|
22
|
+
@property
|
|
23
|
+
def reference_merchant_id(self):
|
|
24
|
+
return self.__reference_merchant_id
|
|
25
|
+
|
|
26
|
+
@reference_merchant_id.setter
|
|
27
|
+
def reference_merchant_id(self, value):
|
|
28
|
+
self.__reference_merchant_id = value
|
|
29
|
+
|
|
30
|
+
def to_ams_json(self):
|
|
31
|
+
json_str = json.dumps(obj=self.__to_ams_dict(), default=lambda o: o.to_ams_dict(), indent=3)
|
|
32
|
+
return json_str
|
|
33
|
+
|
|
34
|
+
def __to_ams_dict(self):
|
|
35
|
+
params = dict()
|
|
36
|
+
if hasattr(self, "registration_request_id") and self.registration_request_id:
|
|
37
|
+
params['registrationRequestId'] = self.registration_request_id
|
|
38
|
+
|
|
39
|
+
if hasattr(self, "reference_merchant_id") and self.reference_merchant_id:
|
|
40
|
+
params['referenceMerchantId'] = self.reference_merchant_id
|
|
41
|
+
|
|
42
|
+
return params
|
|
File without changes
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class AlipayAuthNotify(AlipayNotify):
|
|
5
|
+
|
|
6
|
+
def __init__(self, notify_body):
|
|
7
|
+
super(AlipayAuthNotify, self).__init__()
|
|
8
|
+
self.__authorization_notify_type = None
|
|
9
|
+
self.__auth_client_id = None
|
|
10
|
+
self.__access_token = None
|
|
11
|
+
self.__auth_state = None
|
|
12
|
+
self.__auth_code = None
|
|
13
|
+
self.__reason = None
|
|
14
|
+
self.__user_login_id = None
|
|
15
|
+
self.__user_id = None
|
|
16
|
+
self.__parse_notify_body(notify_body)
|
|
17
|
+
|
|
18
|
+
@property
|
|
19
|
+
def authorization_notify_type(self):
|
|
20
|
+
return self.__authorization_notify_type
|
|
21
|
+
|
|
22
|
+
@property
|
|
23
|
+
def auth_client_id(self):
|
|
24
|
+
return self.__auth_client_id
|
|
25
|
+
|
|
26
|
+
@property
|
|
27
|
+
def access_token(self):
|
|
28
|
+
return self.__access_token
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def auth_state(self):
|
|
32
|
+
return self.__auth_state
|
|
33
|
+
|
|
34
|
+
@property
|
|
35
|
+
def auth_code(self):
|
|
36
|
+
return self.__auth_code
|
|
37
|
+
|
|
38
|
+
@property
|
|
39
|
+
def reason(self):
|
|
40
|
+
return self.__reason
|
|
41
|
+
|
|
42
|
+
@property
|
|
43
|
+
def user_login_id(self):
|
|
44
|
+
return self.__user_login_id
|
|
45
|
+
|
|
46
|
+
@property
|
|
47
|
+
def user_id(self):
|
|
48
|
+
return self.__user_id
|
|
49
|
+
|
|
50
|
+
def __parse_notify_body(self, notify_body):
|
|
51
|
+
notify = super(AlipayAuthNotify, self).parse_notify_body(notify_body)
|
|
52
|
+
if 'authorizationNotifyType' in notify:
|
|
53
|
+
self.__authorization_notify_type = notify['authorizationNotifyType']
|
|
54
|
+
if 'authClientId' in notify:
|
|
55
|
+
self.__auth_client_id = notify['authClientId']
|
|
56
|
+
if 'accessToken' in notify:
|
|
57
|
+
self.__access_token = notify['accessToken']
|
|
58
|
+
if 'authState' in notify:
|
|
59
|
+
self.__auth_state = notify['authState']
|
|
60
|
+
if 'authCode' in notify:
|
|
61
|
+
self.__auth_code = notify['authCode']
|
|
62
|
+
if 'reason' in notify:
|
|
63
|
+
self.__reason = notify['reason']
|
|
64
|
+
if 'userLoginId' in notify:
|
|
65
|
+
self.__user_login_id = notify['userLoginId']
|
|
66
|
+
if 'userId' in notify:
|
|
67
|
+
self.__user_id = notify['userId']
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
from com.alipay.ams.api.model.acquirer_info import AcquirerInfo
|
|
2
|
+
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
class AlipayCaptureResultNotify(AlipayNotify):
|
|
6
|
+
|
|
7
|
+
def __init__(self, notify_body):
|
|
8
|
+
super(AlipayCaptureResultNotify, self).__init__()
|
|
9
|
+
self.__capture_request_id = None
|
|
10
|
+
self.__payment_id = None
|
|
11
|
+
self.__capture_id = None
|
|
12
|
+
self.__capture_amount = None
|
|
13
|
+
self.__capture_time = None
|
|
14
|
+
self.__acquirer_reference_no = None
|
|
15
|
+
self.__acquirer_info = None # type: AcquirerInfo
|
|
16
|
+
self.__parse_notify_body(notify_body)
|
|
17
|
+
|
|
18
|
+
@property
|
|
19
|
+
def capture_request_id(self):
|
|
20
|
+
return self.__capture_request_id
|
|
21
|
+
|
|
22
|
+
@property
|
|
23
|
+
def payment_id(self):
|
|
24
|
+
return self.__payment_id
|
|
25
|
+
|
|
26
|
+
@property
|
|
27
|
+
def capture_id(self):
|
|
28
|
+
return self.__capture_id
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def capture_amount(self):
|
|
32
|
+
return self.__capture_amount
|
|
33
|
+
|
|
34
|
+
@property
|
|
35
|
+
def capture_time(self):
|
|
36
|
+
return self.__capture_time
|
|
37
|
+
|
|
38
|
+
@property
|
|
39
|
+
def acquirer_reference_no(self):
|
|
40
|
+
return self.__acquirer_reference_no
|
|
41
|
+
|
|
42
|
+
@property
|
|
43
|
+
def acquirer_info(self):
|
|
44
|
+
return self.__acquirer_info
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
def __parse_notify_body(self, notify_body):
|
|
48
|
+
notify = super(AlipayCaptureResultNotify, self).parse_notify_body(notify_body)
|
|
49
|
+
if 'captureRequestId' in notify:
|
|
50
|
+
self.__capture_request_id = notify['captureRequestId']
|
|
51
|
+
if 'paymentId' in notify:
|
|
52
|
+
self.__payment_id = notify['paymentId']
|
|
53
|
+
if 'captureId' in notify:
|
|
54
|
+
self.__capture_id = notify['captureId']
|
|
55
|
+
if 'captureAmount' in notify:
|
|
56
|
+
self.__capture_amount = notify['captureAmount']
|
|
57
|
+
if 'captureTime' in notify:
|
|
58
|
+
self.__capture_time = notify['captureTime']
|
|
59
|
+
if 'acquirerReferenceNo' in notify:
|
|
60
|
+
self.__acquirer_reference_no = notify['acquirerReferenceNo']
|
|
61
|
+
if 'acquirerInfo' in notify:
|
|
62
|
+
self.__acquirer_info = acquirer_info = AcquirerInfo()
|
|
63
|
+
acquirer_info.parse_rsp_body(notify['acquirerInfo'])
|
|
64
|
+
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
from com.alipay.ams.api.model.dispute_accept_reason_type import DisputeAcceptReasonType
|
|
2
|
+
from com.alipay.ams.api.model.dispute_notification_type import DisputeNotificationType
|
|
3
|
+
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class DisputeJudgedResult:
|
|
7
|
+
pass
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
class AlipayDisputeNotify(AlipayNotify):
|
|
11
|
+
|
|
12
|
+
def __init__(self, notify_body):
|
|
13
|
+
super(AlipayDisputeNotify, self).__init__()
|
|
14
|
+
self.__payment_request_id = None
|
|
15
|
+
self.__dispute_id = None
|
|
16
|
+
self.__payment_id = None
|
|
17
|
+
self.__dispute_time = None
|
|
18
|
+
self.__dispute_amount = None
|
|
19
|
+
self.__dispute_notification_type = None #type: DisputeNotificationType
|
|
20
|
+
self.__dispute_reason_msg = None
|
|
21
|
+
self.__dispute_judged_time = None
|
|
22
|
+
self.__dispute_judged_amount = None
|
|
23
|
+
self.__dispute_judged_result = None #type: DisputeJudgedResult
|
|
24
|
+
self.__defense_due_time = None
|
|
25
|
+
self.__dispute_reason_code = None
|
|
26
|
+
self.__dispute_source = None
|
|
27
|
+
self.__arn = None
|
|
28
|
+
self.__dispute_accept_reason = None #type: DisputeAcceptReasonType
|
|
29
|
+
self.__dispute_accept_time = None
|
|
30
|
+
self.__dispute_type = None
|
|
31
|
+
self.__defendable = None
|
|
32
|
+
self.__parse_notify_body(notify_body)
|
|
33
|
+
|
|
34
|
+
@property
|
|
35
|
+
def payment_request_id(self):
|
|
36
|
+
return self.__payment_request_id
|
|
37
|
+
|
|
38
|
+
@property
|
|
39
|
+
def dispute_id(self):
|
|
40
|
+
return self.__dispute_id
|
|
41
|
+
|
|
42
|
+
@property
|
|
43
|
+
def payment_id(self):
|
|
44
|
+
return self.__payment_id
|
|
45
|
+
|
|
46
|
+
@property
|
|
47
|
+
def dispute_time(self):
|
|
48
|
+
return self.__dispute_time
|
|
49
|
+
|
|
50
|
+
@property
|
|
51
|
+
def dispute_amount(self):
|
|
52
|
+
return self.__dispute_amount
|
|
53
|
+
|
|
54
|
+
@property
|
|
55
|
+
def dispute_notification_type(self):
|
|
56
|
+
return self.__dispute_notification_type
|
|
57
|
+
|
|
58
|
+
@property
|
|
59
|
+
def dispute_reason_msg(self):
|
|
60
|
+
return self.__dispute_reason_msg
|
|
61
|
+
|
|
62
|
+
@property
|
|
63
|
+
def dispute_judged_time(self):
|
|
64
|
+
return self.__dispute_judged_time
|
|
65
|
+
|
|
66
|
+
@property
|
|
67
|
+
def dispute_judged_amount(self):
|
|
68
|
+
return self.__dispute_judged_amount
|
|
69
|
+
|
|
70
|
+
@property
|
|
71
|
+
def dispute_judged_result(self):
|
|
72
|
+
return self.__dispute_judged_result
|
|
73
|
+
|
|
74
|
+
@property
|
|
75
|
+
def defense_due_time (self):
|
|
76
|
+
return self.__defense_due_time
|
|
77
|
+
|
|
78
|
+
@property
|
|
79
|
+
def dispute_reason_code(self):
|
|
80
|
+
return self.__dispute_reason_code
|
|
81
|
+
|
|
82
|
+
@property
|
|
83
|
+
def dispute_source(self):
|
|
84
|
+
return self.__dispute_source
|
|
85
|
+
|
|
86
|
+
@property
|
|
87
|
+
def arn(self):
|
|
88
|
+
return self.__arn
|
|
89
|
+
|
|
90
|
+
@property
|
|
91
|
+
def dispute_accept_reason(self):
|
|
92
|
+
return self.__dispute_accept_reason
|
|
93
|
+
|
|
94
|
+
@property
|
|
95
|
+
def dispute_accept_time(self):
|
|
96
|
+
return self.__dispute_accept_time
|
|
97
|
+
|
|
98
|
+
@property
|
|
99
|
+
def dispute_type(self):
|
|
100
|
+
return self.__dispute_type
|
|
101
|
+
|
|
102
|
+
@property
|
|
103
|
+
def defendable(self):
|
|
104
|
+
return self.__defendable
|
|
105
|
+
|
|
106
|
+
def __parse_notify_body(self, notify_body):
|
|
107
|
+
notify = super(AlipayDisputeNotify, self).parse_notify_body(notify_body)
|
|
108
|
+
|
|
109
|
+
if 'payment_request_id' in notify:
|
|
110
|
+
self.__payment_request_id = notify['payment_request_id']
|
|
111
|
+
if 'dispute_id' in notify:
|
|
112
|
+
self.__dispute_id = notify['dispute_id']
|
|
113
|
+
if 'payment_id' in notify:
|
|
114
|
+
self.__payment_id = notify['payment_id']
|
|
115
|
+
if 'dispute_time' in notify:
|
|
116
|
+
self.__dispute_time = notify['dispute_time']
|
|
117
|
+
if 'dispute_amount' in notify:
|
|
118
|
+
self.__dispute_amount = notify['dispute_amount']
|
|
119
|
+
if 'dispute_notification_type' in notify:
|
|
120
|
+
self.__dispute_notification_type = notify['dispute_notification_type']
|
|
121
|
+
if 'dispute_reason_msg' in notify:
|
|
122
|
+
self.__dispute_reason_msg = notify['dispute_reason_msg']
|
|
123
|
+
if 'dispute_judged_time' in notify:
|
|
124
|
+
self.__dispute_judged_time = notify['dispute_judged_time']
|
|
125
|
+
if 'dispute_judged_amount' in notify:
|
|
126
|
+
self.__dispute_judged_amount = notify['dispute_judged_amount']
|
|
127
|
+
if 'dispute_judged_result' in notify:
|
|
128
|
+
self.__dispute_judged_result = notify['dispute_judged_result']
|
|
129
|
+
if 'defense_due_time' in notify:
|
|
130
|
+
self.__defense_due_time = notify['defense_due_time']
|
|
131
|
+
if 'dispute_reason_code' in notify:
|
|
132
|
+
self.__dispute_reason_code = notify['dispute_reason_code']
|
|
133
|
+
if 'dispute_source' in notify:
|
|
134
|
+
self.__dispute_source = notify['dispute_source']
|
|
135
|
+
if 'arn' in notify:
|
|
136
|
+
self.__arn = notify['arn']
|
|
137
|
+
if 'dispute_accept_reason' in notify:
|
|
138
|
+
self.__dispute_accept_reason = notify['dispute_accept_reason']
|
|
139
|
+
if 'dispute_accept_time' in notify:
|
|
140
|
+
self.__dispute_accept_time = notify['dispute_accept_time']
|
|
141
|
+
if 'dispute_type' in notify:
|
|
142
|
+
self.__dispute_type = notify['dispute_type']
|
|
143
|
+
if 'defendable' in notify:
|
|
144
|
+
self.__defendable = notify['defendable']
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import json
|
|
2
|
+
|
|
3
|
+
from com.alipay.ams.api.model.result import Result
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class AlipayNotify(object):
|
|
7
|
+
|
|
8
|
+
def __init__(self):
|
|
9
|
+
self.__notify_type = None
|
|
10
|
+
self.__result = None #type: Result
|
|
11
|
+
|
|
12
|
+
@property
|
|
13
|
+
def notify_type(self):
|
|
14
|
+
return self.__notify_type
|
|
15
|
+
|
|
16
|
+
@property
|
|
17
|
+
def result(self):
|
|
18
|
+
return self.__result
|
|
19
|
+
|
|
20
|
+
def parse_notify_body(self, notify_body):
|
|
21
|
+
notify = json.loads(notify_body)
|
|
22
|
+
if 'notifyType' in notify:
|
|
23
|
+
self.__notify_type = notify['notifyType']
|
|
24
|
+
if 'result' in notify:
|
|
25
|
+
result = Result()
|
|
26
|
+
result.parse_rsp_body(notify['result'])
|
|
27
|
+
self.__result = result
|
|
28
|
+
return notify
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class AlipayPayResultNotify(AlipayNotify):
|
|
5
|
+
|
|
6
|
+
def __init__(self, notify_body):
|
|
7
|
+
super(AlipayPayResultNotify, self).__init__()
|
|
8
|
+
self.__payment_request_id = None
|
|
9
|
+
self.__payment_id = None
|
|
10
|
+
self.__payment_amount = None
|
|
11
|
+
self.__payment_create_time = None
|
|
12
|
+
self.__payment_time = None
|
|
13
|
+
self.__customs_declaration_amount = None
|
|
14
|
+
self.__gross_settlement_amount = None
|
|
15
|
+
self.__settlement_quote = None
|
|
16
|
+
self.__psp_customer_info = None
|
|
17
|
+
self.__acquirer_reference_no = None
|
|
18
|
+
self.__payment_result_info = None
|
|
19
|
+
self.__acquirer_info = None
|
|
20
|
+
self.__promotion_result = None
|
|
21
|
+
self.__payment_method_type = None
|
|
22
|
+
self.__parse_notify_body(notify_body)
|
|
23
|
+
|
|
24
|
+
@property
|
|
25
|
+
def payment_request_id(self):
|
|
26
|
+
return self.__payment_request_id
|
|
27
|
+
|
|
28
|
+
@property
|
|
29
|
+
def payment_id(self):
|
|
30
|
+
return self.__payment_id
|
|
31
|
+
|
|
32
|
+
@property
|
|
33
|
+
def payment_amount(self):
|
|
34
|
+
return self.__payment_amount
|
|
35
|
+
|
|
36
|
+
@property
|
|
37
|
+
def payment_create_time(self):
|
|
38
|
+
return self.__payment_create_time
|
|
39
|
+
|
|
40
|
+
@property
|
|
41
|
+
def payment_time(self):
|
|
42
|
+
return self.__payment_time
|
|
43
|
+
|
|
44
|
+
@property
|
|
45
|
+
def customs_declaration_amount(self):
|
|
46
|
+
return self.__customs_declaration_amount
|
|
47
|
+
|
|
48
|
+
@property
|
|
49
|
+
def gross_settlement_amount(self):
|
|
50
|
+
return self.__gross_settlement_amount
|
|
51
|
+
|
|
52
|
+
@property
|
|
53
|
+
def settlement_quote(self):
|
|
54
|
+
return self.__settlement_quote
|
|
55
|
+
|
|
56
|
+
@property
|
|
57
|
+
def psp_customer_info(self):
|
|
58
|
+
return self.__psp_customer_info
|
|
59
|
+
|
|
60
|
+
@property
|
|
61
|
+
def acquirer_reference_no(self):
|
|
62
|
+
return self.__acquirer_reference_no
|
|
63
|
+
|
|
64
|
+
@property
|
|
65
|
+
def payment_result_info(self):
|
|
66
|
+
return self.__payment_result_info
|
|
67
|
+
|
|
68
|
+
@property
|
|
69
|
+
def acquirer_info(self):
|
|
70
|
+
return self.__acquirer_info
|
|
71
|
+
|
|
72
|
+
@property
|
|
73
|
+
def promotion_result(self):
|
|
74
|
+
return self.__promotion_result
|
|
75
|
+
@property
|
|
76
|
+
def payment_method_type(self):
|
|
77
|
+
return self.__payment_method_type
|
|
78
|
+
|
|
79
|
+
def __parse_notify_body(self, notify_body):
|
|
80
|
+
notify = super(AlipayPayResultNotify, self).parse_notify_body(notify_body)
|
|
81
|
+
if 'paymentRequestId' in notify:
|
|
82
|
+
self.__payment_request_id = notify['paymentRequestId']
|
|
83
|
+
if 'paymentId' in notify:
|
|
84
|
+
self.__payment_id = notify['paymentId']
|
|
85
|
+
if 'paymentAmount' in notify:
|
|
86
|
+
self.__payment_amount = notify['paymentAmount']
|
|
87
|
+
if 'paymentCreateTime' in notify:
|
|
88
|
+
self.__payment_create_time = notify['paymentCreateTime']
|
|
89
|
+
if 'paymentTime' in notify:
|
|
90
|
+
self.__payment_time = notify['paymentTime']
|
|
91
|
+
if 'customsDeclarationAmount' in notify:
|
|
92
|
+
self.__customs_declaration_amount = notify['customsDeclarationAmount']
|
|
93
|
+
if 'grossSettlementAmount' in notify:
|
|
94
|
+
self.__gross_settlement_amount = notify['grossSettlementAmount']
|
|
95
|
+
if 'settlementQuote' in notify:
|
|
96
|
+
self.__settlement_quote = notify['settlementQuote']
|
|
97
|
+
if 'pspCustomerInfo' in notify:
|
|
98
|
+
self.__psp_customer_info = notify['pspCustomerInfo']
|
|
99
|
+
if 'acquirerReferenceNo' in notify:
|
|
100
|
+
self.__acquirer_reference_no = notify['acquirerReferenceNo']
|
|
101
|
+
if 'paymentResultInfo' in notify:
|
|
102
|
+
self.__payment_result_info = notify['paymentResultInfo']
|
|
103
|
+
if 'acquirerInfo' in notify:
|
|
104
|
+
self.__acquirer_info = notify['acquirerInfo']
|
|
105
|
+
if 'promotionResult' in notify:
|
|
106
|
+
self.__promotion_result = notify['promotionResult']
|
|
107
|
+
|
|
108
|
+
if 'paymentMethodType' in notify:
|
|
109
|
+
self.__payment_method_type = notify['paymentMethodType']
|
|
110
|
+
|
|
111
|
+
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
from com.alipay.ams.api.model.amount import Amount
|
|
2
|
+
from com.alipay.ams.api.model.quote import Quote
|
|
3
|
+
from com.alipay.ams.api.request.notify.alipay_notify import AlipayNotify
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class AlipayRefundNotify(AlipayNotify):
|
|
7
|
+
|
|
8
|
+
def __init__(self, notify_body):
|
|
9
|
+
super(AlipayRefundNotify, self).__init__()
|
|
10
|
+
self.__refund_status = None
|
|
11
|
+
self.__refund_request_id = None
|
|
12
|
+
self.__refund_id = None
|
|
13
|
+
self.__refund_amount = None # type: Amount
|
|
14
|
+
self.__refund_time = None
|
|
15
|
+
self.__gross_settlement_amount = None # type: Amount
|
|
16
|
+
self.__settlement_quote = None # type: Quote
|
|
17
|
+
self.__parse_notify_body(notify_body)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
@property
|
|
21
|
+
def refund_status(self):
|
|
22
|
+
return self.__refund_status
|
|
23
|
+
|
|
24
|
+
@property
|
|
25
|
+
def refund_request_id(self):
|
|
26
|
+
return self.__refund_request_id
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
@property
|
|
30
|
+
def refund_id(self):
|
|
31
|
+
return self.__refund_id
|
|
32
|
+
|
|
33
|
+
@property
|
|
34
|
+
def refund_amount(self):
|
|
35
|
+
return self.__refund_amount
|
|
36
|
+
|
|
37
|
+
@property
|
|
38
|
+
def refund_time(self):
|
|
39
|
+
return self.__refund_time
|
|
40
|
+
|
|
41
|
+
@property
|
|
42
|
+
def gross_settlement_amount(self):
|
|
43
|
+
return self.__gross_settlement_amount
|
|
44
|
+
|
|
45
|
+
@property
|
|
46
|
+
def settlement_quote(self):
|
|
47
|
+
return self.__settlement_quote
|
|
48
|
+
|
|
49
|
+
def __parse_notify_body(self, notify_body):
|
|
50
|
+
notify = super(AlipayRefundNotify, self).parse_notify_body(notify_body)
|
|
51
|
+
if 'refundStatus' in notify:
|
|
52
|
+
self.__refund_status = notify['refundStatus']
|
|
53
|
+
if 'refundRequestId' in notify:
|
|
54
|
+
self.__refund_request_id = notify['refundRequestId']
|
|
55
|
+
if 'refundId' in notify:
|
|
56
|
+
self.__refund_id = notify['refundId']
|
|
57
|
+
if 'refundAmount' in notify:
|
|
58
|
+
self.__refund_amount = Amount(notify['refundAmount'])
|
|
59
|
+
if 'refundTime' in notify:
|
|
60
|
+
self.__refund_time = notify['refundTime']
|
|
61
|
+
if 'grossSettlementAmount' in notify:
|
|
62
|
+
self.__gross_settlement_amount = Amount(notify['grossSettlementAmount'])
|
|
63
|
+
if 'settlementQuote' in notify:
|
|
64
|
+
queue = Quote()
|
|
65
|
+
queue.parse_rsp_body(notify['settlementQuote'])
|
|
66
|
+
self.__settlement_quote = queue
|
|
67
|
+
|