#golden-ltda_api
1 messages · Page 1 of 1 (latest)
👋 Welcome to your new thread!
⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always 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/1235674419280613466
📝 Have more to share? Add more details, code, screenshots, videos, etc. below.
Yes, my codes:
Can you clarify what is not happening like you expect?
Yes
I don't understand the problem you're describing. Appreciate the sample requests you shared, but these look to be behaving as i would expect them to.
The cross sell product is no receiving the tax rate.
I will send you the code
and the checkout link generated
const stripe = require('stripe')('xxxx');
const session = stripe.checkout.sessions.create({
payment_method_types: ['card'],
line_items: [
{
price: 'price_1PBK4tHykTKalDQ36s1TTgZT',
quantity: 1,
tax_rates: ['txr_1PBLYFHykTKalDQ3z82S6NTY'],
},
],
mode: 'payment',
success_url: 'xxxx',
cancel_url: 'xxx',
locale: 'fr',
});
Here it is...
When I add the cross-sell product, the tax rate doesn't apply to it...
Can you help me?
I need help to add the tax rate to the cross-sell product that is liked to the primary product that I am selling, price_1PBK4tHykTKalDQ36s1TTgZT.
The cross-sell product is just shown on the checkout link, but not in the code; I need a way yo mention him at the code, to add the tax rate to it...
You need to set a tax code on the cross-sell product and a tax behaviour on the cross-sell price
Can you do that and then try again?
How I can do this? I don't know how to code... I am new on it...
You should be able to do that in your dashboard
I can't, because my account is Brazilian, and doesn't have the tax option.
That is why I am using the code.
I want my costumers to pay the proper tax.
I choose the API way to link the tax rate to the products via checkout creation...
Gotcha, it seem like this is not currently supported then, and does appear to be a gap.
Let me look to see if there are any options
Okay, thanks!!
I can apply the tax rate to both of the products, in the same checkout, but the "cross-sell structure" is destroyed; like on this link:
This one has the cross-sell added because I keep linked on the dashboard to the first product...
But if I removed on the dashboard, it will just show the two products that I generated at the API code.
So ignore the cross-sell option on that link... I need to be able to generate this section by code, aplying the tax rate, you got it?
In résumé: I need to create this second product on the checkout as a cross sell, and not as one more product with the option to add it or not the purchase; I need the cross sell section...
Here is the code that I am using to build that checkout:
Yea, it seems like there is no way for you to assign an explicit tax rate to the cross-sell
const stripe = require('stripe')('xxxx');
const session = stripe.checkout.sessions.create({
payment_method_types: ['card'],
line_items: [
{
price: 'price_1PBK4tHykTKalDQ36s1TTgZT',
quantity: 1,
tax_rates: ['txr_1PBLYFHykTKalDQ3z82S6NTY'],
},
{
price: 'price_1PBKnjHykTKalDQ3Bz6Msn2U',
quantity: 1,
tax_rates: ['txr_1PBLYFHykTKalDQ3z82S6NTY'],
adjustable_quantity: {
enabled: true,
minimum: 0,
maximum: 1,
},
},
],
mode: 'payment',
success_url: 'xxx',
cancel_url: 'xxxx',
locale: 'fr',
});
But there is a way to create a cross sell by code?
I can share feedback about this as a gap to resolve, but I think you need to write in to our support team with this example to ask as a feature request: https://support.stripe.com/contact
Find help and support for Stripe. Our support site 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.
No, cross-sells are a dashboard only feature