#MaryCapp-external-ba
1 messages · Page 1 of 1 (latest)
sure.
if (model.PracticeBankAccount != null)
{
model.StripeBankName = model.PracticeBankAccount.BankName;
PracticeBankAccount pbaModel = new PracticeBankAccount();
pbaModel.AccountHoldersName = model.PracticeBankAccount.AccountHoldersName;
pbaModel.AccountNumber = model.PracticeBankAccount.AccountNumber;
pbaModel.BankName = model.PracticeBankAccount.BankName;
pbaModel.Country = model.PracticeBankAccount.Country;
pbaModel.Currency = model.PracticeBankAccount.Currency;
pbaModel.RoutingNumber = model.PracticeBankAccount.RoutingNumber;
var bankAccount = CreateStripeExternalBankAccount(pbaModel, customer.Id).Result;
var externalBAs = bankAccount.Account.ExternalAccounts;
model.StripeBankAccount = externalBAs.Data[0].Id;
}
protected Task<IExternalAccount> CreateStripeExternalBankAccount(PracticeBankAccount model, string customerId)
{
//var banktoken = CreateStripeCustomerBankStripeTokenRequest(model);
var options = new ExternalAccountCreateOptions
{
ExternalAccount = new AccountBankAccountOptions
{
AccountHolderName = model.AccountHoldersName,
AccountHolderType = "Company", // model.PracticeBankAccount.AccountHolderType,
AccountNumber = model.AccountNumber,
Country = model.Country,
Currency = model.Currency,
RoutingNumber = model.RoutingNumber,
},
};
var service = new ExternalAccountService();
try
{
//return service.Create(customerId, options);
return service.CreateAsync(customerId, options);
}
catch(Exception ex)
{
string err = ex.Message;
return null;
}
Oh I meant the actual request ID for the request that failed
https://support.stripe.com/questions/finding-the-id-for-an-api-request#:~:text=How do I find the,(Request IDs API Docs).
Find help and support for Stripe. Our support center provides answers on all types of situations, including account information, charges and refunds, and subscriptions information. Get your questions answered and find international support for Stripe.
this is weird.. the one that is there shows this:
but I am using the secret key
the one I just tried is not showing in the log but I'm getting the same error
I'd recommend verifying the API key and making sure you're using the right one
I just looked.. I'm suing the secret key from the account: sk_test_51K9aLwHjGWiG4VL2GsFpef9ZKaPpQd6LE1qeIiNU71yt6BLFLRaK7I2bnIPI6al2ETjRKdnodkVn6UwvsvyPOnw400J7Y8VNTD
I'd recommend rolling the key and using the new one
and can you copy paste the request ID here?
req_xxxx
so the weird thing that is happening.. using the correct secret key.. i get the error from above but with this: "The provided key 'sktest*Y8VNTD' does not have access to account 'cusLkUAFiU7jD4NhI' (or that account does not exist). Application access may have been revoked."
but it's not showing up in the logs
so why would the application access have been revoked for the creating the external bank accounts but not for creating customer and credit card
do you think they didn't complete the set up of the connect
if you can share the request ID, I can look into it
the issue is it's not showing in the log
Ah, I see!
at all.. the one that is showing is from earlier and I changed the key to use the correct one
this may sound dumb.. but I'm looking thru the connect.. set up.. it looks like they didn't finish it.. so I'm trying to finish it.. but it looks like this is for receiving payments .. to for paying out..
oh never mind I see transfers
Is there a guide you're following for this?
I was just stepping thru to see what was there
gotcha. np, let me take a look
it fails on this line:
the createasync
and it is not showing up in the logs
and here you can see that connect is active:
Okay let's step back here for a second
ok
are you trying to add an external account for a connected account or a customer?
So that's for a connected account right? You would need to use the connected account ID for this then
so the thing is it's a customer that is doing reselling.. so they are paying fees ect.. but each month they will be getting a pay out
so they are a customer with an externa bank account
they have a credit card to pay fees to medtrix
That's not how this works though.
You can't use a customer object as a connected account
You can't do payout to customers
You can only payout to Connected Accounts
so I have to create a connected account
Yes!
and in there have their credit card to pay their fiees
and external account for the bank
to pay out to
ok need to find an example of creating a connected account
You can refer to this guide
https://stripe.com/docs/connect/explore-connect-guide
is it techical or is it just an over view
It is an overview with references to technical portions
which account type would be used to be able to make payments with a credit card and receive payouts.. standard or custom
That'd depend on your integration
Please read through
https://stripe.com/docs/connect/accounts
ok.. so i create an account.. but the examples are so dumbed down.. where do I actually add the information regarding the credit cards
this does not have any details for credit cards or information regarding the actual account
Please take the time read through the resources I've shared with you as it explains how Connect works.
You'll run into similar issues as before if you skip things.
I don't fully understand what you mean by adding the information regarding the credit cards
It's basically telling you to create a connected account but doesn't give you anything regarding where the details of the account go.. which is why it's so confusing.
I will look thru it.. but the documentation.. really should start with an example that shows where things like name of account etc would go
I will try it.. thank you for your help
OK so I have the account.. now need to figure out how to add a credit card to the account. and go from there.
Awesome. thank you so much!