Balanced payments API test marketplace bank account verification

292 views Asked by At

I am trying to verify a bank account on a TEST marketplace. I am using the Ruby client to work with the Balanced API.

I am creating a bank account with the test routing/account number. I then create a verification and finally confirm it using amount_1 = 1 and amount_2 = 1.

If I look in my marketplace logs everything looks great. All requests are 200, and I see the response from the confirmation as "succeeded" except the marketplace dashboard still shows the verification as pending.

If I try to debit the account it fails because

funding-source-not-debitable: Funding instrument cannot be debited

which I've been told is because it's not verified.

I'm not sure what else to try as the logs show it's working, but everything else acts as if it's not verified.

My Ruby code looks like this:

@account = Balanced::BankAccount.fetch("/bank_accounts/#{balanced_id}")

#for test marketplace auto verify
if !Rails.env.production?
  verification = @account.verify
  verification.confirm(
    amount_1 = 1,
    amount_2 = 1
  )
end
1

There are 1 answers

0
rserna2010 On

That is the correct syntax, however, I believe you are later associating this bank account to a customer. Doing so resets the can_debit field to False. You should therefore associate your customer before creating a verification.