spec/dummy/config/initializers/doorkeeper.rb in doorkeeper-0.3.4 vs spec/dummy/config/initializers/doorkeeper.rb in doorkeeper-0.4.0

- old
+ new

@@ -19,16 +19,23 @@ # # to call them on routes object eg. # # routes.new_admin_session_path # Admin.find_by_id(session[:admin_id]) || redirect_to(routes.new_admin_session_url) # end - authorization_scopes do - scope :public, :default => true, :description => "The public one" - scope :write, :description => "Updating information" - end - # Access token expiration time (default 2 hours) + # If you want to disable expiration, set this to nil. # access_token_expires_in 2.hours # Issue access tokens with refresh token (disabled by default) use_refresh_token + + # Define access token scopes for your provider + # For more information go to https://github.com/applicake/doorkeeper/wiki/Using-Scopes + default_scopes :public + optional_scopes :write, :update + + # Change the way client credentials are retrieved from the request object. + # By default it retrieves first from `HTTP_AUTHORIZATION` header and + # fallsback to `:client_id` and `:client_secret` from `params` object + # Check out the wiki for mor information on customization + # client_credentials :from_basic, :from_params end