Created
June 23, 2011 15:07
-
-
Save fnando/1042705 to your computer and use it in GitHub Desktop.
Rack API with catch-all route
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "rack/api" | |
Rack::API.app do | |
prefix "/" | |
get "users" do | |
[] | |
end | |
get "/api(/*catch_all)" do | |
{:message => "Not Found"} | |
end | |
end | |
run Rack::API |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment