#mboras
1 messages · Page 1 of 1 (latest)
Hello! We'll be with you shortly. 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.
- mboras, 4 days ago, 10 messages
- mboras-checkout-event, 5 days ago, 5 messages
Go for it!
How can I know when I create checkout and set payment_intent_data: {
application_fee_amount: applicationFeeAmount,
transfer_data: {
destination: stripeAccountId,
},
},
- how much stripe fee will be for that transaction
- i need to know that before i set applicationFeeAmount to not be affected
I am using stripe connect to accept payments and transfer them to facility owners
so I want to transfer to facility owner
Total amount - stripe fee - my fee
?
Hello! I'm taking over and catching up...
My app is something like lyft or thumback
https://stripe.com/docs/connect/charges#types
Users on my app can book some sport facility and I need to transfer money to owner and take my fee
I have issue where payment is 19.91euros and with international card and stripe fee is 0.9 for example. I take 0.5 euros and I am in minus 0.4
I want to cover that
You need to set amount under transfer_data when you create the Checkout Session: https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-payment_intent_data-transfer_data-amount
That's the amount that will be sent to the destination account you specify.
Ok, so I want send to that account
- Total amount - stripeFee - myFee
how can I know what stripeFee will be when I am creating checkout
I am little confused please correct me
You would need to calculate it yourself up front, it's not available via the API until after the transaction is complete.
hmm
honestly I don't like this approach
I want to always take
- stripe fee
- my fee
But I don't want stripe fee to be larger than mine fee and then I am in minus
What are other options that I can use
There aren't really other options. We don't calculate and charge Stripe fees until the transaction actually happens.
Yeah I understand that
but can I soemhow make following
- stripe takes it's fee
- I take my fee
I send rest to facility owner
Yes, by setting the appropriate amount using the API I mentioned above.
Kk
Ok one more question
I allowed in checkout promo codes
- Facility owner creates some coupons on his connect account and gives it to user
How can I validate that promo code for that stripe connect account?
Not sure what you mean by validate? Can you provide more details?
So this is flow
user can apply coupon inside of my app on details page (before stripe checkout)
I want to when user presses "apply" validate that promo code and if it is valid return from backend "promotionCodeId" which I'll use when I create checkout and pass it
The thing is I have on my stripe account some coupons
and other on stripe connect
Stripe Promotion Codes are designed to be entered on the Checkout page by the Customer, not on your page before that.
but I can pass them to checkout before
I've done that before in my app
that is my flow
Yeah, you can apply them via the API when you create the Checkout Session: https://stripe.com/docs/api/checkout/sessions/create#create_checkout_session-discounts-promotion_code
I don't understand what you mean by validate though?
Creation of the Checkout Session will fail if you pass in an invalid one there.
that's why I am validating before
But you need to pass the ID of the Promotion Code, not the actual code itself.
You're trying to validate the ID? Or the code?
I receive from code and then I want in my backend to first see for which stripe connect account that code refers and if it exists. If it exists and it is valid I return back promo code id and pass that to checkout
I miss part in implementation
- first see for which stripe connect account that code refers and if it exists. If it exists and it is valid I return back promo code id
You can list Promotion Codes by their code: https://stripe.com/docs/api/promotion_codes/list#list_promotion_code-code
But you can't do that for more than one account at a time.
I am trying that ATM but I can't acces codes from stripe connect account
only from mine account
and I also don't understand why I can't use in checkout code created from stripe connect account dashboard
- I create checkout with stripe connect account ID
- I use code from that stripe connect account and it doesn't work
You need to make the list API request on the connected account: https://stripe.com/docs/connect/authentication
To clarify your other question, can you give me the ID of the Promotion Code you're trying to use, and the ID of the Checkout Session you're trying to use it with?
ok
jsut a sec
tnx
cs_test_b1t7E6tsQCmKKB6cRnNq3eICCRfyv8LnmZkcUMXmiAaVwkZKLWl8jdMF1k
acct_1OVbUOPQ5tZsQmzG
promo_1OPvpDABvR2sPGgdVp7VN5hv
Can you show me a screenshot of what happens when you try to use that code in that Checkout Session?
uff it is on mobile phone
hard to get screenshot here hahha
it. just says code invalid
I'll ask tomorrow again
It's late
thank you for your help rubeus
👋
I think it might be because your platform needs to create the Promotion Code for it to work with a Checkout Session created by your platform.
Aaaa
I would try that and see if it works instead of using one created via the Dashboard.
I thought I can use in my session associated with some stripe connect account id promo code from that account
if you understood what I meant
Honestly I've never tried to do that, so I'm not sure if it's expected to work or not.
kk
Oh, wait, are you trying to use a recurring discount for a one-time payment?
Yeah, I think that's it. You set up a one month Coupon, which only works with Subscriptions.
Did that work?