接口地址:<gateway>?app=article&controller=article&action=get
接受参数:
参数 |
名称 |
传递类型 |
值类型 |
备注 |
contentid |
内容编号 |
GET |
整型 |
必须传递,读取该编号的具体内容 |
返回数据:
{
"state": true,
"data": {
"contentid": "172",
"catid": "7",
"modelid": "1",
"title": "\u6211\u662f\u6765\u6d4b2\u8bd5API\u76844",
"subtitle": "",
"color": "",
"thumb": "",
"tags": "\u6d4b\u8bd5 API",
"sourceid": "1",
"topicid": null,
"url": "http:\/\/ent.cmstop.dev\/2012\/0712\/172.shtml",
"weight": "60",
"status": "6",
"created": "1341819663",
"createdby": "2",
"published": "1342062317",
"publishedby": "2",
"iscontribute": "0",
"spaceid": "1",
"related": "1",
"pv": 1,
"allowcomment": "0",
"comments": "0",
"score": "0",
"tweeted": "0",
"author": "coldstar",
"editor": "coldstar",
"description": "\u6211\u53ea\u662f\u6d4b\u8bd5\u4e00\u4e0b",
"content": "<p>\u8fd9\u91cc\u662f\u6d4b2\u8bd5\u7684\u5185\u5bb9api<\/p>",
"pagecount": "0",
"saveremoteimage": "1",
"source_url": "",
"source_name": "\u65b0\u6d6a",
"source": "\u65b0\u6d6a",
"source_logo": null,
"keywords": [{
"tag": "\u6d4b\u8bd5",
"url": "http:\/\/app.cmstop.dev\/tags.php?tag=%E6%B5%8B%E8%AF%95"
}, {
"tag": "API",
"url": "http:\/\/app.cmstop.dev\/tags.php?tag=API"
}],
"proids": "3",
"relateds": [{
"relatedid": "4",
"contentid": "172",
"orign_contentid": "175",
"title": "\u6211\u662f\u6765\u6d4b2\u8bd5API\u76844",
"thumb": "null",
"url": "http:\/\/ent.cmstop.dev\/2012\/0709\/175.shtml",
"time": "2012-07-09",
"sort": "0"
}, {
"relatedid": "5",
"contentid": "172",
"orign_contentid": "150",
"title": "\u300a\u98de\u8d8a\u8001\u4eba\u9662\u300b\u66dd\u4e3b\u6d77\u62a5 \u8001\u4eba\u5e2e\u96c6\u7ed3\u6b32\u5f00\u6218",
"thumb": "",
"url": "http:\/\/news.cmstop.dev\/2012\/0411\/150.shtml",
"time": "2012-04-11",
"sort": "1"
}],
"author_url": "http:\/\/space.cmstop.dev\/coldstar",
"author_name": "coldstar"
}
}
返回字段说明:
参数 |
名称 |
备注 |
contentid |
内容编号 |
|
catid |
栏目编号 |
|
modelid |
模型编号 |
|
title |
标题 |
|
subtitle |
副标题 |
|
color |
标题颜色 |
#XXXXXX 6位的标准HTML颜色代码 |
thumb |
缩略图 |
|
tags |
标签 |
多个标签以空格隔开 |
sourceid |
来源编号 |
|
topicid |
评论话题编号 |
用来调用评论时使用 |
url |
内容链接 |
|
weight |
权重 |
|
status |
状态 |
这里的状态永远为6,只允许列出已发布的文章 |
created |
创建时间 |
|
createdby |
创建人编号 |
|
published |
发布时间 |
|
publishedby |
发布人编号 |
|
iscontribute |
是否来自投稿 |
|
spaceid |
所属专栏编号 |
|
related |
是否有相关内容 |
0 无相关内容,1 有相关内容, 相关内容在relateds字段中以二维数组方式输出 |
pv |
浏览量 |
|
allowcomment |
是否允许评论 |
|
comments |
评论数 |
|
score |
评分 |
|
tweeted |
是否已被转发 |
如果该内容已被转发微薄,则为1,否则为0 |
author |
作者名称 |
|
editor |
编辑名称 |
|
description |
内容描述 |
|
content |
内容 |
|
pagecount |
分页数量 |
|
source_url |
来源地址 |
|
source_name |
来源名称 |
|
source |
来源名称 |
|
source_logo |
来源LOGO |
URL地址 |
keywords |
关键词列表 |
该内容是二维数组,字段参考: keywords数据说明 |
proids |
属性编号 |
多个属性以英文逗号(,)隔开 |
relateds |
相关内容列表 |
该内容是二维数据,字段参考: relateds数据说明 |
author_url |
专栏作者地址 |
|
author_name |
专栏作者名称 |
|
keyword数据说明:
tag |
关键词名称 |
|
url |
关键词链接 |
|
relateds数据说明:
relatedid |
相关内容编号 |
|
contentid |
内容编号 |
|
orign_contentid |
原始内容编号 |
|
title |
标题 |
|
thumb |
缩略图 |
|
url |
链接地址 |
|
time |
内容发布时间 |
|
sort |
相关排序 |
|