#ben-invoice-pendingitems

1 messages · Page 1 of 1 (latest)

primal doveBOT
harsh grotto
#

hey there, apologies for the delay

#

taking a look

#

ok, and what items here are not expected?

#

What did you expect to see instead?

primal doveBOT
abstract trout
#

item_id si_OAMxvlh34hg6lO is not supposed to be in the response

#

The invoice was created with 3 items, a 4th item was automatically added to the invoice

zinc niche
#

Thanks for the info. Looking in to this.

zinc niche
#

Hey apologies for the delay. Server got busy so I'm still looking in to this. That item was created by a subscription update call that you made where proration_behavior was create_prorations which is expected to create invoice items to be added to the next invoice. If you don't want existing invoice items to be automatically added to the invoice, you need to set pending_invoice_item_behavior to exclude https://stripe.com/docs/api/invoices/create#create_invoice-pending_invoice_items_behavior

#

I think the fundamental thing to address is that you are creating these invoice items before creating the invoice but also may have pending invoice items from prorations. One solution would be switching to creating the invoice first and then specifying that invoice Id when creating the invoice items after

#

I feel like there may be a way to handle this if you stick to creating the invoice items first but am not immediately sure what that would be. I can look in to that if you are interested

primal doveBOT