bee-visitor-recent
版本: 2.0.1
简介
通过小蜜蜂(Bee)建站开放 API,读取取最新访客数据并生成结构化分析报告。
支持分页查询。
输入参数
api_key (string, 必填)
API 身份认证密钥,用于调用方身份识别和接口权限控制。
pagination (object, 必填)
分页设置。
current_page (integer)
- 默认值: 1
- 翻页规则:
data.pagination.has_next_page,是否存在下一页;data.pagination.next_page,下一页页码,没有下一页时为 null;
-
⚠️ 约束: 是否继续读取下一页应由用户决定,智能体不得自动翻页抓取全部数据。
page_size (integer)
输出结构
顶层字段
| 字段 | 类型 | 说明 |
|---|
| status | boolean | 请求状态,true 成功 / false 失败 |
| msg | string | 返回消息 |
| data | object | null | 返回结果数据,失败时为 null |
data.pagination
| 字段 | 类型 | 说明 |
|---|
| current_page | integer | 当前页码 |
| page_size | integer | 每页数量 |
| total_page | integer | 总页数 |
| total_count | integer | 总记录数 |
| has_next_page | boolean | 是否存在下一页 |
| next_page | integer | null | 下一页页码(无则为 null) |
data.list[](访客数据列表)
| 字段 | 类型 | 说明 |
|---|
| ip | string | 访客 IP(IPv4 / IPv6) |
| country_code | string | 国家代码(ISO 3166-1) |
| page_views | integer | 页面浏览次数 |
| first_visit | object | 首次访问记录 |
| recent_visits | array | 最近访问记录(最多 50 条) |
| first_visit_time | string | 首次访问时间(ISO 8601) |
| last_visit_time | string | 最后访问时间(ISO 8601) |
first_visit 对象
| 字段 | 类型 | 说明 |
|---|
| page | object | 首次访问页面信息 |
| screen | object | 屏幕分辨率 |
| visit_time | string | 首次访问时间 |
| referer | string | 来源 URL |
| current_url | string | 当前访问 URL |
| user_agent | string | 浏览器 User-Agent |
first_visit.page
| 字段 | 类型 | 说明 |
|---|
| id | integer | 页面 ID |
| name | string | 页面名称 |
| code | string | 页面标识 |
first_visit.screen
| 字段 | 类型 | 说明 |
|---|
| width | integer | 屏幕宽度 |
| height | integer | 屏幕高度 |
recent_visits[] 对象
| 字段 | 类型 | 说明 |
|---|
| page | object | 页面信息 |
| screen | object | 屏幕分辨率 |
| visit_time | string | 访问时间 |
| referer | string | 来源 URL |
| current_url | string | 当前 URL |
| user_agent | string | 浏览器 User-Agent |
recent_visits.page
| 字段 | 类型 | 说明 |
|---|
| id | integer | 页面 ID |
| name | string | 页面名称 |
| code | string | 页面标识 |
recent_visits.screen
| 字段 | 类型 | 说明 |
|---|
| width | integer | 宽度 |
| height | integer | 高度 |
注意事项
- data 可能为 null(失败时)
- recent_visits 最多 50 条
- 所有时间字段均为 ISO 8601
- next_page 仅在 has_next_page=true 时有效
- 是否继续分页由调用方决定