May 18, 2021 WeChat Mini Program Development Document
WeChat background to inform the owner of the user log off / contract.
The name of the argument | Type | Required | Note |
---|---|---|---|
appid | string | Y | Small program |
mch_id | string | Y | Pay the merchant number |
nonce_str | string | Y | Random string |
encrypted_data | string | Y | Use AESCBCPKCS7PADDING |
Ⅳ | string | Y | IV for decryption (base64) |
sign | string | Y | Signature of 1 to 5 fields |
encrypted_data decrypted data
The name of the argument | Type | Required | Note |
---|---|---|---|
Openid | string | Y | User openid |
cardid | string | N | The owner's user ID |
The name of the argument | Type | Required | Note |
---|---|---|---|
errcode | Int | Y | 0 is a success |
errmsg | string | N | The error message |
nonce_str | string | Y | Bring it back as is |
Request:
{"appid":"test","mch_id":"123456","nonce_str":"abcdefg","encrypted_data":"jfiwajeofjiefef","iv":"afweifwefe"}
encrypted_data is decrypted:
{"openid":"1234","cardid":"1234"}
Return:
{"errcode":0,"nonce_str":"abcdefg","encrypted_data":"jfiwajeofjiefef","iv":"afweifwefe"}