我正在将 Stripe 集成到其中一个应用程序中。当我通过 Node.js SDK 发送发票时,当我使用测试环境 API key 时,它不会向客户发送发票电子邮件。但是,当我使用具有完全相同代码的实时环境 API key 时,它会将发票电子邮件发送给客户。
此外,当我在测试模式下从 Stripe 仪表板发送发票时,它会向客户发送电子邮件。该问题似乎仅存在于测试模式下的 SDK/API。
即使在测试模式下也可以使用 Node.js SDK/API 向客户发送电子邮件吗?
最佳答案
Stripe 在测试模式下不会发送电子邮件。
来自https://support.stripe.com/questions/not-receiving-email-sent-from-stripe :
Stripe only sends email receipts for payments that are made with your live API key or through your live Dashboard. If you are expecting an email for a test transaction, one will not be sent.
关于stripe-payments - Stripe 在测试环境中不向客户发送发票电子邮件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/74713563/