#mnguyen
1 messages · Page 1 of 1 (latest)
Hmm can you illustrate the issue for me with some example requests? Either what you're trying to do that does not work, or that you'd expect to be able to do?
Sure. In the following order here is what we are doing when creating a connected account.
- We have a form that collects bank information when our users submit that form, server side we create a new connected account object under our platform account via the /accounts api.
2, Using that bank information we create a bank token using /token api endpoint. - We then create a source object for the new connected account and that source object has the bank token specified to tie the bank account.
- We also have a form that user can verify microdeposit amounts once they recieve them in their bank account. This calls the source.verify endpoint which then makes the bank account usable.
- So now when topping up, we specify the source id of the source object we created prior in the source parameter of the /topup api.
- This works perfectly as expected.
- If a void happens and the funds are clear we issue a payout using the payout api. This api does not accept source id so we don't specify any info and it uses the default bank account tied to the connected account.
- this works fine until we have to change bank information.
- In order to change bank account we create a new source object and banktoken as originally performed.
- When we topup now since source id is used, we are able to specify the correct bank account to pull funds from.
- However for payouts, since it does not accept source id, we have no way to specify the new bank to return fund to and it uses the original bank account by default.
So the problem is how to properly topup and payout using the new bank account.
Not sure if that is what you are looking for, let me know i can provide more details. but that is scenario we are trying to solve.
We have tried using the external accounts api to get the list of external bank accounts tied to the connected account but that does not return external bank accounts created via the source object with the exception of the first one done that way. Since we only need the bank account id of the one created in order to call the payouts api. Is there another way to get the bank account id of objects we created already.
Ah, ok, i think i understand
I infer from the above that you're using custom accounts, correct?
yes
Ok, then I think the piece you might be missing here is update the default_for_currency on the new external account:
https://stripe.com/docs/api/external_account_bank_accounts/update#account_update_bank_account-default_for_currency
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
I'm familar with that flag however that pertains to creating objects via the external accounts api. If we switch to use this endpoint, then the question becomes how do we complete verification of bank accounts added this way since there is no .verify method for external bank accounts, it only exists for source and normal bank account objects.
That's not required for external accounts for payouts
but it is for topups. and if we are creating the bank account this way it needs to be usable for both ends(direction of funds movement)
Sure, but you can create both the source and the external account, given the details
And that will not trigger two sets of microdeposits then correct since creating via external accounts doesnt need verification, assume that won't trigger a verification workflow for the one created via external accounts when creating two objects representing that bank account.
Good question, I don't think there will be a second set of microdeposits but am checking in to this to confirm
I feel like external accounts api still needs to matriculate the status of that object some how as it starts off in 'new' status and I experimented with using it when it's still in this status and it seems to work however, i cant tell if that is because of the quirk of not being able to test bank stuff in stripe test mode since you can only specify the preconfigured bank accounts and no microdeposits kick off in test mode either way.
can you confirm that external bank accounts created this way are really usable in any status.
Apologies for the delay, so yes as synthrider said verifications are not needed for the external account so the user will not see two sets of microdeposits here. So all of that will only happen for the source object that is being used to top up via that bank account.
I actually thought that microdeposits were testable in test mode but that may only be for other flows.
But yes, creating an external account that way will allow it to be usable for payouts.
roger. will give that a try. thank you