Exception: Drillbit::Errors::InvalidRequestBody

Inherits:
RuntimeError
  • Object
show all
Includes:
Erratum::Error
Defined in:
lib/drillbit/errors/invalid_request_body.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#request_bodyObject

Returns the value of attribute request_body.



10
11
12
# File 'lib/drillbit/errors/invalid_request_body.rb', line 10

def request_body
  @request_body
end

Instance Method Details

#detailObject



20
21
22
23
# File 'lib/drillbit/errors/invalid_request_body.rb', line 20

def detail
  'The information you attempted to send in the request cannot be parsed as ' \
  'a valid JSON document.'
end

#http_statusObject



12
13
14
# File 'lib/drillbit/errors/invalid_request_body.rb', line 12

def http_status
  400
end

#sourceObject



25
26
27
# File 'lib/drillbit/errors/invalid_request_body.rb', line 25

def source
  { request_body: request_body }
end

#titleObject



16
17
18
# File 'lib/drillbit/errors/invalid_request_body.rb', line 16

def title
  'Invalid Request Body'
end