Api Spider Article
目录
文章管理接口文档
接口列表
| 接口名称 | 方法 | 路径 | 说明 |
|---|---|---|---|
| 获取选择列表 | POST | /Spider/Article/selectlist | 获取来源、分类、类型列表 |
| 添加文章 | POST | /Spider/Article/addarticle | 添加新文章 |
| 文章列表 | POST | /Spider/Article/articlelist | 获取文章列表(支持搜索筛选) |
| 文章详情 | POST | /Spider/Article/articleinfo | 获取文章详情 |
| 编辑文章 | POST | /Spider/Article/editarticle | 编辑文章信息 |
| 删除文章 | POST | /Spider/Article/delarticle | 删除文章(软删除) |
1. 获取选择列表
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| outputformat | int | 否 | 输出格式,默认2 |
请求示例
{
"uid": "Mbg9O0O0O1O0O0Ob",
"token": "AD465432DF65245204F4B97044950389",
"json": 1,
"outputformat": 2,
"pid": 1,
"appid": 1
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": {
"source_list": [
{
"id": 1,
"name": "Bloomberg Original"
},
{
"id": 2,
"name": "Bloomberg TV markets"
},
{
"id": 3,
"name": "Bloomberg Technology"
},
{
"id": 4,
"name": "Podcast"
},
{
"id": 5,
"name": "Bloomberg Live"
}
],
"tag_list": [
{
"id": 1,
"name": "人物"
},
{
"id": 2,
"name": "事件"
},
{
"id": 3,
"name": "热点"
},
{
"id": 4,
"name": "创新"
}
],
"type_list": [
{
"id": 4,
"name": "视频"
}
]
}
}2. 添加文章
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| title_en | string | 是 | 英文标题 |
| title_zh | string | 是 | 中文标题 |
| source_id | int | 是 | 来源ID |
| tag_id | int | 是 | 分类ID |
| type_id | int | 是 | 类型ID(1:文本 2:图片 3:音频 4:视频) |
| url | string | 是 | 文章URL |
| boss_select | int | 否 | 是否精选(0:否 1:是),默认0 |
| outputformat | int | 否 | 输出格式,默认2 |
请求示例
{
"uid": "Mbg9O0O0O1O0O0Ob",
"token": "AD465432DF65245204F4B97044950389",
"json": 1,
"outputformat": 2,
"pid": 1,
"appid": 1,
"title_en":"The 'relationship 'between knowledge and action is a core proposition in the history of Chinese philosophy, and the Song and Ming periods represent a crucial stage for the development of the theory of knowledge and action.",
"title_zh":"你好,全世界。",
"source_id":1,
"url":"http://wwww.dssddds.cn",
"tag_id":1,
"type_id":4,
"boss_select":1
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": 13
}返回码
| 返回码 | 说明 |
|---|---|
| 0 | 添加成功 |
| 80001 | 添加失败 |
3. 文章列表
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| page | int | 否 | 页码,默认1 |
| page_size | int | 否 | 每页数量,默认10 |
| title | string | 否 | 标题搜索(模糊匹配中英文) |
| source_id | int | 否 | 来源ID筛选 |
| tag_id | int | 否 | 分类ID筛选 |
| type_id | int | 否 | 类型ID筛选 |
| boss_select | string | 否 | 精选筛选(“0"或"1”) |
| create_time | string | 否 | 创建时间筛选(日期格式) |
| outputformat | int | 否 | 输出格式,默认2 |
请求示例
{
"uid": "Mbg9O0O0O1O0O0Ob",
"token": "AD465432DF65245204F4B97044950389",
"json": 1,
"outputformat": 2,
"pid": 1,
"appid": 1,
"title_en":"The relationship 'between knowledge action is a core proposition in the history of Chinese philosophy, and the Song and Ming periods represent a crucial stage for the development of the theory of knowledge and action.",
"title_zh":"2112112",
"source_id":1,
"tag_id":1,
"type_id":4,
"boss_select":1,
"create_time":"2026-06-11"
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": {
"list": [
{
"id": 5,
"app_id": 1,
"create_time": 1781168381,
"update_time": 1781168381,
"is_del": 0,
"url": "http://wwww.dssddds.cn",
"spider_tag_id": 1,
"spider_source_id": 1,
"title_en": "new for ibloom",
"title_zh": "商业周刊新闻",
"type": 4,
"spider_status": 0,
"boss_select": 1,
"view_num": 0,
"publish_time": 0,
"create_account":"geluli",
"update_account":"geluli"
}
],
"count": 1
}
}返回码
| 返回码 | 说明 |
|---|---|
| 0 | 获取成功 |
| 20018 | 暂无数据 |
4. 文章详情
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| id | int | 是 | 文章ID |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| outputformat | int | 否 | 输出格式,默认2 |
请求示例
{
"uid": "Mbz9Q1O0O0Ob",
"token": "928CC0AD9C0D38E56F877A647C7F2CDE",
"json": 1,
"outputformat": 2,
"pid": "156",
"id": 13
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": {
"id": 13,
"app_id": 1,
"create_time": "2026-06-12 02:41:44",
"update_time": "2026-06-12 02:41:44",
"is_del": 0,
"url": "http://wwww.dssddds.cn",
"spider_tag_id": 1,
"spider_source_id": 1,
"title_en": "The 'relationship 'between knowledge and action is a core proposition in the history of Chinese philosophy, and the Song and Ming periods represent a crucial stage for the development of the theory of knowledge and action.",
"title_zh": "你好,全世界。",
"type": 4,
"spider_status": 0,
"boss_select": 1,
"view_num": 0,
"publish_time": 0,
"source_name": "Bloomberg Original",
"tag_name": "人物",
"type_name": "视频",
"boss_select_name": "是",
"create_account":"geluli",
"update_account":"geluli"
}
}返回码
| 返回码 | 说明 |
|---|---|
| 0 | 获取成功 |
| 70008 | 参数错误 |
| 20018 | 文章不存在 |
5. 编辑文章
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| id | int | 是 | 文章ID |
| title_en | string | 否 | 英文标题 |
| title_zh | string | 否 | 中文标题 |
| source_id | int | 否 | 来源ID |
| tag_id | int | 否 | 分类ID |
| type_id | int | 否 | 类型ID |
| url | string | 否 | 文章URL |
| boss_select | int | 否 | 是否精选(0/1) |
| outputformat | int | 否 | 输出格式,默认2 |
注:至少传一个需要更新的字段
请求示例
{
"uid": "Mbg9O0O0O1O0O0Ob",
"token": "AD465432DF65245204F4B97044950389",
"json": 1,
"outputformat": 2,
"pid": 1,
"appid": 1,
"id": 1,
"title_en":"The and the Song and Ming periods represent a crucial stage for the development of the theory of knowledge and action.",
"title_zh":"你好,晚安安",
"source_id":1,
"url":"http://wwww.dssddds.cn",
"tag_id":1,
"type_id":4,
"boss_select":1
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": 1
}返回码
| 返回码 | 说明 |
|---|---|
| 0 | 编辑成功 |
| 70008 | 参数错误 |
| 20018 | 文章不存在 |
| 80003 | 编辑失败 |
6. 删除文章
请求参数
| 参数 | 类型 | 必填 | 说明 |
|---|---|---|---|
| appid | int | 否 | 应用ID,默认1 |
| pid | int | 否 | 模块ID,默认1 |
| uid | string | 是 | 用户id |
| token | string | 是 | 用户登录token |
| json | int | 否 | 输入格式,默认1 |
| id | int | 是 | 文章ID |
| outputformat | int | 否 | 输出格式,默认2 |
请求示例
{
"uid": "Mbz9Q1O0O0Ob",
"token": "928CC0AD9C0D38E56F877A647C7F2CDE",
"json": 1,
"outputformat": 2,
"pid": "156",
"id": 13
}返回示例
{
"error": {
"code": 0,
"msg": "成功"
},
"data": 1
}返回码
| 返回码 | 说明 |
|---|---|
| 0 | 删除成功 |
| 70008 | 参数错误 |
| 20018 | 文章不存在 |
| 80003 | 删除失败 |
通用返回码说明
| 返回码 | 说明 |
|---|---|
| 0 | 成功 |
| 70008 | 参数错误 |
| 20018 | 数据不存在 |
| 80001 | 操作失败 |
| 80003 | 更新/删除失败 |