Padrino app with REST API
问题 Within a Padrino application I have a posts controller with the conventional routes: Blog::App.controllers :posts do get :index do ... end get :show, :with => :id do ... end end This gives me therefore the normal URL access within the posts namespace http://blog.dev/posts http://blog.dev/posts/show/1 Now I want to provide access through a REST API from a different route outside the namespace , like for example: http://blog.dev/api/v1/post/all http://blog.dev/api/v1/post/1 How can I define the