Get tag document list interface

API call address

{域名地址}/api/tag/data/list

illustrate:{域名地址}You need to replace it with your domain address, such as/api/tag/data/list

Calling methods

GET

Request parameters

Field name type Required illustrate
id int yes Tag ID, if filename is passed, you don't need to pass the ID
filename string no Tag URL alias, tag ID and filename choose one
Order string no Sort by:id desc, supported fields are:id,views,category_id,created_time,updated_timewait
type int no Support buttonpage,list,relatedList method. The default value islist, when type="list", only the specified limit specified number will be displayed. If type="page" is used, the number of documents can be obtained.
page int no Specify which page content to get, only effective when type="page"
limit int no To display quantity, limit can specify the display quantity and paging according to the number. For example, limit="10" will only display 10 pieces. When limit is not a paging list, it supports offset mode, that is, separating mode. If you want to obtain 10 pieces of data from item 2, you can set it to limit="2,10".

Return parameters

Field name type illustrate
code int Error code
msg string Error Cause Description
data object[] Results content
Total int The number of documents will be returned only if type=page

data result item parameter

Field name type illustrate
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 Introduction
module_id int Document model ID
category_id int Document Classification ID
views int Document view count
comment_count int Document comments
images string[] Document group photo
logo string Document Logo
thumb string Document thumbnails
flag string Document recommendation attributes, headlines[h]recommended[c]slide[f]special recommendation[a]scroll[s]bold[h]pics[p]jump[j]
canonical_url string canonical url
fixed_link string Document Permalink
created_time int Document release timestamp
updated_time int Document update timestamp
status int Document display status
user_id int User ID
price int Price, unit points
stock int Inventory quantity
user_id int User ID

Request data example

parameter value
id 1
type page

Return to the data example

{
    "code": 0,
    "data": [
        {
            "id": 1,
            "created_time": 1607308159,
            "updated_time": 1662717106,
            "title": "关于AnqiCMS",
            "seo_title": "",
            "url_token": "design",
            "keywords": "",
            "description": "安企内容管理系统(AnqiCMS),是一款使用 GoLang 开发的企业站内容管理系统,它部署简单,软件安全,界面优雅,小巧,执行速度飞快,使用 AnqiCMS 搭建的网站可以防止众多安全问题发生。",
            "module_id": 1,
            "category_id": 1,
            "views": 1338,
            "comment_count": 0,
            "images": null,
            "template": "",
            "status": 1,
            "canonical_url": "",
            "fixed_link": "",
            "flag": "",
            "user_id": 0,
            "price": 0,
            "stock": 9999999,
            "has_pseudo": 0,
            "keyword_id": 0,
            "origin_url": "",
            "origin_title": "",
            "category": null,
            "module_name": "",
            "data": null,
            "logo": "/uploads/202012/7/bd36c37ef742c7be.webp",
            "thumb": "/uploads/202012/7/thumb_bd36c37ef742c7be.webp",
            "extra": {
                "author": {
                    "name": "作者",
                    "value": "AnqiCMS",
                    "default": null
                },
                "certificate": {
                    "name": "学历",
                    "value": null,
                    "default": null
                },
                "city": {
                    "name": "城市",
                    "value": null,
                    "default": null
                }
            },
            "link": "/design"
        },
        {
            "id": 2,
            "created_time": 1607308247,
            "updated_time": 1611373941,
            "title": "AnqiCMS使用帮助",
            "seo_title": "",
            "url_token": "help",
            "keywords": "",
            "description": "anqicms常见问题汇总",
            "module_id": 1,
            "category_id": 1,
            "views": 1655,
            "comment_count": 0,
            "images": null,
            "template": "",
            "status": 1,
            "canonical_url": "",
            "fixed_link": "",
            "flag": "",
            "user_id": 0,
            "price": 0,
            "stock": 9999999,
            "has_pseudo": 0,
            "keyword_id": 0,
            "origin_url": "",
            "origin_title": "",
            "category": null,
            "module_name": "",
            "data": null,
            "logo": "/uploads/202012/7/bd36c37ef742c7be.webp",
            "thumb": "/uploads/202012/7/thumb_bd36c37ef742c7be.webp",
            "extra": null,
            "link": "/help"
        },
    ],
    "msg": "",
    "total": 2
}

Error code

Error code illustrate
0 OK
-1 Error, the cause of the error is pointed out in msg
1001 Not logged in
1002 Unauthorized
200 API request OK