pypush:基于 Python 的多平台消息推送工具项目

APP 推送通知(Python 库)

Branch1Tags6
FilesLast commitLast update
1 year ago
2 years ago
5 months ago
2 years ago
2 years ago
1 year ago
2 years ago
5 months ago
5 months ago
5 months ago
5 months ago

ipush

向 APP、微信平台推送通知。 支持往 Telegram、钉钉群、飞书群、Lark 群、Bark、Chanify、PushDeer、PushPlus、Showdoc、息知、Alertzy、Notify 推送消息。

Package version Supported Python versions

使用说明

  1. 安装依赖
# pip
pip install -U ipush

# uv
uv add ipush

# 从 GitHub 安装
uv add git+https://github.com/idevsig/pypush.git
  1. 创建 notify 对象,并发送消息
from ipush import Dingtalk as Channel

notify = Channel("token", "secret")
notify.send("iPush test")

支持平台

状态 国内平台 官网 备注
✔ 荐 钉钉群机器人 https://open.dingtalk.com/
✔ 荐 飞书群机器人 https://open.feishu.cn/
✔ 荐 Lark 群机器人 https://open.larksuite.com/
✔ 荐 Bark https://day.app/2021/06/barkfaq/ 仅支持 iOS
✔ Chanify https://www.chanify.net/ 仅支持 iOS
✔ PushDeer https://www.pushdeer.com/
✔ 荐 企业微信群机器人 https://developer.work.weixin.qq.com
// // 基于微信公众号 \\
✔ PushPlus https://www.pushplus.plus/
✔ Showdoc https://push.showdoc.com.cn/
✔ 息知 https://xz.qqoq.net/
✔ 聚合云推 https://tui.juhe.cn/ 聚合推送。支持 邮箱、微信公众号、钉钉机器人、WebHook、企业微信、Bark
状态 国外平台 官网 备注
✔ 荐 Telegram https://core.telegram.org/bots/ 创建Bot后,将 Bot 添加至群组或频道,再添加获取 ChatId 的机器人进群组(可移除),即可获得ChatId
✔ Alertzy https://alertzy.app/
✔ Notify https://notify.dev/ 安装手机 APP,复制设备 ID(Settings -> Device ID),输入到 Playground,获取二维码,再使用手机 APP 扫描

开发

1. 前置开发环境

  1. 使用 uv 作为包管理工具

2. 开发流程

  1. 安装依赖包:
# 同步
uv sync
  1. 代码检测与格式化:
# 使用 prek(推荐)
prek run -a

# 或使用 ruff
uv run ruff check . --fix
uv run ruff format .
  1. 单元测试:
# pytest
uv run python -m pytest

# 打印测试报告
uv run python -m pytest -s

仓库镜像

MyCode ● AtomGit ● GitHub

Introduction

APP 推送通知(Python 库)

Customize your domain