Setup dependency for api controller
Updating controller + tests