elixir-maru / maru

Elixir RESTful Framework
https://maru.readme.io
BSD 3-Clause "New" or "Revised" License
1.32k stars 84 forks source link

add headers in desc support #48

Open Skipper1992 opened 7 years ago

falood commented 7 years ago

Thank you, it's a good idea! I think we can not just make header a part of description, we can make it works as the same as params, parse parameters from header and generate document. The DSL should be like this:

desc "this is description" 
header do
  requires :session_id, type: String
end
params do
  requires :param1, type: Integer
end
post do
  ...
end
jalcine commented 6 years ago

Hey @Skipper1992; are you considering incorporating the feedback above?

jalcine commented 6 years ago

It looks like this was slightly abandoned. If you're cool with it @falood, I can re-open a new PR for this.