def get_csv(*args)
      payload = get!(*args)

      if payload.response.code != '200'
        raise BadResponse, "#{payload.response.code} #{payload.response.msg}"
      end

      response = payload.parsed_response

      unless response.is_a? Hash
        raise BadResponse, "Cannot parse response"
      end
      
      data = csv_node response

      header = data.first.keys
      result = CSV.generate do |csv|
        csv << header
        data.each { |row| csv << row.values }
      end

      result
    end
def get_csv(*args)
      payload = get!(*args)

      if payload.response.code != '200'
        raise BadResponse, "#{payload.response.code} #{payload.response.msg}"
      end

      response = payload.parsed_response

      unless response.is_a? Hash
        raise BadResponse, "Cannot parse response"
      end
      
      data = csv_node response

      header = data.first.keys
      result = CSV.generate do |csv|
        csv << header
        data.each { |row| csv << row.values }
      end

      result
    end
This method uses {#get!} to download and parse the content. It then
 makes the best effort to convert the right part of the data to a
 CSV string.

 You can override this method if you wish to provide a different
 behavior.