【发布时间】:2019-10-10 20:48:38
【问题描述】:
我处于测试模式,我在前端使用 JavaScript 并在后端使用 PHP 成功创建了一个自定义连接帐户。
帐户创建成功,但由于某种原因,业务资料未显示在请求正文中(我在仪表板的条状日志中看到了这一点)。
我在提交表单之前看到一条警告消息:
business_profile 不是可识别的参数
以下是我在测试时使用的 API 编码供您参考: https://stripe.com/docs/api/accounts/create?lang=php#create_account-business_profile
JavaScript
const accountResult = await stripe.createToken('account', {
business_type: 'company',
company: {...},
business_profile: {
mcc: "5812",
support_email: "test@example.com",
url: "https://example.com",
},
tos_shown_and_accepted: true,
});
PHP
// ...
$account = \Stripe\Account::create([
"country" => "FR",
"type" => "custom",
"account_token" => $account_token,
]);
// ...
【问题讨论】:
标签: javascript php stripe-payments