class Airbrake::Request

@since v3.2.0
@api public
@see Airbrake.notify_request
Request holds request data that powers route stats.

def cargo

def cargo
  'routes'
end

def destination

def destination
  'routes-stats'
end

def initialize(

def initialize(
  method:,
  route:,
  status_code:,
  timing: nil,
  time: Time.now
)
  @time_utc = TimeTruncate.utc_truncate_minutes(time)
  @method = method
  @route = route
  @status_code = status_code
  @timing = timing
  @time = time
end

def to_h

def to_h
  {
    'method' => method,
    'route' => route,
    'statusCode' => status_code,
    'time' => @time_utc,
  }.delete_if { |_key, val| val.nil? }
end