Class: Rocksky::Resources::Stats

Inherits:
Base
  • Object
show all
Defined in:
lib/rocksky/resources/stats.rb

Overview

‘app.rocksky.stats.*` endpoints.

Instance Attribute Summary

Attributes inherited from Base

#http

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from Rocksky::Resources::Base

Instance Method Details

#get_stats(did:) ⇒ Object

Per-user stats.



6
7
8
# File 'lib/rocksky/resources/stats.rb', line 6

def get_stats(did:)
  query("app.rocksky.stats.getStats", did: did)
end

#get_wrapped(did:, year: nil) ⇒ Object

Year-in-review (“Wrapped”) data.



11
12
13
# File 'lib/rocksky/resources/stats.rb', line 11

def get_wrapped(did:, year: nil)
  query("app.rocksky.stats.getWrapped", did: did, year: year)
end