# Cleanuparr 接入 Server酱：清理 *arr 卡住任务时微信收到通知（2026 教程）

> Cleanuparr 内置 Apprise 通知，通过 schan:// 协议对接 Server酱，自动清理 Sonarr/Radarr 队列坏种时推送微信消息。需自建 apprise-api 容器。

- 网页版：https://sct.ftqq.com/docs/integrations/cleanuparr/
- 更新日期：2026-07-17

# Cleanuparr + Server酱：清理 *arr 卡住任务时微信收到通知

> 效果：Cleanuparr 自动清理 Sonarr/Radarr 下载队列中卡住或不健康的任务时，微信收到推送通知。

如需推送到企业微信/钉钉/飞书群等其他通道，参见[通道说明](https://sct.ftqq.com/docs/getting-started/channels/)。

## 前置条件

- Server酱 SendKey，需 SCT 开头（[30 秒获取教程](https://sct.ftqq.com/docs/getting-started/sendkey/)）
- 已部署 Cleanuparr 并连接 Sonarr/Radarr
- 已自建 caronc/apprise-api 容器（Cleanuparr 的 Apprise 通知通过它转发，部署详见 [/integrations/apprise/](https://sct.ftqq.com/docs/integrations/apprise/)）

## 配置步骤

**1. 部署 apprise-api 容器**

```bash
docker run -d \
  --name apprise-api \
  -p 8000:8000 \
  caronc/apprise-api:latest
```

Cleanuparr 的 Apprise 通知为 B 类接法，需先运行 apprise-api 作为中转。记录访问地址（如 `http://192.168.1.100:8000`），后续填入 Cleanuparr。通用 Apprise 接法与 apprise-api 部署详见 [/integrations/apprise/](https://sct.ftqq.com/docs/integrations/apprise/)。

**2. 在 Cleanuparr 中填写通知配置**

进入 Settings → Notifications → Apprise，填写以下两项：

- Apprise 服务地址：你的 apprise-api 地址
- URL：`schan://你的SENDKEY`

`schan://` 是 Apprise 中 Server酱的专用协议，底层调用 `https://sctapi.ftqq.com/你的SENDKEY.send`，SCT 开头的 SendKey 直接可用。

**3. 命令行自测（可选）**

```bash
pip install apprise
apprise -t "测试" -b "正文" "schan://你的SENDKEY"
```

收到微信消息说明 SendKey 和协议均正常，可回到 Cleanuparr 完成配置。

## 完整示例

apprise-api 生产部署（docker-compose）：

```yaml
version: "3"
services:
  apprise-api:
    image: caronc/apprise-api:latest
    container_name: apprise-api
    ports:
      - "8000:8000"
    volumes:
      - apprise-config:/config
    restart: unless-stopped

volumes:
  apprise-config:
```

启动后在 Cleanuparr 的 Settings → Notifications → Apprise 中填入 apprise-api 地址与 `schan://你的SENDKEY`。

## 常见问题

**额度是怎么算的？**

免费用户每天 5 条，订阅会员目前特价最低 3 元/月，一天最多可发 1000 条（[价格详情](https://sct.ftqq.com/subscribe)）。日常使用通常足够。

**消息没收到怎么办？**

先检查 apprise-api 容器是否正常运行，再确认填入的 URL 为 `schan://你的SENDKEY`（SCT 开头）。更多排查步骤见[常见问题与排查](https://sct.ftqq.com/docs/getting-started/faq/)。

**频率限制是多少？**

每分钟上限 50 条，会员每日 API 请求上限 1000 次，日常使用通常不会触及。

**sctp 开头的 SendKey 能用吗？**

`schan://` 协议对接 Server酱Turbo，需使用 SCT 开头的 SendKey。

## 相关集成

- [/integrations/qinglong/](https://sct.ftqq.com/docs/integrations/qinglong/) — 青龙面板任务通知
- [/integrations/uptime-kuma/](https://sct.ftqq.com/docs/integrations/uptime-kuma/) — Uptime Kuma 宕机告警
- [/integrations/python/](https://sct.ftqq.com/docs/integrations/python/) — Python 脚本推送


## 懒人方案：把这段话复制给你的 AI 助手

把下面这段文字原样粘贴给 Claude Code、Cursor 或任何 AI 编程助手，它就会替你完成 Server酱 的接入：

```text
请帮我把 Server酱 微信通知接入到我当前的项目/工具中：
1. API：POST https://sctapi.ftqq.com/{SendKey}.send，参数 title（必填，不能含换行）、desp（正文，支持 Markdown，可选）；成功时返回 JSON 的 code 为 0。
2. 如果我的 SendKey 以 sctp 开头，则改用 https://{uid}.push.ft07.com/send/{SendKey}.send，uid 是 SendKey 中 sctp 与 t 之间的数字。
3. SendKey 从环境变量 SERVERCHAN_SENDKEY 读取；如果没有，提醒我到 https://sct.ftqq.com 免费获取（每天 5 条额度）。
4. 安全要求：不要把 SendKey 硬编码进代码、不要打印到日志、不要提交到 git。
5. 频率约定：任务结束发 1 条结果摘要即可，批量任务合并成一条，不要每步都推。
请根据我当前的项目和场景直接写好代码/配置并验证。
```

