#davidhusselmann

1 messages Β· Page 1 of 1 (latest)

scenic zodiacBOT
drowsy swift
#

Cloning a payment method can only be from platform to connected account, and not another way round

#

The only way is to ask customers to add payment method again on platform

thin abyss
#

Okay, so if I want to charge a card and set it up for future payments, but keep the connected account as the merchant of reference, how do I do that while keeping the card details in the platform account?

drowsy swift
#

Are you using Checkout Session or Payment Intent?

thin abyss
#

Checkout Session.

#

(for the first charge+setup anyway) - PaymentIntent for rebilling

#

brb

drowsy swift
#

For Checkout Session, you can set payment_intent_data.on_behalf_of (payment mode) or setup_intent_data.on_behalf_of (setup mode), so that connected account will be the merchant of record to the customers and the payment methods will be saved on the platform.

#

What type of connected account and charges are you using?

  • Connected account types: Standard, Express, Custom
  • Charge types: Direct Charges, Destination Charges, Separate Charges & Transfers
thin abyss
#

using direct charges against standard connected accounts.

#

so if I use on_behalf_of that's not going to cause any other charges/fees right? Until now I was using the Stripe-Account header to do the direct charge against the connected account.

drowsy swift
#

If the payment methods are saved on the platform, Direct Charges can't be used anymore.

Payment methods saved on the platform can only perform Destination Charges and Separate Charges & Transfers: https://stripe.com/docs/connect/charges

In addition,

  • the products and customers will also have to be created on the platform instead of in connected accounts.
  • Destination charges and Separate Charges & Transfers are only recommended for Express and Custom connected account, not Standard connected account
thin abyss
#

even if we clone payment methods into the connected accounts?

drowsy swift
#

If the payment method is saved on the platform and clone it to connected account during payment with Direct Charges, then this will also work

thin abyss
#

aha, ok, that might be just the ticket. thanks

drowsy swift
#

No problem! Happy to help πŸ˜„

thin abyss
#

I'm attempting that direct charge (with an application fee) against the connected account now, but it's giving me this:
| Can only apply an application_fee_amount when the PaymentIntent is attempting a direct payment (using an OAuth key or Stripe-Account header) or destination payment (using transfer_data[destination])

#

I'm doing the Session Create against the platform account, but setting the PaymentIntentData.OnBehalfOf to the connected account. Is this not supported? Seems to work fine when using it in setup mode?

drowsy swift
thin abyss
#

that's interesting, the log is telling me a slightly different error - in any case, request id is this: req_AxB8WsKoMQ10Xh

versed smelt
#

πŸ‘‹ taking over here

thin abyss
#

strange, I can't even set application_fee_amount on that level

versed smelt
#

acct_1MCCJ6DFj58ragMm is your platform account, correct?

thin abyss
#

yes, let me double check that for you

#

yes that's correct.

versed smelt
#

After the brackets for parameters, open another brackets: {stripe_account: '{{CONNECTED_ACCOUNT_ID}}'}

thin abyss
#

yep, I tried that and it works, but the problem is then the payment method (for off session billing) gets created in the connected account, not in the platform account where I'd like them

versed smelt
#

I think that's the misunderstanding here. Direct Charge mean the Charge "belongs" to the Connected Account, you are just the one who is making the request

#

When the Charge belongs to the Connected Account, associated Payment Method will also belongs to the Connected Account

thin abyss
#

So if I want to rebill the card from another connected account, how can I achieve that?

#

Situation is: golfer makes a booking at one club (one of our connected accounts) - they save their card for future billing. Then, another day, they make a booking at a different club (another one of our connected accounts), and they expect their card details to be in the system so we can just rebill them.

versed smelt
#

Um sorry for the back and forth, but it sounds like you need the other 2 flows:

  • Create each club as an Express or Custom Account
  • Use Destination Charge or Separate Charges And Transfers, with on_behalf_of. This way the Payment Method lives in Platform
thin abyss
#

The reason we wanted to use Direct + Standard is a liability thing - we don't want our platform account to be the merchant of record. There are also a lot of fees with the other flows I gather

versed smelt
#

on_behalf_of is the flag make the Connected Account the merchant of record

thin abyss
#

yep, okay, so that is what I've been trying to do - have a look at this:

#

on line 125 there, I set the OnBehalfOf to the connected account

#

the problem is, when I do this, I get that error that I contacted you about before - the one saying I can't use application_fee_amount

versed smelt
#

brb in 5 mins

#

Umm can you share that errored request id?

thin abyss
#

sure, just a moment

#

req_5qTusJa2WoJmPW - The 'payment_intent_data[transfer_data][destination]' param cannot be set to your own account.

#

even though I set on_behalf_of to the connected account

versed smelt
#

The error is pretty clear IMO, you need to set that payment_intent_data.transfer_data.destination to acct_1MDzDaKX8tvh29a8 too, not acct_1MCCJ6DFj58ragMm which is your own (platform) account

thin abyss
#

okay, but how can I charge a fee that is transferred to our platform account?

#

since application_fee doesn't work

versed smelt
thin abyss
#

ok, let me do another request now.

#

ok, adding application_fee_amount to the payment_intent_data gives me this error: Can only apply an application_fee_amount when the PaymentIntent is attempting a direct payment (using an OAuth key or Stripe-Account header) or destination payment (using transfer_data[destination]).

#

request req_lbpZeT1NBrgP2U

#

and annoyingly the logs show a different errorr

#

brb have to have dinner :/

versed smelt
#

Yes it requires to have the transfer_data block, like previous request req_5qTusJa2WoJmPW Why did you remove it πŸ™‚

thin abyss
#

apparently not though if you believe the error message:
You may not provide the application_fee_amount parameter and the transfer_data[amount] parameter simultaneously. They are mutually exclusive.

#

actually let me remove the transfer[amount]

#

okay, that API call worked (req_uOcpVs4l5QBjl2) - however it seems to have put it under our platform account (I'm not exactly sure how to tell who the merchant of record is) - isn't this the separate charges and transfers flow now?