reactjs - Stripe react native : Merchant display name cannot be an empty string

标签 reactjs react-native stripe-payments

我正在尝试将 Stripe React Native SDK 实现到我的 React Native 应用程序中,但是当我向用户出示付款单时出现错误。

我遵循了 stripe 网站 ( https://stripe.com/docs/payments/accept-a-payment?platform=react-native ) 上的教程,但我不断收到以下错误:

{"code": "Failed", "declineCode": null, "localizedMessage": "When a Configuration is passed to
PaymentSheet, the Merchant display name cannot be an empty string.", "message": "When a
Configuration is passed to PaymentSheet, the Merchant display name cannot be an empty string.",
"stripeErrorCode": null, "type": null}

我没有找到任何讨论这个问题的论坛。

提前致谢

最佳答案

我遇到了同样的错误。重新检查文档后,我发现在初始化 strip 付款表时缺少“merchantDisplayName”参数。

const {error} = await initPaymentSheet({
  paymentIntentClientSecret: client_secret,
  googlePay: true,
  merchantDisplayName: 'Merchant Name',
});

关于reactjs - Stripe react native : Merchant display name cannot be an empty string,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/69824403/

相关文章:

xcode - 防止每次在 Xcode 中执行构建时运行 React Native 打包程序

React-native:如何控制键盘向上推

node.js - 部署云函数Firebase/Stripe时出错

javascript - 循环气泡动画

reactjs - 样式组件的多个 Props 选项

reactjs - 当我使用 Lifting State Up 时,useState(false) 不起作用

javascript - 无法在 GraphQL 突变中传递数组 - React Native

wordpress - 无法在类型为 'sepa_debit' 的 strip 中创建源

python - 在 strip 中创建卡的异常

javascript - 如何更改目标跨度 onClick