Flexirest: Required parameters

March 19, 2018 ยท View on GitHub

If you want to specify that certain parameters are required for a specific call, you can specify them like:

class Person < Flexirest::Base
  get :all, '/people', :requires => [:active]
end

@people = Person.all # raises Flexirest::MissingParametersException
@people = Person.all(active:false)

< Root elements | Updating only changed/dirty attributes >