简体   繁体   English

stripe:没有此类外部帐户,但确实存在外部帐户

[英]stripe: No such external account but the external account do exist

I create an account in stripe under test module by stripe api. 我通过stripe api在test模块下的stripe中创建一个帐户。 And bind a bank account with this account. 并将银行帐户与此帐户绑定。 Go to Stripe dashboard -> connect -> accounts , I could see the account which I created. 转到Stripe dashboard -> connect -> accounts ,我可以看到创建的帐户。 Click it and to see the detail, I could see the external accounts: 单击它,然后查看详细信息,我可以看到外部帐户:

在此处输入图片说明

but when I want to create a payout to this bank account: 但是当我想为此银行帐户创建付款时:

curl https://api.stripe.com/v1/payouts    \
     -u sk_test_*********:   \  
     -d amount=400     \
     -d currency=usd    \
     -d destination=ba_1CrVQnJziGn15h8UAvSlEUfI    \
     -d source_type=bank_account

It gives me error: 它给我错误:

{
  "error": {
    "code": "resource_missing",
    "doc_url": "https://stripe.com/docs/error-codes/resource-missing",
    "message": "No such external account: ba_1CrVQnJziGn15h8UAvSlEUfI",
    "param": "destination",
    "type": "invalid_request_error"
 }
}

Here's the correct code to do this. 这是执行此操作的正确代码。

When trying to list payouts on a connected account, you have to make the API request authenticating as this account so in addition to the destination bank account ID you need to pass the stripe account ID. 尝试列出已连接帐户的支出时,您必须使API请求以此帐户进行身份验证,因此,除了目标银行帐户ID外,还需要传递带区帐户ID。

payouts = Stripe::Payout.list(
  {:destination => external_account},
  {:stripe_account => "acct_XXXXXX"},
)

According to Stripe docs , in order to create Payouts for connected accounts you must specify the connected account on the request: 根据Stripe docs的说明 ,要为关联帐户创建付款,您必须在请求中指定关联帐户:

curl https://api.stripe.com/v1/payouts \
  -u {PLATFORM_SECRET_KEY}: \
  -H "Stripe-Account: {{CONNECTED_STRIPE_ACCOUNT_ID}}" \
  -d amount=1000 \
  -d currency=usd

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

相关问题 条带转账到外部账户 - Stripe Transfer to external Account 如何将外部银行帐户设置为Stripe Connect中的默认帐户? - How to make External Bank account as default account in Stripe Connect? Stripe Connect - 克隆外部账户(银行账户)作为新客户的来源 - Stripe Connect - Cloning External Account (Bank Account) as Source for New Customer 平台 Stripe 自动支付给连接的条带账户不起作用 - 没有这样的外部账户 - Platform Stripe automatic payout to connected stripe accounts not working - No such external account 如何使用laravel在条带中添加客户的外部银行账户 - how to add external bank account with customer in stripe using laravel 没有这样的外部帐户,我的 Stripe Payout 无法使用 php 工作? - No such external account and my Stripe Payout not working using php? Stripe:将付款发送到客户的外部银行账户或借记卡 - Stripe: Send payout to customers' external bank account or debit card 收听哪个 webhook 以确认外部银行账户收到的付款 - Which webhook to listen to confirm payout recieved by external bank account in stripe 如何在使用php创建条带管理帐户时提供外部帐户参数? - How to provide external account parameter while creating managed account in stripe using php? 使用Stripe.js(iOS)为Stripe Connect付款创建external_account - Create external_account for Stripe Connect payouts with Stripe.js (iOS)
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM