vitrue/dzl — pull request #12 by rlipman (2012-04-25 20:40:46+00:00)
Title: API key header auth

Endpoints can now be protected with an API key. Include a ```protect``` block in your endpoint with the expected API key header (all lowercase and underscores instead of dashes), and an array of accepted keys.

Missing API key header, or an invalid API key on the protected endpoint will return 401 Not Authorized.

```ruby
endpoint '/api' do
protect do
api_key header: 'x_api_key', valid_keys: ['valid-key']
end
end
```