Blame view

README.md 15.4 KB
8fa7cc70   aarongao   ..
1
2
3
4

## 乐游图后端接口文档
| Specification | Value |
|-----|-----|
cfcccc99   aarongao   ok
5
| API Version | 1.0.0 |
8fa7cc70   aarongao   ..
6
7
8
9
10
11
12
13
14
15
16
| BasePath | https://letu.api.imagchina.com |



### API List
1. [增加访问日志](#accesslog-post)
1. [查询所有商品](#allcommodity-get)
1. [查询所有游玩项目](#allitems-get)
1. [查询所有线路](#allline-get)
1. [所有景区基础信息](#allscenic-get)
1. [查询商品信息](#commodityinfo-get)
f56bf95d   aarongao   ..
17
1. [增加投诉](#createcomplaint-post)
8fa7cc70   aarongao   ..
18
19
20
21
1. [查询用户的定时提醒](#dealymessage-info-get)
1. [创建提醒](#dealymessage-create-post)
1. [增加调查](#investigation-save-post)
1. [查询设备信息](#iteminfo-get)
483ade81   aarongao   v1.1
22
1. [查询线路信息](#lineinfo-get)
8fa7cc70   aarongao   ..
23
24
25
26
27
28
1. [用户登录&注册](#loginuser-post)
1. [返回景区基础信息](#scenicinfo-get)
1. [发送短信验证码](#sms-send-post)
1. [标签列表](#tags-get)
1. [更新商品](#updatecommodity-post)
1. [更新设施](#updateitem-post)
483ade81   aarongao   v1.1
29
1. [更新等待时间](#updateitemtime-post)
8fa7cc70   aarongao   ..
30
31
32
33
34
35
36
37
38
1. [更新线路](#updateline-post)
1. [更新景区基础信息](#updatescenic-post)
1. [修改用户信息](#updateuser-post)
1. [上传](#upload-post)
1. [获取用户信息](#userinfo-get)



<a name="accesslog-post"></a>
8bea6075   aarongao   new
39
40
41
42
43

#### /AccessLog (POST)


增加访问日志
8fa7cc70   aarongao   ..
44
45
46
47

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| UserId | 5dfb03070a9ac17ac7a82054    | string | 用户ID | Yes |
15b2f923   aarongao   ..
48
49
| UserName | Aaron    | string | 用户名称 | Yes |
| TypeNum | 9    | int | 类型编号 | Yes |
d631c7b6   aarongao   ..
50
| TypeName | 点击个人中心    | string | 类型名称 | Yes |
8fa7cc70   aarongao   ..
51
52
53
54
55
| DateTime | 1578556751220    | int | 时间戳 | Yes |
| Location | {"Latitude": 119, "Longitude": 39}    | string | 位置 | Yes |
| Remarks | 备注    | string | 备注 | Yes |


58ec1105   aarongao   new
56
| Code | Type | Model | Message |
8fa7cc70   aarongao   ..
57
58
59
60
61
62
63
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) |  |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="allcommodity-get"></a>
483ade81   aarongao   v1.1
64

8fa7cc70   aarongao   ..
65
66
#### /AllCommodity (GET)

cfcccc99   aarongao   ok
67

8fa7cc70   aarongao   ..
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
查询所有商品

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Price=价格;ShopName=店铺名称;KvPhoto用于列表页的图片;TopPhoto详情页最上面的轮播图;Images详情页下面的产品详细图 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="allitems-get"></a>

#### /AllItems (GET)


查询所有游玩项目

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Tags所属标签,标签有分类;LimitHeight限高;PlayDuration游玩时长;SceneTime场次时间;Picture照片;Voice音频;AverageConsumption平均消费;Menu菜单 |
cfcccc99   aarongao   ok
87
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |
8fa7cc70   aarongao   ..
88
89
90
91
92
93
94
95
96
97
98
99
100



<a name="allline-get"></a>

#### /AllLine (GET)


查询所有线路

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Name名称;SubName副标题;PlayDuration游玩时长;Suitable适合人群;Location线路点坐标;Annotations需要点亮的设施id;Distance距离 |
58ec1105   aarongao   new
101
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |
8fa7cc70   aarongao   ..
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144



<a name="allscenic-get"></a>

#### /AllScenic (GET)


所有景区基础信息

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) |  |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="commodityinfo-get"></a>

#### /CommodityInfo (GET)


查询商品信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | 5dfb03070a9ac17ac7a82054    | string | id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Price=价格;ShopName=店铺名称;KvPhoto用于列表页的图片;TopPhoto详情页最上面的轮播图;Images详情页下面的产品详细图 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="createcomplaint-post"></a>

#### /CreateComplaint (POST)


增加投诉

cfcccc99   aarongao   ok
145
| Param Name | Example | Data Type | Description | Required? |
8fa7cc70   aarongao   ..
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
|-----|-----|-----|-----|-----|
| mobile | 18616619599    | string | 联系电话 | Yes |
| type | 1    | string | 类型 | Yes |
| content | 卫生不干净    | string | 投诉内容 | Yes |
| image | ["http://www.xx.com/123.jpg","http://www.xx.com/123.jpg"]    | string | 照片数组 | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"ok"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="dealymessage-info-get"></a>

#### /DealyMessage/Info (GET)


查询用户的定时提醒

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| UserId | 5dfb03070a9ac17ac7a82054    | string | 用户id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | DelayTime=执行时间;Type=类型(0请求url地址1发送app通知);Fail失败次数;Title=通知标题;Content=通知内容;UDID=设备id |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |


<a name="dealymessage-create-post"></a>

#### /DealyMessage/Create (POST)


创建提醒
f56bf95d   aarongao   ..
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| UserId | 5dfb03070a9ac17ac7a82054    | string | 用户id | Yes |
| UDID | 5dfb03070a9ac17ac7a82054    | string | 设备id | Yes |
| Title | 表演时间提醒    | string | 标题 | Yes |
| Content | 5分钟后有表演    | string | 内容 | Yes |
| DelayTime | 1579066863    | string | 到达这个时间戳就执行 | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"ok"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="investigation-save-post"></a>

#### /Investigation/Save (POST)
8fa7cc70   aarongao   ..
204
205
206
207
208
209
210


增加调查

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| UserId | 1111111    | string | UserId | Yes |
483ade81   aarongao   v1.1
211
212
213
214
215
| Mobile | 18616619599    | string | 联系电话 | Yes |
| type | 1    | string | 类型 | Yes |


| Code | Type | Model | Message |
8fa7cc70   aarongao   ..
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"ok"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="iteminfo-get"></a>

#### /ItemInfo (GET)


查询设备信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | 5dfb03070a9ac17ac7a82054    | string | 设备id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":{"Name":"名称","Describe":"介绍","OpenHours":"开放时间","Mobile":"电话","Address":"地址","SLocation":{"Latitude":0,"Longitude":0},"Picture":["照片1","照片2"]}} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="lineinfo-get"></a>

#### /LineInfo (GET)


查询线路信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | 5dfb03070a9ac17ac7a82054    | string | id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Name名称;SubName副标题;PlayDuration游玩时长;Suitable适合人群;Location线路点坐标;Annotations需要点亮的设施id;Distance距离 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="loginuser-post"></a>

#### /LoginUser (POST)


用户登录&注册

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| mobile | aaron    | string | 手机号 | Yes |
f56bf95d   aarongao   ..
270
| password | 1    | string | 密码或验证码(使用验证码的新手机号自动注册) | Yes |
8fa7cc70   aarongao   ..
271
272
273
274
275
276
277
278
279
280


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":{"Id":"5e09c64c1c09c6f0f7ca2fa9","Token":"640bf934e425aba5d3c90998b2641f2f0ca07261d334d9615d1cd4790b5f34e7"}} 调用其它需要登陆的接口时携带token,有过期时间 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="scenicinfo-get"></a>
483ade81   aarongao   v1.1
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301

#### /ScenicInfo (GET)


返回景区基础信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | 5dfb03070a9ac17ac7a82054    | string | 景区id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Name名称;Describe介绍;OpenHours营业时间;Picture最上面图片;ShopAdPicture商城列表页图片;ItemScenicPicture项目场次照片;ActivityPicture活动照片;VideoList视频 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="sms-send-post"></a>

#### /Sms/Send (POST)
8fa7cc70   aarongao   ..
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334


发送短信验证码

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| Mobile | 18616619599    | string | 手机号 | Yes |
| Location | {"Latitude": 119, "Longitude": 39}    | string | 位置 | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"ok"}验证码3分钟内有效 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="tags-get"></a>

#### /Tags (GET)


标签列表

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":[{"Type":"menu","Name":"服务设施"},{"Type":"normal","Name":"不错"},{"Type":"thrilling","Name":"刺激"},{"Type":"recommend","Name":"必玩"}]} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updatecommodity-post"></a>

cfcccc99   aarongao   ok
335
#### /UpdateCommodity (POST)
8fa7cc70   aarongao   ..
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428


更新商品

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) |  |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updateitem-post"></a>

#### /UpdateItem (POST)


更新设施

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Tags所属标签,标签有分类;LimitHeight限高;PlayDuration游玩时长;SceneTime场次时间;Picture照片;Voice音频;AverageConsumption平均消费;Menu菜单 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updateitemtime-post"></a>

#### /UpdateItemTime (POST)


更新等待时间

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| item | [{"id":"5df864740a9ac17ac7a7feb8","time":"20"},{"id":"5df8660924e03417008b4567","time":"33"}]    | string | 设备列表 | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {errcode: 0, result: "ok"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updateline-post"></a>

#### /UpdateLine (POST)


更新线路

| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) |  |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updatescenic-post"></a>

#### /UpdateScenic (POST)


更新景区基础信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | 5dfb03070a9ac17ac7a82054    | string | 景区id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | Name名称;Describe介绍;OpenHours营业时间;Picture最上面图片;ShopAdPicture商城列表页图片;ItemScenicPicture项目场次照片;ActivityPicture活动照片;VideoList视频 |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="updateuser-post"></a>

#### /UpdateUser (POST)


修改用户信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| password | 1    | string | 密码 | Yes |
| confirmpassword | 1    | string | 确认密码 | Yes |
| birthday | 2010.10.10    | string | 生日 | Yes |
| fullname | aarongao    | string | 全名 | Yes |
| code | 12345678    | string | 6位验证码 | Yes |
| mobile | 18616619599    | string | 手机,同用户名 | Yes |
| openid | 12345    | string | 微信id | Yes |
483ade81   aarongao   v1.1
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"ok"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="upload-post"></a>

#### /Upload (POST)


上传

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| file | 1    | file | 文件 | Yes |


8fa7cc70   aarongao   ..
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":"图片地址"} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |



<a name="userinfo-get"></a>

#### /UserInfo (GET)


获取用户信息

| Param Name | Example | Data Type | Description | Required? |
|-----|-----|-----|-----|-----|
| id | aaron    | string | 用户id | Yes |


| Code | Type | Model | Message |
|-----|-----|-----|-----|
| 200 | object | [ResponseSeccess](#github.com.aarongao.tools.ResponseSeccess) | {"errcode":0,"result":{"Id":"5e09c64c1c09c6f0f7ca2fa9","Token":"640bf934e425aba5d3c90998b2641f2f0ca07261d334d9615d1cd4790b5f34e7"}} |
| 500 | object | [ResponseError](#github.com.aarongao.tools.ResponseError) | {"errcode":1,"errmsg":"错误原因"} |
cfcccc99   aarongao   ok

8fa7cc70   aarongao   ..

8bea6075   aarongao   new

8fa7cc70   aarongao   ..

483ade81   aarongao   v1.1

8fa7cc70   aarongao   ..

15b2f923   aarongao   ..

d631c7b6   aarongao   ..

15b2f923   aarongao   ..

d631c7b6   aarongao   ..

15b2f923   aarongao   ..

d631c7b6   aarongao   ..

15b2f923   aarongao   ..

d631c7b6   aarongao   ..

15b2f923   aarongao   ..

8fa7cc70   aarongao   ..

869149fa   aarongao   ..

8fa7cc70   aarongao   ..

58ec1105   aarongao   new

8fa7cc70   aarongao   ..

483ade81   aarongao   v1.1

8fa7cc70   aarongao   ..

cfcccc99   aarongao   ok

8fa7cc70   aarongao   ..