@@ -76,7 +76,7 @@ type AliPayAgreementUnsign struct {
76
76
AlipayUserId string `json:"alipay_user_id"` // 用户的支付宝账号对应 的支付宝唯一用户号,以 2088 开头的 16 位纯数字 组成
77
77
AlipayLogonId string `json:"alipay_logon_id"` // 用户的支付宝登录账号,支持邮箱或手机号码格式。本参数与alipay_user_id 不可同时为空,若都填写,则以alipay_user_id 为准
78
78
ExternalAgreementNo string `json:"external_agreement_no"` // 萌推系统内部的 contract_code
79
-
79
+ AgreementNo string `json:"agreement_no"` // 支付宝系统中用以唯一标识用户签约记录的编号(用户签约成功后的协议号),如果传了该参数,其他参数会被忽略
80
80
}
81
81
82
82
func (this AliPayAgreementUnsign ) APIName () string {
@@ -99,8 +99,10 @@ func (this AliPayAgreementUnsign) ExtJSONParamValue() string {
99
99
100
100
type AliPayAgreementUnsignResponse struct {
101
101
AlipayUserAgreementUnsignResponse struct {
102
- Code string `json:"code"`
103
- Msg string `json:"msg"`
102
+ Code string `json:"code"`
103
+ Msg string `json:"msg"`
104
+ SubCode string `json:"sub_code"`
105
+ SubMsg string `json:"sub_msg"`
104
106
} `json:"alipay_user_agreement_unsign_response"`
105
107
Sign string `json:"sign"`
106
108
Body string `json:"-"` // 返回内容原文,主要是为了记录日志
@@ -115,3 +117,52 @@ func (this *AliPayAgreementUnsignResponse) IsSuccess() bool {
115
117
func (this * AliPayAgreementUnsignResponse ) SetOriginBody (body string ) {
116
118
this .Body = body
117
119
}
120
+
121
+ ////////////////////////////////////////////////////////////////////////////////
122
+ // https://docs.open.alipay.com/api_2/alipay.user.agreement.executionplan.modify
123
+ // 支付宝个人代扣协议修改接口
124
+ type AliPayAgreementModify struct {
125
+ AgreementNo string `json:"agreement_no"` // 支付宝系统中用以唯一标识用户签约记录的编号(用户签约成功后的协议号),如果传了该参数,其他参数会被忽略
126
+ DeductTime string `json:"deduct_time"` // 商户下一次扣款时间
127
+ Memo string `json:"memo"` // 具体修改原因
128
+ }
129
+
130
+ func (this AliPayAgreementModify ) APIName () string {
131
+ return "alipay.user.agreement.executionplan.modify"
132
+ }
133
+
134
+ func (this AliPayAgreementModify ) Params () map [string ]string {
135
+ var m = make (map [string ]string )
136
+ return m
137
+ }
138
+
139
+ func (this AliPayAgreementModify ) ExtJSONParamName () string {
140
+ return "biz_content"
141
+ }
142
+
143
+ func (this AliPayAgreementModify ) ExtJSONParamValue () string {
144
+ return marshal (this )
145
+ }
146
+
147
+ type AliPayAgreementModifyResponse struct {
148
+ AlipayUserAgreementExecutionplanModifyResponse struct {
149
+ Code string `json:"code"`
150
+ Msg string `json:"msg"`
151
+ SubCode string `json:"sub_code"`
152
+ SubMsg string `json:"sub_msg"`
153
+ AgreementNo string `json:"agreement_no"`
154
+ DeductTime string `json:"deduct_time"`
155
+ } `json:"alipay_user_agreement_executionplan_modify_response"`
156
+ Sign string `json:"sign"`
157
+ Body string `json:"-"` // 返回内容原文,主要是为了记录日志
158
+ }
159
+
160
+ func (this * AliPayAgreementModifyResponse ) IsSuccess () bool {
161
+ if this .AlipayUserAgreementExecutionplanModifyResponse .Code == K_SUCCESS_CODE {
162
+ return true
163
+ }
164
+ return false
165
+ }
166
+ func (this * AliPayAgreementModifyResponse ) SetOriginBody (body string ) {
167
+ this .Body = body
168
+ }
0 commit comments