Module: SendGrid4r::REST::Stats::Global
Overview
SendGrid Web API v3 Stats - Global
Constant Summary
Constants included from Request
Instance Method Summary collapse
Methods included from Request
#create_args, #delete, #execute, #finish, #get, #patch, #post, #process_array_params, #process_url_params, #put
Instance Method Details
#get_global_stats(start_date:, end_date: nil, aggregated_by: nil, &block) ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/sendgrid4r/rest/stats/global.rb', line 11 def get_global_stats( start_date:, end_date: nil, aggregated_by: nil, &block ) params = { start_date: start_date, end_date: end_date, aggregated_by: aggregated_by } resp = get(@auth, "#{BASE_URL}/stats", params, &block) finish(resp, @raw_resp) { |r| Stats.create_top_stats(r) } end |