#edward_transfer-currency

1 messages ยท Page 1 of 1 (latest)

stray gobletBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

๐Ÿ”— This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1425167212230217881

๐Ÿ“ Have more to share? Add more details, code, screenshots, videos, etc. below.

Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

scarlet osprey
#

fyi, this is how i create the Connected Account:

  email: user.email || undefined,
  country: dto.countryCode,
  business_type: 'individual',
  business_profile: {
    product_description: 'Account for withdrawals',
  },
  individual: {
    first_name: user.firstName || undefined,
    last_name: user.lastName || undefined,
    email: user.email || undefined,
  },
  settings: {
    payouts: {
      schedule: {
        interval: 'manual',
      },
    },
  },
  capabilities: {
    transfers: {
      requested: true,
    },
    card_payments: {
      requested: true,
    },
  },
  controller: {
    requirement_collection: 'application',
    fees: {
      payer: 'application',
    },
    losses: {
      payments: 'application',
    },
    stripe_dashboard: {
      type: 'none',
    },
  },
});```
viscid grotto
#

edward_transfer-currency

#

Can you share an example API request?

#

When you get an error there should be a req_123 id

scarlet osprey
#

hi, do you need the API request for the payout or the account creation?

viscid grotto
#

the Payout. I want to see the exact error and where it's raised

stray gobletBOT
scarlet osprey
#

give me 1 minute

viscid grotto
#

Okay I found it from the ba_123

scarlet osprey
#

ah okay

viscid grotto
#

Really if you have a connected account that has bank accounts in SGD and USD, it is impossible to "pay out" the SGD balance to the USD bank account. It has to go to the SGD bank account. It's a hard requirement

#

Only viable path would be to remove/delete that SGD bank account

scarlet osprey
#

hmm then what is the use of the "destination" field for the payout?

#

cause if i don't pass it then it automatically goes to the bank account matching the currency right?

#

and i don't see a way for my user to add more than 1 bank account for 1 currency in the embedded Account Management UI from Stripe

#

so the only thing preventing the transfer to go through is because Stripe is not allowing it? even though we are willing to accept the currency exchange fees?

cursive lynx
#

hello! fyi i am taking over the thread as koopajah has to step away

cursive lynx
scarlet osprey
#

ah that makes sense

#

thank you

#

so if the user doesn't have an external account for the selected currency, can i choose any other external account of other currencies? or does it have to be the default external account?

cursive lynx
#

i think you'd be able to choose, but i'm not completely sure so let me do some additional digging there

scarlet osprey
#

okay, i need to know because that would affect which destinations i show to my users when they create a payout

cursive lynx
#

ok, sorry for the delay, i was just testing some things out to confirm expected behavior here. the short version is that no, the currency will have already been converted to their default currency in this scenario. let's say i:

  1. create a connected account
  2. add a USD external account (their default currency) and a GBP external account
  3. create a transaction in EUR that transfers to the connected account

we automatically convert the currency to USD in this case since they do not have a compatible external account. so in your scenario, the currency would already have been converted by the time you go to initiate the payout.

scarlet osprey
#

makes sense

#

thank you for your time

cursive lynx
#

yep, of course!

scarlet osprey
#

ah, one more thing

#

how do i create a payout for all the money available in the user's Stripe balance?

#

normally if they create a payout in the same currency of the selected external account, then i already know the amount and can create the payout

#

but for the case where stripe automatically converts to the default currency, i don't know the amount to create a payout

#

do i need to query the balance from the user with some stripe API and then use that for the payout, or is there a flag in the payout API that i can use?

cursive lynx
#

specifying the amount is required (there is no "pay out all funds" option), and yes querying the balance before creating the payout would be one way to get the correct amount

scarlet osprey
#

okay, thank you

cursive lynx
#

alternatively you can listen for the balance.available webhook event via a connect webhook on your server to keep up to date on what balance each account has

scarlet osprey
#

that's great, thanks for the suggestion

cursive lynx
#

happy to help ๐Ÿ™‚

scarlet osprey
#

hi again, for the stripe balance API, is the default balance the first one in the "available" array?

#

i don't see a field to mark if a balance is the default one or not

cursive lynx
scarlet osprey
#

ah i don't store my user's stripe details in database

#

so i guess i have to get the account details from stripe API as well