lib/paypal/report.rb
def daily(time = Date.today, page_size = 50)
      time      = time.strftime("%Y-%m-%d") unless time.is_a?(String)
      report_id = run_report_request('DailyActivityReport', {'report_date' => time}, page_size)

      meta_data = get_meta_data_request(report_id)

      data = []
      meta_data["numberOfPages"].to_i.times do |page_num|
        data += get_data_request(report_id, page_num + 1) #it's zero indexed
      end
      data
    end
def daily(time = Date.today, page_size = 50)
      time      = time.strftime("%Y-%m-%d") unless time.is_a?(String)
      report_id = run_report_request('DailyActivityReport', {'report_date' => time}, page_size)

      meta_data = get_meta_data_request(report_id)

      data = []
      meta_data["numberOfPages"].to_i.times do |page_num|
        data += get_data_request(report_id, page_num + 1) #it's zero indexed
      end
      data
    end
high level functions