有谁知道如何使用 Stripe API 转账到银行账户?
在 Stripe 引用中它看起来很简单:https://stripe.com/docs/api/python#create_transfer
stripe.Transfer.create(
amount=400,
currency="usd",
destination="acct_19MKfXGyOv0GIG6Z",
description="Transfer for test@example.com"
)
我不明白目的地 id 来自哪里。如何获取银行帐户的目的地 ID?
谢谢
最佳答案
Stripe 有两种类型的传输:
如果您只有一个指定货币的银行账户,您可以使用特殊值
"default_for_currency"
为 destination
范围。例如。如果您运行此代码:
stripe.Transfer.create(
amount=400,
currency="usd",
destination="default_for_currency",
description="Transfer for test@example.com"
)
然后 4.00 美元将被发送到您的美元银行账户。
编辑:在较新的 API 版本 (>= 2017-04-06 ) 上,“内部转账”现在简称为“转账”,“外部转账”现在称为“支付”。参见this doc page想要查询更多的信息。
关于stripe-payments - Stripe API 转账到银行账户,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40980462/