php - 使用 PaymentIntents API 将产品添加到付款

标签 php stripe-payments

我刚刚使用他们的支付意图 API 在 PHP 上通过 strip 完成了支付设置,并且忘记了必须添加用户刚刚购买的产品/项目。

查看 API 引用,我没有看到任何可以将项目添加到付款意图的地方,因此我可以检索稍后在 webhook 中购买的内容。

我需要做我自己的魔法并以某种方式将项目添加到元数据数组中还是我在这里遗漏了什么?

最佳答案

PaymentIntents 不跟踪与购买相关的任何类型的产品(只是一个金额)。为了将产品链接到付款,您需要use Invoices这将生成 PaymentIntent 作为流程的一部分。

关于php - 使用 PaymentIntents API 将产品添加到付款,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59687006/

相关文章:

Javascript:无法使用 $ ('id' 获取元素)

javascript - Laravel strip 付款表格不处理只是发布

ios - ld : framework not found Stripe for architecture x86_64

javascript - 当我单击下拉菜单时,我需要填充表单。哪个选项性能更高?

php - 在循环中的 2 个 <tr> 上显示自定义标题

php - 如何比较 PHP 中不同 foreach 循环的两个值?

payment-gateway - Stripe 连接错误 'No such merchant'

stripe-payments - 建立在 Stripe 之上的联盟系统

python - Stripe : Error "This application is not authorized to edit this account" while updating the account in stripe

php - 匹配带连字符的单词的正则表达式