Alipay, China's leading third-party online payment solutionAlipay, China's leading third-party online payment solution

alipay.dut.customer.agreement.query

Auto-debit Acquiring customer sign status query Interface-- alipay.dut.customer.agreement.query

This interface can be used by merchant to query the three party agreement signed by the merchant, Alipay and the user.

Request

Service address

Environment

HTTPS request URL

Production environment

https://intlmapi.alipay.com/gateway.do

Test environment

https://mapi.alipaydev.com/gateway.do

Request parameters

ParameterType (length)DescriptionRequiredExample
Basic parameter
serviceStringService Name

Y

alipay.dut.customer.agreement.query
partnerString(16)Partner ID that is composed of 16 digits beginning with 2088.

Y

2088001159940003
_input_charsetStringThe charset with which the request data is encoded. UTF-8 is supported.

N

UTF-8
sign_typeStringSign type. DSA, RSA, and MD5 are supported. Use uppercase.

Y

RSA
signStringSign value

Y

e5815a4556db338ed237f7d3fd222184
Business parameter
product_codeString(64)The code that identifies a payment solution signed between Alipay and the merchant partner.

Y

GENERAL_WITHHOLDING_P
alipay_user_idStringThe unique id in Alipay for the user. It is a 16 digits number beginning with 2088. alipay_user_id and alipay_logon_id cannot be null at the same time. If both are provided, alipay_user_id will be used.

N

2088101122675263
alipay_logon_idString(100)User’s logon id, can be email or cell phone number.
alipay_user_id and alipay_logon_id cannot be null at the same time. If both are provided, alipay_user_id will be used.

N

abx@alitest.com
third_party_typeString(32)Type of the tird party who signs the agreement with Alipay and Alipay user.
Default value is PARTNER
NMERCHANT
sceneString(100)The code for specific scenario, identifying a business case which agreed between Alipay and the merchant.

Y

INDUSTRY|MEDICAL
app_idStringThe app id of the Merchant in Alipay open platform.

N

2014071600176280
external_sign_noString(32)The unique three-party payment agreement number provided by the partner.

Y

e8qdwl9casxor13

Response

ParameterType (length)DescriptionRequiredExample
Basic parameter
is_successStringIndicate if the request succeeds at gateway level.

Y

T
signStringSign value

N

9107908ca1d018b32f82f7b40a27e4c3
sign_typeStringSign type. DSA and RSA are supported. Use uppercase.

N

RSA
errorString
  • The error code, only set with value when is_success is set with F

N

ILLEGAL_SIGN
Business parameter
principal_typeString

Agreement principal type:

  • CARD: Alipay account
  • CUSTOMER: Alipay customer

Y

CARD
principal_idString

Agreement principal id.

  • When principal_type is CARD, principal_id is the Alipay user’s account number.
  • When principal_type is CUSTOMER, principal_id is the unique Alipay user’s id. One user may have multiple Alipay user account, but only one user’s id.

Y

2088101122675263
product_codeStringThe code that identifies a payment solution signed between Alipay and the merchant partner.

Y

ONE_KEY_BUY
sceneStringThe code for specific scenario, identifying a business case which agreed between Alipay and the merchant.

Y

DEFAULT|DEFAULT
thirdpart_typeStringAgreement third party type.

Y

PARTNER
thirdpart_idStringAgreement third party id.

Y

2088102112738609
statusString

Status of the agreement:

  • NORMAL
  • STOP

Y

NORMAL
valid_timeStringEffective date of the agreement. Format: yyyy-MM-dd HH:mm:ss 

Y

2014-04-14 15:00:40
invalid_timeStringExpire date of the agreement. Format: yyyy-MM-dd HH:mm:ss 

Y

2115-02-01 00:00:00
sign_timeStringInitial sign time of the agreement.  Format: yyyy-MM-dd HH:mm:ss 

Y

2014-04-14 15:00:40
sign_modify_timeStringThe latest modification time of the agreement. Format: yyyy-MM-dd HH:mm:ss
If never modified, sign_modify_time = sign_time

Y

2014-04-14 15:00:40
external_sign_noStringThe unique third party payment agreement number.

Y

e8qdwl9casxor13
agreement_noStringThe agreement number

N

2015031300000001
agreement_detailStringAgreement detail in JSON format.

N

{"payToolSummaryDetails":[{"payToolSummary":"COUPON_DC_COUPON_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"},{"payToolSummary":"BANKCARD_CC_EXPRESS_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"},{"payToolSummary":"BANKCARD_CC_CARTOON_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"}]}

agreement_detail

ParameterType (length)DescriptionRequiredExample
payToolSummaryDetailsStringList of pay tools. Alipay system supports multiple pay tools.N[{"payToolSummary":"COUPON_DC_COUPON_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"},{"payToolSummary":"BANKCARD_CC_EXPRESS_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"},{"payToolSummary":"BANKCARD_CC_CARTOON_DEFAULT","extInfo":null,"detailType":"PAYTOOLSUMMARY"}]

Samples

Request sample

https://mapi.alipay.com/gateway.do?sign=b1df9e289e6e4e5fc2a57ed6f24b46c0&product_code=GENERAL_WITHHOLDING_P&sign_type=MD5&service=alipay.dut.customer.agreement.query&partner=2088001159940003&external_sign_no=2088101122675263&third_party_type=MERCHANT