Starting to merge autowire stuff with api