支持的事件

Money Fast 追踪的 Webhook 事件列表。

Money Fast 处理来自支付平台的以下 Webhook 事件。本页列出 Stripe 事件 — 更多支付平台将随支持陆续添加。

在手动配置 Webhook 时,请选择以下事件。如果使用 API Key 方式接入,这些事件会自动配置。

支付事件

事件追踪内容
checkout.session.completed已完成的支付和新订单
checkout.session.expired过期的结账会话
payment_intent.succeeded成功的一次性支付
payment_intent.payment_failed失败的一次性支付
invoice.paid订阅续费和周期性付款
invoice.payment_failed失败的订阅付款

订阅事件

事件追踪内容
customer.subscription.created新增订阅
customer.subscription.updated套餐变更(升级/降级)
customer.subscription.deleted订阅取消
customer.subscription.paused暂停的订阅
customer.subscription.resumed恢复的订阅
customer.subscription.trial_will_end试用期即将结束

退款与争议事件

事件追踪内容
charge.refunded退款和退款金额
charge.dispute.created新的支付争议
charge.dispute.closed已解决的支付争议

事件处理机制

  • 去重 — 每个事件通过 Stripe 事件 ID 去重,重复事件会被安全忽略。
  • 订单 ID 优先级 — 订单通过以下优先级识别:invoice > payment_intent > checkout_session_id。如果同一笔订单来自多个事件,数据会被合并(填充缺失字段,状态只升不降)。
  • 状态优先级unpaid(未付)< expired(过期)< failed(失败)< paid(已付)< refunded(已退款)< disputed(争议中)。状态只能向前推进,不会回退。
  • 计费原因 — 订阅类订单会标记计费原因:subscription_create(首购)、subscription_cycle(续费)、subscription_update(套餐变更)。