#ben-clum_api

1 messages ¡ Page 1 of 1 (latest)

gentle copperBOT
#

👋 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/1225076908837048320

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

supple tideBOT
spiral moth
ocean steeple
#

are you asking me to try that? or if I used it?

spiral moth
#

If you've not tried it then I'd recommend giving it a go. I have a theory but testing would likely confirm what I am thinking

ocean steeple
#

kk checking!

#

oh I just realized upcoming invoice API does not have a application_fee_percent. only the application_fee_amount.

#

I don't see why it wouldn't use that

#

actually no it doesn't even have that for the endpoit

spiral moth
#

Ah sorry, should've been more clear. My theory is that we don't apply the newly updated application fee percent on the proration invoice. We'd likely use that for the next recurring invoice.

Since you've updated the subscription already, I was hoping if you could check the next recurring invoice and see if the correct application fee was reflected there

ocean steeple
#

I just tried setting application_fee_perent on the subscription, and then used the upcoming_invoice API and the application_fee_amount is null. so looks like it's not pulling it.

#
  1. set the application_fee_percent on the subscription to 11.2
  2. called the upcoming invoice API
  3. application_fee_amount was null on the invoice.

so yeah you're theory is correct

spiral moth
#

I don't think my theory is correct though yeah? Since you're not seeing the application fee being reflected?

ocean steeple
#

oh I tried something else:

  1. set the application_fee_percent to 11.2
  2. changed the payment plan in a separate API call
  3. the application_fee_amount is set, but it's using the OLD 11.2 percentage, not the new percentage
#

so it seems like it doesn't use the new percentage if you update them both in the same API call

spiral moth
#

old application fee was 11.37?

ocean steeple
spiral moth
#

Let me see if I can reproduce this

#

I'll check with a colleague too

ocean steeple
supple tideBOT
latent crescent
#

It looks like there actually was an application fee. If you look at the payment intent pi_2P1UIf250JCmBXjU1LAf6QLH, there is an application_fee_amount of 7857

ocean steeple
#

I"m not sure which example you're looking at, but both of the most recent examples do not have fees

#

I don't think you're looking at the right example

#

yeah I confirmed you're looking ath the wrong example.

latent crescent
#

Was working off of a colleagues notes req_4LNZ0Il74CDNCJ made sub_0P1TsN250JCmBXjUBWyNqtHM which created in turn created in_0P1UIf250JCmBXjUwipol8le with pi_2P1UIf250JCmBXjU1LAf6QLH which does have an application fee amount set. I do see that the more recent example from req_ijBaMLuj4j7IHV does not. Looking in to that with my colleagues

#

The objects from the later example for reference
req_ijBaMLuj4j7IHV -> sub_0P1UM6250JCmBXjUM65Hjvtr -> in_0P1UMu250JCmBXjUKBtKolbc -> pi_2P1UMu250JCmBXjU0PQUTnIg

ocean steeple
#

kk let me know what you find

latent crescent
#

FYI still looking in to this. This behavior is turning out to be difficult to parse out

ocean steeple
#

let me know if you need anything else, like maybe clear steps to reproduce

#
  1. create subscription
  2. set application_fee_percent to 0
  3. update subscription with a new payment plan and set the application_fee_percent to anything other than 0 (e.g. 11%) in the same API call.
  4. the subsequent invoice created does not have a application_fee_amount.

this was also attempted:

  1. create subscription
  2. set application_fee_percent to 1%
  3. update subscription with a new payment plan and set the application_fee_percent to anything other than 0% or 1% (e.g. 11%) in the same API call.
  4. the subsequent invoice created does not have a application_fee_amount.
latent crescent
#

@ocean steeple it turns out there is a configuration that prevents application fees from being applied to "one off" invoices. Which it sounds like these proration invoices count as, probably because they are made up of only invoice items.
So if you talk to our support team, they should be able to help remove that configuration from your account. https://support.stripe.com/?contact=true