Login expired. Please log in again.

Feedback

0/300

Feedback

Submitted successfully

ok

Feedback

Network exception, please try again later

ok

Querying Signing Status (By contract_id) API

Latest update time:2022.08.04 Release notes

The signing relationship query interface provides the single transaction signing relationship query

1. API Intro

Applicable object: Common mode Institutional mode

Request Url: https://apihk.mch.weixin.qq.com/v3/global/papay/contracts/{contract_id}

Request method: GET


Pathparameter is a path parameter.
Queryparameter needs to be passed in the request URL.
Bodyparameter needs to be passed in the request JSON.

2. Request Parameters

Name Variable Name Type Required Description
App ID appid string[1,32] Yes Query Appid bound to the merchant ID
Note: Only forCommon mode
Example: wxcbda96de0b165486
Sub-merchant ID sub_mchid string[1,32] Yes Query Sub-merchant ID allocated by WeChat Pay
Note: Only forInstitutional mode
Example: 10000097
App ID of the service provider sp_appid string[1,32] Yes Query Appid bound to the service provider
Note: Only forInstitutional mode
Example: wxcbda96de0b165486
App ID of the sub-merchant sub_appid string[1,32] No Query Appid bound to the sub-merchant ID for initiating signing
Note: Only forInstitutional mode
Example: wxcbda96de0b165484
Auto-debit contract ID

contract_id

string[1,64]

Yes Path Auto-debit contract ID returned by WeChat after successful Auto-debit signing; this parameter is required when contract_id is selected to perform query
Example: 100005698

Example:


https://apihk.mch.weixin.qq.com/v3/global/papay/contracts/100005698?appid=wxcbda96de0b165486
    

https://apihk.mch.weixin.qq.com/v3/global/papay/contracts/100005698?sub_mchid=10000097&sp_appid=wxcbda96de0b165486&sub_appid=wxcbda96de0b165484
  

3. Response Parameters

Name Variable Name Type Required Description
Merchant ID mchid string[1,32] Yes Merchant ID allocated by WeChat Pay
Note: Only forCommon mode
Example: 10000091
App ID appid string[1,32] Yes Appid bound to the merchant ID
Note: Only forCommon mode
Example: wxcbda96de0b165486
Merchant ID of the service provider sp_mchid string[1,32] Yes The institution's merchant ID allocated by WeChat Pay
Note: Only forInstitutional mode
Example: 10000098
Sub-merchant ID sub_mchid string[1,32] Yes Sub-merchant ID allocated by WeChat Pay
Note: Only forInstitutional mode
Example: 10000097
App ID of the service provider sp_appid string[1,32] Yes Appid bound to the service provider’s Official Account
Note: Only forInstitutional mode
Example: wxcbda96de0b165486
App ID of the sub-merchant sub_appid string[1,32] No Mini program appid of the sub-merchant who initiates the signing
Note: Only forInstitutional mode
Example: wxcbda96de0b165484
Auto-debit contract ID contract_id string[1,32] Yes Auto-debit contract ID returned by WeChat after successful signing
Example: 100005698
Template ID plan_id Int Yes When a merchant applies for deduction permission to WeChat Pay, WeChat Pay will allocate a unique deduction template ID to the merchant
Example: 123
Signed contract No. out_contract_code string[1,32] Yes Signed contract No. passed in when the merchant requests signing, which must be unique at the merchant side
Example: 1023658866
Displayed user account name user_display_name string[1,32] Yes The name of the signing user, displayed on the page
Example: Zhang San
Agreement state state string[1,32] Yes NOTSIGN: Not signed
SIGNING: Signing
SIGNED: Signed
TERMINATING: Terminating the contract
TERMINATED: Contract terminated
DELETE: Deleted
SIGNFAIL: Signing is failed
Example: SIGNED
Signing time of the contract signed_time string[1,32] Yes Signing time of the contract
Example: 2015-07-01T10:00:00+08:00
Terminating time of the contract terminated_time string[1,32] No When state is TERMINATED, the value indicates the terminating time of the contract
Example: 2015-09-01T10:00:00+08:00
Termination mode of the contract termination_mode int No When state is TERMINATED, the value indicates the termination mode of the contract  
USER-Terminated by the user
MERCHANT-Terminated by the merchant API 
PLATFORM-Terminated by the merchant platform 
Example: USER
Termination note termination_note string No When state is TERMINATED, the value indicates the termination note
Example: Cause of termination
User ID under the merchant’s appid openid string[1,128] Yes Openid of the user under the merchant’s appid
Note: Only forCommon mode
Example: ouFhd5X9s9WteC3eWRjXV3lea123

Example:


{
	"mchid": "10000100",
	"appid": " wx426b3015555b46be ",
	"contract_id": "203",
	"plan_id": 66,
	"openid": " oHZx6uMbIG46UXQ3SKxVYEgw1LZs ",
	"out_contract_code": " 1005 ",
	"user_display_name": " test ",
	"state": "TERMINATED",
	"signed_time": "2015-07-01T10:00:00+08:00",
	"expired_time": "2016-07-01T10:00:00+08:00",
	"terminated_time": "2015-09-01T10:00:00+08:00",
	"termination_mode": "USER",
	"termination_note": " delete ....",
}
    

{
	"sp_mchid": "10000100",
	"sub_mchid": " 1900000109",
	"sp_appid": " wx426b3015555b46be ",
	"contract_id": "203",
	"plan_id": 66,
	"openid": " oHZx6uMbIG46UXQ3SKxVYEgw1LZs ",
	"out_contract_code": " 1005 ",
	"user_display_name": " test ",
	"state": "TERMINATED",
	"signed_time": "2015-07-01T10:00:00+08:00",
	"expired_time": "2016-07-01T10:00:00+08:00",
	"terminated_time": "2015-09-01T10:00:00+08:00",
	"termination_mode": "EXPIRED",
	"termination_note": " delete .... "
}
  

4. Error Codes

Error Codes Error Message Description Solution
403 CONTRACT_NOT_EXIST The contract cannot be found Please check whether the request contract is correct or whether it is terminated.
400 PARAM_ERROR Parameter error Please check the request parameter format.
500 SYSTEMERROR System error Please try the request again


    Page navigation

Release notes

close
V1.0
2021.08.18
1. Querying Signing Status(By contract_id)API released online

About  WeChat  Pay

Powered By Tencent & Tenpay Copyright©

2005-2024 Tenpay All Rights Reserved.

Contact Us
Wechat Pay Global

WeChat Pay Global

置顶