账号管理API接口
管理苹果ID账号
获取账号列表
http
GET /openapi/account
响应:Pagination<Account[]
>
获取账号详情
http
GET /openapi/account/:id
路径参数:id
账号ID
响应:Account
添加账号
http
POST /openapi/account
请求体参数:
字段名 | 类型 | 可空 | 说明 |
---|---|---|---|
username | string | 否 | 苹果ID账号 |
password | string | 否 | 账号密码 |
check_interval | number | 否 | 检查间隔(单位分钟,范围5-1440) |
enable_update_password_when_incorrect | boolean | 否 | 当密码错误时是否自动更新密码 |
enable | boolean | 否 | 是否启用检测 |
dob | string | 否 | 出生日期(格式 YYYY-MM-DD 或YYYY/MM/DD ) |
questions | Question[] | 否 | 密保问题(3个) |
auto_update_password_interval | number | 是 | 自动更新密码的时间间隔,空则不自动更新 |
auto_remove_devices_interval | number | 是 | 自动移除设备的时间间隔,空则不自动移除 |
lock_country | string | 是 | 锁定地区,不一致时自动修改 |
sort | number | 是 | 分享页账号排序,值越大越靠前 |
desc | string | 是 | 分享页说明 |
remark | string | 是 | 备注 |
tag_ids | number[] | 是 | 关联标签ID列表 |
更新账号
http
PUT /openapi/account/:id
路径参数:id
账号ID
请求体参数:
字段名 | 类型 | 可空 | 说明 |
---|---|---|---|
username | string | 否 | 苹果ID账号 |
password | string | 否 | 账号密码 |
check_interval | number | 否 | 检查间隔(单位分钟,范围5-1440) |
enable_update_password_when_incorrect | boolean | 否 | 当密码错误时是否自动更新密码 |
enable | boolean | 否 | 是否启用检测 |
dob | string | 否 | 出生日期(格式 YYYY-MM-DD 或YYYY/MM/DD ) |
questions | Question[] | 否 | 密保问题(3个) |
auto_update_password_interval | number | 是 | 自动更新密码的时间间隔,空则不自动更新 |
auto_remove_devices_interval | number | 是 | 自动移除设备的时间间隔,空则不自动移除 |
lock_country | string | 是 | 锁定地区,不一致时自动修改 |
sort | number | 是 | 分享页账号排序,值越大越靠前 |
desc | string | 是 | 分享页说明 |
remark | string | 是 | 备注 |
tag_ids | number[] | 是 | 关联标签ID列表 |
删除账号
http
DELETE /openapi/account/:id
路径参数:id
账号ID
示例
bash
curl -X DELETE http://localhost:3000/account/1