lib/datarank/volume.rb in datarank-1.3.0 vs lib/datarank/volume.rb in datarank-1.4.0

- old
+ new

@@ -2,14 +2,63 @@ class Client # Module containing methods for interacting with topics module Volume - # Return volume for a topic grouped by day - # + # Return volume for a topic grouped by a time interval + # # @param slug [String] A topic's unique identifier slug + def volume_secondly(slug, options={}) + get "/topics/#{slug}/volume/secondly", options + end + + def volume_minutely(slug, options={}) + get "/topics/#{slug}/volume/minutely", options + end + + def volume_hourly(slug, options={}) + get "/topics/#{slug}/volume/hourly", options + end + def volume_daily(slug, options={}) get "/topics/#{slug}/volume/daily", options + end + + def volume_weekly(slug, options={}) + get "/topics/#{slug}/volume/weekly", options + end + + def volume_monthly(slug, options={}) + get "/topics/#{slug}/volume/monthly", options + end + + def volume_quarterly(slug, options={}) + get "/topics/#{slug}/volume/quarterly", options + end + + def volume_yearly(slug, options={}) + get "/topics/#{slug}/volume/yearly", options + end + + # Return hourly average volume for a topic + # + # @param slug [String] A topic's unique identifier slug + def volume_hourly_average(slug, options={}) + get "/topics/#{slug}/volume/hourly/average", options + end + + # Return day-of-week volume for a topic + # + # @param slug [String] A topic's unique identifier slug + def volume_weekday(slug, options={}) + get "/topics/#{slug}/volume/weekday", options + end + + # Return hourly day-of-week heatmap information for a topic + # + # @param slug [String] A topic's unique identifier slug + def volume_weekday_heatmap_hourly(slug, options={}) + get "/topics/#{slug}/volume/weekday/heatmap/hourly", options end end end \ No newline at end of file