#atul

1 messages · Page 1 of 1 (latest)

past turretBOT
lost sinew
#

hi, yes, you can't. You have to make two requests, one to create the Schedule with from_subscription and another to update that new Schedule.

cedar laurel
#

While updating it i getting error

#

GEtting error
You can not modify the start date of the current phase.

lost sinew
#

that is because you need to pass two phases when modifying a subscription like this.

#

you need to pass phases with two items, the first item has to match the current state of the subscription, and the second phase has to match the changes you want to make later. With a schedule you are "declaring" the state of the subscription, so you need to pass the 'current' phase when updating it.

cedar laurel
#

How can we match to current state ??

lost sinew
#

for example you pass start_date and end_date on the phase as the value of your subscription.current_period_start and subscription.current_period_end , and you pass the items using the same details are are in subscription.items.