#nick-subscription-schedule

1 messages · Page 1 of 1 (latest)

sleek lion
#

Yes, you do always need to send the current phase. And yes mirroring back the values to make no changes.

#

When updating a subscription schedule, you need to pass in all current and future phases that you want to keep.

bitter zinc
#

Cool, so in that case, I run

stripe subscription_schedules update sub_sched_1JYAClI67GP2qpb4I7lj4E5F --end-behavior=release --proration-behavior=none -d "phases[0][items][0][price]"=price_1J3ifkI67GP2qpb4nkmaC8Hu -d "phases[0][items][0][quantity]"=0 -d "phases[0][end_date]"=1631246400 -d "phases[0][start_date]"=1630627200  -d "phases[1][items][0][price]"=price_1J3ifkI67GP2qpb4nkmaC8Hu -d "phases[1][items][0][quantity]"=0 -d "phases[1][end_date]"=1631246400 -d "phases[1][start_date]"=1633060800 -d "phases[1][billing_cycle_anchor]"=phase_start
{
  "error": {
    "message": "`start_date` must be less than each phase's `end_date` or its derived end date based on `iterations` and `plans`.",
    "type": "invalid_request_error"
  }
}
#

Can you tell me why that is? Trying to change the start_date of phases[1] to be the first of the oct, and the end date of phases[0] is before that. Is it because there is a "gap" between the end date of phases[0] and the start_date of phases[1]?

sleek lion
#

looking, just a bit hard to parse the curl

#

oh

#

youve got the start and end of phase [1] out of order

#

start > end, which isnt allowed

#

looks like maybe you flipped them?