]> git.openstreetmap.org Git - rails.git/blob - app/controllers/api/versions_controller.rb
Add support for an unversioned 'versions' API call
[rails.git] / app / controllers / api / versions_controller.rb
1 module Api
2   class VersionsController < ApiController
3     authorize_resource :class => false
4
5     around_action :api_call_handle_error, :api_call_timeout
6
7     # Show the list of available API versions. This will replace the global
8     # unversioned capabilities call in due course.
9     # Currently we only support deploying one version at a time, but this will
10     # hopefully change soon.
11     def show
12       @versions = [Settings.api_version]
13     end
14   end
15 end