#Santiago Bouso

1 messages · Page 1 of 1 (latest)

spiral ventureBOT
lucid magnet
#

Yeah can you share the session id's? Also what's the exact problem you're seeing?

stoic cobalt
#

So, we have a main account and now we are working with Connect Accounts, Standard Accounts to be precise... this session originally has 4 items that the final customer is buying, but, following your recommendations (with this link: https://support.stripe.com/questions/passing-the-stripe-fee-on-to-customers, and then with another person here in this chat), we are adding a 5th item that are the processing fees (both Stripe fee + our platform fee)

#

The initial 4 items has a Tax Rate (exclusive) and the 5th element doesn't, so taxes are not increased by it

#

cs_test_b1SlONZipSym8ASRt1KN0Q1nhi0Ug42PjS2MK0ZcpHLm04ltNd78IF1qg5

#

With this example, everything seems to be working fine

#

BUT, and here's the problem

#

We also apply discounts, and there's where the problem begins... as per what I've read in the docs, different discounts per line item are not allowed, it's only one discount that you can add (and you can indicate to apply it to "X" product, but not more than one discount applied to one product)

#

So, as we DO offer the possibility of appliying different discounts per line item, we just add the discount to the total value... but, now we have that 5th line item, that, I repeat, has NOT a Tax Rate... however, the discount application seems to alter the way you are calculating taxes, to taxes are not what they should be... let me show you:

#

cs_test_b1PjrpZkH0byuPMgXVQfLQIN42tu3nlqHtsWPTbRFKIpSznAa0UEYl841U

#

Taxes in this session should be USD 39.04, but you are applying, I don't know why, USD 39.15

#

So, look at the first example, the one WITHOUT discount:

  • Line items value (except the 5th with the fees): 449.97
  • Tax Rate rates of those line items: 9,08%
  • 449.97 * 0.0908 = 40.86
    => That's CORRECT, you are applying the Tax Rate for the first 4 line items and just ignoring the 5th for taxes calculation
#

Now, look at the second example, the one WITH a discount:

  • Line items value (except the 5th with the fees): 449.97
  • Minus USD 20 discount: 429.97
  • Tax Rate rates of those line items: 9,08%
  • 429.97 * 0.0908 = 39.04
    => You are showing 39.15 instead, that doesn't seem to be correct
lucid magnet
#

Ok thank you for the many details that's very helpful

#

Let me dig in to see if I can spot what the issue is exactly

stoic cobalt
#

Thank you, if you need any extra information, just tell me

lucid magnet
#

I think this is because of when we apply discount

#

I think it's applied to all line items prior to tax

#

not just to the taxed line items

stoic cobalt
#

So you are "dividing" those USD 20 of the coupon? I mean, you are discounting, for example, USD 4 of each line item?

#

Because that discount it not a percentage off, is "amount_off"

#

USD 20 amount off

stoic cobalt
lucid magnet
#

Hm yeah you're right

stoic cobalt
#

I really don't know how do you apply these "amount_off" discounts

#

When you have several line items

lucid magnet
#

Ok unfortunately we don't know too much about how these calculations are run behind the scenes, since we just mostly are API experts. I would recommend reaching out to support: https://support.stripe.com/contact/email and ask exactly how this calculation is being calculated in this specific instance. Someone over there would know more than us

#

You could copy and paste the info you laid out above in the support email. That should be enough detail to get it escalated properly

stoic cobalt
#

Ok! I'll reach them and send this information

#

Thank you for your help

lucid magnet
#

Sure thing. Sorry I didn't have more info on this

stoic cobalt
#

So, one last thing

lucid magnet
#

Go for it

stoic cobalt
#

At the beginning, I said: "as per what I've read in the docs, different discounts per line item are not allowed, it's only one discount that you can add (and you can indicate to apply it to "X" product, but not more than one discount applied to one product)"

#

Is that correct? It's still not possible to apply more than one discount to different products, when creating a Checkout Session?

lucid magnet
lofty stone
#

Hi, stepping in here. Let us know if you have any follow up questions.