1

我有一个买家账户,里面有几张与之关联的有效卡。根据Balanced 的 文档,最近添加的卡是默认资金来源。如何在不要求用户重新提交其卡详细信息以创建新卡的情况下将另一张现有卡设置为默认资金来源?

4

1 回答 1

1

您目前无法设置备用资金来源,最近添加的卡始终是默认卡。要借记或贷记特定的资金工具,例如卡或银行帐户,您必须通过对象的 URI 作为参数funding_sourcefunding_destination分别传递:

buyer = balanced.Account.find(uri_of_account)
card = buyer.cards[x]
debit = buyer.debit(amount_in_cents, source_uri=card.uri)

merchant = balanced.Account.find(uri_of_account)
bank_account = merchant.bank_accounts[0]
credit = merchant.credit(amount_in_cents, destination_uri=bank_account.uri)
于 2012-07-18T23:45:03.373 回答