#Scott Prins

1 messages · Page 1 of 1 (latest)

umbral saddleBOT
jade sphinx
long fern
#

👋 stepping in

#

Are you making direct charges on your Connected Account?

fossil herald
#

I'm trying to allow the connected accounts to accept the payments directly and I take a platform fee

#
        const stripe = require("stripe")(process.env.STRIPE_SECRET_KEY);
        const creatorStripeAccount =
          await ctx.prisma.userStripeConnect.findFirstOrThrow({
            where: { userId: input.userId },
          });
        const paymentIntent = await stripe.paymentIntents.create(
          {
            amount: input.amount,
            currency: "usd",
            automatic_payment_methods: {
              enabled: true,
            },
            application_fee_amount: input.platformFee,
          },
          {
            stripeAccount: creatorStripeAccount.stripeId,
          }
        );
        return paymentIntent;
      } catch (error) {
        console.log(error);
      }```
long fern
#

Yep that's the problem

fossil herald
#

these are the two errors I get, and it didnt start happening until I added the application_fee_amount and the stripeAccount fields in the payment intent

long fern
#

Need to initialzie Stripe using your publishable key and the Connected Account

#

Client side

fossil herald
#

so not my(the paltform) account?

long fern
#

You use your platform's publishable key and the Stripe Account header. See the doc above

fossil herald
long fern
#
  stripeAccount: '{{CONNECTED_STRIPE_ACCOUNT_ID}}',
});```
fossil herald
#

ok I think its somewhat working, but I am in test mode and in the platform account I am not seeing the fee being added to my account, is it under a payment or somewhere else?

long fern
#

Can you provide the PaymentIntent ID you are testing with?

#

The actual PaymentIntent will exist in your Connected Account

#

Which you can view from your platform

fossil herald
#

oh it's there under collected fees

long fern
#

Yep

fossil herald
#

one other qoestion

#

how do I take on the stripe processing fee and not pass it to the connected account?

long fern
#

You can't

#

You would have to build it into your app fee

#

The processing fees will always take place on the account where the charge takes place

fossil herald
#

I tried to, I got the payment amount for the donation from the form, then I add 12% to that to cover my fee plus Stripes fee at the time of creating the paymentIntent, but I still see both fees showing in the connected account's dashboard

long fern
#

Right that's what I mean. It is impossible to not have the processing fee happen

fossil herald
#

ahh

#

hmmmm

long fern
#

You would just take a smaller app fee if you want to be responsible for the processing fee as the platform

fossil herald
#

makes sense I guess