PHP front-controller and REST API framework