#bajay_code

1 messages ยท Page 1 of 1 (latest)

wary knollBOT
sly lakeBOT
#

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.

wary knollBOT
#

๐Ÿ‘‹ Welcome to your new thread!

โฒ๏ธ We'll be here soon! We typically respond in a few minutes, but in some cases we might need a bit more time (e.g., server's busy, you've got a complex question, etc.).

โฑ๏ธ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can 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/1254710926968356875

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

soft cave
#

{
"line_items": {
"0": {
"price_data": {
"unit_amount": "500",
"currency": "GBP",
"product_data": {
"description": "test",
"name": "arbaz"
}
},
"quantity": "1"
}
},
"cancel_url": "https://sponsa.validatione.com/dashboard/payment-failure",
"customer": "cus_QI80VYQh3vV98d",
"payment_intent_data": {
"application_fee_amount": "25"
},
"mode": "payment",
"success_url": "https://sponsa.validatione.com/dashboard/payment-success/{CHECKOUT_SESSION_ID}",
"payment_method_types": {
"0": "card"
}
}

#

this is response body from stripe
{
"error": {
"code": "resource_missing",
"doc_url": "https://stripe.com/docs/error-codes/resource-missing",
"message": "No such customer: 'cus_QI80VYQh3vV98d'",
"param": "customer",
"request_log_url": "https://dashboard.stripe.com/acct_1PPmvpA7I9fLI6Du/logs/req_fYDXWJLtjiRjVS?t=1719216239",
"type": "invalid_request_error"
}
}

Learn more about error codes and how to resolve them.

wraith canopy
#

Hi, let me help you with this.

soft cave
#

yes please

wraith canopy
#

This is expected, since this Customer exists on the Platform. When you do Destination charges, the Customer, Charge, Products exist on the Platform, but when you do Direct charges, all objects are from the Connected account (since you add the Stripe-Account header). That's why you can't find that Customer on the Connected account.

#

You have to either create a new Customer on the Connected account, or use Destination charges.

soft cave
#

i want to use direct charges. on my platform i have creators and supporters, creators are payee and supporters are payer. Creators are connected to my platform and supporter are not. they are just redirected to stripe checkout session when they click on pay. now on backend we check if supporter is a customer if yes we use that customer id otherwise if not then we create a new customer. what do i need to change here?

wraith canopy
#

If you want to use direct charges, each Connected account ("creator" in your case) will need to have its own Customer objects ("supporters"). Not sure this is ideal if you only have 1 website/app, and not each creator has its own app. Why do you want to use direct charges specifically?

soft cave
#

i want that stripe fee should be deducted from the supporters amount and for that we have to use direct charges

wraith canopy
#

You can add application fee to Destination charges too, or you can just transfer a smaller account to the Connected account.

soft cave
#

this is from my platform and i just has application fee

#

this is from my competitors and it has seperate application fee and stripe fee

#

i want seperate fees

wraith canopy
#

You want your Connected accounts to see the Stripe fee on their charges?

soft cave
#

yes, also i want that stripe fee should be charged to supporter directly not to the platform

wraith canopy
#

You can just make the application fee higher so it covers the Stripe fee. But it's not worth using an integration pattern that's not suitable for your use case just to show the fees separately. You can always fetch the resulting Stripe fee from your destination charges and display it to your creators in your own app.

soft cave
#

what if i make a customer of connected account meaning i make my supporter the customer of the creator they choose to fund. will it work then?

#

also if my competitors are using direct charges so we can also use it

wraith canopy
#

Yes, but you will need to create new Customer objects on every single Connected account you will have, and it's going to be difficult for them to reuse the Payment Methods, if, for example, the same customer wants to support multiple creators.

soft cave
#

okay thank you so much

wary knollBOT
unreal hemlock
#

๐Ÿ‘‹ taking over for my colleague. Let me know if there's any follow-up Qs I can answer!

soft cave
#

i just wanna know that if i add the stripe fee in the application fee, how much stripe fee should i deduct? stripe takes different fee for uk domestic cards and for europe its different. this is why i didn't want to use destination charges in the first place

unreal hemlock
#

if you prefer you can use Separate Charges and Transfers so you would know exactly the Stripe fee before transferring the remaining amount to the connected account

soft cave
#

would it not be easy if i used direct charges instead?

unreal hemlock
#

we recommend using different types of charges based on your use case and how you want to create your connect account, you can learn more about it here https://docs.stripe.com/connect/charges

Learn how to create a charge and split payments between your platform and your sellers or service providers when you accept payments.

soft cave
#

i want that supporter pays the creator let's say 5 pounds, from 5 pounds our 5% platform fee should come to us, stripe takes it fee from 5 pound and remaining goes to creator

#

what type of charge should i use

unreal hemlock
#

you can achieve this with both Direct and Separate Charges and Transfers

#

to choose which one to use it boils down to who is liable when it comes to refunds/disputes

#

please read through the doc I sent you