简体   繁体   English

为什么 Stripe 事件没有触发,也没有被 webhook 接收?

[英]Why aren't Stripe events firing and not being received by webhook?

I've tested my webhooks locally, using the CLI, and they work fine.我已经使用 CLI 在本地测试了我的 webhooks,它们工作正常。 However, when I took the webhooks live and deployed them to Heroku, and went into "live" mode on Stripe (which I assume is necessary to be able to use live webhooks), Stripe just doesn't fire events at all, they don't appear in the dashboard, webhook endpoint doesn't get any requests, nothing;但是,当我实时使用 webhooks 并将它们部署到 Heroku,并在 Stripe 上进入“实时”模式(我认为这是能够使用实时 webhooks 所必需的)时,Stripe 根本不触发事件,它们不会'没有出现在仪表板中,webhook 端点没有收到任何请求,什么都没有; for example, no account.updated when a I try to create a Connected account, or no checkout.session.complete when I try to complete a Checkout purchase.例如,当我尝试创建 Connected account.updated时没有account.updated ,或者当我尝试完成 Checkout 购买时没有checkout.session.complete Is there a step I've perhaps missed when taking my webhooks online?在网上使用我的 webhooks 时,我可能错过了一个步骤吗?

I ran into this issue myself- a few ideas:我自己遇到了这个问题 - 一些想法:

  • Make sure you are configured correctly in the dashboard, eg.确保您在仪表板中正确配置,例如。 only flip the "Test Mode" switch if you are looking at test data如果您正在查看测试数据,请仅翻转“测试模式”开关
  • Make sure you have the endpoints set up for both live and testing.确保为实时和测试设置了端点。 You have to add them each time您必须每次都添加它们
  • Double-check that you're using the correct signing secret.仔细检查您使用的签名密码是否正确。 The signing secret will be differnt for live, production testing, and local testing, even if you're using the same endpoint.即使您使用相同的端点,签名密钥对于实时、生产测试和本地测试也是不同的。

For example:例如:

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Heroku PostgreSQL 连接不会因某些 Express 路线而终止 - Heroku PostgreSQL connections aren't being terminated for certain Express routes Djstripe - Stripe webhook 404 错误:如何解决? - Djstripe - Stripe webhook 404 error: how to resolve? 为什么即使使用供应商前缀也不能在Heroku上不显示渐变? - Why aren't gradients not showing up on Heroku even with vendor prefixes? Stripe:已注册 webhook,但仍然出现“Not a Valid URL”错误 - Stripe: Registered webhook but still getting “Not a Valid URL” error 如何将我的 stripe webhook 发送到我的 Heroku 应用程序? - How do I send my stripe webhook to my Heroku app? Heroku - Redis 超过了带条纹事件的内存配额 - Heroku - Redis Exceeds Memory Quota with Stripe Events 为什么我的node.js heroku任务console.log语句未显示在heroku日志中? - Why aren't my node.js heroku task console.log statements displayed in the heroku log? 在Heroku上作为GET请求收到POST请求 - POST request being received as GET request on Heroku 使用 Heroku 网址时出现 Stripe webhook 错误 400 错误请求 - Stripe webhook error 400 bad request when using Heroku web address 从Cloudfront请求的文件未缓存 - Files requested from Cloudfront aren't cached
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM