Stripe关联账户自动付款失败(未验证/无银行账户)的处理方案咨询
Let's break down your scenario first: you're moving funds from your Stripe account to a Connect account (User B), which is set up for daily auto-payouts to their bank. The problem is when B hasn't completed identity verification or hasn't added a bank account—Stripe won't trigger a payout.failed webhook here because it never even attempts the payout in the first place. Here's how to address this:
1. Proactively Check Connect Account Eligibility
Don't rely solely on webhooks for this scenario. Instead, regularly validate the Connect account's status via Stripe's API to catch issues before payouts fail to initiate:
- Call
GET /v1/accounts/:account_idand inspect therequirementsobject:- Look at
currently_dueandpast_duearrays—these list any missing or invalid information blocking payouts (e.g., missing ID verification, incomplete business details). - Check the
statusfield: if it'srestrictedorpending, the account can't receive payouts.
- Look at
- Verify the presence of a valid bank account with
GET /v1/accounts/:account_id/external_accounts:- Filter for
object: "bank_account"andstatus: "valid"—if no entries match, the account has no usable bank account for payouts.
- Filter for
2. Enforce Onboarding & Automated Reminders
Prevent these issues upfront by guiding User B through proper onboarding:
- Integrate Stripe's Connect Onboarding UI components into your app. This lets B complete identity verification and add a bank account directly in your interface, with real-time feedback from Stripe on missing requirements.
- Enable Stripe's built-in notifications in your Dashboard: Stripe will automatically send emails to B when their account has pending verification requirements or missing payout details.
3. Monitor Payout Status & Account Balance
Even after funds are transferred to B's Connect account, you need to track if payouts are actually being sent:
- Schedule a recurring check (e.g., daily, right after the auto-payout window) using
GET /v1/accounts/:account_id/payoutsto look for recent payouts. If no payout was initiated for the day, cross-reference the account'srequirementsto identify the root cause. - Keep an eye on the Connect account's balance with
GET /v1/accounts/:account_id/balance. If funds are sitting idle (and auto-payouts are enabled), it's a strong indicator that payouts are blocked due to verification or bank account issues.
4. Build Custom Alerting Workflows
Add your own triggers to notify users and your team when issues arise:
- After a
transfer.createdwebhook confirms funds were sent to B's account, set up a delayed task (e.g., 24 hours later) to check if a successful payout occurred. If not, fetch the account's requirements and send a targeted alert to B (via in-app message, email) explaining what they need to fix (e.g., "Please complete your identity verification to receive your payout"). - For critical cases (like large amounts stuck in a restricted account), alert your support team directly so you can follow up manually.
Key Note
Remember: Stripe only triggers payout.failed when it actually attempts to send funds to the bank but gets rejected (e.g., insufficient funds, invalid routing number). If the account isn't eligible to initiate payouts at all, no webhook will fire—so proactive checks are non-negotiable here.
内容的提问来源于stack exchange,提问作者Azephiar

