alipay.dut.customer.agreement.unsign
This interface can be used by merchant to cancel/unbind the three-party payment agreement signed by the merchant, Alipay and the user.
#Request
#Service address
Environment | HTTPS request URL |
Production environment | |
Test environment |
#Request parameters
| Parameter | Description |
| Basic parameter | |
service String | Service name
|
partner String(16) | The partner ID that is assigned by Alipay to identify an Alipay account. The partner ID is composed of 16 digits and begins with 2088.
|
_input_charset String | The charset with which the request data are encoded. UTF-8 is supported.
|
sign_type String | Sign type. DSA, RSA, and MD5 are supported. Use uppercase.
|
sign String | Sign value
|
notify_url String(200) | The URL for receiving asynchronous notifications after the payment is completed.
|
| Business parameter | |
product_code String(64) | The code that identifies a payment solution signed between Alipay and the merchant partner
|
alipay_user_id String(32) | The unique ID in Alipay for the user, which is composed of 16 digits and begins with 2088. Fields alipay_user_id and alipay_logon_id cannot be null at the same time. If both are provided, alipay_user_id is used.
|
alipay_logon_id String(100) | User's login ID, which is an email address or a cell phone number. Fields alipay_user_id and alipay_logon_id cannot be null at the same time. If both are provided, alipay_user_id is used.
|
third_party_type String(32) | Type of the third party who signs the agreement with Alipay and Alipay user. The default value is PARTNER.
|
scene String(100) | The code for specific scenario, identifying a business case which is agreed between Alipay and the merchant.
|
app_id String | The app ID of the merchant on Alipay global open platform
|
external_sign_no String(32) | The unique three-party payment agreement number
|
#Response
#Synchronous response
| Parameter | Description |
is_success String | Indicate whether the request succeeds at gateway level.
|
error String | Error code. This field is required when the value of is_success is F.
|
#Asynchronous response
| Parameter | Description |
| Basic Parameter | |
notify_time String | The time in GMT+8 when the notification is sent. The time format is yyyy-MM-dd HH:mm:ss.
|
notify_type String | Notification type
|
notify_id String | Notification ID, used by the partner system to verify the notification
|
sign_type String | Sign type. DSA and RSA are supported. Use uppercase.
|
sign String | Sign value
|
Business Parameter | |
agreement_no String | The unique identifier for the agreement
|
product_code String | The code that identifies a payment solution signed between Alipay and the user
|
scene String | The code for specific scenario, identifying a business case which is agreed between Alipay and the merchant.
|
status String | The current status of the agreement, with a value of UNSIGN for this interface.
|
alipay_user_id String | The unique ID in Alipay for the user, which is composed of 16 digits and begins with 2088. Fields alipay_user_id and alipay_logon_id cannot be null at the same time. If both are provided, alipay_user_id is used.
|
unsign_time String | Actual time in GMT +8 when the Alipay payment agreement is unsigned. The time format is yyyy-MM-dd HH:mm:ss.
|
sign_modify_time String | The last time in GMT +8 when the Alipay payment agreement is modified. The time format is yyyy-MM-dd HH:mm:ss.
|
external_sign_no String | The unique number of the three-party payment agreement provided by the partner
|
#Error codes
#Access errors
| Error code | Description |
| SYSTEM_ERROR | System error. |
| SESSION_TIMEOUT | Session timeout. |
| ILLEGAL_TARGET_SERVICE | The signature fails the verification. |
| ILLEGAL_ACCESS_SWITCH_SYSTEM | The signature method is unsupported. |
| ILLEGAL_SWITCH_SYSTEM | Target service is illegal. |
| EXTERFACE_IS_CLOSED | The interface name is invalid. |
#Business errors
| Error code | Description |
| AGREEMENT_NOT_EXIST | The agreement is not exist |
| USER_NOT_EXIST_ERROR | The user is not exist |
| ILLGALE_ARGUMENT | Illegal argument. |
| ILLEGAL_SIGN | Illegal sign. |
| ILLEGAL_DYN_MD5_KEY | Dynamic MD5 key is illegal. |
| ILLEGAL_ENCRYPT | Illegal encrypt. |
| ILLEGAL_SERVICE | Wrong service. |
| ILLEGAL_USER | Wrong user id. |
| ILLEGAL_PARTNER | Wrong partner id. |
| ILLEGAL_EXTERFACE | Illegal external interface config. |
| ILLEGAL_PARTNER_EXTERFACE | Illegal partner external interface config. |
| ILLEGAL_SECURITY_PROFILE | Illegal security profile. |
| ILLEGAL_SIGN_TYPE | Illegal sign type. |
| ILLEGAL_CHARSET | Illegal charset. |
| ILLEGAL_CLIENT_IP | Client IP has no access permission. |
| HAS_NO_PRIVILEGE | Has no privilege. |
| ILLEGAL_DIGEST_TYPE | Illegal digest type. |
| ILLEGAL_ENCODING | Illegal encoding. |
| ILLEGAL_SYSTEM | Illegal system. |
| ILLEGAL_REQUEST_REFERER | Illegal request referrer. Used for phising attack prevention. |
#Samples
#Request sample
https://mapi.alipay.com/gateway.do?sign=ba77c7f7a1fd0324cc906f1aa9a7ffb3&product_code=ONE_KEY_BUY&sign_type=RSA&service=alipay.dut.customer.agreement.unsign&partner=2088001159940003&alipay_user_id=2088101122675263
#Response sample
#Synchronous response sample
The agreement is unsigned successfully:
<?xml version="1.0" encoding="utf-8"?>
<alipay>
<is_success>T</is_success>
<request>
<param name="sign">ba77c7f7a1fd0324cc906f1aa9a7ffb3</param>
<param name="product_code">ONE_KEY_BUY</param>
<param name="sign_type">RSA</param>
<param name="service">alipay.dut.customer.agreement.unsign</param>
<param name="alipay_user_id">2088101122675263</param>
<param name="partner">2088001159940003</param>
</request>
<response>
<result/>
</response>
</alipay>The agreement is failed to be unsigned:
<?xml version="1.0" encoding="utf-8"?>
<alipay>
<is_success>F</is_success>
<error>ILLEGAL_SIGN</error>
</alipay>#Asynchronous response sample
http://merchant.com/alipay/notify_url.php?notify_time=2014-10-20+11%3A33%3A36¬ify_type=dut_user_unsign¬ify_id=df35c47ed9df1fe4157a555e5c1f4a39&sign_type=MD5&sign=b1af584504b8e845ebe40b8e0e733729&agreement_no=20141020000353099885&product_code=GENERAL_WITHHOLDING_P&scene=INDUSTRY|MEDIA&status=UNSIGN&alipay_user_id=2088002008073305&unsign_time=2014-10-20+11%3A49%3A19&sign_modify_time=2014-10-20+11%3A49%3A19
http://merchant.com/alipay/notify_url.php
notify_time=2014-10-20 11:33:36
notify_type=dut_user_unsign
notify_id=df35c47ed9df1fe4157a555e5c1f4a39
sign_type=MD5
sign=b1af584504b8e845ebe40b8e0e733729
agreement_no=20141020000353099885
product_code=GENERAL_WITHHOLDING_P
scene=INDUSTRY|MEDIA
status=UNSIGN
alipay_user_id=2088002008073305
unsign_time=2014-10-20 11:49:19
sign_modify_time=2014-10-20 11:49:19