moved app to api class I think it reads better