# NetAlertX接入 Server酱：局域网新设备接入微信告警（2026 教程）

> NetAlertX（原Pi.Alert）接入 Server酱，当局域网发现新设备时，通过 Apprise 插件推送微信告警，配置简单响应快。

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

# NetAlertX + Server酱：局域网新设备接入微信告警

> 效果：当局域网有陌生设备接入或设备状态变化时，微信立刻收到告警通知

## 前置条件

- 获取 SendKey：登录 sct.ftqq.com，在「SendKey」页面复制。详见 [SendKey 获取教程（30 秒获取）](https://sct.ftqq.com/docs/getting-started/sendkey/)
- 部署 `caronc/apprise-api` 容器作为消息中转（NetAlertX 的 APPRISE 插件为 B 类接法，需此容器）

## 配置步骤

1. 在 NetAlertX 界面进入 Settings → APPRISE 插件配置页。

2. 填写以下配置项：

   - `APPRISE_HOST`：填入你的 apprise-api 容器地址（如 `http://192.168.1.100:8000`）
   - `APPRISE_URL`：填入 `schan://你的SENDKEY`

3. 保存配置。当 NetAlertX 扫描到新设备时，即会通过 Apprise 容器调用 Server酱 API 推送消息。

如需在终端验证 `schan://` 协议与 SendKey 是否连通，可执行命令行自测：

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

## 常见问题

**Server酱³（sctp 开头）的 SendKey 如何配置？**

sctp 开头的 SendKey 暂不支持 `schan://` 协议，需在 Apprise 中使用通用 `json://` 插件直连 push.ft07.com API，具体参数参考站内 /integrations/apprise/ 教程。

**消息发送成功但微信没收到？**

请参考 [常见问题与排查](https://sct.ftqq.com/docs/getting-started/faq/)。

**每天推送额度与频率限制是多少？**

免费用户每天可发送 5 条消息，每分钟上限 50 条；订阅会员目前特价最低 3 元/月，一天最多可发 1000 条（[价格详情](https://sct.ftqq.com/subscribe)）。

## 相关集成

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


## 懒人方案：把这段话复制给你的 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 条结果摘要即可，批量任务合并成一条，不要每步都推。
请根据我当前的项目和场景直接写好代码/配置并验证。
```

