cat controller for api refactorized
changes in api