📅 上班状态查询 API
查询指定日期是否需要上班(数据源:商管排班多维表格)
🔒 所有 /api/* 端点都需要 X-API-Key 请求头
端点
GET /api/work-status?date=YYYY-MM-DD
Header: X-API-Key: <你的密钥>
调用示例
curl -H "X-API-Key: YOUR_KEY" \
'https://sb.blzct.win/api/work-status?date=2026-07-06'
返回示例
{
"date": "2026-07-06",
"weekday": "周一",
"found": true,
"is_work": "上班",
"type": "商管大小休",
"is_work_day": true
}
字段说明
| 字段 | 说明 |
date | 查询日期 YYYY-MM-DD |
weekday | 星期(中文) |
found | 表格是否查到记录 |
is_work | 「上班」/「休息」/「?」 |
type | 排班类型 |
is_work_day | 布尔值,true = 上班 |
错误码
| 状态 | 含义 |
| 200 | 请求成功 |
| 400 | 缺/错 date 参数 |
| 401 | 缺/错 X-API-Key |
| 500 | 服务端配置/飞书 API 错误 |
公开端点
GET / — 本文档
GET /favicon.svg — 网站图标
GET /health — 健康检查
GET /stats — 访问统计
在线测试
点击「查询」按钮查看返回结果