获取单页列表接口

API 调用地址

{域名地址}/api/page/list

说明:{域名地址} 需要替换成你的域名地址,如 https://www.anqicms.com/api/page/list

调用方法

GET

请求参数

返回参数

字段名 类型 说明
code int 错误码
msg string 错误原因说明
data object[] 结果内容

data 结果 item 参数

字段名 类型 说明
id int 单页 ID
title string 单页名称
seo_title string 单页 SEO 标题
url_token string 单页 URL 别名
keywords string 单页关键词
description string 单页简介
content string 单页内容详情
type int 单页属性值,1 单页,3 单页面
sort int 单页排序值
images string[] 单页 Banner 图
logo string 单页缩略图
thumb string 单页缩略图
created_time int 单页发布时间戳
updated_time int 单页更新时间戳
status int 单页显示状态

请求数据示例

返回数据示例

{
  "code": 0,
  "data": [
    {
      "id": 1,
      "created_time": 1607308159,
      "updated_time": 1657761249,
      "title": "关于AnqiCMS",
      "seo_title": "",
      "keywords": "",
      "url_token": "help",
      "description": "",
      "content": "<p><br/></p>",
      "type": 3,
      "sort": 1,
      "images": [],
      "logo": "",
      "status": 1,
      "thumb": "https://www.anqicms.com/uploads/202012/7/bd36c37ef742c7be.webp"
    },
    {
      "id": 2,
      "created_time": 1607308159,
      "updated_time": 1657761249,
      "title": "联系AnqiCMS",
      "seo_title": "",
      "keywords": "",
      "url_token": "help",
      "description": "",
      "content": "<p><br/></p>",
      "type": 3,
      "sort": 1,
      "images": [],
      "logo": "",
      "status": 1,
      "thumb": "https://www.anqicms.com/uploads/202012/7/bd36c37ef742c7be.webp"
    }
  ],
  "msg": ""
}

错误代码

错误码 说明
0 OK
-1 错误,错误原因在 msg 中指出
1001 未登录
1002 未授权
200 API 请求 OK