Merge branch 'master' of http://git.dev.yoho.cn/yoho-documents/api-interfaces
Showing
1 changed file
with
108 additions
and
5 deletions
@@ -135,8 +135,7 @@ | @@ -135,8 +135,7 @@ | ||
135 | | :-- | --: | --: | --: | --: | | 135 | | :-- | --: | --: | --: | --: | |
136 | | method | String | true |app.promotion.queryCouponCenter| 请求方法| | 136 | | method | String | true |app.promotion.queryCouponCenter| 请求方法| |
137 | | uid | String | false | 7893817 |用户ID | | 137 | | uid | String | false | 7893817 |用户ID | |
138 | -| code | String | true |1112 |券和资源位关联的code| | ||
139 | -| couponId | String | true |23121,11759,45213 |券id列表| | 138 | +| contentCode | String | true |b38b9c4f1c76f89533e9214629b458e4 |资源位内容码| |
140 | 139 | ||
141 | 140 | ||
142 | #### 响应内容 | 141 | #### 响应内容 |
@@ -145,16 +144,120 @@ | @@ -145,16 +144,120 @@ | ||
145 | { | 144 | { |
146 | "alg": "SALT_MD5", | 145 | "alg": "SALT_MD5", |
147 | "code": 200, | 146 | "code": 200, |
147 | + "data": [ | ||
148 | + { | ||
148 | "data": { | 149 | "data": { |
149 | - "code": "1112", | 150 | + "list": [ |
151 | + { | ||
152 | + "src": "http://img11.static.yhbimg.com/yhb-img01/2016/04/13/06/019bd2c1581f881c8ea22daf0e39a4a9ab.png?imageView/{mode}/w/{width}/h/{height}", | ||
153 | + "url": [] | ||
154 | + }, | ||
155 | + { | ||
156 | + "src": "http://img12.static.yhbimg.com/yhb-img01/2016/04/13/06/02576fa876ccfbfe0648b4e2dabb989b6f.png?imageView/{mode}/w/{width}/h/{height}", | ||
157 | + "url": [] | ||
158 | + }, | ||
159 | + { | ||
160 | + "src": "http://img11.static.yhbimg.com/yhb-img01/2016/04/13/06/01362e8c56fd6ac56ad3852b6a192e5336.png?imageView/{mode}/w/{width}/h/{height}", | ||
161 | + "url": [] | ||
162 | + } | ||
163 | + ], | ||
164 | + "speed": "3" | ||
165 | + }, | ||
166 | + "template_id": 1111253, | ||
167 | + "template_intro": "轮播banner", | ||
168 | + "template_name": "carousel_banner" | ||
169 | + }, | ||
170 | + { | ||
171 | + "data": { | ||
172 | + "list": [ | ||
173 | + { | ||
174 | + "couponID": "2516,2376", | ||
150 | "status": 1, | 175 | "status": 1, |
151 | - "hasNum":99999 | 176 | + "goShopping": "http://item.m.yohobuy.com/product/pro_325933_419711/XiongJiaYouPin619081838990XiongJiaYouPinChuangYiLanRenTanZhuTuiKuan.html", |
177 | + "image": { | ||
178 | + "src": "http://img12.static.yhbimg.com/yhb-img01/2016/01/19/01/02f639de49d79ece0cf86a2f214be781da.jpg?imageView/{mode}/w/{width}/h/{height}", | ||
179 | + "url": "http://2percent.yohobuy.com/?gender=2,3\n" | ||
180 | + }, | ||
181 | + { | ||
182 | + "couponID": "1565", | ||
183 | + "status": 2, | ||
184 | + "goShopping": "http://item.m.yohobuy.com/product/pro_325933_419711/XiongJiaYouPin619081838990XiongJiaYouPinChuangYiLanRenTanZhuTuiKuan.html", | ||
185 | + "image": { | ||
186 | + "src": "http://img12.static.yhbimg.com/yhb-img01/2016/01/19/01/02f639de49d79ece0cf86a2f214be781da.jpg?imageView/{mode}/w/{width}/h/{height}", | ||
187 | + "url": "http://2percent.yohobuy.com/?gender=2,3\n" | ||
188 | + }, | ||
189 | + ], | ||
190 | + "isShow": "YES", | ||
191 | + "title": "标题内容" | ||
192 | + }, | ||
193 | + "template_id": 1111255, | ||
194 | + "template_name": "getCoupon" | ||
195 | + }, | ||
196 | + { | ||
197 | + "data": { | ||
198 | + "list": [ | ||
199 | + { | ||
200 | + "couponID": "200", | ||
201 | + "status": 3, | ||
202 | + "goShopping": "http://item.m.yohobuy.com/product/pro_325933_419711/XiongJiaYouPin619081838990XiongJiaYouPinChuangYiLanRenTanZhuTuiKuan.html", | ||
203 | + "image": { | ||
204 | + "src": "http://img12.static.yhbimg.com/yhb-img01/2016/01/19/01/02f639de49d79ece0cf86a2f214be781da.jpg?imageView/{mode}/w/{width}/h/{height}", | ||
205 | + "url": "http://2percent.yohobuy.com/?gender=2,3\n" | ||
206 | + }, | ||
207 | + } | ||
208 | + ], | ||
209 | + "isShow": "YES", | ||
210 | + "title": "标题内容" | ||
211 | + }, | ||
212 | + "template_id": 1111257, | ||
213 | + "template_name": "getCoupon" | ||
214 | + } | ||
215 | + ], | ||
216 | + "md5": "8febf00780011298f4a0530b6441827b", | ||
217 | + "message": "请求成功" | ||
218 | +} | ||
219 | + | ||
220 | +备注:status 1:可领取 2:已抢光 3:已领取 | ||
221 | + | ||
222 | +``` | ||
223 | + | ||
224 | +### 5、用户批量领券(app.promotion.getBatchCoupon) | ||
225 | + | ||
226 | +#### 请求参数 | ||
227 | +| Param Name | Param Type | Required | Param Value | Desc | | ||
228 | +| :-- | --: | --: | --: | --: | | ||
229 | +| method | String | true |app.promotion.getCoupon| 请求方法| | ||
230 | +| uid | String | true | 7893817 |用户ID | | ||
231 | +| couponIds | int | true |23121,45231 |券id列表| | ||
232 | + | ||
233 | + | ||
234 | +#### 响应内容 | ||
235 | +```json | ||
236 | +成功响应: | ||
237 | +{ | ||
238 | + "alg": "SALT_MD5", | ||
239 | + "code": 200, | ||
240 | + "data": { | ||
152 | }, | 241 | }, |
153 | "md5": "50d19f5f5098c34607018f144baec14a", | 242 | "md5": "50d19f5f5098c34607018f144baec14a", |
154 | "message": "操作成功" | 243 | "message": "操作成功" |
155 | } | 244 | } |
156 | 245 | ||
157 | -备注:status 1:可领取 2:已抢光 3:已领取 | 246 | +错误响应: |
247 | +{ | ||
248 | + "code": 402, | ||
249 | + "message": "优惠券不存在" | ||
250 | +} | ||
251 | + | ||
252 | +{ | ||
253 | + "code": 306, | ||
254 | + "message": "很抱歉!您的用户身份类型不可使用该券" | ||
255 | +} | ||
256 | + | ||
257 | +{ | ||
258 | + "code": 401, | ||
259 | + "message": "优惠券已经领取" | ||
260 | +} | ||
158 | 261 | ||
159 | ``` | 262 | ``` |
160 | 263 |
-
Please register or login to post a comment