# File lib/fog/brightbox/storage/connection.rb, line 15
        def request(params, parse_json = true)
          begin
            raise ArgumentError if params.nil?
            request_params = params.merge(
              :headers => request_headers(params),
              :path => path_in_params(params)
            )
            response = @connection.request(request_params)
          rescue Excon::Errors::Unauthorized => error
            raise AuthenticationRequired.slurp(error)
          rescue Excon::Errors::NotFound => error
            raise Fog::Storage::Brightbox::NotFound.slurp(error)
          rescue Excon::Errors::HTTPStatusError => error
            raise error
          end

          if !response.body.empty? && parse_json && response.get_header("Content-Type") =~ %r{application/json}
            response.body = Fog::JSON.decode(response.body)
          end
          response
        end