fix up some of the more complex api calls