feat: 订阅消息通知体系——登录后请求订阅授权(额度记账)+服务端subscribe/send(access_token缓存/原子扣减/失败回补/发送记录)+管理后台通知推送页;版本v1.4.4

This commit is contained in:
Hermes Agent
2026-09-19 19:28:40 +08:00
parent 9ea09c95f2
commit 6d463b9296
11 changed files with 297 additions and 4 deletions
+2 -1
View File
@@ -160,7 +160,8 @@ const UserSchema = new Schema({
default: Date.now
},
// vpay 用户态签名必需(code2Session 返回,有过期时间,过期后重登录刷新)
sessionKey: { type: String, default: '', select: false }, // [安全] 默认查询不返回(支付签名凭据)
sessionKey: { type: String, default: '', select: false },
notifyQuota: { type: Number, default: 0, min: 0 }, // 订阅消息可发送额度(每次授权+1,发送-1) // [安全] 默认查询不返回(支付签名凭据)
vpayCoins: { type: Number, default: 0 },
lastLoginAt: {
type: Date,