返回指定章节的Detail数据。该API将取代 Bundle: chapterDetail 接口。该接口的使用方法与旧接口相同,只是针对性优化旧接口的数据冗余问题。
Request
HTTP request
GET https://www.featapi.com/api/dimzou/bundle/{id}/node-detail/
Parameters
- Path parameters
| Parameter name | Value | Description |
|---|---|---|
| id | string | Bundle(book) ID |
- Query parameters
| Parameter name | Value | Description |
|---|---|---|
| Optional parameters | ||
| node | string | 章节id,不提交则返回第一个章节 |
| invitation | string | 未登录用户通过提交邀请码阅读“私有权限的书”invitation code, Dimzou.Invitation |
授权
此请求需要具有以下所有范围的授权:
| Scopes |
|---|
| dimzou_bundle |
有关更多信息,请参阅认证和授权页面。
Response
如果成功,则此方法在响应正文中返回 Dimzou.node 资源。
200 成功返回
| Parameter name | Value | Description |
|---|---|---|
| id | integer | Node id,即章节ID |
| bundle_id | integer | Bundle id,即文章ID |
| type | integer | 章节类型,0为普通章节,100为封面章节 |
| sort | integer | 章节序号 |
| last_modified | datetime | 最后修改时间 |
| create_time | datetime | 创建时间 |
| status | integer | 章节状态,0为草稿状态,100为已出版状态 |
| manuscript | string | 章节腹稿,用来描述章节中的段落结构以及段落概要 |
| visibility | boolean | |
| permission | integer | 章节访问权限,0为公开访问,100为仅限协作者可以访问 |
| template_config | json | 章节模版 |
| publish_time | datetime | 出版时间 |
| section | json | |
| user_id | integer | 章节创建者的用户UID |
| collaborators | array[Collaborator] | 章节的协作者数据列表,详情请查看 Dimzou.Collaborator |
| node_words | integer | 章节的已通过审核并当前选取内容的总字数(字符串长度) |
| node_paragraphs_count | integer | 章节的总段落数量(Paragraph) |
| rewords_count | integer | 章节的总修改内容数量(Reword) |
{
"data": {
"id": 1754,
"bundle_id": 1660,
"type": 0,
"sort": 1,
"last_modified": "2020-07-13T01:42:29",
"create_time": "2020-04-28T08:07:27",
"status": 0,
"manuscript": null,
"visibility": true,
"permission": 0,
"template_config": {
"cover_template": "I",
"chapter_template": "I"
},
"publish_time": null,
"section": {
"all_paragraphs": {},
"title_paragraphs": {}
},
"user_id": 5215999252276,
"collaborators": [
{
"id": 886,
"bundle_id": 1660,
"node_id": 1754,
"role": 0,
"created_at": "2020-04-28T08:07:27",
"joined_at": "2020-04-28T08:07:27",
"updated_at": "2020-04-30T06:45:47",
"contributing_words": 2380363,
"user_id": 5215999252276
} ],
"node_words": 2380363,
"node_paragraphs_count": 31168
}
}404 Not found
示例返回数据可参考 API Common – Resource Not Found