API Call Address
{域名地址}/api/archive/detail
Description:{域名地址}Need to replace it with your domain address, such ashttps://en.anqicms.com/api/archive/detail
Calling method
GET
Request parameters
| Field name |
Type |
Required |
Description |
| id |
int |
Yes |
Document ID, if filename is passed, ID is not required |
| filename |
string |
No |
Document URL alias, either document ID or filename is optional |
Return parameters
| Field name |
Type |
Description |
| code |
int |
error code |
| msg |
string |
error reason description |
| data |
object |
result content |
data parameter
| Field name |
Type |
Description |
| id |
int |
Document ID |
| title |
string |
Document Title |
| seo_title |
string |
Document SEO Title |
| url_token |
string |
Document URL Alias |
| Keywords |
string |
Document Keywords |
| Description |
string |
Document Summary |
| module_id |
int |
Document Model ID |
| category_id |
int |
Document Category ID |
| Views |
int |
Document Views |
| Comment Count |
int |
Document comments count |
| images |
string[] |
Document group image |
| Logo |
string |
Document Logo |
| Thumb |
string |
Document thumbnail |
| flag |
string |
Document recommendation attributes, headline [h] recommended [c] featured [f] special [a] scrolling [s] bold [h] image [p] jump [j] |
| canonical_url |
string |
canonical url |
| fixed_link |
string |
document fixed link |
| Created Time |
int |
document publish timestamp |
| updated_time |
int |
Document update timestamp |
| status |
int |
Document display status |
| user_id |
int |
User ID |
| price |
int |
Price, unit in cents |
| stock |
int |
Inventory quantity |
| user_id |
int |
User ID |
| category |
object |
Document category information |
| data |
object |
Document content information |
| extra |
object |
Additional document fields information |
category Document category information
| Field name |
Type |
Description |
| id |
int |
Category ID |
| parent_id |
int |
Category parent ID |
| title |
string |
Category name |
| seo_title |
string |
Category SEO title |
| url_token |
string |
Category URL alias |
| Keywords |
string |
Category Keywords |
| Description |
string |
Category description |
| module_id |
int |
Model ID |
| content |
string |
Category content details |
| type |
int |
Category Attributes, 1 Category, 3 Single Page |
| Sort |
int |
Category Sorting Value |
| images |
string[] |
Category Banner Image |
| Logo |
string |
Category Thumbnail |
| Thumb |
string |
Category Thumbnail |
| Created Time |
int |
document publish timestamp |
| updated_time |
int |
Document update timestamp |
| status |
int |
Document display status |
data Document content information
| Field name |
Type |
Description |
| id |
int |
Category ID |
| content |
string |
Document content details |
extra documentation other field information
extra Based on the model settings, the field structure is key => item:
key is the form field name, item is the content:
| Field name |
Type |
Description |
| name |
string |
Field Name |
| Value |
string |
The entered value |
| Default |
string |
Default Value |
request data example
Return Data Example
{
"code": 0,
"data": {
"id": 1,
"created_time": 1607308159,
"updated_time": 1662717106,
"title": "欢迎使用AnqiCMS",
"seo_title": "",
"url_token": "anqicms",
"keywords": "",
"description": "欢迎使用AnqiCMS",
"module_id": 1,
"category_id": 1,
"views": 1338,
"comment_count": 0,
"images": null,
"status": 1,
"canonical_url": "",
"fixed_link": "",
"flag": "",
"user_id": 0,
"price": 0,
"stock": 9999999,
"category": {
"id": 1,
"created_time": 1607308159,
"updated_time": 1657761249,
"title": "AnqiCMS帮助",
"seo_title": "",
"keywords": "",
"url_token": "goruning",
"description": "",
"content": "<p>欢迎使用AnqiCMS</p>",
"module_id": 1,
"parent_id": 0,
"type": 1,
"sort": 1,
"images": [],
"logo": "https://en.anqicms.com/uploads/202012/7/bd36c37ef742c7be.webp",
"status": 1,
"thumb": "https://en.anqicms.com/uploads/202012/7/thumb_bd36c37ef742c7be.webp"
},
"data": {
"id": 1,
"content": "<p>欢迎使用AnqiCMS</p>"
},
"logo": "https://en.anqicms.com/uploads/202012/7/bd36c37ef742c7be.webp",
"thumb": "https://en.anqicms.com/uploads/202012/7/thumb_bd36c37ef742c7be.webp",
"extra": {
"author": {
"name": "作者",
"value": "AnqiCMS",
"default": ""
}
},
"link": ""
},
"msg": ""
}
Error Code
| error code |
Description |
| 0 |
OK |
| -1 |
Error, the reason is indicated in the msg |
| 1001 |
Not logged in |
| 1002 |
Unauthorized |
| 200 |
API request OK |