#jm199seo-subscriptions

1 messages · Page 1 of 1 (latest)

teal nest
#

@flint marsh hmm well usually you keep the item but change the Price on it.

#

it's something people commonly miss(passing the id of the existing item).

#

not sure I completely follow your question. Are you maybe just asking how to only remove/replace the item at the end of the current billing cycle or something?

flint marsh
#

what i experienced when I passed the id was that the usage transferred over to the new price, which is not applicable for my situation.
I'm trying to preserve the old price with the old usages + new price with new usages for 1 billing cycle and then remove the old price from the subscription after customer payment/invoice.

teal nest
#

ah ok

#

then yes you are wanting to remove the old price at the end of the period. There's no straightforward way to do it unfortunately! The options are basically:

flint marsh
#

would a better solution be creating a new subscription and canceling the old subscription at the end of the billing cycle? or do you suggest keeping the subscription and just modifying the items inside it?

#
  • call the API again at the start of the next billing cycle(you can listen to the invoice.created webhook event, or customer.subscription.updated to detect that) and remove the other item
    I think this can be handled by voiding any subscription items without lookup_keys after a webhook event