I’ve been going through the API for a project I’m working on and can’t figure out a good way to reduce a goal’s safety buffer programatically.
Once the safety buffer reaches a certain threshold, I would like to lower it to an established minimum. Are there any examples out there or established ways of doing this?
roadall is an array of (date, value, rate) triples, meaning "on date X, the value for the road was Y, and changing at rate Z from then on.) So you’ll need to do a fair bit of calculation to figure out how to munge it in order to leave you with the exact amount of safety buffer you want, but it’s not impossible.
Unfortunately, while you can replicate it this way, there isn’t (to the best of my knowledge) an API that directly just retroratchets a goal. I doubt, however, that as @matti says it’s because this is a feature reserved for certain premium plans: the road editor is also reserved for the same premium plans, and the API has features to directly replicate what the road editor can do.