Class: Raven::Transports::HTTP
- Defined in:
- lib/raven/transports/http.rb
Instance Attribute Summary
Attributes inherited from Transport
Instance Method Summary collapse
Methods inherited from Transport
Constructor Details
This class inherits a constructor from Raven::Transports::Transport
Instance Method Details
#send(auth_header, data, options = {}) ⇒ Object
12 13 14 15 16 17 18 19 |
# File 'lib/raven/transports/http.rb', line 12 def send(auth_header, data, = {}) response = conn.post '/api/store/' do |req| req.headers['Content-Type'] = [:content_type] req.headers['X-Sentry-Auth'] = auth_header req.body = data end raise Error.new("Error from Sentry server (#{response.status}): #{response.body}") unless response.status == 200 end |