1. 通用
1.2 通用统计
http://test.cheshen.cn/public/statistic.htm
参数:
type_id: 操作类型
1,//百科点击
2,//百科分享 todo
5,//广告点击
10,//自媒体文章点击
11,//自媒体文章分享 todo
15,//自媒体点击
16,//自媒体分享
20,//页面分享
30,//文章点赞
40,//自媒体活动点击
41,//自媒体活动分享
ta_id: 被收藏/分享的对象id
id: 点击/赞的对象id
title: 分享-title
link: 分享-link
imgUrl: 分享-imgUrl
source_url: 分享-source_url
share_type: 分享类型:1.朋友圈;2.朋友;3.qq;4.微博;5.qq空间
返回:
{
"status": 200,
"msg": "success",
"data": []
}
2. 自媒体文章
2.2 获取文章评论
http://test.cheshen.cn/media/articleComment.htm
参数:
id: 文章id
sort: 排序方式
time:时间,默认方式
likes:点赞数
page_index:page_index
返回:
{
"status": 200,
"msg": "success",
"data": {
"list": [
{
"id": "10",
"art_id": "42",
"uid": "1",
"nickname": "[啤酒]ifhaveif[闪电]呀",
"avatar": "",
"title": "这是一单图的文章,好看成吗?不要删除!!!a+b 'xxx'",
"content": "aaaabbbbxx'xx",
"reply_id": "5",
"reply_uid": "1",
"reply_nickname": "[啤酒]ifhaveif[闪电]呀",
"reply_content": "xx'xx",
"status": "3",
"likes": "0", //点赞数
"created": "1466412898",
"is_like": false //是否已点赞
}
],
"hasNext": true, //是否有下一页
"pageSize": 2,
"pageIndex": 1
}
}
3. 自媒体活动
3.2 获取评论
http://test.cheshen.cn/act/comment.htm
参数:
id: 文章id
sort: 排序方式
time:时间,默认方式
likes:点赞数
page_index:page_index
返回:
{
"status": 200,
"msg": "success",
"data": {
"list": [
{
"id": "10",
"art_id": "42",
"uid": "1",
"nickname": "[啤酒]ifhaveif[闪电]呀",
"avatar": "",
"title": "这是一单图的文章,好看成吗?不要删除!!!a+b 'xxx'",
"content": "aaaabbbbxx'xx",
"reply_id": "5",
"reply_uid": "1",
"reply_nickname": "[啤酒]ifhaveif[闪电]呀",
"reply_content": "xx'xx",
"status": "3",
"likes": "0", //点赞数
"created": "1466412898",
"is_like": false //是否已点赞
}
],
"hasNext": true, //是否有下一页
"pageSize": 2,
"pageIndex": 1
}
}
9. 我
9.2 我的消息
http://test.cheshen.cn/my/message.htm
参数:
无
返回:参考链接
http://test.cheshen.cn/my/message.htm?debug=1
"list": [
{
"id": "4",
"uid": "1",
"ta_id": "42", //文章/活动Id
"ta_id2": "5", //评论id
"ta_uid": "1",
"ta_nickname": "[啤酒]ifhaveif[闪电]呀",
"ta_avatar": "",
"ta_content": "xx'xx",
"ta_reply_content": "xxxx",
"type": "2", //类型:100.系统消息;1.文章评论;2.文章评论被回复;3.文章评论被点赞;4.活动评论;5.活动评论被回复;6.活动评论被点赞
"created": "1466412898"
}
],
"hasNext": true
10. 游戏
10.1 获取登录用户及游戏信息
http://test.cheshen.cn/event/game/index.htm
参数:
invite_code_from: 页面地址中的邀请码,可为空
返回:
{
"status": 200,
"msg": "success",
"data": {
"is_first_play": false, //是否第一次玩游戏
"is_first_visit": false, //是否第一次访问这个链接
"my": { //登录者信息
"id": "4",
"uid": "1",
"invite_code_my": "zTq90K", //邀请码
"coin_total": "310", //金币数
"nickname": "13719100871",
"avatar": "http://pic.cheshen.cn/imgs/88818c2b257887b573637b095b0352d8.png"
},
"ta": { //邀请者信息,当invite_code_from不存在时,返回空数组
"id": "4",
"uid": "1",
"invite_code_my": "zTq90K",
"coin_total": "310",
"nickname": "13719100871",
"avatar": "http://pic.cheshen.cn/imgs/88818c2b257887b573637b095b0352d8.png"
},
"sign": { //微信分享需要的
"appId": "wxf57faee7db902aac",
"nonceStr": "3v3vfUgyZWyOKBrM",
"timestamp": 1460614087,
"url": "http://wx.cs.cn/event/game/index.htm?invite_code_from=bbbbbbbb",
"signature": "b43434284a71378d6cfbd39ac4078bf45bcebd5b",
"rawString": "jsapi_ticket=bxLdikRXVbTPdHSM05e5u7H3MWRimQrnJLZxae3JjnYOmhAK7tGEseqPIpRDFfs5x1G-yssMpFL8gnc85T47jA&noncestr=3v3vfUgyZWyOKBrM×tamp=1460614087&url=http://wx.cs.cn/event/game/index.htm?invite_code_from=bbbbbbbb"
},
"list": [ //用户列表
{
"id": "4",
"uid": "1",
"coin_total": "310",
"nickname": "13719100871",
"avatar": "http://pic.cheshen.cn/imgs/88818c2b257887b573637b095b0352d8.png"
}
]
}
}
10.3 排行榜
http://test.cheshen.cn/event/game/rank.htm
参数:
无
返回:
{
"status": 200,
"msg": "success",
"data": {
"total": 4, //总数
"ranking": 4, //我的排名
"list": [ //列表
{
"id": "5",
"uid": "1",
"coin_total": "1",
"nickname": "13719100871",
"avatar": "http://pic.cheshen.cn/imgs/bc21b0c23a5ca48c1da187890d234af3.png"
}
]
}
}