Adding app API routes and CORS config.