upgrades: various changes based on review feedback

The crux of this change is that the role of StateContext and
APIContext have been taken over by the base Context interface. This
also allows for a single step interface which allows for
simplifications throughout.