#gbarba
1 messages · Page 1 of 1 (latest)
Sure, can you share the in_xxx ID?
Looks like we're apply a credit from the balance of the associated customer, which is expected: https://stripe.com/docs/invoicing/customer/balance#working-with-credit-balances
Mmm so how could I manage this
Well if your desire is to charge the customer for the full amount of the invoice then you'll need to decrement their balance to 0: https://stripe.com/docs/invoicing/customer/balance?dashboard-or-api=api#modifying
No, you need to use this API: https://stripe.com/docs/api/customer_balance_transactions/create
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
So you'd create a new transaction for a minus amount to decrement the balance back to 0
Mmm but this only happens some times and I think is because the amount of the product I’m charging.. let me see the last link you sent me
I don't think so. If you look at the invoice in the Dashboard, you can see the credit balance applied offsetting the amount:
And this value comes from the customer at stripe isn’t it?
Yes, their customer balance as I shared before. That is where any credit for unused time is applied if/when cancelling a subscription, for example
But at the point I created the customer the balance was 0 from what I see in the events
Ok, I see an event where the balance was updated evt_1OR7BNLf6j9PT4hqxbwAEj6i
Yeah, when you created the Customer object they won't have had a balance. But between prorated upgrades/downgrades and cancellations, they can accrue a balance: https://dashboard.stripe.com/customers/cus_PFcQKPvw4dC8sT/balance_transactions
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
So in that example the invoice amount was beneath our minimum charge amount for IDR, so we apply it to the balance: https://stripe.com/docs/invoicing/customer/balance?dashboard-or-api=api#modifying:~:text=This happens when the amount due on an invoice is less than the minimum chargeable amount. This functionality only occurs for users without a cash balance.
So setting the balance always to -500 we will make sure we charge what we are asking for, isn’t it?
Well, no. Because then that will essentially act as a debit (i.e. they own you money) and will subsequently be charged on a following invoice
My main concern is why I am getting this balance update event evt_1OR7BNLf6j9PT4hqxbwAEj6i from where comes this…
Sy maybe is clear for you but I’m not getting this 😓
From your subscription you just created here: https://dashboard.stripe.com/logs/req_jrjWOcnF0bc6Mv
998.00 IDR Is beneath our minimum charge amount for that currency, so we are always going to debit the customer balance for 998 IDR to be paid on a future invoice
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Ok.. is always the minimum the same?
Yes, it's currency dependent: https://stripe.com/docs/currencies#minimum-and-maximum-charge-amounts
Where I can see the list of minimum charge amount per currency in stripe
Ok. Now is clear thanks!! One last thing, so now I’ve changed 0 because we are not able to charge less than the minimum.. so the next charge of the subscription will happens the same? Or we will charge the previous plus the current
Yes if you try to charge 998 IDR again it will debit the balance again because it's beneath the min. charge amount so we can't actually charge a card on file for that
From what I see in the upcoming invoice yes.. so as this is a 1 month subscription I guess on month 3 we will charge 0 and in month 4 we will charge again 998 x 2
Sounds right yep!
Thanks!!
If the user cancels the subscription before arrive to month 2 I guess we don’t change anything, we lost the money basically isn’t it?
Hey! Taking over for my colleague. Let me catch up.